MotionBASIC
TM
Error Handler
Modifying Your Program
Chapter 5
Modifying
Your Program
5. Modifying Your Program
There are three steps to adding the Error Handler Module to your program:
1.
First, you must configure the module using MotionPRO’s off-line editor.
Chapter 1 described this step.
2.
Second, you merge ERRMENU.BAS, and any other MBTools you want
to use, into the controller’s Setup Area. Chapter 2 described this step
3.
Third, you modify your program to work with the Error Handler Module.
This chapter describes how to do step three.
5.1 Steps Required To Modify Your Program
Modifying your program is a four step process:
1.
You must check for and resolve conflicts in variable names and
program labels. Obviously, this is much easier if you review potential
conflicts before you write your program.
2.
You must add statements to your program to correctly initialize the
MBTools Modules.
3.
You must at subroutines to your program to handle application specific
error trapping, emergency stop and restart-after-fault procedures.
4.
You must add statements to invoke the Fault Menu at the appropriate
places in your program.
GN3-ERRb
page 13
Summary of Contents for MotionBASIC
Page 3: ...ii...
Page 5: ...MotionBASICTM Error Handler Table of Contents A3 Complete Program Listings 31 iv...
Page 6: ...v...
Page 8: ...vii...
Page 10: ...MotionBASICTM Error Handler Welcome THIS PAGE INTENTIONALLY LEFT BLANK page 2 GN3 ERRb...
Page 37: ...MotionBASICTM Error Handler Appendix A1 GN3 ERRb page 29...
Page 38: ...MotionBASICTM Error Handler Appendix A1 THIS PAGE INTENTIONALLY LEFT BLANK page 30 GN3 ERRb...
Page 40: ...MotionBASICTM Error Handler Appendix A2 THIS PAGE INTENTIONALLY LEFT BLANK page 32 GN3 ERRb...