added more details to logs
This commit is contained in:
8
main.py
8
main.py
@@ -20,8 +20,8 @@ from secrets import WIFI_SSID, WIFI_PASSWORD, NEXTCLOUD_USERNAME, NEXTCLOUD_PASS
|
|||||||
try:
|
try:
|
||||||
ih.network_connect_better(WIFI_SSID, WIFI_PASSWORD)
|
ih.network_connect_better(WIFI_SSID, WIFI_PASSWORD)
|
||||||
except RuntimeError as e:
|
except RuntimeError as e:
|
||||||
print(e)
|
print(f' connect error: {e}')
|
||||||
write_err(e)
|
write_err(f' connect error: {e}')
|
||||||
#Likely a network oops, try starting again
|
#Likely a network oops, try starting again
|
||||||
uos.umount("/sd")
|
uos.umount("/sd")
|
||||||
machine.soft_reset()
|
machine.soft_reset()
|
||||||
@@ -31,8 +31,8 @@ try:
|
|||||||
nc.set_auth(NEXTCLOUD_USERNAME, NEXTCLOUD_PASSWORD)
|
nc.set_auth(NEXTCLOUD_USERNAME, NEXTCLOUD_PASSWORD)
|
||||||
response = nc.get_folder_items("eink-frame")
|
response = nc.get_folder_items("eink-frame")
|
||||||
except OSError as e:
|
except OSError as e:
|
||||||
print(e)
|
print(f' nextcloud error: {e}')
|
||||||
write_err(e)
|
write_err(f' nextcloud error: {e}')
|
||||||
#Likely a network oops, try starting again
|
#Likely a network oops, try starting again
|
||||||
uos.umount("/sd")
|
uos.umount("/sd")
|
||||||
machine.soft_reset()
|
machine.soft_reset()
|
||||||
|
|||||||
Reference in New Issue
Block a user