Shop OBEX P1 Docs P2 Docs Learn Events
Temperature sensor — Parallax Forums

Temperature sensor

ArchiverArchiver Posts: 46,084
edited 2004-03-02 21:14 in General Discussion
Hi everybody,

I'm working on a central heating control project. I have to get the
temperature from different places, which are far from the control unit.
I'd like to use PT100 sensors, because they're very reliable and linear.
Does somebody know if there is a chip which converts the PT100 resistance
into a CURRENT value ? I'd like to get a current value to avoid voltage drop
on the line.
There is maybe another solution, like integrated temperature sensors. Any
idea is welcome !
Thanks in advance for your help !

Philippe Derenne

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2000-08-10 23:39
    Check out National Semiconductors website for the LM35. They have a good
    twisted pair circuit for the LM35.
    Original Message
    From: "Philippe Derenne" <derennep@s...>
    To: <basicstamps@egroups.com>
    Sent: Thursday, August 10, 2000 3:15 PM
    Subject: [noparse][[/noparse]basicstamps] Temperature sensor


    > Hi everybody,
    >
    > I'm working on a central heating control project. I have to get the
    > temperature from different places, which are far from the control unit.
    > I'd like to use PT100 sensors, because they're very reliable and linear.
    > Does somebody know if there is a chip which converts the PT100 resistance
    > into a CURRENT value ? I'd like to get a current value to avoid voltage
    drop
    > on the line.
    > There is maybe another solution, like integrated temperature sensors. Any
    > idea is welcome !
    > Thanks in advance for your help !
    >
    > Philippe Derenne
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-10 23:48
    Hi Matthew,

    Thanks for your fast answer ! I got the information from this site, it looks
    like that's what I'm looking for !

    Best regards,

    Philippe Derenne

    Original Message
    From: Matthew Lewis <aiden.bell@h...>
    To: <basicstamps@egroups.com>
    Sent: Friday, August 11, 2000 12:39 AM
    Subject: Re: [noparse][[/noparse]basicstamps] Temperature sensor


    > Check out National Semiconductors website for the LM35. They have a good
    > twisted pair circuit for the LM35.
    >
    > > Hi everybody,
    > >
    > > I'm working on a central heating control project. I have to get the
    > > temperature from different places, which are far from the control unit.
    > > I'd like to use PT100 sensors, because they're very reliable and linear.
    > > Does somebody know if there is a chip which converts the PT100
    resistance
    > > into a CURRENT value ? I'd like to get a current value to avoid voltage
    > drop
    > > on the line.
    > > There is maybe another solution, like integrated temperature sensors.
    Any
    > > idea is welcome !
    > > Thanks in advance for your help !
    > >
    > > Philippe Derenne
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-11 00:17
    Hi Phillipe,

    You might also look into the AD590 or AD592, which are a linear current
    output temperature sensors meant for use on long cables.

    http://www.emesystems.com/OWL2face.htm#AD590
    http://www.stampsinclass.com/downloads/em3.pdf

    --Tracy
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-11 00:25
    Hi Tracy,

    Thanks for those very usefull informations !

    Philippe Derenne

    Original Message
    From: Tracy Allen <emesys@c...>
    To: <basicstamps@egroups.com>
    Sent: Friday, August 11, 2000 1:17 AM
    Subject: [noparse][[/noparse]basicstamps] Temperature sensor


    > Hi Phillipe,
    >
    > You might also look into the AD590 or AD592, which are a linear current
    > output temperature sensors meant for use on long cables.
    >
    > http://www.emesystems.com/OWL2face.htm#AD590
    > http://www.stampsinclass.com/downloads/em3.pdf
    >
    > --Tracy
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-11 00:37
    Phililppe,

    Your welcome, make sure to use the right case style for your app. The
    LM35DZ is the most general and it has a plastic package. The most usefull
    is the T-220 syle.

    I have used the twisted pair circuit before and it works well. Using an
    op-amp will help with the noise too.


    Matthew
    Original Message
    From: "Philippe Derenne" <derennep@s...>
    To: <basicstamps@egroups.com>
    Sent: Thursday, August 10, 2000 3:48 PM
    Subject: Re: [noparse][[/noparse]basicstamps] Temperature sensor


    > Hi Matthew,
    >
    > Thanks for your fast answer ! I got the information from this site, it
    looks
    > like that's what I'm looking for !
    >
    > Best regards,
    >
    > Philippe Derenne
    >
    >
    Original Message
    > From: Matthew Lewis <aiden.bell@h...>
    > To: <basicstamps@egroups.com>
    > Sent: Friday, August 11, 2000 12:39 AM
    > Subject: Re: [noparse][[/noparse]basicstamps] Temperature sensor
    >
    >
    > > Check out National Semiconductors website for the LM35. They have a
    good
    > > twisted pair circuit for the LM35.
    > >
    > > > Hi everybody,
    > > >
    > > > I'm working on a central heating control project. I have to get the
    > > > temperature from different places, which are far from the control
    unit.
    > > > I'd like to use PT100 sensors, because they're very reliable and
    linear.
    > > > Does somebody know if there is a chip which converts the PT100
    > resistance
    > > > into a CURRENT value ? I'd like to get a current value to avoid
    voltage
    > > drop
    > > > on the line.
    > > > There is maybe another solution, like integrated temperature sensors.
    > Any
    > > > idea is welcome !
    > > > Thanks in advance for your help !
    > > >
    > > > Philippe Derenne
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-11 08:17
    At 12:15 AM 8/11/00, you wrote:
    >Hi everybody,
    >
    >I'm working on a central heating control project. I have to get the
    >temperature from different places, which are far from the control unit.
    >I'd like to use PT100 sensors, because they're very reliable and linear.
    >Does somebody know if there is a chip which converts the PT100 resistance
    >into a CURRENT value ? I'd like to get a current value to avoid voltage drop
    >on the line.
    >There is maybe another solution, like integrated temperature sensors. Any
    >idea is welcome !
    >Thanks in advance for your help !
    >
    >Philippe Derenne

    Hi Philippe -

    The easiest, quickest, and most efficient solution is probably to use one
    of the various Honeywell (or others) Integrated HVAC Controller systems,
    and modify the control of that, if necessay, with a microcontroller.
    Otherwise, you have a rather ambitious project ahead of you which may tax
    both your time and your patience. Of course, packaged systems aren't much
    fun :-)

    That aside, Dallas Semiconductors [noparse][[/noparse]www.dalsemi.com ] has a thermostat on a
    chip (see below), as well as various temperature sensor chips and other
    allied components. They offer a complete line of time/date, and
    environmental condition oriented chips. Their thermal management offerings
    include 3-wire, 2-wire, and 1-wire types. Steer clear of the Dallas 1-wire
    units, since there are timing considerations which are difficult (if not
    impossible) to overcome with the Stamp (alone). If the 1-wire systems
    appeal to you, I would personally opt for a MicroChip PIC and use either
    C++ or PBasic Pro from Micro Engineering Labs [noparse][[/noparse] www.melabs,com ]. I
    purchased mine from Chuck at ElProducts
    [noparse][[/noparse] www.elproducts.com ], and am quite pleased with it. It offers the ability
    to code in assembler (as many C compilers do) for routines where the Basic
    language is inadequte for the task, or too slow. The system follows that of
    the Parallax PBASIC Stamps, and accepts most of it without much change.

    Thermostat-On-A-Chip

    There are various offerings in DS-162x series, and with various features.
    The DS-1624 (a 2-wire unit) has 256 bytes of EEPROM for saving data
    (reducing the on Stamp data storage requirements), is multi-drop (up to 8
    units per bus), and can be controlled and addressed via the PABSIC
    operators Shiftin/Shiftout (I believe). This is a high-precision,
    "direct-to-digital" [noparse][[/noparse]tm] unit.

    Please remember there is a 2-byte (13 bit) data transfer, due to the
    greater accuracy of this device over other 8-bit units. This will
    necessitate allocation of WORD length variables on the Stamp/PIC.The
    DS-1629 also includes an RTC is you find that is a requirement for your design.

    The FTP site [noparse][[/noparse] ftp://ftp.dalsemi.com/pub/ ] has zipped packages of chip
    data and applications information, or the inline HTTP links can be used as
    well. A less integrated and less accurate non-networked solution (4-20 mA
    examples are often given, however, with external components) can be
    obtained by use of the LM-35 style chips by National [noparse][[/noparse] www.natsemi.com ]
    and others. Parallax [noparse][[/noparse]www.parallaxinc.com ] offers APPMods for these
    products. From my point of view, these LM-35 (type) chips generally fall
    short in two areas:

    1) they are not directly addressable, and

    2) the output is analog, as opposed to digital

    Neither shortfall prevents thier use, but the Dallas parts include all that
    PLUS the EEPROM and thermostat function - all on one chip. Additionally,
    the Dallas chips have an applications note for an evaluation board (DS-1702-K,
    [noparse][[/noparse] http://www.dalsemi.com/news/resource/rsc9_1702k.html ], which is actually
    a temperature controller (such as you may be presently considering), to
    ease re-inventing the wheel, or just to evaluate present (and future) free
    samples, as they become available.

    Hope that helps.

    Regards,

    Bruce Bates
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-11 15:46
    Hi Philippe

    ·
    Hi everybody,

    I'm working on a central heating control project. I have to get the
    temperature from different places, which are far from the control unit.
    I've used a SMT160-30 (Farnell) , this can directly interface to a microP, it uses some PWM output.You must measure the width of the puls high state and low state, then mix that with a little math.
    Of course calibrating is difficult.
    But's just an idea.
    --- Greetings from Joost Luyten, ON2BBP
    email :
    - on2bbp@pi.be
    - on2bbp@advalvas.be (this sends an SMS notification to my mobile phone)
    ICQ· : 45143957
    Home :
    Joost Luyten
    Werftsesteenweg 44
    2220 Heist op den Berg
    Belgium
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-12 13:43
    Hi Hans,

    Thanks for this advice. It looks like those Dallas ICs are closer to the
    Stamp than analog sensors...
    I went to your site, your LawnMover is very interesting ! I've read
    somewhere that you're about to translate those pages to english... this
    would be nice !

    Best regards,

    Philippe Derenne

    Original Message
    From: MUX / robotshop.nu <mux@l...>
    To: <basicstamps@egroups.com>
    Sent: Friday, August 11, 2000 8:06 AM
    Subject: SV: [noparse][[/noparse]basicstamps] Temperature sensor


    Hi Philippe!

    Well, i have already read several great ansvers to your query e.g. th
    excellent LM 35.

    However, just to make sure you are aware of the great temp-sensors from
    "dallas semiconductors"

    Theese smart chips measures the temp an sends out the temp as serial code,
    that can be directly connected to
    the STAMP, no extras needed. AND, one type of "dallas sensor" has individual
    adresses, so you can hook as many as you want on a long serial cable and
    from your STAMP "ask" for each temperature...

    The rechnique is described in several of the PDF-documents regarding "Stamp
    in class" at parallax...try the "earth and measure" work book.

    I think that therar are more "serial-sensors" from dallas, like an small
    sensor, with "individual adress", that detects an digital input, so you
    could monitor both temperatures and "status" of various stuff like motors,
    pumps alarms etc...all on the same wire!


    Greetings
    Hans Forsberg
    http://www.robotshop.nu
    Build your own STAMP powered LawnMover...

    Ursprungligt meddelande
    Fr
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-12 13:47
    Hi Bruce,

    Congratulations, your answer is the more complete I received !
    Many thanks for your advice, and for those interesting web addresses. I'll
    have a look there.

    Best regards,

    Philippe Derenne

    Original Message
    From: Bruce Bates <bvbates@u...>
    To: <basicstamps@egroups.com>
    Sent: Friday, August 11, 2000 9:17 AM
    Subject: Re: [noparse][[/noparse]basicstamps] Temperature sensor


    > At 12:15 AM 8/11/00, you wrote:
    > >Hi everybody,
    > >
    > >I'm working on a central heating control project. I have to get the
    > >temperature from different places, which are far from the control unit.
    > >I'd like to use PT100 sensors, because they're very reliable and linear.
    > >Does somebody know if there is a chip which converts the PT100 resistance
    > >into a CURRENT value ? I'd like to get a current value to avoid voltage
    drop
    > >on the line.
    > >There is maybe another solution, like integrated temperature sensors. Any
    > >idea is welcome !
    > >Thanks in advance for your help !
    > >
    > >Philippe Derenne
    >
    > Hi Philippe -
    >
    > The easiest, quickest, and most efficient solution is probably to use
    one
    > of the various Honeywell (or others) Integrated HVAC Controller systems,
    > and modify the control of that, if necessay, with a microcontroller.
    > Otherwise, you have a rather ambitious project ahead of you which may tax
    > both your time and your patience. Of course, packaged systems aren't much
    > fun :-)
    >
    > That aside, Dallas Semiconductors [noparse][[/noparse]www.dalsemi.com ] has a thermostat on a
    > chip (see below), as well as various temperature sensor chips and other
    > allied components. They offer a complete line of time/date, and
    > environmental condition oriented chips. Their thermal management offerings
    > include 3-wire, 2-wire, and 1-wire types. Steer clear of the Dallas
    1-wire
    > units, since there are timing considerations which are difficult (if not
    > impossible) to overcome with the Stamp (alone). If the 1-wire systems
    > appeal to you, I would personally opt for a MicroChip PIC and use either
    > C++ or PBasic Pro from Micro Engineering Labs [noparse][[/noparse] www.melabs,com ]. I
    > purchased mine from Chuck at ElProducts
    > [noparse][[/noparse] www.elproducts.com ], and am quite pleased with it. It offers the
    ability
    > to code in assembler (as many C compilers do) for routines where the Basic
    > language is inadequte for the task, or too slow. The system follows that
    of
    > the Parallax PBASIC Stamps, and accepts most of it without much change.
    >
    > Thermostat-On-A-Chip
    >
    > There are various offerings in DS-162x series, and with various features.
    > The DS-1624 (a 2-wire unit) has 256 bytes of EEPROM for saving data
    > (reducing the on Stamp data storage requirements), is multi-drop (up to 8
    > units per bus), and can be controlled and addressed via the PABSIC
    > operators Shiftin/Shiftout (I believe). This is a high-precision,
    > "direct-to-digital" [noparse][[/noparse]tm] unit.
    >
    > Please remember there is a 2-byte (13 bit) data transfer, due to the
    > greater accuracy of this device over other 8-bit units. This will
    > necessitate allocation of WORD length variables on the Stamp/PIC.The
    > DS-1629 also includes an RTC is you find that is a requirement for your
    design.
    >
    > The FTP site [noparse][[/noparse] ftp://ftp.dalsemi.com/pub/ ] has zipped packages of chip
    > data and applications information, or the inline HTTP links can be used
    as
    > well. A less integrated and less accurate non-networked solution (4-20 mA
    > examples are often given, however, with external components) can be
    > obtained by use of the LM-35 style chips by National [noparse][[/noparse] www.natsemi.com ]
    > and others. Parallax [noparse][[/noparse]www.parallaxinc.com ] offers APPMods for these
    > products. From my point of view, these LM-35 (type) chips generally fall
    > short in two areas:
    >
    > 1) they are not directly addressable, and
    >
    > 2) the output is analog, as opposed to digital
    >
    > Neither shortfall prevents thier use, but the Dallas parts include all
    that
    > PLUS the EEPROM and thermostat function - all on one chip. Additionally,
    > the Dallas chips have an applications note for an evaluation board
    (DS-1702-K,
    > [noparse][[/noparse] http://www.dalsemi.com/news/resource/rsc9_1702k.html ], which is
    actually
    > a temperature controller (such as you may be presently considering), to
    > ease re-inventing the wheel, or just to evaluate present (and future) free
    > samples, as they become available.
    >
    > Hope that helps.
    >
    > Regards,
    >
    > Bruce Bates
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-12 14:04
    Hi Joost,

    It's funny to have a conversation with another Belgian thru a server in USA !
    Thanks for your idea. I think the most difficult part of my job will be choosing between all answers I got...

    Best regards,

    Philippe Derenne
    Computer Solutions
    Goz
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-13 01:40
    Hello Philippe,

    Try looking at our temperature and humidity sensor product the RHT7 at
    www.technologykit.com

    It will transmit the temperatures and humidity over long distances, and
    directly interface with a stamp or microprocessor without the need for
    external circuitry. Another "plus" of our unit is the onboard calibration
    system.

    Sincerely,

    Charles Page, President, Technology Electronics, Ltd.

    Original Message
    From: Philippe Derenne <derennep@s...>
    To: basicstamps@egroups.com <basicstamps@egroups.com>
    Date: Thursday, August 10, 2000 6:18 PM
    Subject: [noparse][[/noparse]basicstamps] Temperature sensor


    >Hi everybody,
    >
    >I'm working on a central heating control project. I have to get the
    >temperature from different places, which are far from the control unit.
    >I'd like to use PT100 sensors, because they're very reliable and linear.
    >Does somebody know if there is a chip which converts the PT100 resistance
    >into a CURRENT value ? I'd like to get a current value to avoid voltage
    drop
    >on the line.
    >There is maybe another solution, like integrated temperature sensors. Any
    >idea is welcome !
    >Thanks in advance for your help !
    >
    >Philippe Derenne
    >
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-08-13 11:40
    Hello Charles,

    Thanks for this information, I'll have a look on your site.

    Best regards,

    Philippe Derenne
    Original Message
    From: Technology Electronics, Ltd. <teltd@i...>
    To: <basicstamps@egroups.com>
    Sent: Sunday, August 13, 2000 2:40 AM
    Subject: Re: [noparse][[/noparse]basicstamps] Temperature sensor


    > Hello Philippe,
    >
    > Try looking at our temperature and humidity sensor product the RHT7 at
    > www.technologykit.com
    >
    > It will transmit the temperatures and humidity over long distances, and
    > directly interface with a stamp or microprocessor without the need for
    > external circuitry. Another "plus" of our unit is the onboard calibration
    > system.
    >
    > Sincerely,
    >
    > Charles Page, President, Technology Electronics, Ltd.
    >
    >
    Original Message
    > From: Philippe Derenne <derennep@s...>
    > To: basicstamps@egroups.com <basicstamps@egroups.com>
    > Date: Thursday, August 10, 2000 6:18 PM
    > Subject: [noparse][[/noparse]basicstamps] Temperature sensor
    >
    >
    > >Hi everybody,
    > >
    > >I'm working on a central heating control project. I have to get the
    > >temperature from different places, which are far from the control unit.
    > >I'd like to use PT100 sensors, because they're very reliable and linear.
    > >Does somebody know if there is a chip which converts the PT100 resistance
    > >into a CURRENT value ? I'd like to get a current value to avoid voltage
    > drop
    > >on the line.
    > >There is maybe another solution, like integrated temperature sensors. Any
    > >idea is welcome !
    > >Thanks in advance for your help !
    > >
    > >Philippe Derenne
    > >
    > >
    > >
    > >
    > >
    > >
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2001-02-03 04:17
    Hello

    How can i convert the 8bit output from the ADC0804 to a two digit
    display?



    Best regards,
    Kalun mailto:klnlau@v...
  • ArchiverArchiver Posts: 46,084
    edited 2001-02-03 04:24
    You have a 1 byte vakue that you want to display in HEX? As in a one byte
    value of 23 and you want to display this as two characters '2' '3', or ascii
    3233 ?

    copy the 1 byte value to a new variable (x)
    shift x right 4 bits (integer divide by 16 if shifting isn't available)
    lookup x,'0123456789ABCDEF', x
    'x is now the first digit

    mask the upper 4 bits off the original value using logical and x'0f'
    then use the same lookup command as above and then you have the second digit
    too

    Don Russell

    Position? Let's see.. .I'm at the corner of "Walk" and "Don't Walk"
    Original Message
    From: "Kalun Lau" <klnlau@t...>
    To: <basicstamps@yahoogroups.com>
    Sent: Friday, February 02, 2001 8:17 PM
    Subject: [noparse][[/noparse]basicstamps] temperature sensor


    > Hello
    >
    > How can i convert the 8bit output from the ADC0804 to a two digit
    > display?
    >
    >
    >
    > Best regards,
    > Kalun mailto:klnlau@v...
    >
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2001-02-03 04:40
    Re: My previous reply... Since you said you wanted a two digit display, I
    assumed you wanted to display the 8 bit value in HEX. If you wanted to
    display the 8bit value in decimal, you may need up to three digits (0-255).

    If you want the 8bit value displayed as a decimal number in the range 0-255
    you can use the DEC modifier on the SEROUT command and the Stamp will do the
    necessary conversion auto-magically. :-)

    Don Russell

    Position? Let's see.. .I'm at the corner of "Walk" and "Don't Walk"
    Original Message
    From: "Kalun Lau" <klnlau@t...>
    To: <basicstamps@yahoogroups.com>
    Sent: Friday, February 02, 2001 8:17 PM
    Subject: [noparse][[/noparse]basicstamps] temperature sensor


    > Hello
    >
    > How can i convert the 8bit output from the ADC0804 to a two digit
    > display?
    >
    >
    >
    > Best regards,
    > Kalun mailto:klnlau@v...
    >
    >
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2001-07-25 18:06
    Looks like you need an op amp circuit designed so that when the temp
    sensor output is lowest the op amp output is 4ma and when the sensor is
    highest you get 20 ma output. Not a big task, but would take a little
    bit of linear design calculations. An instrumentation style op Amp
    might be required for high accuracy. You would need to digitize the
    signal to get it reliably back to the stamp. Maxium make some nice
    cheap A/D converters.


    Regards,

    Leroy
    --

    *******************************************************
    * Leroy Hall *
    * 317 Cherokee Drive *
    * Loveland, Ohio - USA 45140-2404 *
    *******************************************************
    * Phone: (513) 697-7539 *
    * Cell : (513) 300-8632 *
    * Email: leroy@f... *
    * Home page URL: http://home.fuse.net/leroy/ *
    * Resume URL: http://home.fuse.net/leroy/resume.htm *
    *******************************************************
    * Leroy Hall *
    * 317 Cherokee Drive *
    * Loveland, Ohio - USA 45140-2404 *
    *******************************************************
  • ArchiverArchiver Posts: 46,084
    edited 2004-03-01 16:51
    Dear all,
    I am making a testpannel for my students. In it I incorporate a
    temperature sensor and a basic stamp 2.
    I need the value of the capacitor to use or how to calculate it. The
    sensor is a NTC (20Kohm At 0°C) I will be using the RCTIME command
    in the program and the schematic of the "What's a microcontroller?
    page 201.
    The BS2 will switch an outpin high when a student tuches te
    temperature sensor.

    Thank you,
  • ArchiverArchiver Posts: 46,084
    edited 2004-03-01 18:57
    >Dear all,
    >I am making a testpannel for my students. In it I incorporate a
    >temperature sensor and a basic stamp 2.
    >I need the value of the capacitor to use or how to calculate it. The
    >sensor is a NTC (20Kohm At 0°C) I will be using the RCTIME command
    >in the program and the schematic of the "What's a microcontroller?
    >page 201.
    >The BS2 will switch an outpin high when a student tuches te
    >temperature sensor.
    >
    >Thank you,


    Choose the capacitor so that the time constant will be about 1 or 2
    milliseconds. (BS2 a count of 500 or 1000)

    If the circuit is set up so that the capacitor voltage approaches the
    ~1.3 volt Stamp threshold from above the formula is:

    RCtime 0,1,x
    tm = 2*x ' tm= 1.35 * R * C

    So for a 2 millisecond time constant with R=20kohms,
    C = 2000 microseconds / (1.35 * 20000 ohms) = 0.074 microfarad.
    for convenience, you might use a 0.1 microfarad capacitor, and the
    time at 0 degrees would be approximately
    tm = 1.35 * 0.1 microfarad * 20000 ohms = 2700 microseconds
    or a count of x=about 1350 on a BS2. You students are going to have
    to calibrate it in any case. See what count they get before and
    after touching it, and then make their output pin logic split the
    difference.

    The formula is different if the capacitor voltage approaches the
    threshold from below:
    RCtime 0,0,x
    tm 2*x ' tm = 0.3 * R * C

    more reference
    http://www.emesystems.com/BS2rct.htm#RCtime

    -- Tracy
  • ArchiverArchiver Posts: 46,084
    edited 2004-03-02 21:14
    Wonderful answer, Thank you Tracy

    This is what I needed.

    Original Message
    From: Tracy Allen [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=0eYaa-AKESSTJ2dcmjm0cMBa31pNwKnEsDJ-VUpgSifIT7uvjUCUwUJwGEkRBfheBdtiB9gEt74QSlgpSQ]tracy@e...[/url
    Sent: maandag 1 maart 2004 19:57
    To: basicstamps@yahoogroups.com
    Subject: Re: [noparse][[/noparse]basicstamps] Temperature sensor


    >Dear all,
    >I am making a testpannel for my students. In it I incorporate a
    >temperature sensor and a basic stamp 2. I need the value of the
    >capacitor to use or how to calculate it. The sensor is a NTC (20Kohm At

    >0°C) I will be using the RCTIME command in the program and the
    >schematic of the "What's a microcontroller? page 201.
    >The BS2 will switch an outpin high when a student tuches te
    >temperature sensor.
    >
    >Thank you,


    Choose the capacitor so that the time constant will be about 1 or 2
    milliseconds. (BS2 a count of 500 or 1000)

    If the circuit is set up so that the capacitor voltage approaches the
    ~1.3 volt Stamp threshold from above the formula is:

    RCtime 0,1,x
    tm = 2*x ' tm= 1.35 * R * C

    So for a 2 millisecond time constant with R=20kohms,
    C = 2000 microseconds / (1.35 * 20000 ohms) = 0.074 microfarad. for
    convenience, you might use a 0.1 microfarad capacitor, and the
    time at 0 degrees would be approximately
    tm = 1.35 * 0.1 microfarad * 20000 ohms = 2700 microseconds or a count
    of x=about 1350 on a BS2. You students are going to have
    to calibrate it in any case. See what count they get before and
    after touching it, and then make their output pin logic split the
    difference.

    The formula is different if the capacitor voltage approaches the
    threshold from below:
    RCtime 0,0,x
    tm 2*x ' tm = 0.3 * R * C

    more reference
    http://www.emesystems.com/BS2rct.htm#RCtime

    -- Tracy


    To UNSUBSCRIBE, just send mail to:
    basicstamps-unsubscribe@yahoogroups.com
    from the same email address that you subscribed. Text in the Subject
    and Body of the message will be ignored.

    Yahoo! Groups Links
Sign In or Register to comment.