Shop OBEX P1 Docs P2 Docs Learn Events
need help quickly please — Parallax Forums

need help quickly please

ObiwanObiwan Posts: 36
edited 2005-06-12 02:33 in Robotics
i have a big problem.· I thought that when you don't declare an i/o pin high or low, it disconnects itself from any voltage.· Apparently, current can still flow through my i/o pin even if my program is.
Do
pause 1000
loop

How can I stop current from flowing through the i/o pin.

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-06-08 05:10
    Hello,

    ·· You're saying this is the program you downloaded onto the Stamp Module?· Is that everything?· How do you know current is still flowing through the pin?· What's connected to it?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • edited 2005-06-08 15:51
    Your I/O pin should not draw current if these two conditions are true:

    - The voltage applied to the I/O pin ranges between 0 and 5 V.
    - No command that changes the I/O pin from input to output has been used (HIGH and LOW are examples)

    Consult the BASIC Stamp Manual to make sure that a given command does not leave an I/O pin in an output state. If you are applying voltages outside the 0 to 5 V range, you will need a series resistor to protect the I/O pin's clamping diodes. For an example of that, see the BASIC Stamp Manual's explanation of SEROUT.

    The The BASIC Stamp Manual is available for download from www.parallax.com -> Downloads -> Documentation.

    Post Edited (Andy Lindsay (Parallax)) : 6/8/2005 3:57:30 PM GMT
  • Beau SchwabeBeau Schwabe Posts: 6,547
    edited 2005-06-08 18:52
    Obiwan,

    Assuming from some of your other post in the forum that are related to this matter,· I can provide an explanation why you are seeing or
    detecting a current flow even if you have declared a Stamp pin as an INPUT.
    ·
    Inside of the IC used on the Stamp, there is what is called a back-to back diode (B2BD)·which is really designed to handle ESD events.
    Typically, there is a B2BD circuit on ALL of the IC pins.· When you connect to the BASE of a·PNP transistor through a Stamp I/O, and
    the·Emitter of the PNP transistor is connected to a higher voltage potential than the Stamp (5V), you run the risk of this scenario.
    ·


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
    1031 x 959 - 243K
  • ObiwanObiwan Posts: 36
    edited 2005-06-12 02:33
    thanks for the good explanation.· I actually realized this problem while brainstorming the solution but it really helped having it explained again.
Sign In or Register to comment.