LM35 to ADC

Go To Last Post
14 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'm not very strong in analog stuff, and particularly not in RF, so I could use some advice. :D

I'd like to tie the output of an LM35 to the ADC pin of an XBee module. The desired range over which I'd like to log is 10C-35C. Anything below or above that can simply be logged as out of range.

Since the signal would be between .1 and .35V, in order for the ADC to read it with accuracy and precision, I'd need a pretty low reference voltage - but even then, noise of just a few mV can be a problem.

So, I would think that an op-amp with some gain and a higher reference voltage would be a good thing. That brings me to my first question: Is that thinking on the right track?

Since this will be in the same (small) enclosure as the radio, I would think that using a low-pass filter would be in order, perhaps even an RC between the LM35 and op-amp, and another between the op-amp and ADC pin. Since it will be in close proximity to the radio, a small inductor would also seem in order. So, my second question: Am I going about the filtering correctly, or is there a much better way to keep things clean?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I would use an instrumentation amplifier like the tlc27l2 from TI. It has a low slew rate so noise should not be a problem. There are two amps in the package so you could use the other for anything else you could need.

This way you could use a hight reference and be fine.

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Wow, that is a really good option that I hadn't considered. Or, more appropriately, it's an option I wasn't even aware of. :D

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The chip I refered to has a little 'slow' so transients are not a big deal. I use it all the time. But with the second amp you could create an active filter for the output of the first op-amp.

Oh, one thing, it prefers split supplies in order to achieve accuracy. If that is not an option then you will need to compensate for that. Not hard to do.

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Make the amp a x10 amplifier and now your range is 1v-3.5v. THat should enable tou to use a 5v reference and give you plenty of headroom

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I think I might just have an INA122 (http://focus.ti.com/lit/ds/symlink/ina122.pdf) available to me, which looks better at low supply voltages, and even slower... but if anybody who actually knows what they're doing (as opposed to me) wants to double-check that, I'd appreciate it. :D

Since the rest of the board is all 3.3V, I thought about a 3.0V precision reference, and an 8x gain.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
Since the rest of the board is all 3.3V,

I think +Vsupply is 4-20 V for this sensor...

JC

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Huh, it is indeed. I thought that it would work at 3.3, but I've looked at too many datasheets today, and had far too little sleep last night!

Thanks for catching that.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Your welcome!
That's what peer review is for.

JC

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Take a look at the LM60, they are supposed to be good down to 2.7v. Also, I do not think the 2.5 ghz rf from the module's transmitter will have any effect at all on your temp measurement subsystem. Just employ the usual bypass cap on the LM60's Vcc.

Tom Pappano
Tulsa, Oklahoma

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Since all of the errors will add up, I like the 0.5 degree accuracy of the LM35 over the 2 degree accuracy of the LM60. :D

Thanks for the confirmation that the radio won't be much of a problem. Once I check to see if I do have the INA122, I'm going to order some Xbees.

I originally picked up some cheap modules that are *somewhat* similar in that they give you UART->Wireless, but are as simple and dumb as can be. Rather than doing the checksumming, retransmitting, etc. myself, I'd much rather use the xbees. Besides, the 60mW transmit power and decent antenna options of the xbees will give me a much better range!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Actually if you look carefully at pages 8 and 9 of the datasheet you can see how to change the gain and offset of the LM35. No op amps needed.

Go electric!
Happy electric car owner / builder

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I saw how to change the offset, but not the gain. Which figure should I be looking at?

Changing the offset alone doesn't help, as I still end up using only a small fraction of the resolution of the ADC. The sensor may be .5C accurate, but if +/- 1 LSB is a full degree, that makes things a bit wild. :D

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

page 9. Look close at the equations down at the bottom.

Go electric!
Happy electric car owner / builder