Blog

Fish Learns to Drive Robotic Tank
Carrot, a betta fish, has been promoted to tank captain thanks to a tinkerer who was determined not to let a fish become permanently locked in one location. Everything Is Hacked spent over a year developing a simple concept and gradually turning it into a reality. It all began with riffing on an old joke about a fish who gets to control the tank, and they set out to make the punchline a living, breathing entity. They were first playing with the concept of putting a simple fish bowl on a toy truck, but it felt too lazy. The major issue here was finding adequate space, as most fish want personal space to breathe, and cramming a full tank onto a small wheeled robot simply wasn’t going to cut it.



They backpedaled a little and decided to go all in, so they used a Raspberry Pi to handle most of the grunt work, along with a rudimentary webcam mounted above the tank. The camera looks for Carrot’s bright orange body and uses some basic color detection to figure out where he is; the software simply locks on the largest orangeish blob it can see and draws a box around it; if Carrot swims over one side of the middle line, the tank turns that way. However, if he swims to the other side, the tank will turn in that direction. The fish moves forward by swimming ahead and backwards by swimming backwards. To move the tank about the shop, they used two motors with differential steering, powered by a LiPo battery.

Getting all of the hardware in order was a slow burn, as it took some tuning to get the motors to behave; at first, they were basically whining and jerking around all over the place, occasionally turning the tank around in circles when Carrot became really excited. They turned out to have over-tuned them, which they fixed and were good to go. Replaced the play sand with some easier-to-care-for gravel, hooked up a heater to keep the water warm, and finally slapped a lid on to keep Carrot from trying to escape, though to be fair, he was determined to do it at least once during testing.

Fish Learns to Drive Robotic Tank
The entire tank is literally sitting on a sturdy piece of robotics hardware, transforming it into a large family house. Carrot joined the party after they conducted some study; goldfish require far too much space and company, so a feisty little solo betta was the way to go. They chose him from a pet store display and named him Carrot, after the bright orange vegetables they used to fine-tune the tracking system to focus on him. It took him a long time to adjust to his new surroundings,as he was throwing a tantrum at reflection, swiping at the camera, and basically behaving like he owned the place straight away.

Fish Learns to Drive Robotic Tank
Training began in a controlled atmosphere, on a folding table, in a very improvised configuration. The targets included a Grab n’ Go bag of food, a TV playing Finding Nemo, a mirror, and an aggressive-looking fake betta named Brad who was simply chilling in his tank. Carrot basically disregarded everyone except Brad. Every time, he’d charge right at the poor victim, slamming the tank forward with all his might. To ensure that he wasn’t just wandering around, the creator ran some data to determine if Carrot’s course was a fluke or not, and it turned out that Carrot had a pretty clear plan of attack.

Fish Learns to Drive Robotic Tank
As the training sessions progressed, the maker taught him to link bright colors with food, which was a very basic notion that Carrot seemed to grasp quickly. He even got to the point where he could swim to the feeding spot on demand with no issue. After that, there were several outside trials with a leash for safety, as well as a short run through a grocery store parking lot. But, let’s be honest, the outcomes varied. Carrot would occasionally follow cues, but the chilly air and all the new sights and sounds made it difficult to persuade him to do exactly what he was told.

Fish Learns to Drive Robotic Tank
Carrot returned to his life in a large permanent tank with a snail companion after the experiment. Everything is Hacked discovered that you really can teach a fish to manipulate its environment through careful movement. Plus, even when Carrot is out of the water, he retained his navigation skills and was motivated by pure curiosity. Even his combative attitude proved to be an asset, considering how he used it to push the tank exactly where he wanted it.
[Source]

This Fish Isn’t Just Swimming It’s Driving Around in a Custom Robotic Tank

#Fish #Isnt #Swimming #Driving #Custom #Robotic #Tank