Shop OBEX P1 Docs P2 Docs Learn Events
is pullup/pulldown necessry when... — Parallax Forums

is pullup/pulldown necessry when...

mobile_bobmobile_bob Posts: 50
edited 2008-08-14 18:27 in BASIC Stamp
you are using two processors where
logic levels are transmitted from one pin of one bs2
to another pin of a seperate bs2?

if so, is it sufficient to use a single point pullup or down?
such as on a backplane? or..

should it be done on each processor pin? and also at the
backplane?

i notice alot of digital pc circuits use pullup/down resistors
at the cardslot but not between the IC's generally, so wondered if
it is necessary between to processors. where one is just reading the logic level of a pin on another processor.

bob g

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Dream it, design it, engineer it, build it, and

do what is necessary to make the damn thing work!

Comments

  • allanlane5allanlane5 Posts: 3,815
    edited 2008-08-14 13:29
    The problem when you're communicating between two BS2's (like "master" and "slave") is that if both the "Master" I/O pin is set to an output, and the "Slave" I/O pin is set to an output, if "Master" outputs a HIGH and "Slave" outputs a LOW, you've now connected Vdd to Vss with a "short circuit" through your BS2's. This burns out I/O pins, permanently.

    Now, MOST digital PC circuits don't use the same pin for an output, then turn around and use it for an input. The BS2 is a little unusual in doing this, but it's very handy.

    To prevent damage, you can put a 220 ohm resistor between the two BS2's. Then instead of a "short circuit" you get a current the BS2 I/O pins can deal with, so they won't burn out. You STILL don't want to connect two outputs together at the same time, but sometimes you can't avoid it.

    Another way to prevent damage is to have an "open baud" mode. In this mode, the pin is only "driven" high, but allowed to "float" (through a pull-down resistor) low. Or vice-versa. This approach lets you build a "party line", where ONE BS2 can talk at a time, while all other BS2's on the party line listen. If two BS2's try to 'talk' at the same time, data will be garbled, but no damage will be done.

    To answer your question, if the BS2's are on the same 'card', a single 10 Kohm pull-up (or pull-down) will be enough. If they're on separate cards, you might put a pull-up (or pull-down) next to each BS2. Putting a 220 ohm resistor in series with each one would also be a good idea, to prevent damage during testing.
  • mobile_bobmobile_bob Posts: 50
    edited 2008-08-14 17:34
    actually what i want to do is have for instance

    a master that outputs a high on a pin

    and across the bus another pin of slave to check for this logic high, and check only

    there would be no bi directional or need to change the direction of either controller pin,

    the master puts out a high logic, the slave checks for the high and uses that as a signal to break out of loop

    and start its process.

    would i still need the 220ohm resister between the pins?

    should i still use a 10k pull down resister as well?

    i guess what i am after

    an example

    bs2 (A) outputs a high on pin #1

    (i want)

    bs2 (B) pin #1 to be connected to BS2 (A) pin #1 , but

    i just want BS2 (B) to check the state of what is on pin #1, i want it to be able to see that BS2 (A) is high

    would this still require the 220ohm resistor between both pins under this circumstance?

    if so, now is the time to insert them!, i haven't powered up yet and don't want to burn up pins!

    thanks
    bob g

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Dream it, design it, engineer it, build it, and

    do what is necessary to make the damn thing work!
  • mobile_bobmobile_bob Posts: 50
    edited 2008-08-14 18:00
    Thanks Allan

    i just went back and reread your post, and it makes sense

    to be safe, put the 220 between the two processor pins, that way

    incase i program them incorrectly , one driven high output and the other driven low input

    the current is limited and there is some current limit and no burnt pins.

    ok, i follow

    220 resistors it is!

    i guess i might as well add the 10k pulldown resistors as well, so there is no

    floating going on.

    ok, seems simpe enough now that i think it through

    bob g

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Dream it, design it, engineer it, build it, and

    do what is necessary to make the damn thing work!
  • allanlane5allanlane5 Posts: 3,815
    edited 2008-08-14 18:07
    That should cover all the possibilities, all-right, includeing the one where the "master" is turned off -- the 'slaves' pull-down resistor will guarantee it reads a 'low' in that case, instead of '60 Hz noise' which is what it WOULD read without the pull-down.
  • mobile_bobmobile_bob Posts: 50
    edited 2008-08-14 18:27
    thanks so much!

    well i gotta go track down a bunch of 220 and 10k resistors now!

    [noparse]:)[/noparse]

    bob g

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Dream it, design it, engineer it, build it, and

    do what is necessary to make the damn thing work!
Sign In or Register to comment.