-
Notifications
You must be signed in to change notification settings - Fork 1
Setup
CalebJ2 edited this page Aug 10, 2020
·
29 revisions
- Install git or a git GUI client like SmartGit or SourceTree
- If you haven't already, clone this repository using the GUI or by running
git clone --recurse-submodules https://gitlab.cs.wallawalla.edu/robotics-club/Rover.git - Install VSCode
- Install some VSCode extensions. Get a list by opening the repository folder in VSCode, pressing f1, and running the
Extensions: Show Recommended Extensionscommand. The most important is PlatformIO for VSCode. This is basically a different IDE for Arduino that has good command line support. - Install docker. linux, windows
- Install docker compose
- Run and build everything with
docker-compose up - Start coding. See Development process
- Install docker
- Install docker compose
- Install the GitLab runner
- Register the runner as a shell executor and give it the rover_remote tag. Get the url and token from the repository Settings > CI/CD > Runners page.
- Add
gitlab-runneruser todockergroup withsudo usermod -aG docker gitlab-runner. See Building Docker images with GitLab. - Install platformio on the GitLab runner account by running
sudo su gitlab-runner && pip install -U platformiothen restart the terminal to switch back to your normal user. Ideally all GitLab stuff should be done in Docker and changing that would be fairly straightforward. - (Optional) Set up DNS forwarding to more easily access the robot's local ip
- (Optional) enable ssh to remotely access the PC
- (If the PC can't boot due to excessive current draw on startup) Change BIOS settings to limit max power consumption.
- Advanced > Power and Performance > CPU - Power Management Control
- Boot performance mode: Max battery (default: Max Non-Turbo Performance)
- HDC Control > Turbo Mode: Disabled (default: Enabled)
- HDC Control > CPU - Power Management Control > Configurable TDP boot mode: Down (default: Nominal)
- (optional, this sets max average power draw in milliwatts for normal mode) HDC Control > CPU - Power Management Control > Config TDP Configurations > Power Limit 1: (default: 20000)
- (optional, this sets max average power draw in milliwatts for turbo mode) HDC Control > CPU - Power Management Control > Config TDP Configurations > Power Limit 2: (default: 44000)
- Advanced > Power and Performance > CPU - Power Management Control
- Enable DNS for your domain and add the DNS record you want to be updated. namecheap's instructions
- Install ddclient
sudo apt-get install ddclient -y - Enter the configuration if you know it (namecheap's example). Guess if you don't know.
- Edit the configuration file
sudo nano /etc/ddclient.conf. Edit most fields to match instructions from your dns provider, there are a lot of tutorials for this so I'll skip that. To make it use the local ip, the "use" line should beuse if, if=wlp1s0or similar. This makes check the wifi interface's ip instead of getting the public ip by asking some website. View available interfaces with theifconfigcommand. - Restart ddclient
sudo /etc/init.d/ddclient restart - Hopefully you should be able to access the website at your.domain.com:8080 or similar when you are on the same network.
It might be useful to install ROS etc. in a regular Ubuntu install.
- Install Ubuntu 18.04.2 LTS: https://www.ubuntu.com/download/desktop There are several ways to do this:
- Install in a virtual machine. Lets Ubuntu and windows run at the same time. Runs slower and can be hard to get drivers working.
- Install on bootable USB drive. Useful because you can switch between computers. Requires a fast USB drive.
- Boot from USB drive in virtual machine. Combination of the previous 2.
- Dual boot. Windows and Ubuntu installed on the same drive.
- Install git
sudo apt install git - Clone this repository
git clone https://gitlab.cs.wallawalla.edu/robotics-club/Rover.git - Run the installation script
cd Rover && install.sh- Installs ROS Melodic: http://wiki.ros.org/melodic/Installation/Ubuntu
- Installs Arduino IDE: https://www.arduino.cc/en/guide/linux
- Installs Teensyduino (have to manually click through installer): https://www.pjrc.com/teensy/td_download.html
- Go through the development environment setup section above
- If docker gives an error like "Get https://registry-1.docker.io/v2/: net/http: request canceled while waiting for connection", try changing your DNS server to 8.8.8.8 and restarting.