鱼香ROS一键安装,旧电脑,破设备,可以使用docker安装任意版本ros
wget http://fishros.com/install -O fishros && . fishros
手动拉取humble
sudo docker pull fishros2/ros:humble-desktop-full
docker安装会有网络问题,拉取不到镜像修改daemon.json
sudo nano /etc/docker/daemon.json
{"builder":
{
"gc": { "defaultKeepStorage": "20GB", "enabled": true }},
"experimental": false,
"registry-mirrors": [ "https://2a6bf1988cb6428c877f723ec7530dbc.mirror.swr.myhuaweicloud.com", "https://docker.m.daocloud.io", "https://hub-mirror.c.163.com", "https://mirror.baidubce.com", "https://your_preferred_mirror", "https://dockerhub.icu", "https://docker.registry.cyou", "https://docker-cf.registry.cyou", "https://dockercf.jsdelivr.fyi", "https://docker.jsdelivr.fyi", "https://dockertest.jsdelivr.fyi", "https://mirror.aliyuncs.com", "https://dockerproxy.com", "https://mirror.baidubce.com", "https://docker.m.daocloud.io", "https://docker.nju.edu.cn", "https://docker.mirrors.sjtug.sjtu.edu.cn", "https://docker.mirrors.ustc.edu.cn", "https://mirror.iscas.ac.cn", "https://docker.rainbond.cc"
]
}
固件制作:
打开platform.ini
,接着我们添加MicroROS的依赖。
lib_deps =
https://gitee.com/ohhuo/micro_ros_platformio.git
ROS2主机安装Agent:
下载MicroROS-Agent
sudo apt-get install -y build-essential
mkdir -p microros_ws/src
cd microros_ws/src
git clone http://github.fishros.org/https://github.com/fishros/micro-ROS-Agent.git -b humble
git clone http://github.fishros.org/https://github.com/micro-ROS/micro_ros_msgs.git -b humble
编译
下载完成后,编译MicroROS-Agent:
cd microros_ws
colcon build
编译完成后添加环境变量
source ~/microros_ws/install/setup.bash
运行
ros2 run micro_ros_agent micro_ros_agent serial -b 921600 --dev /dev/ttyUSB0 -v6