Do you love your Heol Robot ? After reading this, you don't go to love it any more, you go to adore it !
The subject of this Instructables is to make a wireless transmission between a comptuer (or an equivalent) and your Heol robot. For what ? To move it !
This part of the project was made at Polytech Paris UPMC, in the case of a formation.
For more informations, visit the following links:
So, ready, set, go !
Step 1: Step 1: Required Equipments
For this tutorial, we will use an Humanoid robot called Heol, you can make it easily, and quickly with our another Instructables. It's totally 3D printed and accesible to everyone.
Link: coming soon ...
Moreover, you will need some electronics component which as are follows:
- A comptuter (of course!)
- An arduino NANO/UNO: https://www.arduino.cc/en/Main/ArduinoBoardNa
- ESP8266: https://www.sparkfun.com/products/13678
- Voltage regulator 5V to 3.3V: https://www.pololu.com/product/2122
- Logic level regulator: https://www.sparkfun.com/products/12009
- 470 Ohms resistor
- USB Cable for supplying the regulator
So, you're ready ?
Step 2: Step 2: Electronic Part (using Bluetooth Protocol)
Now, we are going to assemble the electronic part to control the Heol robot wireless.
You have 2 ways to realize this part:
- Using the Bluetooth protocol
- Using Wi-Fi protocol (go directly to the step 5)
For this step, we are using only the Arduino, HC-05 unit and some wires (and your PC but it's logical !)
Begin by cabling the following assembly on the support of your choice (in the picture area of this step)
Nothing of wizard here, you can verify before moving on to the next step.
Step 3: Step 3: Put a Sketch With Your Arduino IDE
Put some wires it's very beautiful, but without code it's useless!
So open your Arduino IDE (https://www.arduino.cc/en/main/software), choose the COM port of your board and paste the code in the appropriate space.
To increase the visibility and some colours on the code, the code is available on the Heol Ressource Center: http://ressources.heol.io/codes/245555009/
The code include two files, one for the motor ID and one for the goal position of motors, you can download the files for free on the Heol Ressource Center:
Now upload the code into your Arduino Board, and we are going to test it.
Step 4: Step 4: Test the Bluetooth
To test the communication between the host and the robot, you need a Serial Terminal.
For example, we recommend to use RealTerm: https://sourceforge.net/projects/realterm/
If your PC doesn't have Bluetooth, you can use your phone with a Bluetooth terminal (Findable easily on the Play Store or on the AppStore)
Connect your host device to the Bluetooth (the name depend on the HC-05 configuration). If you are on a PC, go to the bluetooth advanced setting to see the COM port assigned to the bluetooth module of Heol (you have 2 port, RX and TX). Remember it !
Now, open RealTerm, set the COM port and the communication speed to 115000 bps (depend on the HC-05 configuration) and click on Open !
Go on the Send tab, write a letter on the first textbox, click on "Send Number", and if the work run, the robot will say no by turning the looped head.
Congralutation! Now, you can control your robot without any wire etween you and it !
Step 5: Step 5: Electronic Part (Using Wi-Fi Protocol)
If you prefer to use the Wi-Fi, this next two step is for you.
On Heol, we think differently and we purpose different solutions for everything.
For this step, we use all the necessary components, except the HC05 sensor.
Begin by cabling the schematic (on the picture area of this step)
Be very careful before switching on, the Wi-Fi module must be ABSOLUTELY powered with 3.3 V, it's the same for the RX pin of it. Otherwise, you will destroy the sensor !
We advise you to test everything with the multimeter before (even if components are not very expensive !)
It's OK ? Go on the next step !
Step 6: Step 6: Program Your Board (Using Wi-Fi Protocol)
It’s almost finished, this is the last step!
Launch your Arduino IDE, put the following code into the correct space. (Always host on the PastieBin website)
The previous code will connect the module to your Wi-Fi (by changing the default informations by your wifi id's at the top of the program)
To verify if the ESP8266 is correctly connected to your Wi-Fi, you can check your network (for example on the http://192.168.1.1). At this time, we haven't try another way to know this.
Now, you can edit the code, by paste the following code in the loop function:
WiFiData = Serial.readString();
After that, a switch condition on the data, and it's all !
You have problems ? The step 7 will help you to solve them.
Step 7: Step 7: Improvements and Solutions
To make your experience easier, we purpose soon to download a Window software, totally customizable, to control your robot ! You can see the screenshots of the interface in the picture area of the step ! (In French)
If when you are reading the tutorial you had some issues, we purpose to you some solutions
(If a problem isn’t present in this list, you can contact us and we are happy to add it)
My HC-05 doesn’t work
Check your cabling, and if the problem is still here, try to send “AT” using the AT command program on the third question. If after that the HC05 still don’t word, try our motors (the Bluetooth can run but the motors not), after that, you can contact us, and we try to solve your problem.
My robot doesn’t move when I send a letter
Check the motors visually (you can see a red led when you put it under voltage ?)
Check the baud rate of the motor, the default speed is 115200, but you can change it using the RoboPlus software (available on the constructor website: http://en.robotis.com/index/product.php?cate_code=...)
A short procedure is available on the Heol Resources Center:
(Link of the RoboPlus tutorial coming soon ...)
How I can configure the name, password or baud rate of the Bluetooth?
It’s easy. Try using the AT commands with the following code:
To know all the commands that are available, read the manual on our resources center: