This routine was reposted by RobStride Dynamics from DR.MuShibo. Sincere gratitude goes to DR.MuShibo for their development and sharing.
- canable (cantact clone): http://canable.io/ (STM32F042C6)
- 灵足的串口转CAN模块只适用于灵足的上位机,Ubuntu上使用需要额外的canable模块。
sudo apt-get install net-tools
sudo apt-get install can-utils
sudo apt-get install ros-noetic-can-msgs
sudo apt-get install ros-noetic-socketcan-bridgesudo modprobe can
sudo modprobe can_raw
sudo modprobe can_dev
sudo ip link set can0 type can bitrate 1000000
sudo ip link set can0 up
sudo ifconfig can0 txqueuelen 100- 在工作空间中运行如下命令:
catkin build
source ./devel/setup.zsh (or bash)
roslaunch motor_control motor_test.launch