pimoroni / enviro

MIT License
101 stars 79 forks source link

Enviro Indoor takes readings only after manually running main.py #171

Closed memotho closed 2 weeks ago

memotho commented 1 year ago

After provisioning Enviro Indoor to log readings internally, and leaving the USB attached to the computer the board takes one reading and stops taking any more readings. White LED keeps pulsing. No new readings are taken.

The firmware was updated to v0.0.9 as per guide here https://github.com/pimoroni/enviro/blob/main/documentation/upgrading-firmware.md.

Here is the log file output:

2021-01-01 00:01:00 [info / 86kB] > GET /networks.json (200 OK) [1163ms] 2021-01-01 00:01:01 [info / 70kB] > GET /images/pirate-logo.svg (200 OK) [1576ms] 2021-01-01 00:01:01 [info / 66kB] > GET /images/logo-indoor.svg (200 OK) [1643ms] 2021-01-01 00:01:01 [info / 99kB] > GET /images/guide-qr-code.svg (200 OK) [1719ms] 2021-01-01 00:01:02 [info / 85kB] > GET /connecttest.txt (301 Moved Permanently) [65ms] 2021-01-01 00:01:03 [info / 72kB] > GET /connecttest.txt (301 Moved Permanently) [246ms] 2021-01-01 00:01:03 [info / 106kB] > GET /connecttest.txt (301 Moved Permanently) [134ms] 2021-01-01 00:01:04 [info / 95kB] > GET /connecttest.txt (301 Moved Permanently) [238ms] 2021-01-01 00:01:07 [info / 94kB] > POST /provision-step-2-wifi (301 Moved Permanently) [281ms] 2021-01-01 00:01:07 [debug / 64kB] > parsed template: enviro/html/header.html (took 20 ms) 2021-01-01 00:01:07 [debug / 59kB] > parsed template: enviro/html/header-mini.html (took 10 ms) 2021-01-01 00:01:07 [debug / 86kB] > parsed template: enviro/html/footer.html (took 13 ms) 2021-01-01 00:01:07 [debug / 84kB] > parsed template: enviro/html/provision-step-3-logging.html (took 313 ms) 2021-01-01 00:01:07 [info / 81kB] > GET /provision-step-3-logging (200 OK) [827ms] 2021-01-01 00:01:08 [info / 106kB] > GET /images/logo-indoor.svg (200 OK) [361ms] 2021-01-01 00:01:08 [info / 82kB] > GET /images/pirate-logo.svg (200 OK) [451ms] 2021-01-01 00:01:08 [info / 76kB] > GET /images/guide-qr-code.svg (200 OK) [519ms] 2021-01-01 00:01:24 [info / 77kB] > POST /provision-step-3-logging (301 Moved Permanently) [402ms] 2021-01-01 00:01:25 [debug / 77kB] > parsed template: enviro/html/header.html (took 35 ms) 2021-01-01 00:01:25 [debug / 72kB] > parsed template: enviro/html/header-mini.html (took 13 ms) 2021-01-01 00:01:25 [info / 80kB] > GET /images/logo-indoor.svg (200 OK) [200ms] 2021-01-01 00:01:25 [debug / 94kB] > parsed template: enviro/html/footer.html (took 24 ms) 2021-01-01 00:01:25 [debug / 91kB] > parsed template: enviro/html/provision-step-4-destination.html (took 611 ms) 2021-01-01 00:01:25 [info / 88kB] > GET /provision-step-4-destination (200 OK) [1263ms] 2021-01-01 00:01:26 [info / 61kB] > GET /images/pirate-logo.svg (200 OK) [487ms] 2021-01-01 00:01:26 [info / 88kB] > GET /images/guide-qr-code.svg (200 OK) [559ms] 2021-01-01 00:01:31 [info / 93kB] > POST /provision-step-4-destination (301 Moved Permanently) [2353ms] 2021-01-01 00:01:31 [debug / 86kB] > parsed template: enviro/html/header.html (took 34 ms) 2021-01-01 00:01:31 [debug / 81kB] > parsed template: enviro/html/header-mini.html (took 11 ms) 2021-01-01 00:01:32 [debug / 72kB] > parsed template: enviro/html/footer.html (took 10 ms) 2021-01-01 00:01:32 [debug / 69kB] > parsed template: enviro/html/provision-step-5-done.html (took 323 ms) 2021-01-01 00:01:32 [info / 67kB] > GET /provision-step-5-done (200 OK) [869ms] 2021-01-01 00:01:32 [info / 83kB] > GET /images/logo-indoor.svg (200 OK) [241ms] 2021-01-01 00:01:32 [info / 65kB] > GET /images/pirate-logo.svg (200 OK) [528ms] 2021-01-01 00:01:33 [info / 79kB] > GET /images/guide-qr-code.svg (200 OK) [800ms] 2021-01-01 00:01:35 [info / 62kB] > GET /connecttest.txt (301 Moved Permanently) [232ms] 2000-01-01 00:04:09 [info / 121kB] > performing startup 2000-01-01 00:04:09 [debug / 119kB] - running Enviro 0.0.9, MicroPython 9dfabcd-dirty on 2022-11-18 2000-01-01 00:04:09 [info / 113kB] - wake reason: usb_powered 2000-01-01 00:04:09 [debug / 112kB] - turn on activity led 2000-01-01 00:04:09 [info / 110kB] > clock not set, synchronise from ntp server 2000-01-01 00:04:09 [info / 108kB] > connecting to wifi network 'SM-A526W1552' 2000-01-01 00:04:16 [info / 121kB] - ip address: 192.168.135.108 2023-04-17 17:25:35 [info / 118kB] - rtc synched 2023-04-17 17:25:35 [debug / 114kB] > 88 blocks free out of 212 2023-04-17 17:25:35 [debug / 111kB] > taking new reading 2023-04-17 17:25:35 [info / 107kB] - seconds since last reading: 45471 2023-04-17 17:25:35 [debug / 101kB] > saving reading locally 2023-04-17 18:07:05 [info / 121kB] > performing startup 2023-04-17 18:07:05 [debug / 119kB] - running Enviro 0.0.9, MicroPython 9dfabcd-dirty on 2022-11-18 2023-04-17 18:07:05 [info / 113kB] - wake reason: usb_powered 2023-04-17 18:07:05 [debug / 111kB] - turn on activity led 2023-04-17 18:07:05 [debug / 107kB] > 87 blocks free out of 212 2023-04-17 18:07:05 [debug / 105kB] > taking new reading 2023-04-17 18:07:06 [info / 100kB] - seconds since last reading: 2491 2023-04-17 18:07:06 [debug / 94kB] > saving reading locally 2023-04-17 18:08:41 [info / 121kB] > performing startup 2023-04-17 18:08:41 [debug / 119kB] - running Enviro 0.0.9, MicroPython 9dfabcd-dirty on 2022-11-18 2023-04-17 18:08:41 [info / 113kB] - wake reason: usb_powered 2023-04-17 18:08:41 [debug / 111kB] - turn on activity led 2023-04-17 18:08:41 [debug / 107kB] > 87 blocks free out of 212 2023-04-17 18:08:41 [debug / 105kB] > taking new reading 2023-04-17 18:08:42 [info / 100kB] - seconds since last reading: 96 2023-04-17 18:08:42 [debug / 94kB] > saving reading locally 2023-04-17 18:11:46 [info / 121kB] > performing startup 2023-04-17 18:11:46 [debug / 118kB] - running Enviro 0.0.9, MicroPython 9dfabcd-dirty on 2022-11-18 2023-04-17 18:11:46 [info / 113kB] - wake reason: usb_powered 2023-04-17 18:11:46 [debug / 111kB] - turn on activity led 2023-04-17 18:11:46 [debug / 106kB] > 87 blocks free out of 212 2023-04-17 18:11:46 [debug / 104kB] > taking new reading 2023-04-17 18:11:47 [info / 100kB] - seconds since last reading: 185 2023-04-17 18:11:47 [debug / 93kB] > saving reading locally 2023-04-17 18:11:47 [info / 119kB] > going to sleep 2023-04-17 18:11:47 [debug / 117kB] - clearing and disabling previous alarm 2023-04-17 18:11:47 [info / 115kB] - setting alarm to wake at 18:15pm 2023-04-17 18:11:47 [info / 113kB] - shutting down 2023-04-17 18:11:47 [debug / 110kB] - on usb power (so can't shutdown). Halt and wait for alarm or user reset instead 2023-04-17 18:12:51 [info / 121kB] > performing startup 2023-04-17 18:12:51 [debug / 118kB] - running Enviro 0.0.9, MicroPython 9dfabcd-dirty on 2022-11-18 2023-04-17 18:12:51 [info / 113kB] - wake reason: usb_powered 2023-04-17 18:12:51 [debug / 111kB] - turn on activity led 2023-04-17 18:12:51 [debug / 106kB] > 87 blocks free out of 212 2023-04-17 18:12:52 [debug / 104kB] > taking new reading 2023-04-17 18:12:52 [info / 100kB] - seconds since last reading: 65 2023-04-17 18:12:52 [debug / 94kB] > saving reading locally 2023-04-17 18:12:52 [info / 120kB] > going to sleep 2023-04-17 18:12:52 [debug / 117kB] - clearing and disabling previous alarm 2023-04-17 18:12:52 [info / 115kB] - setting alarm to wake at 18:15pm 2023-04-17 18:12:52 [info / 113kB] - shutting down 2023-04-17 18:12:52 [debug / 111kB] - on usb power (so can't shutdown). Halt and wait for alarm or user reset instead

Here are the readings files' output:

  1. timestamp,temperature,humidity,pressure,gas_resistance,aqi,luminance,color_temperature 2023-04-17T04:45:59Z,25.79,38.81193,1007.24,29851,11.9,23,1884

  2. timestamp,temperature,humidity,pressure,gas_resistance,aqi,luminance,color_temperature 2023-04-17T04:47:45Z,24.81,45.10785,1007.26,30274,12.1,2,1242

  3. timestamp,temperature,humidity,pressure,gas_resistance,aqi,luminance,color_temperature 2023-04-17T17:25:35Z,25.89,49.52008,1001.47,41330,12.6,0,0

  4. timestamp,temperature,humidity,pressure,gas_resistance,aqi,luminance,color_temperature 2023-04-17T18:07:06Z,23.34,35.47286,1000.6,58595,12.4,6,3209

  5. timestamp,temperature,humidity,pressure,gas_resistance,aqi,luminance,color_temperature 2023-04-17T18:11:47Z,23.01,34.89084,1000.38,46310,12.1,7,4052

  6. timestamp,temperature,humidity,pressure,gas_resistance,aqi,luminance,color_temperature 2023-04-17T18:11:47Z,23.01,34.89084,1000.38,46310,12.1,7,4052

Here is the config file:

enviro config file

