LEGO MINDSTORMS NXT

Sequence Beam

The sequence beam controls the flow of your program. It indicates the sequence in which programming blocks will run. Blocks connected to the sequence beam can be downloaded to the NXT. Other blocks in the work area that are not connected to the sequence beam will not be downloaded.

Image of the starting point plus a move block and a sound block on a sequence beam

 

You can use the starting point to create additional sequence beams that will allow your program to run simultaneous tasks. For example, you might have the main sequence beam in your program controlling a robot’s forward motion but have a second sequence beam controlling a robotic arm that sits on top of the robot.

Image of a program with a main sequence beam and a parallel sequence beam coming out of the starting point perpendicularly and then turning to run parallel

 

Create a parallel sequence beam by moving the mouse pointer over the starting point (or over the wire stub), and pressing and holding your mouse button while you move the mouse upwards or downwards. This will draw out a sequence beam that can be connected to programming blocks. When you download and run the program, the blocks on both sequence beams will run in parallel. You can use data wires to have the blocks on both sequence beams communicate with each other.

Image of the starting point with a new sequence beam being drawn upwards

 

You can also start a new sequence beam later in your program (i.e., not from the starting point). Do this by holding down the Shift key and moving your mouse pointer straight up or down from a position on the main sequence beam.

Image showing a mouse pointer, moving straight up or down, “drawing out” a new sequence beam from the master sequence beam