I started assembling my PiDog and everything was going fine. I built the body of the dog, installed the software and was able to zero out the servos for the tail and legs. When I went to zero out the next servo. I ran the servo_zeroing script, gently turned the servo a bit and then plugged it in. Nothing happened. I tried moving a servo that I had zeroed berfore successfully and it didn’t respond either. I have checked to make sure both I2C and SPI interfaces are enabled. I’ve tried different Raspberry Pi’s, I bought a new robot-hat v4, nothing works. I also tried bringing down different branches of the robot hat and pi dog repos, but I can’t get any servos to work. Any help would be greatly appreciated, I’m at the end of my rope and I really don’t want to let my son down with this project!
I started over from scratch. Following the instructions exactly. I installed Raspberry Pi OS 32-bit Legacy
and installed all the packages. Now when I attach a servo to the PWM pins marked “11” making sure that the colors on the bases of the pins match the colors of the wires. Next, I run the servo_zeroing.py script, it reboots the Raspberry Pi as soon as it prints that it is zeroing pin 11. I’ve attached a video of the problem. Please help! Thank you!
Will the Raspberry Pi reboot if you have added another servo to the P11 pin and run the servo_zeroing.py script.
If you have added another servo to the P11 pin and it does not reboot the Raspberry Pi, there may be a problem with the servo in the video.
Or you can connect the servo you are currently testing to other pins, except for the P11 pin, and see if the Raspberry Pi reboot occurs as well.
If it also restarts the Raspberry Pi, it means the servo in the video is faulty, we will send you a new servo.
Thank you for responding. I have tried it with many different servos on many different pins and I see the same behavior. This morning I turned the robot on forgetting the servo from my last test was still connected to PWM 11 and now it won’t even boot. I disconnected the servo and turned the robot on and tried to boot it, but it still won’t boot. It makes some clicking noises and then resets. I’ve attached a video of what happens.
Sorry, your robot hat is not connected to battery power, you only connect the external power supply.
The main purpose of the external power supply is to charge the battery, not to supply power to the robot hat and Raspberry Pi. If your robot hat is not connected to the battery, and only relies on the external power supply, the Raspberry Pi may not be supplied with enough power, resulting in a power failure and shutdown.
It is recommended that you connect the battery to the robot hat, the battery and keep enough power, and then go to start the Raspberry Pi to run the code script to see how it works.
If you are unable to boot the system, it is recommended that you reinstall the Raspberry Pi system and try again.
Finally ask for verification:
- If you add another servo to the P11 pin and run the servo_zeroing.py script, does the Raspberry Pi reboot?
If you added another servo to pin P11 and it did not reboot the Raspberry Pi, there may be a problem with the servo in the video.
- Alternatively, you can connect the currently tested servo to a pin other than the P11 pin and see if the Raspberry Pi reboots as well.
If the Raspberry Pi also restarts, the servo in the video is faulty and we will send you a new one.
Please respond to us in order of test points.
Thank you very much for getting back to me so quickly. I really appreciate it. I plugged the battery back in and the servo zeroed. I’m a bit embarrassed that I didn’t think to do that. I think that I’m good to go. My son and I will start working on the robot again this weekend. Thank you again for the great customer service! I will definitely be ordering more kits!
Michael Green
I spoke too soon. When I tried one servo, it appeared to work after I had attached the battery. So I reconnected all of the servos and ran the servo_zeroing.py script and none of the servos moved even though I had moved them out of the zero position. I disconnected all the servos and plugged in the servo that worked before and now it won’t move. I tried every servo in the kit on all PWM pins and they just don’t move. Please help.
Here’s a video of attaching just one servo.
It is possible that your servo has not been fully properly adjusted for return to zero.
Run
cd ~/pidog/examples
sudo python3 servo_zeroing.py
Next, angle the servo and plug the servo cable into the PWM pin, you will see the servo arm rotate to a specific position (0°). Once the servo is zeroed, follow the instructions on the assembly foldout. Pay attention to the angle of each part of the assembly, remember to secure the servo with screws after the assembly angle is controlled, then assemble the next servo, and so on through the rest of the servos. After assembly, go back to the calibration pidog.
Suggest you re-assemble the servo back to zero, please install the video tutorial to assemble:
Tutorial homepage:
https://docs.sunfounder.com/projects/pidog/en/latest/assemble_video.html
I turned each servo all the way to the left or right before testing them, so that is not the problem. It is not specific to any servo or PWM pin.
It has nothing to do with the PWM pins, and it is not specified to connect to the P11 pin to do a zero return.
P0-P11 pins are fine. However, the servos must be assembled and fixed with power on, if you zero all the servos at once and then assemble and fix them, the original zero angle of the servos will be messed up again, which will cause the zero angle of the servos to change when you re-run the zero example.
So we suggest you follow the video tutorial to assemble the servo.
The most important thing is to power up the servo to zero back and assemble the fixed servo.