Raspberry + ROS + Servo
Hi guys,
could anyone tell me some tutorial that teaches to control servoss via ROS installed in a Raspberry PI 3 (Ubuntu Mate
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
Hi guys,
could anyone tell me some tutorial that teaches to control servoss via ROS installed in a Raspberry PI 3 (Ubuntu Mate
I've been working through this scenario. (See if this description is what you are attempting: http://elder.ninja/blog/p/6106 )
Here are a few things which may make your life a bit easier:
Using Ubuntu server for RPi3 (rather than raspbian jessie) does make your query easier as you can install most packages using "apt-get install" and not need to "git" the source.
For PWM for positional control of standard servos as well as speed and direction control of continuous servos, you might check out the ros_i2cpwmboard package: https://gitlab.com/bradanlane/ros-i2c...
Short description of end-to-end demonstration: http://elder.ninja/blog/p/6804 and accompanying video: https://vimeo.com/193201509
The documentation ( http://bradanlane.gitlab.io/ros-i2cpw... ) for the ros_i2cpwmboard package gives simple test examples of rostopic() and rosservice(). The package supports controlling servos using direct PWM values, proportional values (-1.0 .. 1.0) and using geometry_msgs::Twist - the latter makes it easier to integrate with the turtlesim tutorials.
I'm assuming you have ROS installed on your Pi3. I would first start by controlling a servo using the Pi PWM or any of the widely used Pi GPIO libraries. . Then start by writing a ROS servo subscriber node. You can use this ROS tutorial) as an example.
Once you have the two parts running, you will have to merge the servo code to the subscriber code, so that the servo node listens on a ros topic, say /pi/servoAngle. You can then send commands to the topic using the rostopic pub command.
If you are not familiar with ROS concepts, I would start with the basic ROS tutorials first.
Asked: 2016-11-21 13:43:28 -0500
Seen: 5,651 times
Last updated: Dec 11 '16
Raspberry Pi 2 or Odroid U3 enough performance to run ROS and AR-Tag Pose Estimation?
How to subscribe information from terminal to microprocessor regularly?
Process has died - Exit Code -11
gps waypoints are not shown in mapviz
ROS vs ROS 2.0 vs ROS industrial
Package to detect interrupted connection?