you may edit this file by hand but if you enter provisioning mode

then the file will be automatically overwritten with new details

provisioned = True

enter a nickname for this board

nickname = 'dan-enviro-indoor'

network access details

wifi_ssid = 'SM-A526W1552' wifi_password = '*****'

how often to wake up and take a reading (in minutes)

reading_frequency = 15

how often to trigger a resync of the onboard RTC (in hours)

resync_frequency = 168

where to upload to ("http", "mqtt", "adafruit_io", "influxdb")

destination = ''

how often to upload data (number of cached readings)

upload_frequency = None

web hook settings

custom_http_url = '' custom_http_username = '' custom_http_password = ''

mqtt broker settings

mqtt_broker_address = '' mqtt_broker_username = '' mqtt_broker_password = ''

mqtt broker if using local SSL

mqtt_broker_ca_file = None

adafruit ui settings

adafruit_io_username = 'daneksithethos' adafruit_io_key = '*****'

influxdb settings

influxdb_org = '' influxdb_url = '' influxdb_token = '' influxdb_bucket = ''

grow specific settings

auto_water = False moisture_target_a = 50 moisture_target_b = 50 moisture_target_c = 50

compensate for usb power

usb_power_temperature_offset = 4.5

memotho commented 1 year ago

The same is true for v0.0.2, only this time the board does not take the first reading, and the LEDs do not flash, or pulse after provisioning the board.

Here is the output of Thonny's terminal/shell after manually running main.py:

%Run -c $EDITOR_CONTENT


/ /\ //\ //\ / /\ / /\ / /\
/ /:/ \ \:\ \ \:\ / /:/ / /::\ / /::\
/ /:/ /\ \ \:\ \ \:\ / /:/ / /:/\:\ / /:/\:\
/ /:/ /:/
\\:\ \ \:\ //::\ / /:/~/:/ / /:/ \:\
/
/:/ /:/ /\ //::::::::\ /\ \\:\ _\/\:__ /_/:/ /:/ //:/ \\:\
\ \:\/:/ /:/ \ \:\^^^\/ \ \:\ | |:| \ \:\/\ \ \:\/:::::/ \ \:\ / /:/
\ \::/ /:/ \ \:\ \ \:| |:| \
\::/ \ \::/^^^^ \ \:\ /:/
\ \:\/:/ \ \:\ \ \:_|:| / /:/ \ \:\ \ \:\/:/
\ \::/ \ \:\ \ \::::/ //:/ \ \:\ \ \::/
\
\/ _
\/ ^^^^^ _\/ _\/ __\/

   -  --  ---- ------=--==--===  i can has data?  ===--==--=------ ----  --  -      

2023-04-18 04:13:36 [info / 116512] 2023-04-18 04:13:36 [info / 114896] hey enviro, let's go! 2023-04-18 04:13:36 [info / 113200] - --=-=-===-=-=-- - 2023-04-18 04:13:36 [info / 111600] 2023-04-18 04:13:36 [debug / 109984] > performing startup 2023-04-18 04:13:36 [debug / 108288] - hold vsys_en high 2023-04-18 04:13:36 [info / 128000] - wake reason: unknown 2023-04-18 04:13:36 [debug / 126272] - turn on activity led 2023-04-18 04:13:37 [debug / 121840] > 96 blocks free out of 212 Traceback (most recent call last): File "", line 87, in TypeError: unsupported types for ge: 'int', 'str'

memotho commented 1 year ago

Issue is reproducible on v0.0.8. Onboard LEDs are not flashing or pulsing after provisioning the board.

Take readings every 5 minutes. Never upload, log locally.

Log.txt output.

