Shop OBEX P1 Docs P2 Docs Learn Events
reading resistance — Parallax Forums

reading resistance

TMillsTMills Posts: 2
edited 2005-06-08 01:41 in BASIC Stamp
I have a pressure sender that I would like to read the resistance from and display on the screen.· What is the best way of doing this?· The sender goes from 240 ohm. to 34 ohm.
Thanks

Comments

  • NewzedNewzed Posts: 2,503
    edited 2005-06-06 22:29
    Assuming the other end of the resistance from the sender goes to ground, you connect a .1uf capacitor from resistance connection to ground, then read the RC time.· RC time is stored in a variable which you can easily display on the debug screen.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Sid Weaver
    Need a bezel for your LCD?

    Newzed@aol.com
    ·
  • TMillsTMills Posts: 2
    edited 2005-06-06 22:36
    how do you know what time corresponds with what resistance?
  • NewzedNewzed Posts: 2,503
    edited 2005-06-06 23:03
    Study RCTime in the Editor Help section.· You know the capacitance so you can calculate the resistance.· I would use a·10% capacitor such as Digikey BC1114CT.· Better still, if you have a multimeter that will measure capacitance, you can find out exactly what the value is.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Sid Weaver
    Need a bezel for your LCD?

    Newzed@aol.com
    ·
  • Tracy AllenTracy Allen Posts: 6,658
    edited 2005-06-07 15:46
    That is quite a low range of resistance you have to work with (34 to 240 ohms). Is that right? It is hard to do that very well with RCTIME directly, because those low resistances take too much current from the Stamp pns. You could do something with an op-amp to convert the small resistance to either a proportional current for RCTIME or to a voltage for an analog to digital converter.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tracy Allen
    www.emesystems.com
  • NewzedNewzed Posts: 2,503
    edited 2005-06-07 15:50
    Another thing you might be able to do is add a 1K resistor in series with your sender, so you would be looking 1034 to 1240 ohms.· This would give you a larger value for RCTime and also reduce current thru the Stamp pin.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Sid Weaver
    Need a bezel for your LCD?

    Newzed@aol.com
    ·
  • SunflowerSunflower Posts: 48
    edited 2005-06-08 01:41
    i used a 220 ohm in series with such a sensor, plus a 220 ohm for pin protection. may need more charging time.
Sign In or Register to comment.