Skip to content

rover project – part 3

Since the last post, I have set up a raspberry pi and connected it to the arduino over usb. I configured wifi on the raspberry pi and I’ve written a simple python script to control the rover.

Now, I can ssh into the raspberry pi, launch the python script and I can remotely control the rover using the same keys from the arduino sketch (‘l’ for left, ‘r’ for right, etc.).



Here is the python script to control the arduino.

The code is pretty simple. It opens a connection to the arduino (/dev/ttyACM0) and loops forever. When a valid key is entered, (l, r, c, f, b, k), it sends it to the arduino and the arduino processes the command. Then the loop repeats.

Next, I will start adding sensors and possibly a camera.

Comments are closed, but trackbacks and pingbacks are open.