DIY Boat Monitoring System
l-36.com
l-36.com
So, the novel idea is this, a bunch of kids from MIT or CalTech or where ever decide to bug yachts. They get unassuming jobs as deckhands and stewards to give themselves time to install devices like this DIY boat monitoring system along with microphones behind all the panelling around the yachts which are owned by CEOs of major companies. More or less, the device caches all the audio recordings and waits for the ship to enter a marina where it connects to wifi and sends the information home. They are looking for stock trading information, mostly. They are in the Caribbean maybe in St. Martin and overhear some nasty things by the Russian mafia. Someone made a mistake and they get caught. That's the beginning. The rest of the novel is a bunch of nerdy kids having to MacGyver their way out of the Caribbean while being chased by the most powerful and dangerous people on Earth.
> "144192 5/4/2021 Yacht Looking for 8 day workers to wash and detail yacht on Monday May 10th. 8 hours. FT LAUDERDALE"
That job probably pays $15 - $20 an hour cash under the table and the chef will make them all lunch. Not a bad gig job. 8 day workers? That's a lot, they wouldn't need that many people for 120 foot yacht[1]. The price of that yacht probably starts at something like $18,000,000. It would be a nothing burger to install anything on that boat with nobody noticing.
[0] https://www.daywork123.com/JobAnnouncementList.aspx
[1] https://www.denisonyachtsales.com/yachts-for-sale/?brand=&mi...
You might even be able to hide it in the VoiP phone on his desk and steal both power and network.
1. Guy allowed to come in and check our microwave for 'radiation leakage'. May have been a simple money scam but obviously a way to listen to staff conversations.
2. Casual cleaners employed to sanitise desk phones .. after a scare saying that's where a lot of bacteria collects. I noticed these cleaners being way too slow and too likely to let their gaze linger on computer screens. They didn't last.
He hid out in a conference room and had unfettered access to the office all night, he left behind a network device plugged in to a spare network jack behind a printer.
Granted anyone that has the time and money to actually learn how to sail the things is likely not in a position where boat heists have a great risk/reward.
> The group’s modus operandi involved renting a yacht from a charter company with different passports in each case, paying all costs in cash, and then taking out the automatic identification system of the yacht and putting it in a remote control toy boat to make the renters think that the yacht was adrift in territorial waters. Meanwhile, the stolen yacht had already reached international waters.
* http://theislander.net/member-of-yacht-robbery-group-arreste...
Of course fencing a boat can be difficult, but I'm guessing they probably break it up for parts (engine, electronics, galley/kitchen, etc).
You can't haul out and tow away a giant boat like that without involving a lot of people (marina travelift, trucking company with wide load permits) so that's out.
You could try sailing it away but with a top speed not much over 10mph, it'll be the lowest speed chase ever.
A boat was stolen from a charter company in SF bay some years ago. I think they got about a day head start, but even so it's not like they got very far.
---
Plot: A bunch of kids from MIT or CalTech or where ever decide to bug yachts. They get unassuming jobs as deckhands and stewards to give themselves time to install devices like this DIY boat monitoring system along with microphones behind all the panelling around the yachts which are owned by CEOs of major companies. More or less, the device caches all the audio recordings and waits for the ship to enter a marina where it connects to wifi and sends the information home. They are looking for stock trading information, mostly. They are in the Caribbean maybe in St. Martin and overhear some nasty things by the Russian mafia. Someone made a mistake and they get caught. That's the beginning. The rest of the novel is a bunch of nerdy kids having to MacGyver their way out of the Caribbean while being chased by the most powerful and dangerous people on Earth.
Chapter 1: ____ is on a yachting trip in the Caribbean. He gets a message from his friends on shore telling him they've been caught and are on the run. He has to decide whether to try and help his friends or try and get off the boat and call the authorities.
Chapter 2: ____ decides to help his friends. He needs a weapon, so he builds a crossbow from materials he finds on the boat, and he needs to learn how to use the weapon. He also needs to know how to defend himself in hand-to-hand combat, so he takes some of his friends' martial arts training. To learn how to use the crossbow, he goes to a nearby island where he has to steal or purchase a target.
Chapter 3: ____ steals a target from a competitor. He then goes back to the yacht and practices using the crossbow on the target.
Chapter 4: ____ goes to a nearby island to look for a drink to help him stave off seasickness. While there, he meets a young girl named ____ who is a pickpocket. She also teaches him some thieving skills.
Chapter 5: ____ returns to the yacht. He needs to make a plan for the next day. The yacht is going to be in a marina to drop off the CEO of a company who is on the yacht and ____ needs to decide what he's going to do with the microphone. He also has to spend some time learning to use the microphone in case he decides he wants to stay on board.
Chapter 6: ____ decides he is going to stay on board. He spends the next day learning how to use the microphone and listening to the CEO of the company. The CEO gets a call from the Russian mafia, who are threatening to kill his family unless he gives them the company. The CEO gives them the company. ____ decides to stay on board after overhearing this conversation.
Chapter 7: ____ has to make a plan for the rest of the trip. He needs to decide when he's going to connect the microphone to the wifi so the information gets sent home. He decides to wait until they are docked in a marina. In the meantime, he has to continue learning how to use the microphone and the crossbow.
Epilogue: The whole point of the book is to show how these kids had lives that could have been, but chose to work for the government instead. I don't know. The ending was not at all satisfying.
And there's a guide to using our open source software-only option on a Pi:
https://medium.com/@floathub/open-source-boat-monitoring-7ea...
Contacting the author of the parent version now to compare notes :-)
The power draw from our dedicated device (https://floathub.com/store) is much lower than a Pi, but you don't get the advantage of a general purpose computer that can run other stuff at the same time.
Some great projects are easily achievable from Arduino. It seems to be slightly looked down on as a platform, but I’m not skilled enough to know why. It has an IDE and a language that’s easy enough to use. There is also a huge community and a mass of projects out there. ESPHome is another excellent project which takes the coding down to just yaml config files and then you can makes automations one Home Assistant.
take a look in some of the subsections here: https://www.pololu.com/category/131/step-down-voltage-regula...
Given the cost of the system and chance for failure I think it would make sense to either add a second system or enable some sort of automatic override (possibly via mechanical float switch wired directly to large pump and set at a higher water level than the other two switches)
So that there will be enough time between a potential large leak occuring and detection of controller failure(via lack of daily email) to prevent it from sinking the boat.
>The monitor knows if I take the boat out when I turn on the main boat power and switches the small pump to auto and otherwise stops monitoring. But when the main power is back on, the pump will initially run every half hour and then every hour and then after about a day it will only be running once a day"
Though reading closer there are only two relays, and the author talks about controlling both the small pump and the fan with relays, and there is language around the large pump that while isn't conclusive, may indicate it is indeed on a separate float switch and system and the ESP32 is only involved in the monitoring of it.
> I have a large pump that only goes off if the small pump fails or the boat is trying to sink. If the float switch lifts, the monitor wakes up and sends an email alerting me.
The PLC sends me a mail each morning with how much water it used, the max temperature of the water pump(I repurposed a RV water pump with a PID PWM + SSR driven from the PLC) all running from a 24v solar system. They're very much designed to be in-the-loop on systems that need to be robust with pretty extensive error report/alarms and the like.
It would probably be beneficial to monitor the status of the control outputs, to see if they actually agree with the inputs.
Also, of course the microcontroller and its code are points of failure like you say.
I am not sure if I specifically mentioned it in the article but this is a wood boat and it leaks. The pump will run about 25 seconds a day to remove the day's water. I have the sequence after running the engine because a hard sail can cause the leaking to increase until things swell back up.
There have also been several changes to make the monitor more robust since I wrote the article. One main one is that a lot of the sample code on the web for email monitoring has "while" loops. These need to have counters to exit if the WiFi is down for example.
I used to get various telemetry read outs via email in the mornings and while they are nice they still require me to remember to read an email and more importantly to notice that an email is missing. A more positive feedback system is more secure: send me an alarm notification when something is wrong the one day a year that it is, not 364 notifications a year that everything is right.
You could set up a monitoring system for the monitoring system...
Checking from outside is not ideal though as a network outage looks the same as a sinking, a leak or any other problem.
I'm considering this for a home automation system: a smaller, simpler device connected to the network, powered via battery (recharged from mains but surge protected) aka UPS, and able to send SMS messages via mobile network.
The idea is it's a heartbeat/monitoring system for the essentials:
- power cut/outage - network down/outage - main server down, or has some problem
Then I can get an SMS telling me something's wrong.
[0]: http://www.lilygo.cn/prod_view.aspx?TypeId=50044&Id=1127&FId...
Good thing about email is that it can be dismissed. It literally goes into an inbox where you are already looking at other things that need your attention - and then you can delete/archive when you see that everything is fine.
https://www.segeln-forum.de/board194-boot-technik/board195-o...
You'd need your own 'friendly' email server that is expecting traffic from that specific IoT device, allowing outbound relay through it. One of the challenges of doing outbound SMTP from randomly located IoT devices is that due to weirdness of cellular or other uplinks, it might appear from a wide range of IPs.
Normally if I have some old weird monitoring device on a network that needs to send unauthenticated SMTP outbound for alerting, I can give postfix an ACL for its specific static /32, but that can't be a good solution for something like this...
> mbed TLS supports SSLv3 up to TLSv1.2
From a systems level critically relying on any of the following seems iffy in a marine environment where safety is key: wireless (unreliable; may be accidentally suddenly degraded by changes to outside environment), remote store and forward email notifications (unreliable and slow), single MCUs (due to SPOF), unsealed electronics in the bilge (extremely dangerous and often causes corrosion and loss of rudders), press-fit electronics (bad in marine environments, particularly near engines, due to vibration).
You are correct that all kind of things like WiFi, email servers, etc are unreliable. There is a ton of fault tolerant code in there now. Retries, exits to loops so they cannot hang. The ultimate backup is that if I don't get an email in the morning, something is wrong. That is why I send an email every day regardless of the conditions on the boat.
Perhaps I should write all that up as well.
In fact, if you decouple the delivery method from the report generation, you can have have it running even while under sail and do periodic data collection and logging. If you get a Marine SSB radio, you could even collect the data while crossing an ocean!
SSB is not a set and forget communication. It's great for long distance communications but the operator has to be seriously fairly knowledgeable on how to make HF work. It's a 100W radio that can do some damage if used incorrectly.
Still seems like a good idea to have monitoring even if you can see the boat.
He blamed it on galvanic corrosion from the boat being plugged into shore power with depleted anodes.
A quick google search shows that corroded drain plugs do happen from time to time. And the drain plug is just one of the through-hull fittings that can leak.
Came across this quote:
To quote BoatUS Insurance, “for every one boat that sinks underway, four sink at the dock” and “failed thru-hull fittings account for 50% of all sunken boats at the dock.
- Galley sink drain - Galley sink raw water in - 3x transducers (came with boat, kept them where they are, definitely a liability) - Water intake
Too many for my liking. I think I could get rid of the speedo and one transducer and live a little more comfortably... maybe next year.
Maybe my expectations for microcontroller software are too high.
So far I've built controller for x-ray tube (turning AC on for required number of cycles), oil boiler consumption monitor, gate/garage door opener (to remotely open the gate for delivery courriers), remote power and monitoring for electrical boiler for sauna and some more.
On the other hand, FPGAs have warped my sense of what is possible though. Allocating s corner of a chip to one role and having other areas do other tasks at the same time with no context switching (...because hardware) gets very addictive.
Might seem like overkill where regular maintenance should be sufficient but you can never have too many redundancies to keep a boat afloat. Murphy's Law very much applies.
And there is maintenance. Even if you seal up all of the leaks, something will always degrade and start leaking. If you are away from the boat for weeks at a time, you may find your leak-free boat on the bottom of the harbor.
So yes, you could conceivably find and seal every single leak, especially if you don't have a rotating shaft that penetrates the hull, but it would not negate the need for monitoring.
Connection to your comment: there was a huge explosion in Beirut. There were safety issues with a ship loaded with fertilizer. The port offloaded the fertilizer and let the crew leave. One consequence was the terrible explosion. The other was that before that the ship sank. Big ships are described in the podcast as needing constant maintenance to keep them from sinking, which is one of the reasons ports are reluctant to let the crew leave.
Seems like it's similar for much smaller boats.
There are always bugs (leaks) and potential for bugs (leaks), some effort in both directions is usually a better use of time (and in this case, money).