Your program may create a separate vector table in memory to contain its exception vectors. If this is done, the program must change the value of the VBR to point to the new vector table. In order to use the debugger facilities you can copy the proper vectors from the 177Bug vector table into the corresponding vector locations in your program vector table. The vector for the 177Bug generalized exception handler (described in detail in the 177Bug Generalized Exception Handler section in this chapter) may be copied from offset $08 (bus error vector) in the target vector table to all locations in your program vector table where a separate exception handler is not used. This provides diagnostic support in the event that your program is stopped by an unexpected exception. The generalized exception handler gives a formatted display of the target registers and identifies the type of the exception.
It may happen that your program
uses one or more of the exception vectors that are required for debugger operation. Debugger facilities may still be used, however, if your exception handler can determine when to handle the exception itself and when to pass the exception to the debugger. When an exception occurs which you want to pass on to the debugger; i.e., ABORT, your exception handler must read the vector offset from the format word of the exception stack frame. This offset is added to the address of the 177Bug target program vector table (which your program saved), yielding the address of the 177Bug exception vector. The program then jumps to the address stored at this vector location, which is the address of the 177Bug exception handler.
Your program must make
sure that there is an exception stack frame in the stack, and that it is exactly the same as the processor would have created for the particular exception before jumping to the address of the exception handler. The following is an example of an exception handler which can pass an exception along to the debugger:The 177Bug has a generalized exception handler which it uses to handle all of the exceptions not listed in Table B-3. For all these exceptions, the target stack pointer is left pointing to the top of the exception stack frame created. In this way, if an unexpected exception occurs during execution of your code
Payment method and delivery
Shipment: EMS,DHL,UPS & FEDEX
Payment: T/T or Western Union
Professional seller
Professional sales of major electrical brand products in the world
Overseas direct purchase of products, authentic inventory, price concessions
After sales warranty, complete models, same products, different prices and services