Shop OBEX P1 Docs P2 Docs Learn Events
Basic Stamp input High/Low values — Parallax Forums

Basic Stamp input High/Low values

davejamesdavejames Posts: 4,047
edited 2013-08-23 22:15 in BASIC Stamp
Stamp Gurus,

I've looked for, but could not find the Vil/Vih for a Basic Stamp pin set as input.

Anyone know, or know where this could be found?

Thanks much.

Comments

  • ercoerco Posts: 20,256
    edited 2013-08-22 10:54
    1.3-1.4V transition, if I understand your question correctly. Surely in the manual somewhere.
  • davejamesdavejames Posts: 4,047
    edited 2013-08-22 11:00
    erco wrote: »
    1.3-1.4V transition, if I understand your question correctly. Surely in the manual somewhere.

    Yes, you do - and I was thinking similar values; looking for "official docs".


    "...and don't call me Shirley" :smile:
  • davejamesdavejames Posts: 4,047
    edited 2013-08-22 13:01
    ...well, duh! I could look up the Vil/Vih of the given PIC or SX device.

    Synapses are firing slowly today...
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2013-08-22 16:45
    As the BS2 is based on the PIC16F57 (Interpreter) those values would be found in the datasheet for that part. Likewise, for all other BS2 models you would look at the datasheet for the appropriate SX chip (SX28 or SX48). I hope this helps.
  • davejamesdavejames Posts: 4,047
    edited 2013-08-23 08:20
    Hi Mr. Savage,

    Yup - I went down that path. Now if the datasheet is correct, then the often stated 1.3-1.4 volt transition range is not.

    Have you any empirical experience? I'll be checking this over the weekend in between stripping the kitchen cabinets.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2013-08-23 11:28
    It's easy enough to test...just get a 10K pot and connect one end to GND and the other to VDD, now connect the wiper to an I/O pin and connect your DMM to it. Run a program that displays the binary value of that I/O pin and slowly turn the potentiometer from the GND side to the VDD side and observe when the 0 becomes a 1.
  • Tracy AllenTracy Allen Posts: 6,662
    edited 2013-08-23 16:22
    On both the PIC and the SX, the inputs are set for the TTL input threshold option. The data sheet will give you a range of values, one being the value guaranteed to be low and the other the value guaranteed to read as high. That does not answer your question. In practice the threshold is a very sharp transition and is very consistent and predictable. On the original BASIC Stamp is is a little lower than on the SX based Stamps, 1.3V in the former and 1.4V in the latter. That is my memory from many experiments done at one time, but is subject to change from manufacturing batch to batch and of course there are small variations within batches. But I have found those values to be generally spot on for calculation of things such as RCTIME.
  • davejamesdavejames Posts: 4,047
    edited 2013-08-23 22:15
    The data sheet will give you a range of values, one being the value guaranteed to be low and the other the value guaranteed to read as high. That does not answer your question.

    Hi Mr. Allen, thanks for weighing in.

    Actually, the data sheet does answer my question as I'm not interested in the exact transition point - even though this thread kinda went in that direction.

    I needed to know the "guaranteed" points at which the Stamp (either PIC or SX) would call an input level high or low. And yes, they appear to be the somewhat standard TTL thresholds.
Sign In or Register to comment.