Shop OBEX P1 Docs P2 Docs Learn Events
LM34 and the Basic Stamp 2.5 — Parallax Forums

LM34 and the Basic Stamp 2.5

kovachjmkovachjm Posts: 2
edited 2013-12-07 10:17 in BASIC Stamp
What is the best way to use the temperature sensor LM34 for the Basic Stamp 2.5. I do not have an ADC chip; can I use the RCtime command? What would the RC circuit look like attached to the LM34 leads?

Comments

  • SapphireSapphire Posts: 496
    edited 2013-12-06 18:10
    You cannot use RC time to read the LM34 temp. It requires an ADC, or at least a comparator configured to function as an ADC which you drive with the stamp.
  • bsjohnbsjohn Posts: 19
    edited 2013-12-06 18:13
    Well the most elegant way is with a ADC because the lm34 outputs in increments of 10mv/F degree but lacking that I found these articles which should suite you well:
    http://www.societyofrobots.com/robotforum/index.php?topic=8776.0
    http://www.noisemantra.com/BASICStampAnalogInput.htm
    I've never tried these so your results may vary.
  • kovachjmkovachjm Posts: 2
    edited 2013-12-06 21:37
    Thank you for the replies. I ended up just borrowing an Arduino from a friend to use.

    -bsjohn, Thanks for the articles, the second one seems to make a lot of sense. I am going to finish my project with an Arduino. But, after I finish it I will return to the BS2 and try to see if I can modify the circuit in the second article for my use.

    Thanks
  • davejamesdavejames Posts: 4,047
    edited 2013-12-07 07:20
    kovachjm - hope that you come back from the "dark side" soon! :smile:

    BTW, I changed your original post to indicate "solved".
  • Tracy AllenTracy Allen Posts: 6,662
    edited 2013-12-07 10:17
    That's funny, the societyofrobots link is a verbatim but unattributed copy of my article at http://emesystems.com/BS2rct.htm#B_voltage.

    Neither that nor the noisemantra articles are good ways to deal with the LM34.

    If you really want to use the LM34 in an RCtime circuit, look at the figure in the LM34 data sheet under the caption, "Two-Wire Remote Temperature Sensor (Output Referred to Ground)". That turns the LM34 into a linear current source of 20µA/°F that can charge the RCTIME capacitor at a rate directly proportional to temperature. You would replace the 50kΩ rheostat shown in that schematic with a stable capacitor, say 0.01µF.
Sign In or Register to comment.