Subject:
|
Understanding Event Register Container
|
Newsgroups:
|
lugnet.robotics.rcx.robolab
|
Date:
|
Fri, 27 Aug 2004 00:17:20 GMT
|
Viewed:
|
9030 times
|
| |
| |
Below is text output of a Robolab 2.5 program using two concurrent events. What
exactly does "Variable 0 = 0" mean? It's right under the EventLand label. This
line represent the default Red Container being assigned the Event Register
Container.
Begin of Task 0
Set sensor 0 to type Light
Set sensor 0 to mode Raw - slope: 4
Set sensor 2 to type Light
Set sensor 2 to mode Raw - slope: 4
Wait for Constant 100
sete 0,0,10
set 28,0,2,10
set 29,0,2,35
set 30,0,2,2
set 31,0,2,1
sete 2,2,10
set 28,2,2,10
set 29,2,2,35
set 30,2,2,2
set 31,2,2,1
Label0:
Set power of motors A to Constant 7
Set direction to A Forward
Turn motors A On
Set power of motors C to Constant 7
Set direction to C Forward
Turn motors C On
monel 2,5,EventLand
Jump Label2
EventLand:
Variable 0 = 0
If Constant 3 = Variable 0 then Label1002
Set power of motors A to Constant 7
Set direction to A Backward
Turn motors A On
Wait for Constant 15
Jump Label1005
Label1002:
If Constant 2 = Variable 0 then Label1003
Set power of motors C to Constant 7
Set direction to C Backward
Turn motors C On
Wait for Constant 15
Jump Label1004
Label1003:
Label1004:
Label1005:
Label2:
Jump Label0
endt
|
|
Message has 1 Reply:
4 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|