Situation
It is desired, in case of an alarm or in case of a lack of feedback from an axis belonging to the power, to delay the disabling of the Power Set so that a controlled stop ramp can be commanded from application software.
NOTE: The axis in alarm may not be able to perform such ramping (e.g., power stage breakage, ...).
Procedure
In the power set graphic configurator, set a delay time.
NOTE: This time must be just greater the stop ramp.
From the R3/LD program, use the PS_STATUS function and use the BITs that signal "count in progress" or the keyword SWITCHING_OFF to, for example, assign the axes the stop RULE with the maximum possible deceleration.
Example
I32 power_sts, systemPowered, powerGoingDown power_sts = ps_status(power)
systemPowered = ((power_sts r_and 0x12) = 0x12) powerGoingDown = (power_sts r_and 0xC0) |