This code repository contains the source code and test data for our school project. The code is only tested on Linux, (specifically KDE Neon, but Ubuntu should be fine) as we had problems connecting to the dog using other operating systems
This project uses the Linux command emulator Konsole to display data on the dog via the SSH connection. You may use any terminal emulator you want, but will then have to change the command strings using the emulator commands in robot_controls/server/ssh.py.
Konsole can be installed using
sudo apt install konsoleYou will then have to install the python requirements by running
python3 install -r requirements.txtThe clients in the dog will be started automatically over ssh by the server. To make this possible, you must add some configuration to your /.ssh/config file
Host dog_pi
HostName 192.168.12.1
User pi
Host dog_head
HostName 192.168.123.13
User unitree
ProxyCommand ssh -q -W %h:%p dog_pi
Then add your ssh key to the dog by running
ssh-copy-id dog_pi
ssh-copy-id dog_headThe password for both devices are 123
- Put the dog on the ground, and position the rear legs in the same position as the front legs were in the box
- Start the dog by first clicking the on/off button on the side once, and then holding it in until the lights start flashing
- Wait until the robot starts and goes into standing position
- Connect to the Unitree hotspot created by the dog
Start the server_manual.py file
Start the server_autonomous.py file
The autonomous server is also able to receive commands directly from the terminal. These include
Forward: Dog starts walking
Stop: Dog stops walking
Turn: Dog starts turning in the next determined direction
Calibrate: Dog resets all sensors based on its current location
It is also possible to test the detection system on a video by running the Start the video_loader.py file