robot_joy_udp.zip

3rd PC-side Python program. This one enables the joystick to be attached to one computer while a different computer connected to the same LAN communicates with the car by BLE. The connection between the two uses UDP. The code doesn't have any features to deal with connection drops, this is just a 10 line demo.

Zip Archive - 1.15 kB - 04/02/2020 at 06:44

Download

adapter_board.zip

Design files of the PCB that connects the Arduino Mini to the nrf8001 module and the TB6612FNG motor driver. The board is designed to be milled and I didn't pay attention to the location/visibility of the component IDs. The design files are from a Kicad project, I algo include the gerber files of the front layer, back layer and board cutout in a separate folder.

Zip Archive - 73.12 kB - 03/31/2020 at 21:40

Download

robot_joy_evdev.py

2nd PC-side Python program that reads the joystick input and sends it to the car controller via BLE. This does pretty much the same as the 1st program but it uses the evdev library instead of the PyGame library. The transition wasn't straightforward but I had to do it in order for the program to work on a Raspberry Pi with no screen attach and not running an X server (apparently, PyGame isn't meant for headless)

x-python - 1.07 kB - 03/31/2020 at 21:28

Download

robot_joy_pygame.py

1st PC-side Python program that reads the joystick input and sends it to the car controller via BLE. This uses the PyGame library to read the joystick data. Modify the MAC address in the code to match your nrf8001 module.

x-python - 915.00 bytes - 03/31/2020 at 21:27

Download

ble_car.ino

1st Arduino code that reads nrf8001 BLE connections and controls the motor driver to make the car move. The code is borrowed from the wheelchair project removing the local physical controller

x-arduino - 14.55 kB - 03/28/2020 at 18:51

Download