My second balancing bot built with the help off Kas guide Balancing robot for dummies(http://www.x-firm.com/?page_id=145) that i'm hosting on my server.. The v2 is made in aluminium to be lighter but all the electronics are still connected with jumper wires and will be changed later on with some custom made PCB boards and better wiring. My motors are very different in behavior so i will add a PID for each motor to get them to behave more a like and use a bluesmirf to remote control the robot from my netbook.
Update 2011-04-22
I have recoded the motor part and added the encoder for the other motor and made a PID for each motor that takes the output from the current PID. This for trying to get the two motors to behave equal. The original PID is only looking on the right motor encoder as before. But I'm calculating the current speed in pulses/10ms for each motor and then using that and the output from the old PID to control the motors for a requested speed in pulses/10ms..
That feels better than just sending a value of 0-255 that has no connection to the speed of the motor that are depending on the surface and battery level.
I have made a new sketch for the bot and a GUI to make settings and testing the motor PIDs you can download it from this links:
Motor_PID_Enc_v2 (Bot code)
Motor_PID_Enc_v2 (GUI)
Self balancing
- Actuators / output devices: 29:1 Metal Gearmotor 37Dx52L mm with 64 CPR Encoder
- Control method: Bluetooth serial messages formatted by PC. Could just as easily be a cell phone.
- CPU: Arduino Diecimilla
- Power source: 12volt 3800mA Ni-MH
- Programming language: Arduino
- Sensors / input devices: accelerometer, gyro
- Target environment: indoor
This is a companion discussion topic for the original entry at https://community.robotshop.com/robots/show/x-bot-v2