add more pi setup info
This commit is contained in:
parent
7bbd4a5789
commit
70f5f14211
|
@ -1,13 +1,27 @@
|
|||
# Python Sensor Application
|
||||
Updated script running on a RaspberryPi. Pure python implementation.
|
||||
|
||||
## Pi Setup
|
||||
Enable *I2C1*: `sudo raspi-config` > *Interface Options* > *I2C*
|
||||
|
||||
## Install libraries
|
||||
```
|
||||
pip install -r requirements.txt
|
||||
sudo apt install git python3-pip
|
||||
```
|
||||
|
||||
```
|
||||
pip3 install -r requirements.txt
|
||||
```
|
||||
|
||||
Setup *config.json*
|
||||
|
||||
# Install service
|
||||
```bash
|
||||
sudo cp aqi_monitor_py/service/sensor.* /etc/systemd/system
|
||||
sudo cp aqi_monitor/aqi_monitor_py/service/sensor.* /etc/systemd/system
|
||||
sudo systemctl enable --now sensor.timer
|
||||
```
|
||||
|
||||
Watch service logs for errors:
|
||||
```
|
||||
journalctl -u sensor -f
|
||||
```
|
||||
|
|
Loading…
Reference in New Issue