A simple Elixir application to control the Tinkerkit Braccio robotic arm through a web interface.
The name comes from Braccio (which is the name of the robot but also the Italian word for "arm") + Arduino.
- Raspberry Pi 3b
- Arduino Due
- Tinkerkit Braccio
- braccino: shared code between the firmware and the web interface
- braccino_firmware: the firmware for the Raspberry Pi 3b, created using Nerves
- arduino-sketch: contains Arduino sketch files
- braccino_ui: the web interface, created using Phoenix Live View
The Tinkerkit Braccio robotic arm is controlled by an Arduino Due. The Arduino Due is connected to the Raspberry Pi 3b via a USB cable and they communicate through UART. The Raspberry Pi hosts a web interface to control the arm.
-
Clone this repository
-
Install the dependencies of
braccino
# inside braccino/ mix deps.get
-
Install the dependencies of
braccino_ui
# inside braccino_ui/ mix deps.get npm install --prefix assets
-
Build static assets of the web UI.
# inside braccino_ui/ npm install --prefix assets --production npm run deploy --prefix assets mix phx.digest
-
Install the dependencies of
braccino_firmware
# inside braccino_firmware/ export MIX_TARGET=rpi3 mix deps.get
-
Build the firmware
# inside braccino_firmware/ export MIX_TARGET=rpi3 mix firmware
-
Either burn the firmware to an SD card or upload it to the Raspberry Pi 3b.
# inside braccino_firmware/ export MIX_TARGET=rpi3 # to burn the firmware to an SD card mix firmware.burn # to upload the firmware mix upload
If you are using vscode there are two workspaces:
frontend.code-workspace
to use in the development of the web interfacefull-stack.code-workspace
to use in the development of the firmware + web interface
These workspaces contain extension recommendations and configuration.
This workspace includes only the braccino
and braccino_ui
folders.
To start the development server, first install the dependencies, then run mix phx.server
.
This workspace includes the braccino
, braccino_firmware
and braccino_ui
folders.
It also contains various tasks to automate building the firmware and the web interface and to deploy to the Raspberry Pi.