robocup2D教程
robocup2D教程
1.1 系统要求
比赛环境运行于ubuntu16.04STL。(或者你可以选择在win10中安装子系统,在win10应用商店搜索ubuntu,不过我没有找到windows下的monitor,但会生成比赛录像文件,可以观看)
1.2 ubuntu下平台安装
1.2.1 下载源码
https://github.com/rcsoccersim
1.2.2 换阿里源
-
备份源
sudo cp /etc/apt/sources.list /etc/apt/sources.list20191205
-
打开文件
sudo gedit /etc/apt/sources.list
-
用如下内容替换
deb-src http://archive.ubuntu.com/ubuntu xenial main restricted #Added by software-properties deb http://mirrors.aliyun.com/ubuntu/ xenial main restricted deb-src http://mirrors.aliyun.com/ubuntu/ xenial main restricted multiverse universe #Added by software-properties deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted deb-src http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted multiverse universe #Added by software-properties deb http://mirrors.aliyun.com/ubuntu/ xenial universe deb http://mirrors.aliyun.com/ubuntu/ xenial-updates universe deb http://mirrors.aliyun.com/ubuntu/ xenial multiverse deb http://mirrors.aliyun.com/ubuntu/ xenial-updates multiverse deb http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse #Added by software-properties deb http://archive.canonical.com/ubuntu xenial partner deb-src http://archive.canonical.com/ubuntu xenial partner deb http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted deb-src http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted multiverse universe #Added by software-properties deb http://mirrors.aliyun.com/ubuntu/ xenial-security universe deb http://mirrors.aliyun.com/ubuntu/ xenial-security multiverse
-
执行更新
sudo apt-get update
1.2.3 安装依赖
-
终端执行下面命令
sudo apt-get install -y build-essential libboost-all-dev flex libqt4-dev libxpm-dev libaudio-dev libxt-dev libpng-dev libglib2.0-dev libfreetype6-dev libxrender-dev libxext-dev libfontconfig-dev libxi-dev -
下载bison并解压和安装
https://download.csdn.net/download/efhgyj/12015599(谢谢)
百度网盘:链接:https://pan.baidu.com/s/1PpY_pS_TIpYlzNaZpfetJA 提取码:7v56tar -zxvf bison-2.7.1.tar.gz cd bison-2.7.1 ./configure make sudo make install cd .. sudo ldconfig
1.2.4安装server
tar -zxvf rcssserver.tar.gz
cd rcssserver
./configure --with-boost-libdir=/usr/lib/x86_64-linux-gnu
make
sudo make install
cd ..
1.2.5 安装logplayer
tar -zxvf rcsslogplayer.tar.gz
cd rcsslogplayer
./configure --disable-gl --with-boost-libdir=/usr/lib/x86_64-linux-gnu
make
sudo make install
cd ..
1.2.6 安装 monitor
tar -zxvf rcssmonitor.tar.gz
cd rcssmonitor
./configure --with-boost-libdir=/usr/lib/x86_64-linux-gnu
make
sudo make install
cd ..
sudo ldconfig
1.3 window的子系统下安装
(队伍可以启动,也可以生成比赛日志文件,但如何和linux上一样比赛同时又观看,还没找到解决方法)
1.3.1 安装linus子系统
-
打开win10的开发者模式
打开win10设置:-> 系统设置 -> 更新和安全 -> 针对开发人员 -> 选择开发者模式 -
安装win10的linus子系统组件
顺序:-> 系统设置 -> 应用 -> 右侧的程序和功能 -> 启动或关闭windows功能 -> 勾选适用于 Linux 的 Windows 子系统
确定后,重启电脑,系统更新配置 -
安装Linus子系统
在win10应用商店搜索Ubuntu, 安装Ubuntu16.04 LTS -
安装完成后设置用户名和密码