Error handling at the FBSD level
At this point you may come to the conclusion that the FB places the FBSD in an error state in the event of an inadmissible command because it is a command issuing state automaton. According to the PLCopen specification, however, this is not the case because the following applies to the FBSD:
Note 3: The transition Error refers to errors from the axis and axis control and not from the Function Block instances.
These axis errors may also be reflected in the output of the Function Blocks ‘FB instances errors’.
This means that a motion FB never places the FBSD in the ERROR state, but is only an error that is reported by the motion controller. To this end, it is necessary for an axis-specific handler process to obtain the error messages from the HLI and to file them in the axis-specific work data, i.e. in the FBSD. The individual FBs then see the error state of the axis via their AXIS_REF.