Specifications

BASIC Stamp II
Parallax, Inc. • BASIC Stamp Programming Manual 1.8 • Page 325
2
This is to ensure that the sender sees a stop signal (0 for inverted comms)
when the receiver is being programmed.
Flow-control Timeout
Flow control solves one problem but can create another—if the receiver
isn’t connected, Serout may never get permission to send. The pro-
gram will be stuck in Serout indefinitely. To prevent this, Serout allows
you to specify how long it should wait for permission, from 0 to 65535
ms. If the specified time passes without permission to send, Serout
aborts, allowing the program to continue at tlabel. Here’s the previous
example (just the Sender code) with a 2.5-second timeout:
Serout 1\0,16468,2500,noFlow["HELLO!"]
' ...instructions executed after a successful Serout
stop
noFlow:
' If Serout times-out waiting for flow-control permission,
' It jumps to this label in the program.
Networking with Open Baudmodes
The open baudmodes can be used to connect multiple BS2s to a single
pair of wires to create a party-line network. Open baudmodes only
actively drive the Serout pin in one state; in the other state they discon-
nect the pin. If BS2s in a network used the always-driven baudmodes,
two BS2s could simultaneously output opposite states. This would cre-
ate a short circuit from +5V to ground through the output drivers of
the BS2s. The heavy current flow would likely damage the BS2s (and it
would certainly prevent communication). Since the open baudmodes
only drive in one state and float in the other, there’s no chance of this
kind of short.
The polarity selected for Serout determines which state is driven and
which is open, as follows:
— Polarity — Resistor
State Inverted Noninverted Pulled to
0 open driven GND
1 driven open +5V