|
Post by miketangobravo on Apr 20, 2020 15:22:21 GMT -8
Hi all, I have a WeatherPi up and running for the past couple of years, as part of the OpenVino.org project. wiki.costaflores.com/display/OP/The+Weather+StationOpenvino.org ...and now I am trying to add the SI1145 sunlight sensor. I managed to install the Adafruit_Python_PureIO module and i2cdetect sees the sensor: mbarrow@openvinopi:~/light/Adafruit_Python_PureIO/SDL_Pi_SI1145-master $ sudo i2cdetect -y 1 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: -- -- -- -- -- -- -- -- 48 -- -- -- -- -- -- -- 50: -- -- -- -- -- -- -- 57 -- -- -- -- -- -- -- -- 60: 60 -- -- -- -- -- -- -- 68 -- -- -- -- -- -- -- 70: -- -- -- -- -- -- -- 77 But I am not getting any data from the sensor: mbarrow@openvinopi:~/light/Adafruit_Python_PureIO/SDL_Pi_SI1145-master $ sudo python simpletest.py Press Cntrl + Z to cancel -------------------- Vis: 0 IR: 0 UV: 0 -------------------- Vis Lux: 0.0 IR Lux: 0.0 UV Index: 0.0 -------------------- If I disconnect VCC or Ground the script aborts, so it would seem like it is connecting to the sensor, but not reading any values. What other ways can I troubleshoot this? Thanks! ./mike
|
|
|
Post by SDL on Apr 22, 2020 14:57:51 GMT -8
Mike,
Boy, something is hosed up in the driver. Can you try a different driver? I don't turns the PureIO library in this case.
It is being picked up on the i2cdetect
BP
|
|
|
Post by miketangobravo on Apr 23, 2020 17:35:33 GMT -8
Which driver would you recommend?
BTW, I tried connecting the sensor to an Arduino, and it works somewhat. So, I doesn't seem to be a problem with the sensor itself.
I haven't tested it in sunlight yet, but I can get the values to move some with different indoor lighting and UV LEDs:
Beginning Si1145! Si1145 is ready! //--------------------------------------// Vis: 260 IR: 253 UV: 0.02 //--------------------------------------// Vis: 261 IR: 254 UV: 0.02 //--------------------------------------// Vis: 261 IR: 254 UV: 0.02 //--------------------------------------// Vis: 260 IR: 254 UV: 0.02
|
|
|
Post by SDL on Apr 25, 2020 12:19:11 GMT -8
|
|
|
Post by miketangobravo on Apr 26, 2020 12:24:26 GMT -8
That did the trick! Now the sensor is reading fine from my OpenVinoPi: wiki.costaflores.com/display/OP/SI1145+Sunlight+SensorI built a shield with the quartz panel as well. Tomorrow I will install the sensor in the middle of Costaflores Organic Vineyard, in Mendoza, Argentina. BTW, The data we are collecting with the WeatherPi, along with Vinduino soil moisture data (and now the sunlight sensor) is written directly to the Ethereum blockchain. We do this as part of a strategy to "self-certify" our grapes as organic. Thanks! I see that this sensor is discontinued...is there a better sensor I should be using?
|
|
|
Post by SDL on Apr 30, 2020 15:14:13 GMT -8
|
|