Method for using a toy to conduct sales over a network6368177Abstract There is provided a method for using a toy for effecting sales over a public network, the method comprising: providing a toy having interactive speaking and listening functionality; connecting the toy via a public network to at least one server having transactional functionality; and effecting sales by employing the transactional functionality via the interactive speaking and listening functionality of said toy. Claims What is claimed is: Description FIELD OF THE INVENTION
1. K1 Relay Dept, Idec, 1213 Elco Drive,
Sunnyvale, Calif. 94089-2211, USA.
2. U1 8751 microcontroller, Intel
Corporation, San Tomas 4, 2700 Sun
Tomas Expressway, 2nd Floor, Santa
Clara 95051, CA USA.
3. U2 CXO-12 MHZ (crystal oscillator),
Raltron, 2315 N.W. 107th Avenue,
Miami, FL 33172, USA.
4. U4 MC33174, Motorola, Phoenix, AZ
USA., Tel. No. (602)897-5056.
5. Diodes 1N914, Motorola, Phoenix, AZ, USA.
Tel. No. (602)897-5056.
6. Transistors 2N2222 and MPSA14, Motorola,
Phoenix, AZ, USA. Tel. No.
(602)897-5056.
The following is a preferred parts list for the apparatus of FIG. 5D:
1. U1 SILRAX-418-A UHF radio telemetry
receive module, Ginsburg Electronic
GmbH, Am Moosfeld 85, D-81829,
Munchen, Germany.
Alternatively, U1 of FIG. 5D may be replaced by:
U1 433.92 MHz Receive Module Part No.
0927, available from CEL SALES LTD.,
Cel House, Unit 2, Block 6, Shenstone
Trading Estate Bromsgrove,
Halesowen, West Midlands B36 3XB, UK.
2. U2 TXM-418-A low power UHF radio
telemetry transmit module, Ginsburg
Electronic GmbH, Am Moosfeld 85, D-
81829, Munchen, Germany.
Alternatively, U2 of FIG. 5D may be replaced by:
U2 433.92 SIL FM Transmitter Module
Part No, 5229, available from CEL
SALES LTD., Cel House, Unit 2, Block
6, Shenstone Trading Estate Bromsgrove,
Halesowen, West Midlands B36 3XB, UK.
Reference is now additionally made to FIG. 5E, which is a schematic diagram of an alternative implementation of the apparatus of FIG. 5D. The following is a preferred parts list for the apparatus of FIG. 5E:
1. U1 BIM-418-F low power UHF data
transceiver module, Ginsburg
Electronic GmbH, Am Moosfeld 85, D-
81829, Munchen, Germany.
Alternate 1. U1 S20043 spread spectrum full duplex
transceiver, AMI Semiconductors-
American Microsystems, Inc., Idaho,
USA.
Alternate 1. U1 SDT-300 synthesized transceiver,
Circuit Design, Inc., Japan.
Alternatively, U1 may be replaced by:
U1 RY3GB021 RF 900 Mhz units,
available from SHARP ELECTRONIC
COMPONENTS GROUP, 5700 Northwest,
Pacific Rim Boulevard #20, Camas,
Washington, USA.
U1 RY3GB100 RF Units For DECT,
available from SHARP ELECTRONIC
COMPONENTS GROUP, 5700 Northwest,
Pacific Rim Boulevard #20, Camas,
Washington, USA.
In the parts list for FIG. 5E, one of item 1 or either of the alternate items 1 may be used for U1. It is appreciated that the appropriate changes will have to be made to all the circuit boards for alternate embodiments of the apparatus. The apparatus of FIG. 5E has similar functionality to the apparatus of FIG. 5D, but has higher bit rate transmission and reception capacity and is, for example, preferred when MIDI data is transmitted and received. FIGS. 5A-5E are self-explanatory with regard to the above parts lists. Reference is now made to FIG. 6 which is a simplified block diagram of a preferred embodiment of the toy control device 130 of FIG. 1A. The apparatus of FIG. 6 comprises a radio transceiver 260, similar to the radio transceiver 260 of FIG. 4. The apparatus of FIG. 6 also comprises a microcontroller 250 similar to the microcontroller 250 of FIG. 4. The apparatus of FIG. 6 also comprises a digital input/output interface (digital I/O interface) 290, which is operative to provide an interface between the microcontroller 250 and a plurality of input and output devices which may be connected thereto such as, for example, four input device and four output devices. A preferred implementation of the digital I/O interface 290 is described in more detail below with reference to FIGS. 7A-7F. The apparatus of FIG. 6 also comprises an analog input/output interface (analog I/O interface) 300 operatively connected to the radio transceiver 260, and operative to receive signals therefrom and to send signals thereto. The apparatus of FIG. 6 also comprises a multiplexer 305 which is operative, in response to a signal from the microcontroller 250, to provide output to the analog I/O interface 300 only when analog signals are being transmitted by the radio transceiver 260, and to pass input from the analog I/O interface 300 only when such input is desired. The apparatus of FIG. 6 also comprises input devices 140 and output devices 150. In FIG. 6, the input devices 140 comprise, by way of example, a tilt switch operatively connected to the digital I/O interface 290, and a microphone operatively connected to the analog I/O interface 300. It is appreciated that a wide variety of input devices 140 may be used. In FIG. 6, the output devices 150 comprise, by way of example, a DC motor operatively connected to the digital I/O interface 290, and a speaker operatively connected to the analog I/O interface 300. It is appreciated that a wide variety of output devices 150 may be used. The apparatus of FIG. 6 also comprises a DC control 310, a preferred implementation of which is described in more detail below with reference to FIGS. 7A-7F. The apparatus of FIG. 6 also comprises a comparator 280, similar to the comparator 280 of FIG. 4. The apparatus of FIG. 6 also comprises a power source 125, shown in FIG. 6 by way of example as batteries, operative to provide electrical power to the apparatus of FIG. 6 via the DC control 310. Reference is now made to FIGS. 7A-7F which, taken together with either FIG. 5D or 5E, comprise a schematic diagram of the toy control device of FIG. 6. If the schematics of FIG. 5E is employed to implement the computer radio interface of FIG. 4, using RY3GB021 as U1 of FIG. 5E, then the same schematics of FIG. 5E are preferably employed to implement the toy control device of FIG. 6 except that RY3GH021 is used to implement U1 rather than RY3GB021. The following is a preferred parts list for the apparatus of FIGS. 7A-7F:
1. U1 8751 microcontroller, Intel
Corporation, San Tomas 4, 2700 Sun
Tomas Expressway, 2nd Floor, Santa
Clara 95051, CA USA.
2. U2 LM78L05, National Semiconductor,
2900 Semiconductor Drive, Santa
Clara, CA 95052, USA.
3. U3 CXO-12 MHz (crystal oscillator),
Raltron, 2315 N.W. 107th Avenue,
Miami, FL 33172, USA.
4. U4 MC33174, Motorola, Phoenix, AZ
USA. Tel. No. (602)897-5056.
5. U5 MC34119, Motorola, Phoenix, AZ
USA. Tel. No. (602)897-5056.
6. U6 4066, Motorola, Phoenix, AZ, USA.
Tel. No. (602)897-5056.
7. Diode 1N914, 1N4005, Motorola, Phoenix,
AZ USA. Tel. No. (602)897-5056.
8. Transistor 2N2222, 2N3906, Motorola, Phoenix,
AZ USA. Tel. No. (602)897-5056.
9. Transistors 2N2907 and MPSA14, Motorola,
Phoenix, AZ USA. Tel. No.
(602)897-5056.
FIGS. 7A-7F are self-explanatory with reference to the above parts list. As stated above with reference to FIG. 1A, the signals transmitted between the computer radio interface 110 and the toy control device 130 may be either analog signals or digital signals. It the case of digital signals, the digital signals preferably comprise a plurality of predefined messages, known to both the computer 100 and to the toy control device 130. Each message sent by the computer radio interface 110 to the toy control device 130 comprises an indication of the intended recipient of the message. Each message sent by the toy control device 130 to the computer radio interface 110 comprises an indication of the sender of the message. In the embodiment of FIG. 1C described above, messages also comprise the following: each message sent by the computer radio interface 110 to the toy control device 130 comprises an indication of the sender of the message; and each message sent by the toy control device 130 to the computer radio interface 110 comprises an indication of the intended recipient of the message. A preferred set of predefined messages is as follows: Command Structure
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
Commands List From the Computer to the Toy control device. A. Output Commands
SET_IO_TO_DATA
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 00 01 IO 00 D x
x
Set Toy control device output pin to a digital level D.
P: Computer address 00-03 H
A: unit address - 00-FF H
IO: i/o number - 00-03 H
D: Data- 00-01 H
Example
1. 01 0000 05 00 01 03 01 00 00 set io 3 to "1"
2. 01 0000 05 00 01 03 00 00 00 set io 3 to "0"
CHANGE_IO_FOR_TIME
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 00 02 00 IO 00 D
T1 T2
Change Toy control device output pin to D for a period of time and then
return to previous state.
P: Computer address 00-03 H
A: unit address - 00-FF H
IO: i/o number - 00-03 H
T1, T2: time - 00-FF H
D: Data- 00-01 H
example:
1. 01 0000 05 00 02 03 05 00 00 set io 3 to "1" for 5 seconds
B. Input Commands
SEND_STATUS_OF_SENSORS
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 01 00 x x x x
x x
send the Toy control device status of all sensors.
P: Computer address 00-03 H
A: unit address - 00-FF H
example:
1. 01 0000 05 00 00 00 00 00 send current status of sensors
SENSORS_SCAN_MODE_ON
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 01 01 x x x x
x x
Start scanning the Toy control device sensors, and if one of them is closed
(pressed to `0`), send back an ack.
P: Computer address 00-03 H
A: unit address - 00-FF H
example:
1. 01 0000 05 01 01 00 00 00 00 scan mode of sensors ON
SENSORS_SCAN_MODE_ON_ONCE
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 01 02 x x x x
x x
Start scanning the Toy control device sensors, and if one of them is closed
(press to `0`), send back an ack,
then disable scanning the sensors.
P: Computer address 00-03 H
A: unit address - 00-FF H
1. 01 0000 05 01 02 00 00 00 00 scan mode of sensors ON once
SENSORS_SCAN_MODE_OFF
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 01 03 x x x x
x x
Stop scanning the Toy control device sensors.
P: Computer address 00-03 H
A: unit address - 00-FF H
1. 01 0000 05 01 03 00 00 00 00 scan mode of sensors OFF
C. Audio Out Commands
START_AUDIO_PLAY
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 02 00 x x x x
xx xx
Start playing an audio in a speaker of the Toy control device The Audio is
sent to the Toy control device by the
computer sound card and the Computer ratio interface.
P: Computer address 00-03 H
A: unit address - 00-FF H
1. 01 0000 05 02 00 00 00 00 00 Start audio-play
STOP_AUDIO_PLAY
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 02 01 x x x x
x x
Stop playing an audio in a speaker of the Toy control device.
P: Computer address 00-03 H
A: unit address - 00-FF H
1. 01 0000 05 02 01 00 00 00 00 Stop audio-play
START_AUDIO_AND_TO_PLAY_FOR_TIME
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 02 04 T1 T2 T0 td
SC IO
Start playing an audio in a speaker of the Toy control device and set an io
pin to `I`. After time T, stop audio and set
IO to `0`. start this command after a delay td* 100 ms if SC - "1" then
after the execution of this command, start the
input command SCAN_SENSORS _ON_ONCE (if any sensor is pressed, even during
the audio play, send a
message to the computer).
P: Computer address 00-03 H
A: unit address - 00-FF H
IO: i/o number - 0-3 H (if IO > 3 then don't set IO)
T0, T1, T2 TIME 000-FFF H (*100 ms) (T0 = MMSB, T1 = MSB
T0 = LSB)
td: delay time befor execute 0-F (*100 ms)
1. 01 0000 05 02 04 80 2A 03 00 Start audio-play and IO #3 for 6.4 second
640 = 28011
delay before execution - 10* 100 ms = 1 sec
2. 01 0000 05 02 04 80 2A 13 00 Start audio-play and IO #3 for 6.4 second
and
set scan sensors on once mode.
delay before execution = 10* 100 ms = 1 sec
D. Audio In Commands
TRANSMIT_MIC_FOR_TIME
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 03 00 T1 T2 x x
x x
Requests the Toy control device to Transmit microphone audio from the Toy
control device to the Computer ratio
interface and to the sound card of the computer for time T.
P: Computer address 00-03 H
A: unit address - 00-FF H
T1, T2: TIME 00-FF H (SEC)
example:
1. 01 0000 05 03 00 0A 00 00 00 start mic mode for 10 seconds
E. General Toy Commands
GOTO_SLEEP_MODE
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 01 x x x x
x x
Requests the Toy control device to go into power save mode (sleep).
P: Computer address 00-03 H
A: unit address - 00-FF H
1. 01 0000 05 04 01 00 00 00 00 switch the Toy control device into sleep
mode.
GOTO_AWAKE_MODE
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 02 x x x x
x x
Requests the Toy control device to go into an awake mode.
P: Computer address 00-03 H
A: unit address - 00-F H
1. 01 0000 05 04 02 00 00 00 00 switch the Toy control device into awake
mode.
TOY_RESET
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 0F x x x x
x x
Requests the Toy control device to perform RESET
P: Computer address 00-03 H
A: unit address - 00-FF H
1. 01 0000 05 04 0F 00 00 00 00 Toy reset
TOY_USE_NEW_RF_CHANNELS
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 0A CH1 CH2 x x
x x
Requests the Toy control device to switch to new RF transmit and receive
channels.
P: Computer address 00-03 H
A: unit address - 00-FF H
CH1: Transmit RF channel number 0-F H
CH2: Receive RF Channel number 0-F H
1. 01 0000 05 04 0A 12 00 00 00 Switch to new RX and TX RF channels
Note: This command is available only with enhanced radio modules (alternate
U1 of FIG. 5E) or with the modules described if FIG 15A-15E and 23A-24E.
E. Telemetry Information sent by the Toy control device, as an ACK to the command recieved from the Computer radio interface.
OK_ACK
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 0A 00 cmd1 cmd2 cmd3
cmd4 sen1 sen2
Send back an ACK about the command that was received ok.
P: Computer address 00-03 H
A: unit address - 00-FF H
cmd 1, 2: Received command MSB ok ack. 00-FF H
cmd 3, 4: Received command LSB ok ack. 00-FF H
sen 1, 2 Sensors 0-7 status 00-FF H
1. 01 6000 05 0A 00 01 01 FF 00 OK ack for 0101 command. (sensors scan
mode
on command). status: all sensors are not
pressed (FF).
2. 01 6000 05 0A 00 01 01 FE 00 OK ack for 0101 command. (sensors scan
mode
on command). status: sensor #8 is pressed
(FE)
the computer_radio_interface number is 6.
E. Requests Request sent by the Toy control device, after an event
TOY_IS_AWAKE_REQ
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 0A 00 c1 c2 x x
x x
Send a message to the Computer radio interface if the Toy control device
goes from sleep mode to awake mode.
P: Computer address 00-03 H
A: unit address - 00-FF H
c1, c2: status command AB H
1. 01 6000 05 0A 00 AB 00 FF 00 Toy is awake message.
E. CRI (Computer Ratio Interface)-commands Commands that are sent to the Computer radio interface.
SWITCH_AUDIO_OUT_TO_RADIO_&_TRANSMIT
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 x 0C 00 x x x x
x x
Requests the Computer radio interface to switch audio_out from the computer
sound card to the radio wireless
transceiver and transmit.
P: Computer address 00-03 H
SWITCH_AUDIO_OUT_TO_JACK_&_STOP_TRANSMIT
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 x 0C 01 x x x x
x x
Requests the Computer radio interface to switch audio_out from the radio RF
wireless transceiver to the speakers jack
and to stop transmit.
P: Computer address 00-03 H
SWITCH_AUDIO_OUT_TO_JACK_&_STOP_TRANSMIT
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 x 0C 01 x x x x
x x
Requests the Computer radio interface to switch audio_out from the radio RF
wireless transceiver to the speakers jack
and to stop transmit.
P: Computer address 00-03 H
G. CRI-ACK ACK sent only to the Computer by the Computer radio interface, only after CRl commands
CRI_COMMAND_ACK
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 x 0D 00 cmd1 cmd2 cmd3
cmd4 x x
This is an ACK for a CRI command. this ACK is sent to the computer by the
computer-radio-interface, after executing
a command successfully.
P: Computer address 00-03 H
cmd 1, 2: Received CRI command MSB ok ack. 00-FF H
cmd 3, 4: Received CRI command LSB ok ack. 00-FF H
1. 01 6000 00 0D 00 0C 01 00 00 OK ack for 0C01 CRI command (SWITCH
AUDIO OUT TO JACK)
the computer_radio_interface number is 6.
2. 01 6000 00 0D 00 0C 0F 00 00 OK ack for 0C0F CRI command (CRI reset)
the computer_radio_interface number is 6.
This ack is also sent on POWER UP RESET
UN-MUTE_RADIO
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 00 00 00 x 0C 03 x x x x
x x
UN-Mute the radio transmit.
CRI_RESET
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 x 0C 0F x x x x
x x
Perform software reset on the Computer radio interface unit.
P: Computer address 00-03 H
Reference is now made to FIG. 8A, which is a simplified flowchart illustration of a preferred method for receiving radio signals, executing commands comprised therein, and sending radio signals, within the toy control device 130 of FIG. 1A. Typically, each message as described above comprises a command, which may include a command to process information also comprised in the message. The method of FIG. 8A preferably comprises the following steps: A synchronization signal or preamble is detected (step 400). A header is detected (step 403). A command contained in the signal is received (step 405). The command contained in the signal is executed (step 410). Executing the command may be as described above with reference to FIG. 1A. A signal comprising a command intended for the computer radio interface 110 is sent (step 420). Reference is now made to FIGS. 8B-8T which, taken together, comprise a simplified flowchart illustration of a preferred implementation of the method of FIG. 8A. The method of FIGS. 8B-8T is self-explanatory. Reference is now made to FIG. 9A, which is a simplified flowchart illustration of a preferred method for receiving MIDI signals, receiving radio signals, executing commands comprised therein, sending radio signals, and sending MIDI signals, within the computer radio interface 110 of FIG. 1A. Some of the steps of FIG. 9A are identical to steps of FIG. 8A, described above. FIG. 9A also preferably comprises the following steps: A MIDI command is received from the computer 100 (step 430). The MIDI command may comprise a command intended to be transmitted to the toy control device 130, may comprise an audio in or audio out command, or may comprise a general command. A MIDI command is sent to the computer 100 (step 440). The MIDI command may comprise a signal received from the toy control device 130, may comprise a response to a MIDI command previously received by the computer radio interface 110 from the computer 100, or may comprise a general command. The command contained in the MIDI command or in the received signal is executed (step 450). Executing the command may comprise, in the case of a received signal, reporting the command to the computer 100, whereupon the computer 100 may typically carry out any appropriate action under program control as, for example, changing a screen display or taking any other appropriate action in response to the received command. In the case of a MIDI command received from the computer 100, executing the command may comprise transmitting the command to the toy control device 130. Executing a MIDI command may also comprise switching audio output of the computer control device 110 between the secondary audio interface 230 and the radio transceiver 260. Normally the secondary audio interface 230 is directly connected to the audio interface 220 preserving the connection between the computer sound board and the peripheral audio devices such as speakers, microphone and stereo system. Reference is now made to FIGS. 9B-9N, and additionally reference is made back to FIGS. 8D-8M, all of which, taken together, comprise a simplified flowchart illustration of a preferred implementation of the method of FIG. 9A. The method of FIGS. 9B-9M, taken together with FIGS. 8D-8M, is self-explanatory. Reference is now additionally made to FIGS. 10A-10C, which are simplified pictorial illustrations of a signal transmitted between the computer radio interface 110 and the toy control device 130 of FIG. 1A. FIG. 10A comprises a synchronization preamble. The duration T_SYNC of the synchronization preamble is preferably 0.500 millisecond, being preferably substantially equally divided into on and off components. FIG. 10B comprises a signal representing a bit with value 0, while FIG. 10C comprises a signal representing a bit with value 1. It is appreciated that FIGS. 10B and 10C refer to the case where the apparatus of FIG. 5D is used. In the case of the apparatus of FIG. 5E, functionality corresponding to that depicted in FIGS. 10B and 10C is provided within the apparatus of FIG. 5E. Preferably, each bit is assigned a predetermined duration T, which is the same for every bit. A frequency modulated carrier is transmitted, using the method of frequency modulation keying as is well known in the art. An "off" signal (typically less than 0.7 Volts) presented at termination 5 of U2 in FIG. 5D causes a transmission at a frequency below the median channel frequency. An "on" signal (typically over 2.3 Volts) presented at pin 5 of U2 in FIG. 5D causes a transmission at a frequency above the median frequency. These signals are received by the corresponding receiver U1. Output signal from pin 6 of U1 is fed to the comparator 280 of FIGS. 4 and 6 that is operative to determine whether the received signal is "off" or "on", respectively. It is also possible to use the comparator that is contained within U1 by connecting pin 7 of U1 of FIG. 5D, through pin 6 of the connector J1 of FIG. 5D, pin 6 of connector J1 of FIG. 5A, through the jumper to pin 12 of U1 of FIG. 5A. Preferably, receipt of an on signal or spike of duration less than 0.01*T is ignored. Receipt of an on signal as shown in FIG. 10B, of duration between 0.01*T and 0.40*T is is preferably taken to be a bit with value 0. Receipt of an on signal as shown in FIG. 10C, of duration greater than 0.40*T is preferably taken to be a bit with value 1. Typically, T has a value of 1.0 millisecond. Furthermore, after receipt of an on signal, the duration of the subsequent off signal is measured. The sum of the durations of the on signal and the off signal must be between 0.90 T and 1.10 T for the bit to be considered valid. Otherwise, the bit is considered invalid and is ignored. Reference is now made to FIG. 11, which is a simplified flowchart illustration of a method for generating control instructions for the apparatus of FIG. 1A. The method of FIG. 11 preferably includes the following steps: A toy is selected (step 550). At least one command is selected, preferably from a plurality of commands associated with the selected toy (steps 560-580). Alternatively, a command may be entered by selecting, modifying, and creating a new binary command (step 585). Typically, selecting a command in steps 560-580 may include choosing a command and specifying one or more control parameters associated with the command. A control parameter may include, for example, a condition depending on a result of a previous command, the previous command being associated either with the selected toy or with another toy. A control parameter may also include an execution condition governing execution of a command such as, for example: a condition stating that a specified output is to occur based on a status of the toy, that is, if and only if a specified input is received; a condition stating that the command is to be performed at a specified time; a condition stating that performance of the command is to cease at a specified time; a condition comprising a command modifier modifying execution of the command, such as, for example, to terminate execution of the command in a case where execution of the command continues over a period of time; a condition dependent on the occurrence of a future event; or another condition. The command may comprise a command to cancel a previous command. The output of the method of FIG. 11 typically comprises one or more control instructions implementing the specified command, generated in step 590. Typically, the one or more control instructions are comprised in a command file. Typically, the command file is called from a driver program which typically determines which command is to be executed at a given point in time and then calls the command file associated with the given command. Preferably, a user of the method of FIG. 11 performs steps 550 and 560 using a computer having a graphical user interface. Reference is now made to FIGS. 12A-12C, which are pictorial illustrations of a preferred embodiment of a graphical user interface implementation of the method of FIG. 11. FIG. 12A comprises a toy selection area 600, comprising a plurality of toy selection icons 610, each depicting a toy. The user of the graphical user interface of FIGS 12A-12C typically selects one of the toy selection icons 610, indicating that a command is to be specified for the selected toy. FIG. 12A also typically comprises action buttons 620, typically comprising one or more of the following: a button allowing the user, typically an expert user, to enter a direct binary command implementing an advanced or particularly complex command not otherwise available through the graphical user interface of FIGS. 12A-12C; a button allowing the user to install a new toy, thus adding a new toy selection icon 610; and a button allowing the user to exit the graphical user interface of FIGS. 12A-12C. FIG. 12B depicts a command generator screen typically displayed after the user has selected one of the toy selection icons 610 of FIG. 12A. FIG. 12B comprises an animation area 630, preferably comprising a depiction of the selected toy selection icon 610, and a text area 635 comprising text describing the selected toy. FIG. 12B also comprises a plurality of command category buttons 640, each of which allow the user to select a category of commands such as, for example: output commands; input commands; audio in commands; audio out commands; and general commands. FIG. 12B also comprises a cancel button 645 to cancel command selection and return to the screen of FIG. 12A. FIG. 12C comprises a command selection area 650, allowing the user to specify a specific command. A wide variety of commands may be specified, and the commands shown in FIG. 12C are shown by way of example only. FIG. 12C also comprises a file name area 655, in which the user may specify the name of the file which is to receive the generated control instructions. FIG. 12C also comprises a cancel button 645, similar to the cancel button 645 of FIG. 12B. FIG. 12C also comprises a make button 660. When the user actuates the make button 660, the control instruction generator of FIG. 11 generates control instructions implementing the chosen command for the chosen toy, and writes the control instructions to the specified file. FIG. 12C also comprises a parameter selection area 665, in which the user may specify a parameter associated with the chosen command. Reference is now made to Appendix A, which is a computer listing of a preferred software implementation of the method of FIGS. 8A-8T. Appendix A is an INTEL hex format file. The data bytes start from character number 9 in each line. Each byte is represented by 2 characters. The last byte (2 characters) in each line, should be ignored. For example, for a sample line: The original line reads- :07000000020100020320329F The data bytes- 02010002032032 (02,01,00,02,03,20,32) Starting address of the data bytes- 0000 (00,00) Appendix A may be programmed into the memory of microcontroller 250 of FIG. 6. Appendix B is a computer listing of a preferred software implementation of the method of FIGS. 9A-9N, together with the method of FIGS. 8D-8M. Appendix B is an INTEL hex format file. The data bytes start from character number 9 in each line. Each byte is represented by 2 characters. The last byte (2 characters) in each line, should be ignored. For example, for a sample line: The original line reads- :070000000201000205A73216 The data bytes- 0201000205A732 (02,01,00,02,05,A7,32) Starting address of the data bytes- 0000 (00,00) Appendix B may be programmed into the memory of microcontroller 250 of FIG. 4. Appendix C is a computer listing of a preferred software implementation of an example of a computer game for use in the computer 100 of FIG. 1. Appendix D is a computer listing of a preferred software implementation of the method of FIGS. 11 and FIGS. 12A-12C. For Appendices C and D, these programs were developed using VISUAL BASIC. To run the programs you need to install the VISUAL BASIC environment first. The application needs a Visual Basic custom control for performing MIDI I/O similar to the one called MIDIVBX.VBX. VISUAL BASIC is manufactured by Microsoft Corporation, One Microsoft Way, Redmond, Wash. 98052-6399, USA. MIDIVBX.VBX is available from Wayne Radinsky, electronic mail address a-wayner@microsoft.com. The steps for programming the microcontrollers of the present invention include the use of a universal programmer, such as the Universal Programmer, type EXPRO 60/80, manufactured by Sunshine Electronics Co. Ltd., Taipei, Japan. The method for programming the microcontrollers with the data of Appendices A and B, includes the following steps: 1. Run the program EXPRO.EXE, which is provided with the EXPRO 60/80". 2. Choose from the main menu the EDIT/VIEW option. 3. Choose the EDIT BUFFER option. 4. Enter the string E 0000. 5. Enter the relevant data (given in Appendices A or B), byte after byte, starting from the address 0000. In each line there is a new starting address for each data byte which appears in this line. 6. Press ESC. 7. Enter the letter Q. 8. Choose from the main menu the DEVICE option. 9. Choose the MPU/MCU option. 10. Choose the INTEL option. 11. Choose the 87C51. 12. Choose from the main menu the RUNFUNC option. 13. Choose the PROGRAM option. 14. Place the 87C51 chip in the programmer's socket. 15. Enter Y and wait until the OK message. 16. The chip is now ready to be installed in the board. The method for creating the relevant files for the computer 100, with the data of Appendices C and D, includes using a HEX EDITOR which is able to edit DOS formatted files. A typical HEX and ASCII editor is manufactured by Martin Doppelbauer, Am Spoerkel 17, 44227 Dortmund, Germany, UET401 at electronic mail address hrz.unidozr.uni-dortmund.de. The steps necessary for creating the files by means of a HEX editor, such as by the Martin Doppelbauer editor include the following: 1. Copy any DOS file to a new file with the desired name and with the extension .EXE. (For example, write COPY AUTOEXEC.BAT TOY1.EXE). 2. Run the program ME.EXE. 3. From the main menu press the letter L(load file). 04. Write the main menu of the new file (for example TOY1.EXE). 5. From the main menu, press the letter (insert). 6. Enter the relevant data (written in Appendices C or D), byte after byte, starting from the address 0000. 7. Press ESC. 8. From the main menu, enter the letter W(write file). 9. Press the RETURN key and exit from the editor by pressing the letter Q. The above-described embodiment of FIG. 1C includes a description of a preferred set of predefined messages including a category termed "General commands". Other General Commands are defined by the following description: Multiport Commands
AVAILABILITY_INTERROGATION_COMMAND
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 05 00 00 00 00
x x
A computer transmits this command to verify that the radio channel is
vacant. If another computer is already using
this channel it will respond with the Availability Response Command. If no
response is received within 250 msec the
channel is deemed vacant.
P: Computer address 00-03 H
A: unit address - 00-FF H
AVAILABILITY_INTERROGATION_COMMAND
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 05 00 00 00 00
x x
A computer transmits this command to verify that the radio channel is
vacant. If another computer is already using
this channel it will respond with the Availability Response Command. If no
response is received within 250 msec the
channel is deemed vacant.
P: Computer address 00-03 H
A: unit address - 00-FF H
TOY_AVAILABILITY_COMMAND
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 07 00 00 00 00
x x
A Toy transmits this command to declare its existence and receive in
response a Channel Pair Selection Command
designating the computer that will control it and the radio channels to
use.
P: Computer address 00-03 H
A: unit address - 00-FF H
TOY_AVAILABILITY_COMMAND
byte 0 byte 1 byte 2 byte 3 byte 4 byte 5 byte 6 byte 7
byte 8 byte 9
Head PC Unit # Unit # Unit # CMD CMD -8 bits- -8 bits-
-8 bits- CRC
add A-sb B-sb C-sb msb lsb
Dat1 Dat1 Dat2
Dat2 Dat3 Dat3
msb lsb msb
lsb msb lsb
8 bit 2 bit 6 bit 8 bit 8 bit 8 bit 8 bit 4 bit 4 bit 4 bit 4
bit 4 bit 4 bit 8 bits
01 P 00 00 A 04 07 00 00 00 00
x x
A Toy transmits this command to declare its existence and receive in
response a Channel Pair Selection Command
designating the computer that will control it and the radio channels to
use.
P: Computer address 00-03 H
A: unit address - 00-FF H
In FIGS. 13 and 14 there are illustrated block diagrams of multiport multi-channel implementation of the computer radio interface 110 of FIG. 1A. FIG. 13 illustrates the processing sub-unit of the computer interface that is implemented as an add-in board installed inside a PC. FIG. 14 is the RF transceiver which is a device external to the computer and connects to the processing subunit by means of a cable. In the present application of the RF unit there are 4 transceivers each capable of utilizing two radio channels simultaneously. Referring briefly to FIG. 3, it is appreciated that, optionally, both sound and control commands may be transmitted via the MIDI connector 210 rather than transmitting sound commands via the analog connector 220. It is additionally appreciated that the functions of the interfaces 210 and 220 between the computer radio interface 110 and the sound card 190 may, alternatively, be implemented as connections between the computer radio interface 110 to the serial and/or parallel ports of the computer 100, as shown in FIGS. 25A-25F. If it is desired to provide full duplex communication, each transceiver 260 which forms part of the computer radio interface 110 of FIG. 1A preferably is operative to transmit on a first channel pair and to receive on a different, second channel pair. The transceiver 260 (FIG. 4) which forms part of the toy control device 130 of FIG. 1A preferably is operative to transmit on the second channel and to receive on the first channel. Any suitable technology may be employed to define at least two channel pairs such as narrow band technology or spread spectrum technologies such as frequency hopping technology or direct sequence technology, as illustrated in FIGS. 15A-15E, showing a Multi-Channel Computer Radio Interface, and in FIGS. 24A-24E showing a Multi-Channel Toy Control Device. Appendices E-H, taken together, are computer listings from which a first, DLL-compatible, functions library may be constructed. The DLL-compatible functions library may be subsequently used by a suitable computer system such as an IBM PC to generate a variety of games for any of the computer control systems shown and described herein. Alternatively, games may be generated using the applications generator of FIGS. 11-12C. To generate a DLL (dynamic loading and linking) function library based on Appendices E-H, the following operations are performed: 1) Open Visual C++4.0 2) Go to File Menu 3) Choose New from File Menu 4) Choose Project Workspace 5) Choose Dynamic-Link Library 6) The Project Name is: DLL32.MDP 7) Press Create button 8) Go to File Menu 9) Choose New from File Menu 10) Choose Text File 11) Now write the Source 12) Write on the current page a file containing the contents of Appendix E 13) Press the mouse right button and choose: Insert File Into Project 14) Click on DLL32 project 15) On the save dialog write CREATOR.C 16) Press the OK button 17) Go to File Menu 18) Choose New from File Menu 19) Choose Text File 20) Write on this page a file containing the contents of Appendix F; 21) Go to File Menu 22) Press Save 23) On the save dialog write CRMIDI.H 24) Press the OK button 25) Go to File Menu 26) Choose New from File Menu 27) Choose Text File 28) Write on this page a file containing the contents of Appendix G; 29) Go to File Menu 30) Press Save 31) On the save dialog write a file CREATOR.H 32) Press the OK button 33) Go to File Menu 34) Choose New from File Menu 35) Choose Text File 36) Write on this page a file containing the contents of Appendix H; 37) Press the mouse right button and choose: Insert File Into Project 38) Click on DLL32 project 39) On the save dialog write CREATOR.DEF 40) Press the OK button 41) Go to Insert Menu 42) Press File Into Project . . . 43) On the List Files of Type: Choose Library Files (*.lib) 44) Go to the Visual C++library directory and choose WINMM.LIB 45) Press the OK button 46) Go to the Build menu 47) Press Rebuild ALL A description of the commands included in the DLL function library based on Appendices E-H now follows: A. MIDI input functions 1-2: 1. Open MIDI input device Syntax: long MIDIInOpen(long Device) This function opens the MIDI device for input. Return 0 for success, -1 otherwise. Delphi Example: Device:=0; if MIDIInOpen(Device)<>0 Then MessageDlg(`Error opening MIDI input device`, mtError, mbOk, 0); 2. Reset MIDI input device Syntax: long MIDIInReset(void) this function resets MIDI input device. Return 0 for success, -1 otherwise. Delphi Example: if MIDIInRest<>0 Then MessageDlg(`Error reseting MIDI input device`, mtError, mbOk, 0); B. MIDI output functions 3-6: 3. Close MIDI input device Syntax: long MIDIInClose(void) This function close MIDI input device. Return 0 for success, -1 otherwise. Delphi Example: if MIDIInClose<>0 Then MessageDlg(`Error closing MIDI input device`, mtError, mbOk, 0); 4. Open MIDI output device Syntax: long MIDIOutOpen(long Device) This function opens MIDI output device. Return 0 if success, -1 otherwise. m Delphi Example: Device:=0; if MIDIOutOpen(Device)<>0 Then MessageDlg(`Error opening MIDI output device`, mtError, mbOk, 0); 5. Reset MIDI Output device Syntax: long MIDIOutReset(void) This function resets MIDI output device. Return 0 if success, -1 otherwise. Delphi Example: if MIDIOutReset<>0 Then MessageDlg(`Error reseting MIDI output device`, mtError, mbOk, 0); 6. Close MIDI output device Syntax: long MIDIOutClose(void) This function close MIDI output device. Return 0 if success, -1 otherwise. Delphi Example: Device:=0; if MIDIOutClose<>0 Then MessageDlg(`Error opening MIDI output device`, mtError, mbOk, 0); C. General functions 7-10: 7. Send Data Syntax: long SendData(long Data) This function sends 4 bytes to toy card. Currently used to send 144 for init toy card. Return 0 if succesfull, -1 otherwise. Delphi Example: If SendData(144)<>0 Then MessageDlg(`Error sending data to toy`, mtError, mbOk, 0); 8. Send Message Syntax: long SendMessage(char*Mess) This function sends string to toy card. Return 1 if successful, or error code otherwise. Delphi Example: Mess:=`00 01 00 00 00 00 00 05 00 00 00 01 00 03 00 01 00 00 00`; If SendMessage(Mess)<>1 Then MessageDlg(`Error opening MIDI output device`, mtError, mbOk, 0); 9. Check message Syntax: long CheckMessage(void) This function returns 0 if no message found from toy card. Delphi Example: If CheckMessage Then Mess:=GetMessage; 10. Get Message Syntax: char*GetMessage(char*Mess) This function returns 20 chars toy message if present, or "Time Out" otherwise. Delphi Example: If GetMessage="Time Out" Then MessageDlg(`No message received`, mtError, mbOk, 0); D. Toy control functions 11-16: 11. Get Toy Number Syntax: char*GetToyNumber(void) This function returns Toy Number of last receiving message, or "00 00 00 00" if no message was received. 12. Get Sensor Number Syntax: long GetSensorNumber(void) This function returns Sensor Number of last receiving message, or 255 if no message was received. 13. Toy Reset Syntax: long ToyReset(char*ToyNumber) This function sends a reset string to toy. Return 0 if successful, or -1 otherwise. 14. Toy Transceive Syntax: char*ToyTranceive(char*ToyNumber,char*Mess) This function sends message to toy and waits 3 sec to acknowledge. Return "Ack. Ok" if received, or "Time Out" if not. 15. Prepare Toy Talk yntax: char*PrepareToyTalk(char*ToyNumber, char*WaveFile) This function prepares toy card to generate sound using toy speaker. After calling this function, WaveFile may be played and heard at toy speaker. Return "Ack. Ok" if successful, or "Time Out" otherwise. 16. Go To Sleep Mode Syntax: char*GoSleep(char*ToyNumber) This function sends to toy the sleep command. Return "Ack. Ok" if successful, or "Time Out" otherwise. Appendices I-O, taken together, are computer listings of a second functions library which may be used to generate a variety of games for any of the computer control systems shown and described herein in conjunction with a Director 5.0 software package, marketed by Macromedia Inc., 600 Townsend St., San Francisco, Calif., 94103. To generate an XObject function library based on Appendices I-O, the following operations are performed: 1) Create a new directory: C:.backslash.XOBJECT.backslash. by writing (MD C:.backslash.XOBJECT.backslash.) 2) Open Visual C++1.5 3) On the File menu choose NEW 4) Generate a file which contains the contents of Appendix I; 5) Choose Save As from the File Menu 6) Give the file generated in step (4) a name by punching C:.backslash.XOBJECT.backslash.CREATOR.MAK 7) Press the OK button 8) On the File menu choose NEW 9) Generate a file which contains the contents of Appendix J; 10) On the File menu choose Save As. 11) In the File Name: dialog, write C:.backslash.XOBJECT.backslash.CREATOR.C 12) Press the OK button 13) On the File menu choose NEW 14) Generate a file which contains the contents of Appendix K; 15) On the File menu choose Save As. 16) In the File Name: dialog write C:.backslash.XOBJECT.backslash.CREATOR.H 17) Press the OK button 18) On the File menu choose NEW 19) Generate a file which contains the contents of Appendix L; 20) On the File menu choose Save As. 21) In the File Name: dialog write C:.backslash.XOBJECT.backslash.CRMIDI.H 22) Press the OK button 23) On the File menu choose NEW 24) Generate a file which contains the contents of Appendix M; 25) On the File menu choose Save As. 26) In the File Name: dialog write C:.backslash.XOBJECT.backslash.XOBJECT.H 27) Press the OK button 28) On the File menu choose NEW 29) Generate a file which contains the contents of Appendix N; 30) On the File menu choose Save As. 31) In the File Name: dialog write C:.backslash.XOBJECT.backslash.CREATOR.DEF 32) Press the OK button 33) On the File menu choose NEW 34) Generate a file which contains the contents of Appendix O; 35) On the File menu choose Save As. 36) In the File Name: dialog write C:.backslash.XOBJECT.backslash.CREATOR.RC 37) Press the OK button 38) On the Project Menu choose Open 39) In the File Name dialog write C:.backslash.XOBJECT.backslash.CREATOR.MAK40) Press Rebuild All from the Project Menu A description of the commands included in the XObject function library based on Appendices I-O now follows: A. MIDI input functions 1-3: 1. Open MIDI input device Syntax: long MIDIInOpen(long Device) This function opens the MIDI device for input. Return 0 for success, -1 otherwise. Delphi Example: Device:=0; if MIDIInOpen(Device)<>0 Then MessageDlg(`Error opening MIDI input device`, mtError, mbOk, 0); 2. Reset MIDI input device Syntax: long MIDIInReset(void) This function resets MIDI input device. Return 0 for success, -1 otherwise. Delphi Example: if MIDIInRest<>0 Then MessageDlg(`Error reseting MIDI input device`, mtError, mbOk, 0); 3. Close MIDI input device Syntax: long MIDIInClose(void) This function turns off MIDI input device. Return 0 for success, -1 otherwise. Delphi Example: if MIDIInClose<>0 Then MessageDlg(`Error closing MIDI input device`, mtError, mbOk, 0); B. MIDI output functions 4-6: 4. Open MIDI output device Syntax: long MIDIOutOpen(long Device) This function opens MIDI output device. Return 0 if success, -1 otherwise. Delphi Example: Device:=0; if MIDIOutOpen(Device)<>0 Then MessageDlg(`Error opening MIDI output device`, mtError, mbOk, 0); 5. Reset MIDI Output device Syntax: long MIDIOutReset(void) This function resets MIDI output device. Return 0 if success, -1 otherwise. Delphi Example: if MIDIOutReset<>0 Then MessageDlg(`Error reseting MIDI output device`, mtError, mbOk, 0); 6. Close MIDI output device Syntax: long MIDIOutClose(void) This function close MIDI output device. Return 0 if success, -1 otherwise. Delphi Example: Device:=0; if MIDIOutClose<>0 Then MessageDlg(`Error opening MIDI output device`, mtError, mbOk, 0); C. General functions 7-11: 7. New Syntax: Creator(mNew) This function creates a new instance of the XObject The result is 1 if successful, or error code otherwise. Example: openxlib "Creator.Dll" Creator(mNew) Creator(mDispose) See also: Dispose 8. Dispose Syntax: Creator(mNew) This function disposes of XObject instance. The result is1 if successful, or error code otherwise. Example: openxlib "Creator.Dll" Creator(mNew) ... Creator(mDispose) 9. Send Message Syntax: long SendMessage(char*Mess) This function sends string to toy card. Return 1 if successful, or error code otherwise. Delphi Example: Mess:=`00 01 00 00 00 00 00 05 00 00 00 01 00 03 00 01 00 00 00`; If SendMessage(Mess)<>1 Then MessageDlg(`Error opening MIDI output device`, mtError, mbOk, 0); 10. Check message Syntax: long CheckMessage(void) This function returns 0 if no message found from toy card. Delphi Example: If CheckMessage Then Mess:=GetMessage; 11. Get Toy Message Syntax: GetToyMessage This function receives message from toy. The result is a message. If during 3 sec there is no message, the result is "Time Out". Example: set message=GetToyMessage If message="Time Out" Then put "No message receiving" End If See also: Check for Message D. Toy control functions 12-17: 12. Get Toy Number Syntax: cha*GetToyNumber(void) This function returns Toy Number of last receiving message, or "00 00 00 00" if no message was received. 13. Get Sensor Number Syntax: long GetSensorNumber(void) This function returns Sensor Number of last receiving message, or 255 if no message was received. 14. Toy Reset Syntax: long ToyReset(char*ToyNumber) This function sends a reset string to toy. Return 0 if successful, or -1 otherwise. 15. Toy Tranceive Syntax: char*ToyTranceive(char*ToyNumber,char*Mess) This function sends to toy message and waits 3 sec to acknowledge. Return "Ack. Ok" if received, or "Time Out" if not. 16. Prepare Toy Talk Syntax: char*PrepareToyTalk(char*ToyNumber, char*WaveFile) This function prepares toy card to generate sound using from toy speaker. After calling this function, WaveFile may be played and heard at toy speaker. Return "Ack. Ok" if successful, or "Time Out" otherwise. 17. Go To Sleep Mode Syntax: char*GoSleep(char*ToyNumber) This function sends to toy the sleep command. Return "Ack. Ok" if successful, or "Time Out" otherwise. To use the XObject function library in conjunction with the Director, the following method may be employed. 1) Open Director Version 5.0 program 2) From File Menu, choose New 3) Press the Movie Option 4) Go to Windows menu and press Cast 5) Go to the first Script on the cast 6) On the Window menu choose Script 7) Write the script of the desired game. 8) Repeat from step 5 until all desired script(s) have been written. Press (Ctrl+Alt+P) to run the Application Reference is now made to FIG. 16 which is a simplified flowchart illustration of a preferred method of operation of a computer radio interface (CRI) 110 operative to service an individual computer 100 of FIG. 1A without interfering with other computers or being interfered with by the other computers, each of which is similarly serviced by a similar CRI. Typically, the method of FIG. 16 is implemented in software on the computer 100 of FIG. 1A. The CRI includes a conventional radio transceiver (260 of FIG. 4) which may, for example, comprise an RY3 GB021 having 40 channels which are divided into 20 pairs of channels. Typically, 16 of the channel pairs are assigned to information communication and the remaining 4 channel pairs are designated as control channels. In the method of FIG. 16, one of the 4 control channel pairs is selected by the radio interface (step 810) as described in detail below in FIG. 17. The selected control channel pair i is monitored by a first transceiver (step 820) to detect the appearance of a new toy which is signalled by arrival of a toy availability command from the new toy (step 816). When the new toy is detected, an information communication channel pair is selected (step 830) from among the 16 such channel pairs provided over which game program information will be transmitted to the new toy. A preferred method for implementing step 830 is illustrated in self-explanatory flowchart FIG. 18A. The "Locate Computer" command in FIG. 18A (step 1004) is illustrated in the flowchart of FIG. 18B. The identity of the selected information communication channel pair, also termed herein a "channel pair selection command", is sent over the control channel pair to the new toy (step 840). A game program is then begun (step 850), using the selected informatio | ||||||
