24
User Manual
Copyright ©2003 A7 Engineering, Inc.
IF in5 = 0 THEN WaitForConnection
DEBUG “Connected”,CR
‘Wait for 20 seconds
PAUSE 20000
‘I/O Line 6 allows us to switch to Command Mode
OUTPUT 6
‘Switch to Command Mode
LOW 6
SERIN 0,84,[WAIT(CR,”>”)]
‘Disconnect from the remote device
SEROUT 1,84,[“dis”,CR]
SERIN 0,84,[WAIT(CR,”>”)]
DEBUG “Disconnected”,CR
The BASIC Stamp application establishes a connection with the remote Bluetooth
device, waits twenty seconds, switches back to command mode and then
disconnects from the remote device.
3.
On the
File
menu, click
Save As
.
4.
In the
File name
box, enter a file name to which to save the program just created.
For example, Connect.bs2.
5.
Click
Save
.
6.
Apply
power
to the
Board of Education board
.
7.
Apply
power
to the
SumoBoard board
.
8.
On the
Run
menu, click
Run
.
The Connection Status LED (Figure 1) on both eb500 modules will turn on when a
connection is established between the two eb500 modules.
9.
Disconnect the
power
from the
Board of Education board
.
10.
Disconnect
power
from the
SumoBoard board
.