Skip to content

This code runs on a raspberry pi. It is our sensor hub as well as LED hub.

Notifications You must be signed in to change notification settings

LakotaRobotics1038/SensorHub2022

 
 

Repository files navigation

Python Code For Raspberry Pi

Setup

  • If using DIO sensors:
    • Copy line mentioning linit switch for all sensors
  • For LEDs:
    • Set LightCount to the number of LEDs
    • Choose message or rotate
    • Change delay, to balance LED animations
  • RIO coms:
    • use pip3 install with all necessary imports
    • enable i2c bus in the settings

Running program as a linux service

  1. Open a terminal in the project folder
  2. sudo ln -s $(pwd)/led1038.service /lib/systemd/system/led1038.service
  3. sudo ln -s $(pwd)/hub1038.service /lib/systemd/system/hub1038.service
  4. sudo systemctl daemon-reload
  5. sudo systemctl enable led1038
  6. sudo systemctl enable hub1038
  7. Restart the pi

Troubleshooting

Lasers

  • If you get errorno 121, check wiring
  • Add pins connected to laser XSHUT pins to commented list

Known Issues

  • If lasers are in use, you have to power-cycle the pi to restart the hub program

About

This code runs on a raspberry pi. It is our sensor hub as well as LED hub.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%