One switch to two BS2s?
doug.taylor
Posts: 31
Can one switch supply a signal to a separate I/O pins on two different networked BS2s?
Please see the attached for a picture.
Please see the attached for a picture.
Comments
Similarly, if you tie an output to a 'hard +5' (ie a low-resistance path to +5 volts) and then set that output low accidentally, again, the amount of current can burn out the pin. Actually, the transistor drivers behind the pin, but you get the idea.
Now, to prevent damage you need a "current limiting" resistor. 220 ohms is the recommended "current limiting" resistor Parallax uses, and puts in their Homework board. I just figured about half that assigned to each BS2 would work if the BS2's are talking to each other. But, if the BS2's are reading a switch signal, then each one needs the full resistance.
If the 2 Stamps are running on different +5 supplies or ontheir own internal regulators:
·The safest way would be to use a Doubel Pole Switch. This will supply the switch position· information and isolate the 2 Stamps completely. You could also use Opto-Isolators if a DP switch is not possible.
If both Stamps are running from the same 5volt supply:
·You could wire the switch to ground the input (Using a pullup resistor from the pin to +5). The draw back is if either Stamps pins get assigned as an Output you could get blown pins with the switch closed.
Good Luck,
Alan Bradford
Plasma Technologies
www.plasmatechnologies.com
The double pole or Opto-Isolators idea is great. I didn't even think in those terms. As it happens, both Stamps share Vss and Vdd and are networked together using another pair of I/O pins anyway. I don't plan on allowing the pins in question to be anything but inputs but in a previous post allanlane5 supplied a tip using a protective resistor on each pin just in case of "accidents".
I will file away your idea though, in case I ever am dealing with isolated Stamps.