Python Library Created For BSM Robotics. Tested on Python versions 2.7 & 3
Python 2.7:
sudo -H pip install git+https://github.com/BSMRKRS/bsmLib.git
Python 3:
sudo -H pip3 install git+https://github.com/BSMRKRS/bsmLib.git
* Make sure the dependencies are installed
Python 2.7:
sudo -H pip install --upgrade git+https://github.com/BSMRKRS/bsmLib.git
Python 3:
sudo -H pip3 install --upgrade git+https://github.com/BSMRKRS/bsmLib.git
controller - Game controller class
hidePrints - Hides print to console called by any function
networking - Networking classes
RPL - RoboPiLib: Communicate w/ RoboPi hat
vector - Vector math class
RoboPi Reference - BSMRKRS's instructions for operating Raspberry Pi w/ RoboPi hat
Offical RoboPi Documentation - Offical documentation by Mikronauts
clear
- Clears Console
map(value, old_min, old_max, new_min, new_max)
- Returns value mapped to new range
from bsmLib import *
RPL.init() # Init RoboPi
RPL.servoWrite(0, 1000) # Write to pin 0
or
import bsmLib
bsmLib.RPL.init() # Init RoboPi
bsmLib.RPL.servoWrite(0, 1000) # Write to pin 0
*More examples can be found in the examples folder
- python-serial - RoboPiLib
Python 2.7
sudo apt-get install python-serial
Python 3
sudo apt-get install python3-serial
- PyGame - Controller
Python 2.7
sudo -H pip install pygame
Python 3
sudo -H pip3 install pygame
Try to install w/ sudo
Python 2.7
sudo -H python setup.py install
Python 3
sudo -H python3 setup.py install
Reinstall Dependencies
Python 2.7
pip install pygame
sudo apt-get install python-serial
Python 3
pip3 install pygame
sudo apt-get install python3-serial