heatgre.blogg.se

Doom roomba
Doom roomba





I can connect it to If This Then That and clean the floor with my voice. If I go one step further, and expose that server to the internet, I can clean the floor from anywhere. As long as I’m on the network, I can clean the floor from my phone. By making it a Progressive Web App, I could even make it install on my phone’s home screen. But because I’m using Node here, I could add an Express server. Which is great and all, but it’s not entirely less effort than walking over and pressing the button.

doom roomba

It worked very well, and I was able to SSH into my vacuum cleaner and tell it to hoover the floor. I then wrote a Node.js library to control the Roomba, using a standard serial port library, and the Pi’s in-built GPIO control command. The logic converter needs to be powered both at 3.3V and 5V to work, so it's connected to both the regulator's 5V output and the Pi's 3.3V reference pin, resulting in a bit of a bird's-nest of wires where everything is connected to everything else. The problem is that they run at 3.3V, and so we need the logic level converter to bridge the gap. The Pi has a bank of pins called the GPIO, which can be used for more or less anything you need.

doom roomba

The Roomba also exposes a serial-in pin, a serial-out pin, and a binary 'wake-up' pin. I used a linear regulator at first but changed to a switching regulator when I discovered how hot it ran. The voltage regulator takes this high voltage as input, and keeps its output pin a steady 5V above gound, perfect for the Pi. There's anywhere up to about 21V across this gap, which is enough to explode a Raspberry Pi. The Roomba's serial port has two 'battery voltage' pins and two ground pins.







Doom roomba