
|
| THE COMMAND BLOCK FACTORY | |||
|
|
|
| ||
Basic Movements | The basic movements are those from "Stop" to "Rotate from right to | ||||
| left" on the command table. The extent of the movement is expressed | ||||
| in numbers of steps, for example, "Go forward 3 steps" and "Rotate 6 | ||||
| steps to the right". In the case of the "Stop" command, the robot | ||||
| does not move, but instead of the number of steps, the numerical | ||||
| parameter for this command gives the number of seconds for which the | ||||
| robot must stand still. |
|
|
| |
Switching panels The purpose of switching panels is to switch to a program on another | |||||
| panel. Commands such as "Switch to Panel 2" can be used. When the | ||||
| sensor assigned to this command reacts, control switches to the |
|
| ||
| program on Panel 2. |
|
|
| |
|
|
| |||
Command Table | This table lists the basic commands, plus other commands, and describes | ||||
| what they do. |
|
|
| |
|
|
|
|
|
|
Icon | Name | Movement | time(sec) Override | Speed |
|
|
|
|
|
|
|
| Stop | Robot halts for period specified. | time(sec) |
|
|
|
|
|
|
|
|
| Go | Robot advances specified number of steps. | Steps |
|
|
| forward |
|
| ||
|
|
|
|
| |
|
|
|
|
|
|
| Go | Robot retreats specified number of steps. | Steps |
|
|
backward |
|
| |||
|
|
|
| ||
|
|
|
|
|
|
Rotate to | Robot moves left and right legs in opposite |
|
|
| |
directions, and rotates to the right, on | Steps |
|
| ||
the right |
|
| |||
the spot. |
|
|
| ||
|
|
|
|
| |
Rotate to | Robot moves left and right legs in opposite |
|
|
| |
directions, and rotates to the left, on | Steps |
|
| ||
the Left |
|
| |||
the spot. |
|
|
| ||
|
|
|
|
| |
Turn right | Robot turns to the right like a car, by | Steps |
|
| |
moving its legs forward on one side only. |
|
| |||
|
|
|
|
|
|
Turn left | Robot turns to the left like a car, by | Steps |
|
| |
moving its legs forward on one side only. |
|
| |||
|
|
|
|
| |
|
|
|
|
|
|
| Back Up | Robot turns back to the right like a car, |
|
|
|
| by moving its legs backward on one | Steps |
|
| |
| right |
|
| ||
| side only. |
|
|
| |
|
|
|
|
| |
|
|
|
|
|
|
| Back Up | Robot turns back to the left like a car, |
|
|
|
| by moving its legs backward on one | Steps |
|
| |
| left |
|
| ||
| side only. |
|
|
| |
|
|
|
|
| |
|
|
|
|
| |
Rotate to | Robot turns randomly either to the right |
|
|
| |
the right | Steps |
|
| ||
or to the left. |
|
| |||
| or left |
|
|
| |
|
|
|
|
| |
|
|
|
|
|
|
| Sound | Robot emits a call - one of the four calls |
|
|
|
| from 1 to 4 - for the number of times | Times |
|
| |
|
| specified. |
|
|
|
|
|
|
|
|
|
| Call a | While calling, the robot emits the infrared |
|
|
|
| fellow | Time(s) |
|
| |
| signal used for calling to another WonderBorg. |
|
| ||
WonderBorg |
|
|
| ||
|
|
|
|
| |
Threaten | While calling, the robot emits the infrared | Time(s) |
|
| |
| fellow | signal used for threatening another |
|
| |
WonderBorg | WonderBorg. |
|
|
| |
| Dance | Robot rotates rhythmically to the left and | Time(s) |
|
|
| right. |
|
| ||
|
|
|
|
| |
|
|
|
|
|
|
Option ON | Motor or other device connected to Option | Period(sec) |
|
| |
Connector is turned ON for specified period. |
|
| |||
|
|
|
|
| |
|
|
|
|
|
|
| Switch | Control jumps to the panel number specified | Panel no |
|
|
| panel | after the icon (1 to 8). | 1 to 8 |
|
|
|
|
|
|
|
|
| Tone | Robot emits specified tone, which is one | Tone no |
|
|
(1 to 8) | of the 8. | 1 to 8 |
|
|
41
PRIORITY ORDER AND INTERRUPTS
Priority Order
When two sensor blocks react at the same time, the sensor block on the higher line of the program takes priority, and the WonderBorg executes the command linked to that sensor. If the WonderBorg does not behave as you expect it to, check the priority order.
Interrupt
When you click the "Interrupt" button on the Command Block Factory screen, the selected block will turn green and its corners will become rounded. When a block is red, other sensors will be ignored until this block’s command has completed (e.g. until the robot has advanced 5 steps). When the block is green, however, in the event of a reaction by a sensor with a higher priority (i.e. a sensor higher up on the Panel screen than the sensor linked to this command) while this command is being executed, control will switch to the command assigned to the prioritized sensor. In other words, the green block is "interruptable". This is explained in the diagram below.
When you use an interrupt, the WonderBorg will react more swiftly to the sensors, and will break off smoothly in the middle of a series of actions when an interrupt is triggered.
How an Interrupt Works
Example: If you want to make the WonderBorg walk towards the brightest
direction....
Interruptable block
If a sensor with a higher priority reacts while action in progress, control will switch to the command linked to the prioritized sensor
If the WonderBorg is programmed to rotate (30 Steps Left), then change position
slightly (go 2 Steps forward).....
1. While the robot is rotating left (for instance,
when it has walked 3 steps).....
2. IF "Light" Sensor reacts, robot does not have to rotate for remaining number of
steps (nor does it have to take 2 steps
forward in 2nd part of instruction)."Light" Sensor react!!! The "Light" sensor is higher up in the
program than "Nothing Here". The first takes priority.
3. Robot immediately executes "Go Forward 5
Steps" command. ("Go Forward Command" overrides the other command.)
42