Background
I am working on a project that I decided to create a control pad with Processing to control the Inmoov hand that I built. So for starter let me show you how to create a control pad in Processing and switch the LED on Arduino On/Off with it.
Preparation
- Download and install Arduino - https://www.arduino.cc/
- Download and install Processing - https://processing.org/
- Install ControlP5 in process, we use it to draw the buttons - https://github.com/sojamo/controlp5
To install the library from inside the Processing IDE, use the Library Manager from the menu under Sketch → Import Library → Add Library and search for ControlP5.
Design and workflow
Arduino:
The Arduino code is a simple modification of the Blink example from the Arduino IDE, it works as a listener on the serial link when a string is received, it goes through a "Switch" statement and performs the action when it matches a case, "turn the LED ON or OFF". The LED on the Seeeduino Lite is marked as "L" in the picture
Processing:
1. Draws the buttons with ControlP5
2. Send the string over Serial link to the Arduino
The Green LED is being turned ON/OFF in the video:
The whole process is quite straight forward as you can see in the video, feel free to ask questions.
More to come, my plan is to create more buttons and adapt the code to control servos installed in the Inmoov hands.
Comments
Please log in or sign up to comment.