clearing and disabling timer and alarm 2023-04-18 05:57:27 [info / 103kB] - setting alarm to wake at 06:00am 2023-04-18 05:57:27 [info / 101kB] - shutting down 2023-04-18 05:57:27 [debug / 99kB] - on usb power (so can't shutdown) halt and reset instead 2023-04-18 06:03:48 [debug / 115kB] > performing startup 2023-04-18 06:03:48 [info / 127kB] - wake reason: unknown 2023-04-18 06:03:48 [debug / 126kB] - turn on activity led 2023-04-18 06:03:49 [info / 119kB] > 4 cache files need uploading 2023-04-18 06:03:49 [info / 117kB] > connecting to wifi network 'SM-A526W1552' 2023-04-18 06:03:51 [debug / 110kB] - connecting 2023-04-18 06:03:54 [debug / 96kB] - connecting 2023-04-18 06:04:21 [error / 93kB] ! failed to connect to wireless network SM-A526W1552 2023-04-18 06:04:21 [error / 91kB] ! reading upload failed 2023-04-18 06:04:21 [info / 89kB] > going to sleep 2023-04-18 06:04:21 [debug / 87kB] - clearing and disabling timer and alarm 2023-04-18 06:04:21 [info / 85kB] - setting alarm to wake at 06:05am 2023-04-18 06:04:21 [info / 83kB] - shutting down 2023-04-18 06:04:21 [debug / 126kB] - on usb power (so can't shutdown) halt and reset instead 2021-01-01 00:00:06 [info / 128kB] > entering provisioning mode 2021-01-01 00:00:06 [info / 116kB] > auto detecting board type 2021-01-01 00:00:06 [info / 114kB] - indoor 2021-01-01 00:00:06 [info / 112kB] > going into access point mode 2021-01-01 00:00:09 [info / 110kB] - 192.168.4.1 2021-01-01 00:00:09 [info / 108kB] > starting dns server... 2021-01-01 00:00:09 [info / 121kB] > starting catch all dns server on port 53 2021-01-01 00:00:09 [info / 119kB] > creating web server... 2021-01-01 00:00:10 [info / 114kB] > waiting for a client to connect 2023-04-18 06:05:56 [debug / 115kB] > performing startup 2023-04-18 06:05:56 [info / 127kB] - wake reason: unknown 2023-04-18 06:05:56 [debug / 126kB] - turn on activity led 2023-04-18 06:05:57 [info / 119kB] > 5 cache files need uploading 2023-04-18 06:05:57 [info / 116kB] > connecting to wifi network 'SM-A526W1552' 2023-04-18 06:05:59 [debug / 110kB] - connecting 2023-04-18 06:06:02 [debug / 96kB] - connecting 2023-04-18 06:06:04 [info / 88kB] - ip address: 192.168.135.108 2023-04-18 06:06:04 [error / 112kB] ! failed to upload '2023-04-18T05:46:52Z.json' to adafruit_io 2023-04-18 06:06:04 [error / 110kB] ! reading upload failed 2023-04-18 06:06:05 [info / 108kB] > going to sleep 2023-04-18 06:06:05 [debug / 106kB] - clearing and disabling timer and alarm 2023-04-18 06:06:05 [info / 103kB] - setting alarm to wake at 06:10am 2023-04-18 06:06:05 [info / 101kB] - shutting down 2023-04-18 06:06:05 [debug / 99kB] - on usb power (so can't shutdown) halt and reset instead 2021-01-01 00:00:06 [info / 129kB] > entering provisioning mode 2021-01-01 00:00:06 [info / 118kB] > auto detecting board type 2021-01-01 00:00:06 [info / 116kB] - indoor 2021-01-01 00:00:06 [info / 114kB] > going into access point mode 2021-01-01 00:00:09 [info / 116kB] - 192.168.4.1 2021-01-01 00:00:10 [info / 114kB] > starting dns server... 2021-01-01 00:00:10 [info / 112kB] > starting catch all dns server on port 53 2021-01-01 00:00:10 [info / 110kB] > creating web server... 2021-01-01 00:00:10 [info / 105kB] > waiting for a client to connect 2021-01-01 00:00:25 [info / 88kB] - client connected! (b'\xf0W\xa6\xf5\xc4\xb8',) 2021-01-01 00:00:25 [info / 86kB] > running provisioning application... 2021-01-01 00:00:25 [info / 84kB] > starting web server on port 80 2021-01-01 00:00:41 [info / 93kB] > GET /connecttest.txt (301 Moved Permanently) [247ms] 2021-01-01 00:00:41 [info / 84kB] > GET /connecttest.txt (301 Moved Permanently) [54ms] 2021-01-01 00:00:44 [info / 103kB] > GET /wrong-host-redirect (200 OK) [96ms] 2021-01-01 00:00:44 [error / 101kB] need more than 0 values to unpack 2021-01-01 00:00:44 [error / 98kB] need more than 0 values to unpack 2021-01-01 00:00:49 [debug / 85kB] > parsed template: enviro/html/header.html (took 23 ms) 2021-01-01 00:00:49 [debug / 94kB] > parsed template: enviro/html/footer.html (took 12 ms) 2021-01-01 00:00:49 [debug / 91kB] > parsed template: enviro/html/welcome.html (took 268 ms) 2021-01-01 00:00:50 [info / 89kB] > GET /provision-welcome (200 OK) [526ms] 2021-01-01 00:00:50 [info / 109kB] > GET /images/logo-indoor.svg (200 OK) [677ms] 2021-01-01 00:00:50 [info / 102kB] > GET /images/pirate-logo.svg (200 OK) [493ms] 2021-01-01 00:00:50 [info / 93kB] > GET /images/guide-qr-code.svg (200 OK) [644ms] 2021-01-01 00:00:50 [info / 86kB] > GET /images/photo-indoor.jpg (200 OK) [741ms] 2021-01-01 00:01:01 [info / 86kB] > GET /connecttest.txt (301 Moved Permanently) [40ms] 2021-01-01 00:01:01 [info / 75kB] > GET /connecttest.txt (301 Moved Permanently) [240ms] 2021-01-01 00:01:02 [info / 106kB] > GET /connecttest.txt (301 Moved Permanently) [69ms] 2021-01-01 00:01:02 [info / 95kB] > GET /connecttest.txt (301 Moved Permanently) [235ms] 2021-01-01 00:01:34 [info / 69kB] > GET /connecttest.txt (301 Moved Permanently) [184ms] 2021-01-01 00:01:34 [info / 106kB] > GET /connecttest.txt (301 Moved Permanently) [223ms] 2021-01-01 00:02:05 [info / 77kB] > GET /connecttest.txt (301 Moved Permanently) [183ms] 2021-01-01 00:02:06 [info / 68kB] > GET /connecttest.txt (301 Moved Permanently) [232ms] 2021-01-01 00:02:07 [debug / 77kB] > parsed template: enviro/html/header.html (took 17 ms) 2021-01-01 00:02:07 [debug / 96kB] > parsed template: enviro/html/header-mini.html (took 21 ms) 2021-01-01 00:02:07 [debug / 87kB] > parsed template: enviro/html/footer.html (took 8 ms) 2021-01-01 00:02:08 [debug / 85kB] > parsed template: enviro/html/provision-step-1-nickname.html (took 281 ms) 2021-01-01 00:02:08 [info / 82kB] > GET /provision-step-1-nickname (200 OK) [603ms] 2021-01-01 00:02:10 [info / 108kB] > GET /images/logo-indoor.svg (200 OK) [3129ms] 2021-01-01 00:02:10 [info / 87kB] > GET /images/pirate-logo.svg (200 OK) [372ms] 2021-01-01 00:02:10 [info / 83kB] > GET /images/guide-qr-code.svg (200 OK) [447ms] 2021-01-01 00:02:13 [info / 83kB] > POST /provision-step-1-nickname (301 Moved Permanently) [331ms] 2021-01-01 00:02:13 [debug / 89kB] > parsed template: enviro/html/header.html (took 20 ms) 2021-01-01 00:02:13 [debug / 84kB] > parsed template: enviro/html/header-mini.html (took 9 ms) 2021-01-01 00:02:13 [debug / 99kB] > parsed template: enviro/html/footer.html (took 25 ms) 2021-01-01 00:02:14 [debug / 97kB] > parsed template: enviro/html/provision-step-2-wifi.html (took 339 ms) 2021-01-01 00:02:14 [info / 94kB] > GET /provision-step-2-wifi (200 OK) [910ms] 2021-01-01 00:02:15 [info / 99kB] > GET /networks.json (200 OK) [1119ms] 2021-01-01 00:02:15 [info / 85kB] > GET /images/pirate-logo.svg (200 OK) [1401ms] 2021-01-01 00:02:15 [info / 81kB] > GET /images/logo-indoor.svg (200 OK) [1485ms] 2021-01-01 00:02:15 [info / 106kB] > GET /images/guide-qr-code.svg (200 OK) [1679ms] 2021-01-01 00:02:22 [info / 101kB] > POST /provision-step-2-wifi (301 Moved Permanently) [414ms] 2021-01-01 00:02:22 [debug / 71kB] > parsed template: enviro/html/header.html (took 19 ms) 2021-01-01 00:02:22 [debug / 94kB] > parsed template: enviro/html/header-mini.html (took 23 ms) 2021-01-01 00:02:22 [debug / 80kB] > parsed template: enviro/html/footer.html (took 8 ms) 2021-01-01 00:02:22 [debug / 77kB] > parsed template: enviro/html/provision-step-3-logging.html (took 359 ms) 2021-01-01 00:02:22 [info / 75kB] > GET /provision-step-3-logging (200 OK) [978ms] 2021-01-01 00:02:23 [info / 105kB] > GET /images/logo-indoor.svg (200 OK) [420ms] 2021-01-01 00:02:23 [info / 81kB] > GET /images/pirate-logo.svg (200 OK) [425ms] 2021-01-01 00:02:23 [info / 76kB] > GET /images/guide-qr-code.svg (200 OK) [497ms] 2021-01-01 00:02:30 [info / 96kB] > POST /provision-step-3-logging (301 Moved Permanently) [267ms] 2021-01-01 00:02:30 [debug / 63kB] > parsed template: enviro/html/header.html (took 18 ms) 2021-01-01 00:02:31 [debug / 58kB] > parsed template: enviro/html/header-mini.html (took 8 ms) 2021-01-01 00:02:31 [debug / 99kB] > parsed template: enviro/html/footer.html (took 22 ms) 2021-01-01 00:02:31 [debug / 96kB] > parsed template: enviro/html/provision-step-4-destination.html (took 356 ms) 2021-01-01 00:02:31 [info / 94kB] > GET /provision-step-4-destination (200 OK) [845ms] 2021-01-01 00:02:31 [info / 79kB] > GET /images/logo-indoor.svg (200 OK) [308ms] 2021-01-01 00:02:31 [info / 100kB] > GET /images/pirate-logo.svg (200 OK) [394ms] 2021-01-01 00:02:31 [info / 94kB] > GET /images/guide-qr-code.svg (200 OK) [460ms] 2021-01-01 00:02:36 [info / 88kB] > POST /provision-step-4-destination (301 Moved Permanently) [222ms] 2021-01-01 00:02:36 [debug / 86kB] > parsed template: enviro/html/header.html (took 31 ms) 2021-01-01 00:02:36 [debug / 81kB] > parsed template: enviro/html/header-mini.html (took 8 ms) 2021-01-01 00:02:36 [debug / 72kB] > parsed template: enviro/html/footer.html (took 7 ms) 2021-01-01 00:02:36 [debug / 69kB] > parsed template: enviro/html/provision-step-5-done.html (took 250 ms) 2021-01-01 00:02:36 [info / 67kB] > GET /provision-step-5-done (200 OK) [824ms] 2021-01-01 00:02:37 [info / 82kB] > GET /images/pirate-logo.svg (200 OK) [463ms] 2021-01-01 00:02:37 [info / 78kB] > GET /images/logo-indoor.svg (200 OK) [542ms] 2021-01-01 00:02:37 [info / 72kB] > GET /images/guide-qr-code.svg (200 OK) [613ms] 2021-01-01 00:02:37 [info / 65kB] > GET /connecttest.txt (301 Moved Permanently) [176ms] 2021-01-01 00:02:38 [info / 98kB] > GET /connecttest.txt (301 Moved Permanently) [220ms] 2023-04-18 06:10:01 [debug / 115kB] > performing startup 2023-04-18 06:10:01 [info / 127kB] - wake reason: unknown 2023-04-18 06:10:01 [debug / 126kB] - turn on activity led 2023-04-18 06:10:02 [info / 119kB] > going to sleep 2023-04-18 06:10:02 [debug / 117kB] - clearing and disabling timer and alarm 2023-04-18 06:10:02 [info / 114kB] - setting alarm to wake at 06:15am 2023-04-18 06:10:02 [info / 112kB] - shutting down 2023-04-18 06:10:02 [debug / 110kB] - on usb power (so can't shutdown) halt and reset instead

