0. Review the document “Logix 5000 Structured Text“ (1756-pm007_-en-p).


1. Right click on the ‘Main Program’ and select ‘New Routine’. Call the subroutine ‘test’ and set the type to ‘structured text’. Double click on the newly created ‘test’ and a structured text window will pop up.


2. Enter the following program.


3. Modify the main routine to call the subroutine. Set the outputs to be aliases for the output lights.


4. The Structured Text program implements the following state diagram. Enter the program and verify the operation. (Note: you will need to create a timer ‘t’ of type ‘FBD_TIMER’.)




[an error occurred while processing this directive]