You will need:

To use our simulator you will need to have python 3 installed on your machine. We also recommend that you have the numpy library installed, though this should not be necessary.

Download our Simulator

Our simulator is available as a zip file: Download the Simulator

Installation Instructions

Unzip the simulator into the location of your choice. It will create a folder call pirover_simulator. This folder contains two files pysim.py (for use on Windows and Linux machines) and pysimosx.py (for use on Macs)

If possible, add the path to the pirover_simulator, to the PYTHONPATH used by IDLE (there are instructions for this below). If this isn't possible we have workarounds in the worksheets 2 (for the command line) and 5 (for files) but it will be an easier experience for students if they do not need to grapple with this at an early stage.

Setting the PYTHONPATH

Setting up the correct PYTHONPATH varies between operating systems and Python installations, but it is worth trying the following:

On Linux/Mac: Add export PYTHONPATH=$PYTHONPATH:/path/to/simulator to the end of the .bashrc file where /path/to/simulator is the path to pirover_simulator

On Windows: Add PYTHONPATH as a user variable and give it the value %PYTHONPATH%;\path\to\simulator where \path\to\simulator is the path to pirover_simulator

Running the Simulator

You can run the simulator either from the command line or from a Python development environment such as IDLE.

At the Command line (Windows and Linux): Type python3 pysim.py in the pirover_simulator folder then press return.

At the Command line (Macs): Type python3 pysimosx.py in the pirover_simulator folder then press return.

To run the simultor in a Python development environment you will need to follow the instructions for running programs in that environment.

In IDLE (Windows and Linux): Open the file pysim.py using the file menu. Then select Run Module from the Run menu.

In IDLE (Macs): Open the file pysimosx.py using the file menu. Then select Run Module from the Run menu.

Programming Simulated Robots

Instructions for programming the simulated robots can be found in the worksheets.