Tuesday, August 28, 2018

Runaway Boat!

A search through the user forums at bluerobotics.com (the manufacturer of the T200 propellers that AMOS uses) turned up some 3D CAD models for propeller shields that users claimed were useful for protecting against weeds, while only contributing a small amount of additional drag. So I sent those off to 3dhubs.com and am expecting them to come in any day now. So no cool swamp air boat designs for now at least.

During the remainder of our week at Cap-Brulé, we were fortunate that the shifting wind and tides moved all the seaweed somewhere else, so I was able to do some more testing on AMOS without having to worry about the propellers constantly getting stuck. I made some changes to the software to improve how remote steering is done using the phone app. Basically, instead of specifying left and right power levels, and hoping that the boat goes straight if the power levels are the same (it never does) I changed it to check the compass heading if the user tells the boat to go straight at a particular power level, and then try to maintain that compass heading and approximate power level using the existing software routines for GPS navigation. Usually the tests of this new software worked pretty well, but a couple of times the software crashed and AMOS continued on into the open water. Even though the program was halted, the propellers still happily turned and sent the boat well away from shore. I tried in vain for about a minute or so both times to re-establish contact, but of course this was impossible as the boat's program was no longer running. So I hastily pulled the kayak into the water and went after it. The weather was quite windy with waves that broke against the kayak's hull and sprayed me in the face. Fortunately the kayak didn't capsize and I was able to catch and retrieve AMOS, probably somewhere around 500 m from shore. I'm still not sure what caused the crashes to occur. The ship's log file was zero bytes both times, as it had not been closed correctly. I should be able to change the software for that to always open and close the file each time the program writes to it... this will slow file logging considerably, but may help to determine what was happening before the crash occurred. Another idea is to create a second program to launch the current AMOS program, and have it automatically re-start the AMOS program if it detects that a crash occurred. Good software should never crash right? But it doesn't hurt to be prepared for a crash anyway.

After we returned from Cap-Brulé there were a few items waiting for me in the mail: the replacement (waterproof) LiDAR sensor (TF02), the 3D printed sensor tow-boat that was described in last week's post, and a 3/4" NPT metal tap for making a threaded hole in the tow-boat. As I had hoped, the replacement LiDAR truly was plug and play. It is a bit bigger and beefier than its predecessor, and can detect objects up to 22 m away. Here is a picture of the new LiDAR mounted atop a small wooden post on AMOS:


Today I was able to create a threaded hole in the tow-boat and then was actually able to screw the top of the pH probe into it for a nice snug fit. I had never done anything like that before, and was pleasantly surprised that it actually worked! I also mounted the turbidity sensor into the central hole, and epoxied a cat-food tin to the top of it to shield it from ambient light. I then did some crude experiments with clear water and water full of loose dirt and twigs (whilst channeling my inner 5-year old) but was unable to determine for sure whether the turbidity sensor was actually working. Usually the readings for the clear water and twiggy, dirty water were the same. But occasionally the reading for the twiggy, dirty water would get very low, so I'm guessing that the water was just not sufficiently mixed and a change in turbidity was only registered when a large particle happened to get between the transmitter and receiver.



These things will be further tested over the next week. 

No comments:

Post a Comment