robertmee said:
A common culprit is illegal MATH operations. Make sure you don't have any possible DIV by zero cases or multiplication overflows. To guard against DIV by zero, precede your DIV (or CPT) box with a NEQ 0 on the denominator address. It is also common to include a line of ladder at the end of your program to reset the Overflow trap bit which faults the processor.
Just a simple OTU S:5/0
If you follow my experienced colleague Robert's advice, think of it as a "force". You are forcing off a fault that is trying to report a programming error which could result in death destruction and loss of multiple paychecks.
In a real world situation, take those faults very seriously. Your machine is down, and the pressure is on to get her up and flowing again, but take a few seconds before clicking the "Clear Error" button and do a "Go To Error".
Make a quick note of the fault code it shows you, and the rung and file number. An illegal indirect address instruction should leave behind that information for you to quickly analyze.
Then, (remember only ten-fiteen seconds have gone by):
Take a long moment to ensure your self that just clearing the fault and turning the machine back is the right thing to do. Most often, you want to fix the error first.
I have been fortunate in that my fault clearing career has been littered with relatively minor machine damage but never an injury.
For errors that "aren't gonna hurt anything": It is my recommendation that you make a copy of the overflow or any other error bits before releasing them. Do this by examining the error bit, when it contains a 1, latch (OTL) a user memory bit, then branch once and unlatch (OTU) the error bit. I will agree with Robert that this is common practice in situations where interim math my cause an overflow, but the result is later clamped or otherwise corrected. Simply adding an OTU rung is often more efficient than the logic required to avoid the math error.
If you are in class, working on an emulator, etc, then just use Robert's rung, and be sure to remove it before you install it in a running machine where safety's a concern.
Oh yeah, in case you haven't fixed the runtime bug yet, always put one of these in front of indexed addresses ...
LIM
Low: 0
Source Step_number
High: 32
Good chance that the program has an invalid indirect address.
Our student most likely allowed the download to change his file sizes when he downloaded his communication away earlier.
Always read and understand the implications of those warnings...
I can't think of a time when I wanted my data tables automatically resized...
See, David, you are learning so much more than sequencers, huh?
"Every stumble strengthens the knees."