SSH into the robot, and cd to ~/cg2111a/Desktop/cg2111a_git!
ssh pi@raspberrypi.localcd ~/cg2111a/Desktop/cg2111a_git- Check which port is the Arduino being connected to the RPi. If it is not ttyACM0, change the defined port in
alex-pi.cpp
ls /dev/ttyACM*- Sync code on the RPi to latest version from GitHub (if needed).
git stash --all && gh repo sync && git log -1- Use VNC to compile & upload code to the Arduino. The ino file is on the desktop, you can just open it. (Ignore the warning about making a folder by clicking
Cancel->Ok, it will open normally)
- Run code for RPi side (and pray it works).
gcc alex-pi.cpp serial.cpp serialize.cpp -pthread -o alex-pi && ./alex-piExtra: Steps 2 to 4 in one command:
sh letsgo.sh- Check if the port is defined correctly! Sometimes its not ttyACM0
- Anything else ask me (kyuu)