Commanding State Transitions

Run Command

Effect: Commands a transition to the RUNNING controller state.

Starting Conditions: BOOTING or STOPPED state.

Methods for Issuing a Run Command:

oRun/Stop Input: If configured, command a rising edge to the Run/Stop input (assuming the Run/Stop switch is in the RUN position). Set the Run/Stop to 1 for all of the subsequent options to be effective.

Refer to Run/Stop Input for more information.

oRun/Stop Switch: manually set the switch to RUN (given the Run/Stop input is set to 1 if it is configured).

oWith EcoStruxure Machine Expert software (with the Run/Stop Input set to 1 and the Run/Stop switch set to the RUN position):

oClick the menu Online > Start

oClick the start icon which is symbolized by an arrow in the icon bar

oBy an external call via Modbus request using the PLC_W.q_wPLCControl and PLC_W.q_uiOpenPLCControl system variables of the M218 PLCSystem Library.

oLogin with online change option: An online change (partial download) initiated while the controller is in the RUNNING state returns the controller to the RUNNING state if successful.

oThe controller is restarted into the RUNNING state automatically under certain conditions.

Refer to Controller State Diagram for further details.

Stop Command

Effect: Commands a transition to the STOPPED controller state.

Starting Conditions: BOOTING, EMPTY, or RUNNING state.

Methods for Issuing a Stop Command:

oRun/Stop Input: If configured, command a value of 0 to the Run/Stop input. Refer to Run/Stop Input for more information.

oRun/Stop Switch: manually set the switch to STOP.

oWith EcoStruxure Machine Expert software:

oClick the menu Online > Stop

oClick the stop icon which is symbolized by a square in the icon bar

oBy an internal call by the application or an external call via Modbus request using the PLC_W. q_wPLCControl and PLC_W. q_uiOpenPLCControl system variables of the M218 PLCSystem Library.

oLogin with online change option: An online change (partial download) initiated while the controller is in the STOPPED state returns the controller to the STOPPED state if successful.

oDownload Command: implicitly sets the controller into the STOPPED state.

oThe controller is restarted into the STOPPED state automatically under certain conditions.

Refer to Controller State Diagram for further details.

Reset Warm

Effect: Resets all variables, except for the remanent variables, to their default values. Places the controller into the STOPPED state.

Starting Conditions: RUNNING, STOPPED, or HALT states.

Methods for Issuing a Reset Warm Command:

oEcoStruxure Machine Expert Online Menu: Select the Reset warm command.

oBy an internal call by the application or an external call via Modbus request using the PLC_W. q_wPLCControl and PLC_W. q_uiOpenPLCControl system variables of the M218 PLCSystem Library.

Effects of the Reset Warm Command:

1.The application stops.

2.Forcing is erased.

3.Diagnostic indications for errors are reset.

4.The values of the retain variables are maintained.

5.The values of the retain-persistent variables are maintained.

6.All non-located and non-remanent variables are reset to their initialization values.

7.The values of the first 500 %MW registers are maintained.

8.The values of %MW500 to %MW59999 registers are reset to 0.

9.All fieldbus communications are stopped and then restarted after the reset is complete.

10.All I/O are reset to their initialization values.

For details on variables, refer to Remanent Variables.

Reset Cold

Effect: Resets all variables, except for the retain-persistent type of remanent variables, to their initialization values. Places the controller into the STOPPED state.

Starting Conditions: RUNNING, STOPPED, or HALT states.

Methods for Issuing a Reset Cold Command:

oEcoStruxure Machine Expert Online Menu: Select the Reset cold command.

oBy an internal call by the application or an external call via Modbus request using the PLC_W. q_wPLCControl and PLC_W. q_uiOpenPLCControl system variables of the M218 PLCSystem Library.

Effects of the Reset Cold Command:

1.The application stops.

2.Forcing is erased.

3.Diagnostic indications for errors are reset.

4.The values of the retain variables are reset to their initialization value.

5.The values of the retain-persistent variables are maintained.

6.All non-located and non-remanent variables are reset to their initialization values.

