[SOLVED] DI Light Sensor not showing correct values


I’ve got the grove light sensor for a GoPiGo3.

When I plug it into the AD1 port on the GoPiGo board, and run the example python code for easy_Light_sensor.py (or even the example code from the documentation ) the values printed are consistently 4086 and 99%, regardless of ambient light conditions.

If I cover the sensor by pressing it into the black wheel, then it reports values in the range 4084-4085, and 99%.

Is there something special I have to do to calibrate the values? I have 4 of the light and color sensors, and 5 different GoPiGo3 boards. None of the sensors work with any of the boards, all of them output the same 99% values.

Hi @jdoucette,

Can you take us through the steps you’ve followed so far?

Normally, you should only run 2 commands for installing the required dependencies. Here’s a link on getting started with it:

Thank you!

I get very similar symptoms on both my light sensors (4086 to 4099 and all 99%) regardless of light conditions.

I have run update_gopigo3 and update_sensors and I have updated the GoPiGo3 firmware.

Any other suggestions? Thanks.

Hi @seawrightfamily,

That’s because the link @jdoucette has provided to the light sensor class is meant for the Grove Light Sensor, which is only an analog sensor:

The one we currently sell has the documentation in DI-Sensors. The class you’re interested in is this one:

And here’s an example program for our sensor:

Let me know if this clears the waters for you.

Thank you!

Wow, Robert, how on earth did I end up using old documentation!? Looks like your advise was spot on. I am reading values now.

Thank you. I will update my message on the forum.




Hi @seawrightfamily,

I’m glad to hear it solved your problem. I’ll have the thread closed now.

Thank you!