-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
gwrobolib is a collection of classes and functions used by GW Robotics to program their Trinity College Firefighting robot entry. The library makes use of a Raspberry Pi as the robot processor and an Arduino as the input/output board. The Raspberry Pi and Arduino communicate using Nanpy, although a modified version.
Programming the robot is easiest done by programming directly on the Raspberry Pi, though it can also be programmed on a computer, then uploaded to the Raspberry Pi. Plans are in order to investigate Raspberry Pi simulation on a computer, and instructions will be added when that is found.
To make getting started a quick process, the following template is provided.
To run the GW Robotics code on a robot, the following options are available:
The benefit of running the code tethered is having the ability to read print statements during runtime. Obviously, the disadvantage is that the robot is limited to the reach of the tether.
To run the code tethered, you can use python robotname.py (for 2017 it is firefighter.py) in the same directory as the Python script. Alternatively you can go to the HOME directory and run ./run-robotname.sh(for 2017 it is run-firefighter.sh). The robot **WILL NOT **turn on until the activation limit switch is pressed.
When untethering, it is beneficial to use the run-robotname.sh script. This is because it will open the Python script in GNU Screen so that the code output window can be used by running the command screen -r robotname (for 2017 it is screen -r firefighter) while the code is still running.
Wiki maintained by Nam Tran (@omn0mn0m).