PDA

View Full Version : Light output measurement using LDR "mini project"



jonykk
03-01-2012, 07:28 AM
Hi there, Im given a project on implement the measurement of light output using light dependent resistor (LDR). The output is display on 2x16 serial LCD using BS2pe and basic stamp programming. To display the output in LUX value or maybe GOOD, AVERAGE or BAD. Do i need to use a 16bit A/D converter to display the results on the LCD? Thank you....

Tony B.
03-01-2012, 01:29 PM
jonykk,

You will not need an A/D. For simple code example and wiring diagram see Parallax's new website Getting Started with Parallax. Here is a link to the info for a LCD. https://sites.google.com/site/parallaxinretailstores/home/2x16-serial-lcd-backlit

Tony

jonykk
03-02-2012, 01:39 AM
Tony,

Im using a LDR to measure the light... the voltage divider is suppose in analog... can i send the signal into BS2pe directly and output the results on the LCD?

jonykk

Tony B.
03-02-2012, 10:20 PM
jonykk,

Sorry for the miss understanding. I guess that's what happens when I try to help early in the morning.

Although I have not worked with the BS2pe, I know it doesn't have an A/D circuit. You could use an A/D, but it may be better and easier for you to try a RC Time circuit (Resistor,Capacitor Time Circuit). For further explanations, schematics and code examples that will work on the BS2pe go to this webpage http://www.parallax.com/StoreSearchResults/tabid/768/List/0/SortField/4/ProductID/46/Default.aspx?txtSearch=usb+scope and down on the lower left of the page download "Understanding Signals Text" and turn to page 57 and following for more information. It would be best if you started reading at the beginning of the chapter on page 49 for a full understanding of how a RC circuit works and how to use it. By the way you don't have to have an oscilloscope to work with an RC circuit.

With some testing you could get values from dark, full light and medium light and decide were the threshold for switching between them should be and have the BS print the appropriate message on the LCD. For example 0-100 is dark, 101-300 medium, 301-500 full.

Hope this helps, :smile:
Tony

jonykk
03-05-2012, 03:14 AM
Tony,

Thanks for the advice and the reading materials..I will try it out and feedback here once im done..Thank you very much.

From,
Jonykk