SharkShout II Manual
What is SharkShout II?
SharkShout II is the iPhone version of the original SharkShout Apple Watch App. The SharkShout family of apps helps you communicate with others while SCUBA diving.
Implied Consent
By using the SharkShout II iPhone application program (the “App”), you acknowledge that you have read and understood, and that you agree and consent to be bound by, the contents of the SharkShout II Privacy Policy; you also agree and consent to be bound by the terms described in the section entitled “Disclaimer and Hold Harmless” below in this document; you certify that you understand that the App is experimental in nature; and you certify that you understand that the App is not a “Dive Computer”.
Things to do before using SharkShout II
You must do two things before you can start using SharkShout II.
1. Upon first App launch, you will be asked for permission to use Location Services and the Microphone.
2. You need to obtain a waterproof pouch / case rated for the depth that you will be diving to.
Permissions needed for true-heading magnetic variation correction and acoustic modem reception. Waterproofing pouch as available from online retailers.
Crude (continent-level) location is needed to calculate magnetic variation for the True heading display; microphone input is needed to receive audio messages. If you opt out of these, SharkShout’s related functions will be degraded accordingly: Your True heading might not be accurate, and receiving audio-encoded messages will not work (a symptom of this to look for is a perpetual “MIC |-” indication on the top status bar).
Preferably your waterproof pouch will allow you to use the iPhone’s capacitive touch screen. If not, there is an alternative “shake” way to use the user interface. We describe it in more detail below, but to summarize: grasp the bottom of the iPhone and firmly jerk to the left or right to move an orange highlight cursor; then firmly jerk down to select the currently-highlighted button.
SharkShout II Screen Controls
The illustrations below show the functions of the various Screen buttons and displays. Some buttons will take you to separate screens, most of which return to the Main Screen.
The Keyboard Pane on the Main Screen toggles between a board of pre-created messages or a QWERTY keyboard.
Functions of the Main Screen. The Dive Signals Keyboard Pane is shown. Most screens return to this screen.
Pressing the same key multiple times on the Dive Signals Keyboard calls up variations — usually oppositional — of the same message.
The Main Screen with the Freeform Keyboard Pane selected.
How the Marquee (a visual text banner) appears in order to message a Dive Buddy.
Functions of the Preferences Screen. It has an “Info” screen, which can be thought of as its sub-screen.
The Info Screen. The App Absolute Version is expressed as both a decimal quantity and a 6-character pronounceable but nonsense generated word that is designed for easy human checking.
Functions of the Erase Screen. The operations immediately return to the Main Screen.
The Alarm Confirm and Alarm Active Screens. When the Alarm is active, the large triangle flashes, and a repeated SOS morse code tone pattern is played using EBS tone notes.
How to use SharkShout II without using the Touch Screen
You might not be able to find a waterproof case or pouch that allows operation of the touch screen underwater. The touch screen works by sending small AC voltages out of a grid and expecting a finger to form a capacitive path to ground at a particular location, but the problem is that the entire sea is conductive, so there’s no distinguishing one touch location from another. We have seen some partial insulating cases that somewhat-work, but not very well.
Therefore, we’ve developed an alternative:
1. You “push” buttons by moving an orange circular cursor across various locations until you get to the place you want, and then selecting the button at that place. Start by holding the iPhone by its bottom half.
2. Make the cursor show up — and move it — by shaking the iPhone right or left, or by pressing the volume up or down buttons; the volume buttons work for this once you’ve started doing the shaking thing.
3. You do your selection by thrusting the iPhone in a downward direction.
How to use SharkShout II without using the Touch Screen. Both the accelerometers and the volume control buttons are used by the software.
TIP: Remember to press “Send” after you’ve selected your message. Of course, YES, NO, REPEAT, and ALARM will go immediately.
TIP: On the Dive Signals Screen, after picking a message (remember to thrust down!), it will move to Send automatically if you wait a moment.
TIP: On the Dive Signals screen, remember that each thrust down on a particular icon will pick a new variant of that message.
TIP: Think of the motion as more of a smooth rotation rather than a jerk. Hold the iPhone from the bottom.
Overview of SharkShout II
Using a suitable waterproof pouch or case, you take your iPhone diving with you. Depending on whether your case allows use of your iPhone’s capacitive touch screen, you either use tap on buttons directly or use an alternative “shake” gestural interface to move a cursor over the buttons.
When you wish to send a message, you select common PADI dive signals or compose custom texts, and present your iPhone to your fellow diver(s), who can then read your message from a large scrolling display.
Additionally, SharkShout contains an experimental feature for underwater texting (note that WiFi/cellular/BlueTooth doesn’t work underwater). Your message is turned into sounds, which another nearby iPhone or Apple Watch also running SharkShout might be able to “hear” and display, especially if amplified using some simple hardware. Alternatively, you can have the text be spoken via text-to-speech.
A compass display provides your heading. In addition to the big moving rose and big magnetic heading number, two smaller numbers show your back-course magnetic heading (that is, your 180 degree turn-around heading at every moment) and well as your current true heading (corrected for magnetic variation depending on your location). The color codes on the cardinal headings are red for north (which is standard), blue for south (also standard), green for east (think: green = “start” or “beginning” (of day)), and yellow for west (think: yellow = “sunset”).
An acceleration display provides a sense of history of your motions. Accelerations in X,Y,Z (where X-forward is device-forward while holding the iPhone in portrait mode) are corrected for iPhone attitude and are integrated for velocity, and then integrated again for “position”, which is recorded every few seconds on the graph. The timer in the upper right corner shows the amount of time for which the graph has been accumulating; it resets when you reset the graph. You can reset the graph using one of the buttons in the Erase screen. This display is presented as a novelty only; it is not a cartographic map.
SharkShout II Tutorial
The following video demonstrates basic usage of the SharkShout II iPhone app as well as its interoperability with the SharkShout Watch app. Of note, it shows how to present the iPhone to your dive buddy to make the Marquee screen appear as well as how to use the Shake input for the user interface.
SharkShout Messages are Readable by Anyone
Messages that you send using SharkShout are broadcast; they are like things you say in public.
The messages as transmitted by the audio tones are not cryptographically scrambled — although they are encoded using a simple entropy and dictionary compression scheme, and may be sent using one of 2 semi-independent sets of tone frequencies (“channels”). The audio form of the messages are “broadcast” (or “party line”) in dispersal scope, and — although unlikely due to the highly experimental and technically difficult nature of underwater wireless communication — your message could theoretically be received by another party running the App or other compatible software.
In addition, the visible Marquee form of the messages can be seen by anyone who is in a position to view your iPhone.
There is explicitly no design nor expectation of privacy whatsoever in messages sent using the App. Indeed, a lack of privacy (that is, making your message manifest to as many as possible) is an explicit (safety) feature of, and reason for using, the App.
The Conversation, as stored in app memory, is also not encrypted. While not expected to be accessible by other apps, per standard Apple iOS inter-process security, this cannot be guaranteed by the App Developer. After 200 messages they will have scrolled beyond the top and they will then deleted, or they will all be deleted if you force-quit the App, uninstall the App, or reboot or reset your iPhone.
The Apple Watch and iPhone versions of SharkShout’s audio communications tone protocols are compatible: Messages can be sent between other iPhones or Watches running SharkShout; just be sure that you are on the same Channel. Due to the difficulty of underwater communication, you will want to set the iPhone and Watch volumes to maximum, and, with regard to the Watch, an external piece of hardware might unfortunately be required. We have been successful in achieving 30 feet between Watches using an inductive coupler picking up the Watch’s speaker output, connected to a 5W audio amplifier and an underwater transducer.
Your user identity, which is displayed on the Marquee and transmitted as part of the audio, is not your actual name; instead, it is one of 8 (7 names plus DiveMaster) fixed, ad-hoc, nicknames chosen by you in the SharkShout settings screen.
About the SharkShout Acoustic Modem
The Acoustic transmittal of messages and the facility to receive them (which constitutes a “codec” or “modem”) is a highly experimental feature of SharkShout II (and the compatible SharkShout Apple Watch app).
Messages are first compressed using a simple entropy and dictionary technique: More commonly-used (in English) letters are encoded using fewer bits than less commonly-used ones, and indeed this pattern extends even to short ubiquitous combinations of letter pairs or even short words or stems. In fact, entire dive messages can have their own compressor codes.
For example, the letter “E” is encoded using only 4 bits, which is much less that the usual 8 bits used to represent a letter. The Space uses only 2 bits. A very small handful of common letters use 7 or fewer bits, but most use 8 bits; however, many common English words like “THE” and “WITH” are also able to use 8 bits — for the entire word. Dive messages use 8 to 16 bits. In this way, compression ratios often exceed 50%.
The compressed messages are then encapsulated into packets with a 3-bit sender ID (encoding a 0~7 value for 8 different avatars) and a 4-bit checksum, followed by a variable number of payload message bits. There is no explicit length indicator in the packet header. There is a unique start-of-packet tone. End-of-packet is indicated with a special code described below.
Encoding then proceeds into one of 5 opcodes: 4 are used to represent the encodings for 2 bits-at-a-time, plus a 5th code to encode the end-of-packet event.
The 5 opcodes are used to direct a 6-state (6-symbol) clocking rotator, where the advancement-stride, each time, of the rotator is what encodes the data. With each newly-transmitted symbol “frame“, the symbol must differ: Valid (or, more precisely, optimal) data never “has” two or more of the same symbols consecutively; this behavior is necessary for the receiver to be able to distinguish one symbol from another (known as “clock recovery”).
The symbol stream drives a frequency-shift-keying (FSK) 3-tone chord generator. Two of the three tone sets consist of two notes, while one of the tone sets consists of three notes. The waveform of each note has a ramp up/down envelope to avoid high frequency components caused by clicks, plus chirping to provide some frequency diversity against destructive interference cancellation against echoing off walls, water surfaces, etc. Each chord is played several times, trading speed for robustness.
Two of the tone sets in the chord are used in a (2-note as row; 3-note as column) fashion similar to DTMF, yielding the 6 possible symbols, with the note of the remaining (2-note) set being used as a parity check (this provides robustness in addition to the higher-level data-packet checksum).
The sequence of chords is played at maximum volume out of the device (transmitter)’s speaker, traveling through air or water, to another nearly device (receiver)’s microphone.
The receiver records audio continuously. Every 10 ms, it takes a chunk of audio data and analyzes it.
The chunks of audio data are first modified with an automatic gain control (AGC).
We then apply several discrete Fourier transforms (one for each note to detect, with pre-computed sine waves and an error-diffusion 90-degree indexing offset for cosine). This yields a score for each.
Next we use threshold and minimum-uniqueness decisions to sanitize the scores. This allows us to recover note membership estimates in all of the chords (note triplets). If no clear winner can be found, this frame is disregarded.
A note-decoding matrix plus a reversal of the 3rd-note parity check is used to decide, from the tone triplet scores, which symbol is most likely being received. In this way, the symbol stream is recovered. If we can’t decide, or if we find that the parity doesn’t match, this frame is disregarded.
The symbol stream is passed through a majority function to add robustness against multi-path. That is, several iterations of symbol recovery are collected, and they are then used to vote for a most likely candidate. If no clear winner can be found, this frame is disregarded.
The symbol stream is de-rotated to recover the clock (separation points) and therefore usage stream. This thus recovers a stream of discrete opcodes.
The stream of opcodes is interpreted to recover the (2-bit at a time) bit stream, as well as the end-of-packet event when it comes.
If we are in the middle of having started a packet, but it’s taking too long for the end-of-packet event to occur, the entire packet is disregarded and we start waiting for packet-start again.
At end-of-packet time, the bit stream is picked out and de-checksummed. This recovers whether the packet was good-vs-garbled, the sender’s 3-bit (0~7) avatar ID, and the sender’s payload message bits. If the packet was garbled (checksum mismatch), the client will disregard it.
Finally, the message bits are decompressed to recover the text stream. This, too, has some error checking and disregard capabilities, but they’re very limited.
The receiver’s note detectors do not distinguish between silence vs note1 vs note2 or silence vs note1 vs note2 vs note3; they merely distinguish between one of their two or three note inputs. This is one reason we decided to add the parity note.
There are 2 channels (of the above tones); the sender and receiver must be on the same channel.
Documentation Inaccuracies
The information in this document is believed to be correct. However, by the combined acts of reading this document and using the SharkShout II iPhone application program, you agree to hold the authors of the SharkShout II iPhone application program harmless for any errors or omissions.
Disclaimer and Hold Harmless
By using the SharkShout II iPhone application program, you acknowledge that any water sport or activity, including but not limited to, power boating, row boating, touring, scientific research, sport fishing, spear fishing, commercial fishing, abalone or other seafood diving, jet skiing, sailing, surfing, windsurfing, kayaking, paddle boarding, kite surfing, high diving, SCUBA diving, “SNUBA” diving, any kind of free diving, technical or any kind of utility, law enforcement, rescue, or commercial diving, cave or any kind of overhead environment diving, snorkeling, or swimming is inherently dangerous and may lead to serious injury or death. You acknowledge that all functions of the App are highly experimental in nature, and might not perform as expected. You acknowledge that the Apple iPhone, even when encased in a proper waterproof and/or diving enclosure, is not necessarily considered a true diving device, and may not perform as expected. You understand that any failure of your iPhone enclosure while submerged will destroy your iPhone and void its warranty. By using SharkShout II, you agree to hold harmless Ben A. Koning, Johan H. Koning, Shelly N. Koning, Redwines Garage, its principals, employees, contractors, associates, vendors, service providers, investors, and assigns, for any direct or incidental damages to yourself or others, including but not limited to death, injury, illness, lost wages, lost opportunities, property damage, emotional distress, or disappointment with respect to any expectations.
By using the App, you acknowledge that the App is not “Dive Computer”, as colloquially known, nor is it intended to be used in lieu of the functions of a “Dive Computer”, despite the fact that it might display, for purposes of convenience only, some information, such as the current compass heading and dive time, which an actual “Dive Computer” might also display. The App provides no nitrogen load and no breathing gas supply management functions.