Sen 0390
Why my Ambient Light Sensor SEN 0390, the ouput it just -1.00
This is my variabel luxx for the lux meter, but still get -1.00
void luxx(){
float l = myLux.lightStrengthLux();
Serial.print("value: ");
Serial.print(l);
Serial.println(" (lux).");
Blynk.virtualWrite(V1, l);
delay(1000);
}
i already put the myLux in setup and the luxx in loop
Zaki Naufal.MaulanaAccording to the SEN0390 library, the code could work with the ESP32
https://github.com/DFRobot/DFRobot_B_LUX_V30B
https://www.esp32.com/viewtopic.php?t=4742#p20511
You could use this I2C scanner to check if it's connect properly
And could you tell me your wire connection?
Like how you which PIN you connect the sensor to the ESP32.
Yeez_BIm using pin 13 for enable, vcc to vin, gnd to gnd, sda to pin 21, and scl to pin 22
This is my variabel luxx for the lux meter, but still get -1.00
void luxx(){
float l = myLux.lightStrengthLux();
Serial.print("value: ");
Serial.print(l);
Serial.println(" (lux).");
Blynk.virtualWrite(V1, l);
delay(1000);
}
i already put the myLux in setup and the luxx in loop
Could you put your code, wire diagram here and tell us what kind of main baord you are using?
If you are using the Arduino, you could upload the I2C scanner to see if your SEN0390 is hooked up properly onto your main board.
https://github.com/luisllamasbinaburo/Arduino-I2CScanner
Yeez_BI use esp32, its same things or not? For code i use some example from library
Hi!
pls try this code.
ESP32 - I2C Scanner using Arduino IDE (working) - ESP32 Forum
https://www.esp32.com/viewtopic.php?t=4742