Download User Manual

Transcript
12-6
Handling Controller Faults
7KHIROORZLQJORJLFVKRZVRQHZD\WRFKHFNIRUDQ
LQVWUXFWLRQH[HFXWLRQPLQRUIDXOW3ODFHWKLVORJLFZLWKLQDURXWLQHLQ
DSURJUDPQRWLQWKHIDXOWURXWLQH
checking for an instruction-execution minor fault
This example monitors S:MINOR to determine if a minor fault occurs with the execution of the SSV instruction. You could replace this SSV
instruction with any instruction or operation that you want to check to see whether it generates a minor fault (like checking for an overflow
condition with a math instruction). The GSV instruction then retrieves the fault information and stores it in a tag that uses the structure type
you defined. The Destination tag must point to the first DINT of the structure (MyFaultRecord.TimeLow in this example).
Processing other minor faults
minor fault occurs
controller logs minor
fault to FAULTLOG
controller sets minor
fault bit in
FAULTLOG
continue logic
execution
:KHQDPLQRUIDXOWRFFXUVWKHFRQWUROOHUORJVWKHPLQRUIDXOW
LQIRUPDWLRQGLUHFWO\WRWKH)$8/7/2*REMHFW
1756-6.5.12 March 1999