Shop OBEX P1 Docs P2 Docs Learn Events
Minimum voltage that registers HIGH in BS2? — Parallax Forums

Minimum voltage that registers HIGH in BS2?

MigsMigs Posts: 95
edited 2006-11-07 01:21 in BASIC Stamp
Friends:

On the Basic Stamp 2, what is the minimum voltage that can be read at a pin to still register a HIGH condition?

"Sourcing" current means the BS2 can provide the current and "sinking" means it can receive the current right?

Thanks amigos,

Migs

Comments

  • manxstampmanxstamp Posts: 57
    edited 2006-11-05 22:33
    The threshold voltage for a BASIC Stamp is quoted by Parallax at 1.4V. Anything more is sensed as logic 1. So I would expect 1.5V to be the lowest voltage·registering as logic 1, or HIGH, and 1.3V to be logic 0. Closely around 1.4V the results would probably be variable. This cut-off is used in the photoresistor voltage divider used as a light sensor in the SIC Robotics course.

    However, I've never tried the experiment to see measure precisely the very minimum! I don't know whether anyone else has, or Parallax has an official answer. It would possibly vary from Stamp to Stamp.

    John

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔



    Manxstamp,
    Isle of Man, British Isles
  • MigsMigs Posts: 95
    edited 2006-11-05 22:38
    Dear John:

    Thanks a bunch for the info and the speed of the reply. I just got into this doing the "What's a Microcontroller" book. Your answer is plenty useful because in one of the examples using a LED they add a 220 ohm resistor in the circuit and it was unclear how they chose this value. Later they explain that in most cases this resistor is replaced by a wire, which is what I would have expected in the circuit to begin with. Thus the question.

    Again, many thanks!

    Migs

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "Sometimes we forget that the world itself is paradise." Douglas Coupland, 'Microserfs'
    "If the doors of perception were cleansed every thing would appear to man as it is, infinite" - William Blake
    "We either make ourselves miserable, or we make ourselves strong. The amount of work is the same." Carlos Castaneda
    "One single grateful thought raised to heaven is the most perfect prayer. " G. E. Lessing
    “How much of human life is lost in waiting.” Ralph Waldo Emerson
    "Men often mistake notoriety for fame, and would rather be remembered for their vices and follies than not be noticed at all.” Harry Truman
    My website: www.intoku.net my e-mail:mreznicek@pretensa.com me:Miguel Reznicek
  • manxstampmanxstamp Posts: 57
    edited 2006-11-05 23:29
    My reply refers to voltages READ at a pin set as an INPUT.

    You are right about sourcing and sinking current.

    Resistors with LEDs are chosen to limt the current flowing through the LED. Without a current limiting resistor, the LED would burn out. The value of the resistor depends on the voltage drop across the LED and the maximum current that the LED can handle; the formula is explained on several websites, such as

    http://www.kpsec.freeuk.com/components/led.htm

    You'll see that from the WAM text that·with the 5 volts used by the Stamp and the standard LEDs supplied, 470 ohm resistors are usually used.

    John

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔



    Manxstamp,
    Isle of Man, British Isles
  • gprgpr Posts: 2
    edited 2006-11-06 22:04
    I also needed to know the minimum voltage that would trigger the BS2 to read "1", so·I rigged up a voltage divider that allowed me to dial in·a voltage level between 0 and 5 vdc onto pin1, which I monitored with a DVOM. I then continually interrogated the input on pin1, to turn on an LED when it read "1", and off again when it read "0".· After several attempts, I decided that 1.5 volts was the dividing line... at least for my Stamp.

    Regards,

    Glen
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-11-06 23:26
    Glen -

    The 1.5 VDC reading for the assurance of a logic 1 is right in line with the strata criteria of 1.4 VDC being the "no man's land" dividing a logic 0 from a logic 1. It's my understanding, and someone please correct me if I'm wrong, that it is the characteristics of the chip strata, in this case CMOS, and nothing else which dictates the cross-over point (threshold voltage level) for a logic 0 vs. a logic 1. The individual Stamp, or Stamp model should make no difference at all.

    Here is an interesting table with the logic threshold voltage levels for various families of solid state devices:
    http://www.interfacebus.com/voltage_threshold.html

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    <!--StartFragment -->
  • gprgpr Posts: 2
    edited 2006-11-07 01:21
    Bruce- It does appear that the threshold voltage is a function of chip construction. This is supported by the info on p.6 of this pdf:
    http://www.parallax.com/dl/docs/prod/stamps/BASICStamp2px.pdf

    This implies that TTL designs trigger at ~1.4VDC, while CMOS triggers at 50% of the supply voltage. But, the pins of the BS2px can be programmed to trigger either as TTL's or as CMOS. A neat trick that I don't understand.
    Regards-
    Glen
Sign In or Register to comment.