File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 34
34
from micropython import const
35
35
36
36
try :
37
- from typing import Union
37
+ from typing import Union # pylint: disable=unused-import
38
38
from busio import I2C
39
39
except ImportError :
40
40
pass
@@ -102,7 +102,7 @@ def __init__(
102
102
# read ID!
103
103
veml_id = self ._read_register (_REV_ID )
104
104
if veml_id != 0x26 :
105
- raise RuntimeError (f"Incorrect VEML6075 ID { hex (veml_id )} " )
105
+ raise RuntimeError (f"Incorrect VEML6075 ID { hex (veml_id ). upper () } " )
106
106
107
107
# shut down
108
108
self ._write_register (_REG_CONF , 0x01 )
@@ -150,7 +150,7 @@ def uv_index(self) -> float:
150
150
return ((self ._uvacalc * self ._uvaresp ) + (self ._uvbcalc * self ._uvbresp )) / 2
151
151
152
152
@property
153
- def integration_time (self ) -> Union [ None , int ] :
153
+ def integration_time (self ) -> int :
154
154
"""The amount of time the VEML is sampling data for, in millis.
155
155
Valid times are 50, 100, 200, 400 or 800ms"""
156
156
key = (self ._read_register (_REG_CONF ) >> 4 ) & 0x7
You can’t perform that action at this time.
0 commit comments