E100
以下内容源自 原E100文档:
Demo Applications — Gaitech EDU 2.5 documentation
https://edu.gaitech.hk/ria_e100/demo-apps.html
克隆git&编译
mkdir –p ~/catkin_ws/src
cd ~/catkin_ws/src
git clone https://github.com/gaitech-robotics/RIA-E100.git
cd ~/catkin_ws && catkin_make
机器人上已经有环境了 如果出错了可以尝试删除catkin_ws下的bulid和devel目录重新编译
连接
直接连接
接上显示器电源就可以了,开机按power和cpu
出现错误解决不了就重启 先关Ubuntu再关power开关
鼠标键盘手柄是无线的能直接用
注意 红色按钮急停按钮不能按下去 要弹起
手柄前面开关调到X 否则操作会反转
正常情况下两个大轮子是卡住很难挪动的(电机通电后锁定啥的) 如果有个轮子可以随意转动 或者不受控制了,将机器整个重启。
SSH远程连接
先在显示器上看看wifi连接的是哪个(手机开热点)
Open the terminal in host PC and connect to robot via ssh, if prompts for password type “gaitechedu”
用户名 ria 密码 gaitechedu
ssh ria@RIA_IP_ADDRESS
查看IP地址ifconfig
VNC连接
vnc桌面配置
http://blog.sina.com.cn/s/blog_770799310101hu3l.htmlgnome-session &
vncserver 开启一个
vncpasswd 修改秘密 or sudo vncpasswd 修改root用户的
密码最长8位
原 gaiteche
改 密码12345678
VNC连接有点卡 可以尝试一下
TeamViewer连接
安装 TeamViewer 相当于远程桌面,需要联网。
启动server
输入命令的时候可以按Tab自动补全 避免输入错误
roslaunch e100_bringup minimal.launch
手柄可以直接控制,键盘控制要新开一个控制台:
roslaunch e100_teleop keyboard.launch
若开启server后提示 Couldn’t open joystick forcefeedback! 只要能动就是正常情况,要不然就重新编译源文件,检查错误。
SLAM 雷达建图
开启server的情况下
开始建图:
roslaunch e100_navigation slam_gmapping.launch
打开rviz (rviz要显示器,SSH直接开启会提示不能连接显示器,用VNC连接或者用其他带远程桌面的软件连接,桌面是gnome)
roslaunch e100_description view.launch
然后控制机器人移动建图。
保存建图结果:
rosrun map_server map_saver -f office_map
结果保存在~/catkin_ws
目录下
开启导航:
roslaunch e100_navigation navigation.launch
在rivz窗口点击
顶部2D Pose Estimate设置初始位置,2D Nav Goal设置目的位置,自动开始导航(小心会拖着视频线走)
Ball follower 球跟随
克隆新的库:
cd ~/catkin_ws/src
git clone https://github.com/gaitech-robotics/gaitech_edu.git
cd ../
catkin_make
启动server
roslaunch e100_bringup minimal.launch
启动球跟随
rosrun gaitech_edu ball_follower.py
球跟随只用到了OpenCV,识别摄像头画面上的圆圈,再移动机器人将圆圈置于摄像头中央。
人跟随
需要在个人电脑搭建TensorFlow环境
TensorFlow深度学习(一):环境搭建
https://www.imooc.com/article/26141?block_id=tuijian_wz
利用Tensorflow构建自己的物体识别模型(一)
https://www.jianshu.com/p/9c9b908a2b73需要下载Tensorflow object detection API
测试使用环境:
Anaconda
Python 3.7
Tensorfolw==1.15
还需要
pip install websocket
pip install websocket-client
配置
服务端配置
After finishing environment installation (TensorFlow), do the following steps: * copy this pb file to the /object_detection/inference_graph folder
Then copy this pbtxt file to training folder
The last thing is copy this python script to the object_detection folder
Configuration and Running
下载模型 ,放到/research/object_detection/inference_graph (新建文件夹),注意大小为181M 下载不完全会报错。
下载标签文件 放到 /research/object_detection/training 文件夹下
下载python服务端 到 /research/object_detection 文件夹下
1- In the python script go to line 130 and change the IP address to the IP address of the robot (make sure that robot and GPU machine are on the same network).
修改follower_websocket_stream.py 文件130行的机器人IP
WS_url = "ws://192.168.123.76:9091/";
机器人配置:
克隆仓库:
https://github.com/gaitech-robotics/gaitech_roslink
cd ~/catkin_ws/src
git clone https://github.com/gaitech-robotics/gaitech_roslink.git
cd ~/catkin_ws && catkin_make
编译
运行
机器人运行 :roslaunch e100_bringup minimal.launch
再运行:rosrun roslink-ba roslink_tensorflow_bridge_follower_app.py
(官网的代码错了)
最后在本机运行 follower_websocket_stream.py
原理
机器人通过socket发送图像数据到服务器,服务器读取,用模型进行腿识别,标出四个顶点,返回给机器人。机器人根据画出的框大小来移动,保持方框在正中。
如果场景较复杂会导致识别错误。