You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Essentially, I am able to communicate with the VEML7700 on first boot from my nRF52840, but subsequent soft reboots (such as during code reloads) cause the traceback as follows:
>>> veml7700 = adafruit_veml7700.VEML7700(i2c)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/lib/adafruit_veml7700.py", line 207, in __init__
File "adafruit_register/i2c_bit.py", line 70, in __set__
File "adafruit_register/i2c_bit.py", line 65, in __set__
File "adafruit_bus_device/i2c_device.py", line 143, in write_then_readinto
OSError: [Errno 19] Unsupported operation
Through experimentation, I have found that this can be mitigated by replacing this line:
On a cold boot, the first self.light_shutdown = False works successfully. On subsequent soft reboots, it will fail with the traceback previously mentioned; however, running the command again always works. I guess maybe the first attempt flushs some buffer or fixes some invalid state?
I can make a PR if convenient, but just checking if this maybe is just a symptom of an upstream bug that should be fixed instead.
The text was updated successfully, but these errors were encountered:
hi idea is good! for implementation i think better to perhaps have a loop where it tries 3 times to enable, and if it does not enable (else: at the end of the for loop) it throws a runtime error
I am having a very similar issue outlined in this issue:
adafruit/circuitpython#2060
Essentially, I am able to communicate with the VEML7700 on first boot from my nRF52840, but subsequent soft reboots (such as during code reloads) cause the traceback as follows:
Through experimentation, I have found that this can be mitigated by replacing this line:
Adafruit_CircuitPython_VEML7700/adafruit_veml7700.py
Line 206 in f57ccd9
with:
On a cold boot, the first
self.light_shutdown = False
works successfully. On subsequent soft reboots, it will fail with the traceback previously mentioned; however, running the command again always works. I guess maybe the first attempt flushs some buffer or fixes some invalid state?I can make a PR if convenient, but just checking if this maybe is just a symptom of an upstream bug that should be fixed instead.
The text was updated successfully, but these errors were encountered: