16f877 with LM335 problem


Closed Thread
Results 1 to 40 of 47

Hybrid View

  1. #1
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,175


    Did you find this post helpful? Yes | No

    Default Re: Any schematic to achieve this please?

    Attached is one idea. First op-amp works as an adder (or subtracter). It removes the DC offset voltage from the + input. So output is around 0-0,58 volts for -30 to 30 deg.

    Then the second op-amp works as an DC amplifier to boost the 0,58 to 5 volts. So you have to make two adjustments, trimmer R9 at 2,4315 volts and R10 to get 5 Volts for 30 deg.

    Also very critical is to select op-amps that are able to work at 5Volts and be rail to rail. I thing LMC662 is such a chip.

    Ioannis

    Name:  LM335.png
Views: 4930
Size:  10.2 KB

  2. #2
    Join Date
    Aug 2006
    Location
    SWITZERLAND (french speaking)
    Posts
    964


    Did you find this post helpful? Yes | No

    Default Pros & cons of the "opamp circuit" over the LM35 component

    Ioannis,

    Thank you very much for the schema and your comment.

    I need to check what the opamps in my drawer can do and if they don't, I'll order some to test this.

    It makes it quite a "large" circuit in comparison of the usage of a single LM35.

    What would be the advantage of this circuit vs a LM35 please?
    Roger

  3. #3
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,175


    Did you find this post helpful? Yes | No

    Default Re: Pros & cons of the "opamp circuit" over the LM35 component

    If it seems too complicated, you can remove R5, R6, R8 making exact adjustment more critical.

    The circuit will give you more resolution for the range you asked, -30 to +30 for a 0 to 5 volts output or about 0,083 volt/deg celsious.

    Also it gives you an output for negative temperatures.

    For the LM35 you will get 10mV/C. This means you will get from 0-0,3 volts for 0-30 C. If you want to measure from -30, then you must raise the ground of the LM35 above say 0,3 or better 0,6 volts. Maybe with a diode. Your output then will not be referenced to ground but from the pins of the LM35 (out and LM35 gnd). Your span for -30 to +30 will be 0,6 volts. If you need to drive an ADC then it would be better to amplify this small signal too.

    HTH,
    Ioannis

  4. #4
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default Re: 16f877 with LM335 problem

    I think you are better off with the LM335 as it's output is 10mv/deg K. The LM35 is 10mv/deg.c. There is going to be a problem with the accuracy below 0 deg C. when using the LM35. If you would like rather than analog you could use a TMP-03/04 from Analog Devices which is a pulse width output. I have used these before and work quite well. Just a thought...
    Dave Purola,
    N8NTA
    EN82fn

  5. #5
    Join Date
    Aug 2006
    Location
    SWITZERLAND (french speaking)
    Posts
    964


    Did you find this post helpful? Yes | No

    Default Re: 16f877 with LM335 problem

    I think you are better off with the LM335 as it's output is 10mv/deg K. The LM35 is 10mv/deg C.
    Hum...can you explain a little more please?

    I thought Kelvin were used to express a temperature difference and Celsius/Fahrenheit would represent a value. I must be wrong.
    Roger

  6. #6
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,175


    Did you find this post helpful? Yes | No

    Default Re: 16f877 with LM335 problem

    Deg Kelvin references differently. 0 deg Kelvin is the absolute zero. The point that every thermal motion stops. To convert it to Celsius, just add 273,15. So the 0 Celsius is 273,15 Kelvin and 0 Kelvin -273,15 celsius.

    Ioannis

  7. #7
    Join Date
    Aug 2006
    Location
    SWITZERLAND (french speaking)
    Posts
    964


    Did you find this post helpful? Yes | No

    Default Setting up the LM35 and an opamp as voltage doubler

    Thanks Ioannis.

    This (schema) is where I have come up to now - using the simple simplest, maybe too simple (...) The opamp acts as a voltage doubler (seems enough for what I need).

    BTW, I'm using a 16F690 with 10 bits ADC.
    Name:  rsz_ampli_op_2x.jpg
Views: 4739
Size:  9.6 KB
    At 24°C, the LM35 outputs 1,199V so the opamp's Vout shows 2,396V.

    Now, what is the LM35 going to output at 0°C or even less, around -20°C?

    Since 1,199V represent 24°C, can I say that at 0°C, I will have 0,959Volts (LM35 Vout)?

    Talking "temperature", what is the reference when adjusting temperature sensors at home?

    Is it this?
    Name:  rsz_digital_thermometer_hyrometer_30010106.jpg
Views: 4317
Size:  9.3 KB
    Noooooooooooooo......

    NB: You're absolutely right about Kelvins. In the field, talking with cooling systems engineers, to make sure we don't get messed up while setting up machines, we (wrongly) use Kelvins to express a temperature difference or threshold and degrees to set a temperature value
    Roger

Similar Threads

  1. 16F877 HSERIN problem with 3th party software
    By RFsolution in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 11th March 2009, 17:11
  2. LCD problem with 16F877
    By alexx_57 in forum General
    Replies: 10
    Last Post: - 25th July 2007, 13:47
  3. problem using 16f877
    By yrch in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 20th February 2006, 18:58
  4. 16F877 20MHz problem
    By swordman in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 31st July 2004, 10:02
  5. 16F877, DS18S20 and Serial Comm Problem
    By YellowTang in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 26th April 2004, 10:36

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts