fix image var

This commit is contained in:
rootzoll
2020-01-24 18:11:13 +01:00
parent e29873c022
commit d2f4ee9813
2 changed files with 5 additions and 5 deletions

View File

@@ -94,15 +94,15 @@ if [ "${command}" == "image" ]; then
exit 1
else
# test the image path - if file exists
if [ -f "$imagepath" ]; then
echo "# OK - file exists: ${imagepath}"
if [ -f "$imagePath" ]; then
echo "# OK - file exists: ${imagePath}"
else
echo "error='file does not exist'"
exit 1
fi
fi
sudo fbi -a -T 1 -d /dev/fb1 --noverbose ${imagepath} 2> /dev/null
sudo fbi -a -T 1 -d /dev/fb1 --noverbose ${imagePath} 2> /dev/null
exit 0
fi

View File

@@ -119,11 +119,11 @@ if [ "${connector}" == "lndconnect" ]; then
source /etc/profile
# write qr code data to an image
cd /home/admin
lndconnect --host=${host} --port=${port} --image ${extraparamter}
imagePath=$(readlink -f lndconnect-qr.png)
# display qr code image on LCD
/home/admin/config.scripts/blitz.lcd.sh image ${imagePath}
/home/admin/config.scripts/blitz.lcd.sh image /home/admin/lndconnect-qr.png
elif [ "${connector}" == "shango" ]; then