7.The values of the first 500 %MW registers are maintained.

8.The values of %MW500 to %MW59999 registers are reset to 0.

9.All fieldbus communications are stopped and then restarted after the reset is complete.

10.All I/O are reset to their initialization values.

For details on variables, refer to Remanent Variables.

Reset Origin

Effect: Resets all variables, including the remanent variables, to their initialization values. Erases all user files on the controller. Places the controller into the EMPTY state.

Starting Conditions: RUNNING, STOPPED, or HALT states.

Methods for Issuing a Reset Origin Command:

oEcoStruxure Machine Expert Online Menu: Select the Reset origin command.

Effects of the Reset Origin Command:

1.The application stops.

2.Forcing is erased.

3.The Boot application file is erased.

4.Diagnostic indications for errors are reset.

5.The values of the retain variables are reset.

6.The values of the retain-persistent variables are reset.

7.All non-located and non-remanent variables are reset.

8.The values of the first 500 %MW registers are reset to 0.

9.The values of %MW500 to %MW59999 registers are reset to 0.

10.All fieldbus communications are stopped.

11.All other I/Os are reset to their initialization values.

For details on variables, refer to Remanent Variables.

Reboot

Effect: Commands a reboot of the controller.

Starting Conditions: Any state.

Methods for Issuing the Reboot Command:

oPower cycle

Effects of the Reboot:

1.The state of the controller depends on a number of conditions:

a.The controller state will be RUNNING if:

- the Run/Stop switch is in the RUN position

- and, if configured, the Run/Stop Input is set to 1.

The Reboot was provoked by a script and:

- the Starting Mode is set to Start in run, and if the Run/Stop input or switch is configured and set to RUN, and if the controller was not in HALT state before the power cycle, and if the remanent variables are valid.

b.The controller state will be STOPPED if:

- the Run/Stop switch is in the STOP position

- or, if configured, the Run/Stop input is set to STOP.

c.The controller state will be EMPTY if:

- There is no boot application or the boot application is invalid, or

- The reboot was provoked by specific System Errors.

d.The controller state will be INVALID_OS if there is no valid firmware.

2.Forcing is erased.

3.Diagnostic indications for errors are reset.

4.The values of the retain variables are restored if saved context is valid.

5.The values of the retain-persistent variables are restored if saved context is valid.

6.All non-located and non-remanent variables are reset to their initialization values.

7.The values of the first 500 %MW registers are restored if saved context is valid.

8.The values of %MW500 to %MW59999 registers are reset to 0.

9.All fieldbus communications are stopped and restarted after the boot application is loaded successfully.

10.All I/O are reset to their initialization values and then to their user-configured default values if the controller assumes a STOPPED state after the reboot.

For details on variables, refer to Remanent Variables.

NOTE: If you make an online change to your application program while your controller is in the RUNNING or STOPPED state but do not manually update your Boot application, the controller will detect a difference in context at the next reboot, the remanent variables will be reset as per a Reset cold command, and the controller will enter the STOPPED state.

Download Application

Effect: Loads your application executable into the RAM memory. Optionally, creates a Boot application in the Flash memory.

Starting Conditions: RUNNING, STOPPED, HALT, and EMPTY states.

Methods for Issuing the Download Application Command:

oEcoStruxure Machine Expert Online Menu: select Download command.

Effects of the EcoStruxure Machine Expert Download Command:

1.The existing application stops and then is erased.

2.If valid, the new application is loaded and the controller assumes a STOPPED state.

3.Forcing is erased.

4.Diagnostic indications for errors are reset.

5.The values of the retain variables are reset to their initialization values.

6.The values of any existing retain-persistent variables are maintained.

7.All non-located and non-remanent variables are reset to their initialization values.

8.The values of the first 500 %MW registers are maintained.

9.The values of %MW500 to %MW59999 registers are reset to 0.

10.All fieldbus communications are stopped and then any configured fieldbus of the new application is started after the download is complete.

11.All I/O are reset to their initialization values and then set to the new user-configured default values after the download is complete.

For details on variables, refer to Remanent Variables.