Shop OBEX P1 Docs P2 Docs Learn Events
Philips LM75A interfacing with Basic Stamp 2? — Parallax Forums

Philips LM75A interfacing with Basic Stamp 2?

DuCzDuCz Posts: 9
edited 2007-08-01 12:10 in BASIC Stamp
I'm working on a project which requiring to monitor 3 temperature input from 3 difference probe. I have a LM75A Digital temperature sensor and thermal Watchdog + 3x 100Ohms Resistance Thermometers and i have no ideal how to hook them up to the IC and interfacing with Basic Stamp.

Please HELP! any idea or suggestions would be greatly appreciated. THANK HEAPS!!!

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
BASIC Stamp 2sx:$59 4x20 Serial LCD:$99.95 4 x 4 Matrix Keypad:$19 Parallax Professional Development Board:$149.95 Got helps from Parallax Forums :PRICELESS For everything else:Ebay.com

Post Edited (DuCz) : 7/14/2007 10:50:27 AM GMT

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2007-07-12 16:57
    Hello,

    Some things that may possible help you get answers from forum members would be to include details about the IC and sensors. Perhaps post links to the datasheets. Take care.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
  • DuCzDuCz Posts: 9
    edited 2007-07-13 02:37
    Hi Chris,

    Thank you for your reply.

    Sensor Info: (see pics)

    The sensor has a resistance of 100 ohms at 0 Celsius and 138.4 ohms at 100 Celsius, 2-wire configuration

    Size: 5mm dia. about 28mm length. 160mm leads.

    IC info: (Please see attachment)

    1. Do i connect the sensor to OS pin3 ???
    2. Can i connect more than 1 sensor to the chips?
    400 x 157 - 8K
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2007-07-13 04:28
    The LM75A is an I2C device whose pin out looks suspiciously like an EEPROM. In any event it can connect directly to a BASIC Stamp. It would be easier if you had a BS2p which supports I2C directly, but it could be done with a BS2. As for the three thermistors you will need an ADC or similar to read them with any accuracy. You can find some examples of reading a temperature probe in the Applied Sensors and Process Control manuals on our website. I hope this helps. Take care.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
  • pwillardpwillard Posts: 321
    edited 2007-07-13 15:29
    Having to add an external ADC might actually be more complex than just using the LM75 and the BIT-BANG method if you have just a BS2. There are examples of using the I2C protocol in Stamps that don't have native I2C support. (I2Cout and I2Cin commands aren't there in the bare bones Stamp)

    For good examples on how this would be done, read "The Nuts and Volts of Basic Stamps" article # 85. Jon Williams to the rescue. It should be available somewhere on the Parallax site or on the Parallax CDROM. Even though it talks about the PCF8574, the techniques for the LM75 will be close enough, just look at your Datasheet for the specifics. like device address and how to read values.

    Pete
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2007-07-13 17:53
    Pete,

    Bear in mind the ADC wasn’t to interface the LM75A…It was for the temperature probes (thermistors) that he has. The LM75A should hook directly as mentioned.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
  • pwillardpwillard Posts: 321
    edited 2007-07-13 18:05
    Yes,·· sorry I wan't clear.· I understood that the ADC was for the 3 thermistors.· ;-)

    ..and forgive me for not being a fan of thermistors over semiconductor solutions.· Somehow thermistors lack a certain coolness factor (pun intended).

    Pete
  • DuCzDuCz Posts: 9
    edited 2007-07-14 09:21
    Dear Chris and Pete,

    Thank you so much for your responses,

    I’m actually using the BS2SX module which supports I2C directly, so connecting the LM75 to BS2SX shouldn’t be a problem.

    So, I need the ADCs (such as ADC0831) for my 3 temperature probes, hook them up to the LM75A then interface it with the BX2SX???

    I’m a little confused, according to the datasheet. The LM75 is a temperature-to-digital converter using an on-chip band-gap temperature sensor and Sigma-delta A-to-D conversion. Does it mean this device has a built-in 11-bit ADC and a temperature senor???
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2007-07-14 09:34
    DuCz -

    The I2C commands I2CIN and I2COUT are NOT supported on the BS-2SX. You need to use a BS-2p- series PBASIC Stamp in order to use those commands. That's NOT to say that I2C can't be utilized on a BS-2SX, it's just that there are no native commands for doing so.

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
  • pwillardpwillard Posts: 321
    edited 2007-07-14 11:28
    ducz said...
    Does it mean this device has a built-in 11-bit ADC and a temperature senor???
    Yes, that's correct.·· The LM75 does not require any external devices to sense the ambient temperature. It is a self contained temperature sensor with all of the sensing and conversion within it.· All you need to do is "ask the right question" and it responds.

    The LM75 has been commonly used to monitor PC motherboard temperature.· Many motherboards have a number of these in various places, such as "under the CPU" and in non-heat generating place to measure general case temperature.· The chip needs to be located "where" you want the temperature measured.

    Now, with that said... maybe your application has confined space where mounting the chip is more difficult than a thermistor.· In that case, then a separate ADC chip and thermistors (or LM34) might be a better choice.

    http://www.national.com/mpf/LM/LM75.html

    Pete

    Post Edited (pwillard) : 7/14/2007 11:45:29 AM GMT
  • DuCzDuCz Posts: 9
    edited 2007-07-14 13:40
    Thank heaps everyone for your HELP!!!

    Pete, thank you so much for the explanations and it is very clear now. It seems that I choose the in-correct ADC.

    One more question [noparse]:)[/noparse] So if I need to proceed 3 input channel (3 probes) ADC, I'm better off using the MAX1270 instead of the ADC0831 with a multiplexer between it?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    BASIC Stamp 2sx:$59 4x20 Serial LCD:$99.95 4 x 4 Matrix Keypad:$19 Parallax Professional Development Board:$149.95 Got helps from Parallax Forums :PRICELESS For everything else:Ebay.com
  • Tracy AllenTracy Allen Posts: 6,664
    edited 2007-07-14 17:32
    It sounds like the three resistance sensors are RTDs (resistance temperature device). In answer to your last question, yes, you are better off with an ADC like the MAX1270 with 12 bits of resolution and a built in multiplexer. There is a another issue, though. Those 100 ohm RTDs have a relatively low resistance and the change over the full temperature range 0 to 100 degC is only 38.4 ohms. The simplest way to read the resistance is to put the RTD in series with another resistor, say 1000 ohms s as not to draw too much current and heat up the RTD. Then the voltage at the junction of the resistors goes into the ADC, but that voltage only changes by 0.153 volts for the whole temperature range. That would be about 125 counts on the ADC, about 1 degC resolution. Is that enough? There are tricks you can play with the ADC reference or with amplifier circuitry to improve that.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tracy Allen
    www.emesystems.com
  • DuCzDuCz Posts: 9
    edited 2007-07-15 12:44
    Dear Tracy Allen,

    Thank you so much for your suggestion, that is exactly what I'm thinking of doing by simply adding a series resistor, the total resistance is also accounting for the 2-3m leads from the ADC to RTD (capacitor require ???) which could effect the resolution.

    If i want to get a 1/2DegC resolution? Do i simply half the Vref=2.048v???

    Thank heaps

    DuCz

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    BASIC Stamp 2sx:$59 4x20 Serial LCD:$99.95 4 x 4 Matrix Keypad:$19 Parallax Professional Development Board:$149.95 Got helps from Parallax Forums :PRICELESS For everything else:Ebay.com
  • Tracy AllenTracy Allen Posts: 6,664
    edited 2007-07-15 18:01
    With a 100 ohm RTC, the length of the leads at 2 to 3 meters of say 22 gage wire is going to matter much and it is a fixed offset. However, you have to be meticulous with the connections, that they are solidly made. You don't want any resistance in the connections. A capacitor might help a little bit, but the impedance of 100 ohms is very low, so electrostatic pickup will be a minimal concern. Magnetic pickup is another matter and just to be sure you should run twisted pair, shielded twisted pair, to the RTD.

    The MAX1270 has selectable ranges, however, AFAIK it does not allow an external reference. For that you need to find the less common MAX1271.

    Another ADC you might consider is the TLC2543, which has 11 input channels and which would allow you to set both the lower and upper reference points. So for example you could set a full scale range from say 0.4 to 0.8 volt with pretty good resolution.

    Another option would be one of the 24 bit converters, even referenced to the power supply. I don't recall what part number, but there are some of those that are designed specifically for interface to RTDs, with the excitation built in.

    And finally, another option would be to have the RTD in a circuit that amplifies its signal and subtracts the offset, so the output would be, say, 0 to 5 volts for -25 to 100 degC, so you could put that into any ADC.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tracy Allen
    www.emesystems.com
  • DuCzDuCz Posts: 9
    edited 2007-07-31 12:08
    Dear Tracy Allen,

    I'm have troubles getting my hand on the TLC2543 at my local electronic stores. However after searching around on the net, I found Futurlec.com carrying a Microchip MCP3304 8-Channel 13-Bit A/D Convertor w/SPI which I thinks is suitable for my application.

    I also found the Analog Device AD7714 24-Bit Sigma-Delta A/D Converter is this the one you are talking about?

    DuCz

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    BASIC Stamp 2sx:$59 4x20 Serial LCD:$99.95 4 x 4 Matrix Keypad:$19 Parallax Professional Development Board:$149.95 Got helps from Parallax Forums :PRICELESS For everything else:Ebay.com
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2007-07-31 14:33
    DuCz -

    In the future you may want to search for chip distributors here:
    http://www.findchips.com/

    They show 11 distributors who have the TLC2543 you were seeking.

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
  • DuCzDuCz Posts: 9
    edited 2007-07-31 15:22
    Dear Bruce,

    Thank you so much for the link, the problem is I'm living in Australia.

    Regards,

    DuCz

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    BASIC Stamp 2sx:$59 4x20 Serial LCD:$99.95 4 x 4 Matrix Keypad:$19 Parallax Professional Development Board:$149.95 Got helps from Parallax Forums :PRICELESS For everything else:Ebay.com
  • Tracy AllenTracy Allen Posts: 6,664
    edited 2007-07-31 16:58
    Burr-Brown/TI has a line of RTD to current loop conditioners, the XTR114 being one example. If you visit www.ti.com and type rtd into their search engine you will get lots of hits.

    The AD7711 is a 24 bit converter with special support for RTDs. A similar device from Linear Technology is the LTC2446. However, due to multiple inputs and operating modes, and multiple pin surface mount packaging, and engineering considerations, these devices are daunting. A simple single channel 24 bit converter like the LTC2420 is not so difficult and will come in a much more manageable package. But you have 3 sensors, right?

    Farnell Australia carries the TLC2543. I have lots of them around in DIP packages and could probably mail you one cheaper than you could purchase it there. Contact me via PM if you're interested. I don't know about the MCP3304, but I'm sure there are lots of chips out there that could do the job.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tracy Allen
    www.emesystems.com
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2007-07-31 19:24
    DuCz -

    Did you try Dick Smith Electronics?

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
  • OzStampOzStamp Posts: 377
    edited 2007-08-01 12:10
    Hi Bruce and DuCZ

    Dick Smith as you know them Bruce "HI how are you" > ... they sell tv's toasters vacuums etc etc.
    Very little in the way of stuff for the hobbyist these day's
    If you asked for some TLC2543's .. .. they probably would think you wanted some "Tender Loving Care"
    You want fries with that..
    Sorry could not resist..

    DuCZ we keep stock of the following ad chips ADC0831 TLC1549 and also the LTC1298
    Cheers Ronald Nollet Australia
Sign In or Register to comment.