Question from Tim McGeary:

What would a reason be that when I try to assemble my program I get a "Run time error 90, PC=50FF"??? I cannot see any errors in my program on the screen or the hard copy.

ANSWER from mdwagh:

You have some pretty long DB lines in your program. The assembler reads only first 70 or so characters from a line and ignores the rest. This would be ok if the missing characters are parts of comments. But if the assembler misses out a closing quote like in:

DB 'This is a very very very very very very very very very looooong line'

then, it is totally lost.

Unfortunately, at these errors, the listing file (say, prog2.prn) is not closed and you cannot find out where the assembler got stuck.

Do the following: Run assembler in debug mode (to show each assembly pass) and also request the output listing (normally written to file prog2.prn) to be sent to the console. This is done by invoking A80 as:

a80 prog2 /d /pcon

You will then see the listing prog2.prn scrolling on the screen. When the program gets stuck, you can see which line it was assembling. (The assembly program line number is written at the beginning of each line in the prn file). Once you know the line with this problem, merely split it in two shorter DB statements. This will always work!