Shop OBEX P1 Docs P2 Docs Learn Events
Light output measurement using LDR "mini project" — Parallax Forums

Light output measurement using LDR "mini project"

jonykkjonykk Posts: 17
edited 2012-03-04 19:14 in Learn with BlocklyProp
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....

Comments

  • Tony B.Tony B. Posts: 356
    edited 2012-03-01 05:29
    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
  • jonykkjonykk Posts: 17
    edited 2012-03-01 17:39
    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.Tony B. Posts: 356
    edited 2012-03-02 14:20
    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
  • jonykkjonykk Posts: 17
    edited 2012-03-04 19:14
    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
Sign In or Register to comment.