Launch, machine and parameter files required to bringup the HERO robot
- Upload calibration files:
hsrb_command upload_robot_config
(as root/administrator) - Back-Up of virtualbox image which are located in
~/vbox_images
:- Stop systemd service:
sudo systemctl stop hero1-speech5-windows-speech.service
orsudo systemctl stop hero1-demo-speech5-windows-speech.service
- Actual back-up i.e.:
scp -r ~/vbox_images amigo@hero2.local:~/vbox_images_backup
- Stop systemd service:
- Back-Up the odometer files:
scp -r ~/odometer amigo@hero2.local:~/odometer_backup
-
Required items:
- USB Stick
- Optional: External monitor with VGA connection. This is needed for any changes in the BIOS. As the BIOS is not shown on the internal screen.
-
Insert keyboard into robot
-
Insert USB Stick directly into the robot. Don't use any USB hub, etc.
-
Boot the robot. If no install screen is shown, follow these steps:
- Reboot the robot, press
ESC
during boot to enter the BIOS. - Check in
Boot
if the USB stick is set as first boot option. Note: No UEFI. - Otherwise change in
CMS parameters
orHard Drive parameters
theBoot option filter
tolegacy only
. - Save changes and reboot again into the bios. Check again the USB stick is the first boot option. This should be the case. Reboot and let the installer do its job.
- Reboot the robot, press
-
Wait till installer is finished. It will display a message to remove install medium. Do this and press main power button for a few seconds to shut down the robot.
-
Start the robot again via the main power button.
Directly on the robot:
- Open a terminal and change to
administrator
:su - administrator
- Change hostname to
hero1
:sudo vim /etc/hostname
sudo vim /etc/hosts
- Set static IP (Using external Wi-Fi adapter):
-
Make a back-up of the config:
sudo cp /etc/network/interfaces.eth /etc/network/interfaces.eth.bk
-
Open the file:
sudo vim /etc/network/interfaces.eth
-
Look for the following line:
iface enp4s0 inet dhcp
. Change it to:iface enp4s0 inet static
-
Add the following lines directly after the previous changed line:
address 192.168.44.51 netmask 255.255.255.0 gateway 192.168.44.1 dns-nameservers 192.168.44.1 8.8.8.8 8.8.4.4
-
Make a back-up of the resolve config:
sudo cp /etc/systemd/resolved.conf /etc/systemd/resolved.conf.bk
-
Open the file:
sudo vim /etc/systemd/resolved.conf
-
Change the line:
#DNS=
toDNS=192.168.44.1 8.8.8.8 8.8.4.4
-
Set to use ethernet:
sudo disable_wireless
-
reboot:
sudo reboot
-
The following steps need to be done on the robot(hsr-hmi
) via the GUI:
- Disable automatic updates in settings: Software & Updates > Updates:
- Automatically check for updates:
Never
- When there are other updates:
Display every two weeks
- Notify me of a new Ubuntu version:
Never
- Automatically check for updates:
The following steps can be done via SSH or directly on the robot (SSH: ssh administrator@hero1.local
)
- Change passwords of the accounts (hsr-hmi, hsr-user, administrator):
sudo passwd XX
- (Run apt-get update):
sudo apt-get update
(as root/administrator) - Update hsrb_command:
hsrb_command upgrade
(as root/administrator) - Update dockers:
hsrb_command update_release XX.XX
(as root/administrator) - Restore calibration files:
hsrb_command restore
(as root/administrator) - Restore odometer files:
scp -r amigo@hero2.local:~/odometer_backup ~/odometer
- Fix the owner of all files and folders in the
administrator
home folder:sudo chown -R administrator:administrator /home/administrator/*
- restore virtualbox image to
~/vbox_images
:scp -r amigo@hero2.local:~/vbox_images_backup ~/vbox_images
(Path of the files should be like:~/vbox_images/windows/windows.XX
) - Install virtualbox debian from https://www.virtualbox.org/wiki/Downloads:
sudo dpkg -i "XX.deb"
- (
sudo apt-get install -f
to fix missing dependencies)
- On the robot(
administrator
): Open virtualbox and add the windows image. - On the robot(
administrator
): Set correct network adapter for the virtualbox. Depending on the use of internal of external Wi-Fi. - On the robot(
hsr-hmi
): Instartup applications
disable Toyota head display - Remove apt sources provided by Toyota:
sudo rm /etc/apt/sources.list.d/*
- Install tue-env (https://github.com/tue-robotics/tue-env) and install
networking
target:tue-get install networking
- Reboot the robot to activate ssh:
sudo reboot
- Use ssh with key forwarding to connect to the robot. This is needed to clone private repos. (
sshhero1
does this) - Configure tue-env to use ssh for git:
tue-env config ros-$TUE_ROS_DISTRO git-use-ssh
- Install the
hero1
target:tue-get install hero1
- Build the software:
tue-make
- (Fix timezone:
tue-robocup-set-timezone-home
) - Disable the default Toyota Services:
sudo systemctl disable docker.hsrb.*
- Stop the default Toyota Services:
sudo systemctl stop docker.hsrb.*
- Install the background services:
rosrun hero_bringup install_systemd_autostart_hero1
- Reboot and ready to go!
- Download the latest
hero-display.AppImage
from https://github.com/tue-robotics/hero-display/releases - Move the file to
sudo mv ./hero-display.AppImage /opt/tue/bin/hero-display.AppImage
It might be needed to create the target directory:sudo mkdir -p /opt/tue/bin
- Make sure all users have all rights:
sudo chmod a+rwx /opt/tue/bin/hero-display.AppImage
- On HERO (hsr-hmi user) go to Startup Applications and add a new item with
/opt/tue/bin/hero-display.AppImage
as command. - Run it once manually or reboot HERO
- Close the current hero-display session
- Repeat steps 1-3 & 5 from First install
The following services are running on HERO1. Normally these are ran from the demo account:
- hero1-battery-conversion: Publishing a BatteryState message from the custom Toyota messages
- hero1-monitor.service: HERO version of
hsrb_monitor
fromhsrb_bringup
- hero1-ntpdate.service: Service to sync time with servers
- hero1-webserver.service: Service to always have the webserver running to facilitate hero-dashboard, hero-display and other web applications.
- hero1-roscore.service: Service containing the roscore. Runs the Toyota wrapper(
rosrun hsrb_bringup hsrb_roscore_service namespace:=/hero
) - hero1-speech1-vboxautostart-service: Slightly changed version of vboxautostart
- hero1-speech2-vboxballoonctrl-service: Slightly changed version of vboxballoonctrl
- hero1-speech3-vboxdrv: Slightly changed version of vboxdrv
- hero1-speech4-vboxweb-service: Slightly changed version of vboxweb
- hero1-speech5-windows-speech: Service to start the Windows virtualbox
- Backup the backup of the virtualbox images:
scp -r amigo@hero2.local:~/vbox_images_backup ~/vbox_images_backup
- Backup any other data (I.E. MEGA folder).
-
Install Ubuntu 20.04 Desktop:
Name: amigo Hostname: hero2 Username: amigo
-
Change ethernet configuration to static IP via GUI. Set static IP for ipv4 with the following settings:
Address: 192.168.44.52 Netmask: 255.255.255.0 Gateway: 192.168.44.1 DNS servers: 192.168.44.1, 8.8.8.8, 8.8.4.4
-
Turn Airplane-mode on, make sure Wi-Fi and Bluetooth is disabled
-
Disable automatic updates in settings: Software & Updates > Updates:
- Automatically check for updates:
Never
- When there are other updates:
Display every two weeks
- Notify me of a new Ubuntu version:
Never
- Automatically check for updates:
-
Set
Automatic suspend
to off in Power Settings, both forBattery Power
andPlugged in
-
Keep laptop on with lid closed:
sudo vim /etc/systemd/logind.conf
, addHandleLidSwitch=ignore
andHandleLidSwitchExternalPower=ignore
-
Install tue-env (https://github.com/tue-robotics/tue-env) and install
networking
target:tue-get install networking
-
Configure tue-env to use ssh for git:
tue-env config ros-$TUE_ROS_DISTRO git-use-ssh
-
Reboot the laptop to activate ssh:
sudo reboot
-
Use ssh with key forwarding to connect to the robot. This is needed to clone private repos. (
sshhero2
does this) -
Install
hero2
targettue-get install hero2
-
Install the correct
cuda-drivers
:sudo apt-get install cuda-drivers=545.23.08-1
-
Set keyboard shortcut
Ctrl+Alt+T
to terminator -
Restore any backed-up data
-
Setup MEGA sync via GUI
-
Build the software:
tue-make
-
Install the background services:
rosrun hero_bringup install_systemd_autostart_hero2
-
Reboot and ready to go!
The following services are running on HERO2. Normally these are ran from the demo account:
- hero2-battery-manager: Running a battery manager to let the robot speak in case of a low battery level
- hero2-openpose: Running OpenPose
- hero2-rgbd-shm-server: Running a
rgbd
shared memory server, so there is only one RGBD connection from HERO1 to HERO2 - hero2-upower-ros: Running
upower_ros
to publish the battery state of HERO2
To prevent HERO2 to shut down on unplugging the power supply, some power settings need to be changed. (https://askubuntu.com/a/1132068)
gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-type nothing
gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-battery-type nothing
gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-timeout 0
gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-battery-timeout 0
gsettings set org.gnome.settings-daemon.plugins.power lid-close-ac-action nothing
gsettings set org.gnome.settings-daemon.plugins.power lid-close-battery-action nothing
gsettings set org.gnome.settings-daemon.plugins.power critical-battery-action nothing
# Copy settings from amigo account to gdm account
OLD_IFS=${IFS}; IFS=$'\n'; for x in $(sudo -Hu amigo gsettings list-recursively org.gnome.settings-daemon.plugins.power); do eval "sudo -Hu gdm dbus-launch gsettings set ${x}"; done; IFS=${OLD_IFS}; unset OLD_IFS
-
Install Ubuntu 18.04 Desktop:
Name: demo Hostname: demo-laptop Username: demo
-
Setup Wi-Fi to AtHome(-2.4)
-
Install tue-env (https://github.com/tue-robotics/tue-env)
-
Install
hero-demo-laptop
target:tue-get install hero-demo-laptop
-
Compile the software:
tue-make
-
Set keyboard shortcut
Ctrl+Alt+T
to terminator -
Pin shortcuts of
hero-dashboard
andhero-rviz
-
Disable laptop going to sleep and disable power button turning off the laptop
-
Copy ssh keys to HERO:
hero-copy-my-id
HERO uses many of the Toyota launch structure. This requires compatibility of launch file arguments, frame names, namespacing, etc.. In case of incompatibility it can look like a local issue. To exclude any uncertainty a list of compatible package versions is maintained. There is a seperate list for the robot and dev pc's.
hero-start
contains a required node, which checks the currently installed set of Toyota software packages. In case of a package, which is not tracked, a warning is shown. In case of a tracked package with an incompatible version, an error is shown and hero-start
will terminate.
In case of an incompatible package version, you can add the new package version(s) to the list manually or run the update script with the add option: rosrun hero_bringup update_toyota_software_version --add
. In case this seems to run without any issues (node names, topic names, service names, frame names, etc.), you can open a PR to update the tracked compatibility list.
In case of any issues, the issues should be solved and the compatibility list should be reset. You can reset the compatible package version of the packages causing the issues manually or reset the entire list by running the update script with the 'reset' option: rosrun hero_bringup update_toyota_software_version --reset
. You can try to fix (small) issues yourself, but it is recommended to ask @MatthijsBurgh to fix these issues.