Here’s my project I have working on for weeks, it’s due next MONDAY, it’s still have a lor problems, guys, please help me, please.
- 6 pairs of 1-wires
- 3 servo motors
- 2 RGB LEDs
- 2 infrared transceivers
Each pair of 1-wires is programmed into different states.
Head Servo motor 1 is controlled by the infrared transceivers. The speed is controlled by a pair of 1-wires.
A pair of Arm servo motors’ rotation speed and degree speed is controlled by a pair of 1-wires.
RGB LEDs’ color and blink duration is controlled by a pair of 1-wires.
Right now, the code able to recognize every 1-wire pin, and able to change RGB LEDs’ color when a pair of 1-wire is replaced.
But, the rest of sensors don’t function well.
- Arm servo motors only rotate once and stopped. They could keep rotating randomly.
- Head servo motor is moving too slow and keep vibrating.
here's my code: please see the attachment below, thanks.
final_5.ino (13.2 KB)