View Full Version : Analog input light sensor question

03-26-2008, 08:31 PM
Hi all, I have a couple Phidget light sensors that I am using in a custom application and was able to import the phidget library and get values within my code, but I am not sure what the values represent exactly. Are they lux measurements? The application I am using it for is to take a measurement and calibrate a display device's brightness according to that value. Also there are two methods for getting the value...one that returns the sensor value which is normalized, and one that returns the raw sensor value. If anyone has any advice on which would be better suited for this type of application I would greatly appreciate it. Thanks in advance!


03-27-2008, 02:04 PM
hi Jared,

The values that the Phidget library outputs are just the digitally converted values of the 0-5V analog signal. Keep in mind that the 8/8/8 does not know what kind of sensor you have plugged into one of its analog ports. It just sees that a signal is coming in and throws an event to tell you about it.

The Phidget.InterfaceKit.sensors[i].value is a filtered value that Phidgets "averages" to get a value ranging between 0 - 1000. Voltage from this value is determined by 5mV per sensor step (5mV * 1000 = 5V).

The Phidget.InterfaceKit.sensors[i].RawValue is a raw, unfiltered value that Phidgets doesn't touch with any averaging. This gives you a 12 bit A-D accuracy of a value ranging between 0 - 4096. This is used in case you want to try and get some better accuracy than the averaged value above.

That aside though, the light sensor is a generic low voltage device which is not very accurate. You won't be able to easily measure lumens from it. You'll need a "known" lumen source and possibly duplicate it somehow.

What I would do is just display a percentage value based off of the range of 0 - 1000.

Hope that helps a bit:)