3.1 Basic Functionality3.1.1 Programs3-16 Specifying Sequence ProgramsSequence programs must be specified directly. Indirect designations cannot be used.Specify the program number of the sequence program to execute (SPM). Work RegistersWork registers are used to monitor sequence programs.The work registers have Status Flags inside the M-EXECUTOR control registers, in the sameway as motion programs that are registered in the M-EXECUTOR.• Sequence Program Status FlagsThe Sequence Program Status Flags give the execution condition of the sequence program.The following table describes the meanings of the Status Flags.Bit No. Name Status0 Program Executing Program is being executed.1 − Reserved for system.2 − Reserved for system.3 − Reserved for system.4 − Reserved for system.5 − Reserved for system.6 − Reserved for system.7 − Reserved for system.8 Program Alarm There is a program alarm.9 Program Stopped at Breakpoint Execution is stopped at a breakpoint.A − Reserved for system.B Debug Operation Mode The program is in Debug Mode (EWS debugging).C Program Type Program Type, 1: Sequence programD Start Request History There is a request to start program execution.E − Reserved for system.F − Reserved for system.Sequence Program AlarmsWhen an error is detected, bit 8 (Program Alarm) turns ON in the Status Flags in the M-EXECU-TOR control registers.When the error is removed, this bit turns OFF.The following errors can occur.• The called program is not registered.• The called program is not a sequence program.• The called program is not a subprogram (a main program was called).• Called Program Number Limit Exceeded Error• Too Many Nesting Levels ErrorSPM001IF MW000<32767;MW000=MW000+1;ELSE;MW000;IEND;Sequence programM-EXECUTOR Program Execution DefinitionsNote