setting OUTC low
davejames
Posts: 4,047
in BASIC Stamp
Hi All - FYI, I'm using a BS2.
My eyes began to cross at midnight while reading through the Stamp programming reference looking for a way to set the group of pins, OUTC, all low with one command.
I wound up setting Pins 8, 9, 10, 11 low individually as a work-around.
Anyone know of a command that will set pin group OUTC low with one command?
Thanks much,
DJ
My eyes began to cross at midnight while reading through the Stamp programming reference looking for a way to set the group of pins, OUTC, all low with one command.
I wound up setting Pins 8, 9, 10, 11 low individually as a work-around.
Anyone know of a command that will set pin group OUTC low with one command?
Thanks much,
DJ
Comments
Thanks Tom - I'll give it a go tonight.
Dave
Refer to page 83 of the BASIC Stamp Manual.
On power-up or reset all memory locations become 0.
Thus:
The pin directions will all be inputs since a 0 in DIRx makes a pin an Input.
Also the output levels will all be low since a 0 in OUTx makes a pin output Low.
Usually you will see a "DIRx = something" statement near the top of the program and it might be followed by an OUTx.
Smile! I forgot about the physical book. I was digging through the on-line version that's included with the programming environment.
Thanks for the pointer & reminder.
DJ
Tom - that was the ticket! Thanks much.
Dave