memotho commented 1 year ago

Issue is reproducible on v0.0.7

Same setup as for v0.0.8

Log.txt output.

2021-01-01 00:00:02 [error / 124kB] > missing or corrupt config.py no module named 'config' 2021-01-01 00:00:02 [info / 122kB] > entering provisioning mode 2021-01-01 00:00:02 [info / 117kB] > auto detecting board type 2021-01-01 00:00:02 [info / 115kB] - indoor 2021-01-01 00:00:02 [info / 114kB] > going into access point mode 2021-01-01 00:00:06 [info / 112kB] - 192.168.4.1 2021-01-01 00:00:06 [info / 110kB] > starting dns server... 2021-01-01 00:00:06 [info / 108kB] > starting catch all dns server on port 53 2021-01-01 00:00:06 [info / 105kB] > creating web server... 2021-01-01 00:00:06 [info / 101kB] > waiting for a client to connect 2021-01-01 00:02:07 [info / 104kB] - client connected! (b'\xf0W\xa6\xf5\xc4\xb8',) 2021-01-01 00:02:07 [info / 102kB] > running provisioning application... 2021-01-01 00:02:07 [info / 100kB] > starting web server on port 80 2021-01-01 00:02:24 [info / 101kB] > GET /connecttest.txt (301 Moved Permanently) [238ms] 2021-01-01 00:02:24 [info / 91kB] > GET /connecttest.txt (301 Moved Permanently) [234ms] 2021-01-01 00:02:26 [info / 105kB] > GET /wrong-host-redirect (200 OK) [199ms] 2021-01-01 00:02:27 [error / 102kB] need more than 0 values to unpack 2021-01-01 00:02:27 [error / 100kB] need more than 0 values to unpack 2021-01-01 00:02:30 [debug / 98kB] > parsed template: enviro/html/header.html (took 69 ms) 2021-01-01 00:02:30 [debug / 98kB] > parsed template: enviro/html/footer.html (took 7 ms) 2021-01-01 00:02:30 [debug / 96kB] > parsed template: enviro/html/welcome.html (took 327 ms) 2021-01-01 00:02:30 [info / 94kB] > GET /provision-welcome (200 OK) [439ms] 2021-01-01 00:02:31 [info / 111kB] > GET /images/logo-indoor.svg (200 OK) [1666ms] 2021-01-01 00:02:32 [info / 106kB] > GET /images/pirate-logo.svg (200 OK) [513ms] 2021-01-01 00:02:32 [info / 97kB] > GET /images/guide-qr-code.svg (200 OK) [588ms] 2021-01-01 00:02:32 [info / 91kB] > GET /images/photo-indoor.jpg (200 OK) [825ms] 2021-01-01 00:02:43 [info / 88kB] > GET /connecttest.txt (301 Moved Permanently) [242ms] 2021-01-01 00:02:44 [info / 79kB] > GET /connecttest.txt (301 Moved Permanently) [235ms] 2021-01-01 00:02:44 [info / 108kB] > GET /connecttest.txt (301 Moved Permanently) [59ms] 2021-01-01 00:02:45 [info / 99kB] > GET /connecttest.txt (301 Moved Permanently) [239ms] 2021-01-01 00:03:15 [info / 77kB] > GET /connecttest.txt (301 Moved Permanently) [227ms] 2021-01-01 00:03:16 [info / 68kB] > GET /connecttest.txt (301 Moved Permanently) [227ms] 2021-01-01 00:03:47 [info / 88kB] > GET /connecttest.txt (301 Moved Permanently) [231ms] 2021-01-01 00:03:47 [info / 79kB] > GET /connecttest.txt (301 Moved Permanently) [229ms] 2021-01-01 00:04:06 [debug / 73kB] > parsed template: enviro/html/header.html (took 19 ms) 2021-01-01 00:04:06 [debug / 89kB] > parsed template: enviro/html/header-mini.html (took 9 ms) 2021-01-01 00:04:06 [debug / 80kB] > parsed template: enviro/html/footer.html (took 8 ms) 2021-01-01 00:04:06 [debug / 77kB] > parsed template: enviro/html/provision-step-1-nickname.html (took 306 ms) 2021-01-01 00:04:06 [info / 74kB] > GET /provision-step-1-nickname (200 OK) [558ms] 2021-01-01 00:04:07 [info / 113kB] > GET /images/logo-indoor.svg (200 OK) [1101ms] 2021-01-01 00:04:07 [info / 88kB] > GET /images/pirate-logo.svg (200 OK) [424ms] 2021-01-01 00:04:07 [info / 84kB] > GET /images/guide-qr-code.svg (200 OK) [559ms] 2021-01-01 00:04:19 [info / 72kB] > GET /connecttest.txt (301 Moved Permanently) [25ms] 2021-01-01 00:04:19 [info / 107kB] > GET /connecttest.txt (301 Moved Permanently) [247ms] 2021-01-01 00:04:35 [info / 75kB] > POST /provision-step-1-nickname (301 Moved Permanently) [174ms] 2021-01-01 00:04:35 [debug / 88kB] > parsed template: enviro/html/header.html (took 26 ms) 2021-01-01 00:04:35 [debug / 82kB] > parsed template: enviro/html/header-mini.html (took 8 ms) 2021-01-01 00:04:36 [debug / 97kB] > parsed template: enviro/html/footer.html (took 13 ms) 2021-01-01 00:04:36 [debug / 94kB] > parsed template: enviro/html/provision-step-2-wifi.html (took 412 ms) 2021-01-01 00:04:36 [info / 91kB] > GET /provision-step-2-wifi (200 OK) [766ms] 2021-01-01 00:04:36 [info / 76kB] > GET /images/logo-indoor.svg (200 OK) [96ms] 2021-01-01 00:04:37 [info / 92kB] > GET /networks.json (200 OK) [1137ms] 2021-01-01 00:04:37 [info / 84kB] > GET /images/pirate-logo.svg (200 OK) [1246ms] 2021-01-01 00:04:37 [info / 80kB] > GET /images/guide-qr-code.svg (200 OK) [1319ms] 2021-01-01 00:04:50 [info / 108kB] > GET /connecttest.txt (301 Moved Permanently) [255ms] 2021-01-01 00:04:51 [info / 98kB] > GET /connecttest.txt (301 Moved Permanently) [253ms] 2021-01-01 00:04:53 [info / 101kB] > POST /provision-step-2-wifi (301 Moved Permanently) [341ms] 2021-01-01 00:04:53 [debug / 71kB] > parsed template: enviro/html/header.html (took 20 ms) 2021-01-01 00:04:53 [debug / 66kB] > parsed template: enviro/html/header-mini.html (took 8 ms) 2021-01-01 00:04:53 [debug / 93kB] > parsed template: enviro/html/footer.html (took 12 ms) 2021-01-01 00:04:53 [debug / 90kB] > parsed template: enviro/html/provision-step-3-logging.html (took 308 ms) 2021-01-01 00:04:53 [info / 87kB] > GET /provision-step-3-logging (200 OK) [816ms] 2021-01-01 00:04:53 [info / 69kB] > GET /images/logo-indoor.svg (200 OK) [134ms] 2021-01-01 00:04:54 [info / 83kB] > GET /images/pirate-logo.svg (200 OK) [356ms] 2021-01-01 00:04:54 [info / 77kB] > GET /images/guide-qr-code.svg (200 OK) [431ms] 2021-01-01 00:05:00 [info / 68kB] > POST /provision-step-3-logging (301 Moved Permanently) [341ms] 2021-01-01 00:05:01 [debug / 72kB] > parsed template: enviro/html/header.html (took 68 ms) 2021-01-01 00:05:01 [debug / 67kB] > parsed template: enviro/html/header-mini.html (took 9 ms) 2021-01-01 00:05:01 [debug / 75kB] > parsed template: enviro/html/footer.html (took 8 ms) 2021-01-01 00:05:01 [debug / 72kB] > parsed template: enviro/html/provision-step-4-destination.html (took 438 ms) 2021-01-01 00:05:01 [info / 69kB] > GET /provision-step-4-destination (200 OK) [1017ms] 2021-01-01 00:05:01 [info / 110kB] > GET /images/logo-indoor.svg (200 OK) [99ms] 2021-01-01 00:05:02 [info / 87kB] > GET /images/pirate-logo.svg (200 OK) [370ms] 2021-01-01 00:05:02 [info / 81kB] > GET /images/guide-qr-code.svg (200 OK) [444ms] 2021-01-01 00:05:04 [info / 78kB] > POST /provision-step-4-destination (301 Moved Permanently) [206ms] 2021-01-01 00:05:05 [debug / 76kB] > parsed template: enviro/html/header.html (took 18 ms) 2021-01-01 00:05:05 [debug / 71kB] > parsed template: enviro/html/header-mini.html (took 8 ms) 2021-01-01 00:05:05 [debug / 94kB] > parsed template: enviro/html/footer.html (took 7 ms) 2021-01-01 00:05:05 [debug / 92kB] > parsed template: enviro/html/provision-step-5-done.html (took 299 ms) 2021-01-01 00:05:05 [info / 90kB] > GET /provision-step-5-done (200 OK) [837ms] 2021-01-01 00:05:06 [info / 89kB] > GET /images/pirate-logo.svg (200 OK) [466ms] 2021-01-01 00:05:06 [info / 86kB] > GET /images/logo-indoor.svg (200 OK) [544ms] 2021-01-01 00:05:06 [info / 82kB] > GET /images/guide-qr-code.svg (200 OK) [629ms] 2023-04-18 06:33:31 [debug / 118kB] > performing startup 2023-04-18 06:33:31 [info / 116kB] - wake reason: unknown 2023-04-18 06:33:31 [debug / 114kB] - turn on activity led 2023-04-18 06:33:31 [info / 108kB] > going to sleep 2023-04-18 06:33:31 [debug / 128kB] - clearing and disabling timer and alarm 2023-04-18 06:33:31 [info / 126kB] - setting alarm to wake at 06:35am 2023-04-18 06:33:31 [info / 124kB] - shutting down 2023-04-18 06:33:31 [debug / 121kB] - on usb power (so can't shutdown) halt and reset instead

memotho commented 1 year ago

Hitting 'RESET' button seems to work the same as running main.py manually.

bmustata commented 1 year ago

Any fix for this?

memotho commented 1 year ago

Please note that my tests may have been impaired by weak wifi signal.

I have tested it with a battery pack, and hitting a poke button worked, but otherwise the board would not send the results to Adafruit.io (this is due to me using weak mobile data and a mobile hotspot on my Samsung Galaxy A52).

It seems that the board logs data with the battery pack, just does not upload.

sjefferson99 commented 12 months ago

@memotho Just checking, the logs suggest the upload function is never called and that would be consistent with your posted config file where destination = ''

You can configure multiple locations to upload to with credentials, but it's the line above that enables uploading to that particular source (note you can only choose one source).

If you instead have destination = 'adafruit_io' in your config file, does this fix the issue? or at least provide more information in the log files?

memotho commented 12 months ago

@sjefferson99 Hello, I have tested with destination set to adafruit.io and the result is the same blinking red led.

sjefferson99 commented 12 months ago

Are the logs saying anything different now?

memotho commented 12 months ago

@sjefferson99 I need to retest, I do not remember, but I tried both logging locally and provisioning to adafruit.io, and the result was the same flashing red led and I think the logs were saying "could not connect to wifi".

memotho commented 3 weeks ago

@sjefferson99 @bmustata Hello, Sorry for the late update. I have enviro indoor working now, the issue was my hotspot password it was either too long and/or had special characters, I shortened it and removed special characters and now my enviro indoor can connect. Please close the issue. Thank you!