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
I am in the process of adding sensors to the files and converting all the tabs to space i have noticed things are being done twice in this section of code, is this deliberate. Please note my device is on address 0x03 and does work with the code below as written.
I am in the process of adding sensors to the files and converting all the tabs to space i have noticed things are being done twice in this section of code, is this deliberate. Please note my device is on address 0x03 and does work with the code below as written.
`# as3935 Set up Lightning Detector
as3935LastInterrupt = 0
as3935LightningCount = 0
as3935LastDistance = 0
as3935LastStatus = ""
as3935Interrupt = False
switch to BUS1 - for low loading ib Base Bus
if (config.TCA9545_I2CMux_Present):
tca9545.write_control_register(TCA9545_CONFIG_BUS1)
as3935 = RPi_AS3935(address=0x02, bus=1)
#set values for lightning
format: [NoiseFloor, Indoor, TuneCap, DisturberDetection, WatchDogThreshold, SpikeDetection]
default: [2,1,7,0,3,3]
NoiseFloor = config.AS3935_Lightning_Config[0]
Indoor = config.AS3935_Lightning_Config[1]
TuneCap = config.AS3935_Lightning_Config[2]
DisturberDetection = config.AS3935_Lightning_Config[3]
WatchDogThreshold = config.AS3935_Lightning_Config[4]
SpikeDetection = config.AS3935_Lightning_Config[5]
try:
except IOError as e:
print "I/O error({0}): {1}".format(e.errno, e.strerror)
back to BUS0
if (config.TCA9545_I2CMux_Present):
tca9545.write_control_register(TCA9545_CONFIG_BUS0)
time.sleep(0.003`
The text was updated successfully, but these errors were encountered: