I have created a hardware_interface which interfaces with the PCA9685, a 16-channel PWM driver, which communicates via I2C. It is used in these Adafruit products:
- Adafruit 8-Channel PWM or Servo FeatherWing
- Adafruit 16-Channel 12-bit PWM/Servo Shield
- Adafruit 16-Channel PWM / Servo HAT for Raspberry Pi
- Adafruit 16-Channel PWM / Servo Bonnet for Raspberry Pi
With this driver you can connect your shield/hats/bonnets to the i2c port of your Raspberry Pi (or similar single board computer) and use them in conjunction with ros2_control framework.
This repo is using a modified version of this library, GitHub - barulicm/PiPCA9685: C++ and Python Library for PCA9685 chips and the Raspberry Pi, to communicate via I2C with a PCA9685. Thank you, barulicm (Matthew Barulic) · GitHub.
Here is the link to our repository which contains the hardware_interface as one package and an example how to use joint_group_velocity_controller to send commands to it in another package: GitHub - rosblox/pca9685_ros2_control
And here is a link to a repo which packages the above repo in a Docker image: GitHub - rosblox/ros-pca9685-ros2-control. Clone the repo, execute ./build.sh to build the image, execute ./run.sh to start a container from the image, type run (an alias) to start the launch file with from the example controller.
Please note, that this is in a proof-of-concept state. I plan to potentially use this shield to teleoperate a skid-steered rover which is implemented with a pca9685.
Thank you for your inspirational videos, ArticulatedRobotics, https://articulatedrobotics.xyz/.