Skip to content

Commit a3427ab

Browse files
install correct library
1 parent 36e386c commit a3427ab

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

install.sh

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,16 @@ usrdir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
99

1010
# sudo apt update
1111

12-
sudo apt-get install -y python3-smbus i2c-tools python3-rpi-lgpio python3-gpiozero
12+
# Check if python3-rpi-lgpio package is available
13+
if apt-cache show python3-rpi-lgpio > /dev/null 2>&1; then
14+
echo "- installing python3-rpi-lgpio"
15+
sudo apt-get install -y python3-rpi-lgpio
16+
else
17+
echo "- installing python3-rpi.gpio"
18+
sudo apt-get install -y python3-rpi.gpio
19+
fi
20+
21+
sudo apt-get install -y python3-smbus i2c-tools python3-gpiozero
1322
sudo apt-get install -y libopenjp2-7
1423
pip3 install redis paho-mqtt xmltodict requests adafruit-circuitpython-ssd1306 Pillow
1524

module.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name" : "emonPiLCD",
3-
"version" : "2.1.2",
3+
"version" : "2.1.3",
44
"location" : "/opt/openenergymonitor",
55
"branches_available": ["stable","master"],
66
"requires": []

0 commit comments

Comments
 (0)