Robotics StackExchange | Archived questions

Servo controller is exceeding timeout value

This is a continuation of my previous problem from this post.

Basically, I'm trying to control a Sunfounder PiCar robot car with ROS on the Raspberry Pi. The servos that control the camera head and steering are controlled with a PCA9685 servo controller, which is controlled with this package from Bradan Lane Studios, and control from the keyboard is done with this code (slightly modified) from Tiziano Fiorenzani.

I turn on the PCA9685 control node and the low level control node on the robot, both work fine. I can access the topics from my laptop and I can confirm that the raspberry pi is subscribed to /cmdvel. However, when I start the teleoptwistkeyboard node, it just gives me an error "Waiting for subscriber to /cmdvel".

I've looked at the low level control node, and after a few seconds of starting it starts saying "False: Setting actuators to idle." I've looked in the code, and this is because the time since the controller has received it's last command has exceeded its timeout value. This would tell me that the controller is not actually receiving commands.

Does anyone know the reason this could be happening? I know one problem I've been having is that the Raspberry Pi itself is connected to a Robot HATS specifically from Sunfounder which I cannot figure out how to send signals from. I know this is quite hardware specific but any tips or suggestions would be appreciated.

A link to a pic of the hardware for the robot: https://www.flickr.com/photos/192126654@N06/shares/CH6345

Asked by RobotHunter on 2021-02-27 14:09:50 UTC

Comments

Answers