From that assembly listing, you can see what it has done with the duplicate symbols. Look at the generated code for each instruction as shown on the left, you can see that all the "beq read_again" instructions assemble as "27 f9" (shown in hexadecimal, of course).The 27 is the opcode for beq, and the f9 (minus 7 in decimal) is the offset, relative to the next instruction, to branch to. So, it has created code that does what you want, but to me just doing that silently is a big trap for the unwary - think what could happen if you accidentally used the same symbol twice.
I don't remember where I got AS11 from. I have it in a directory together with the Axiom IDE (I had one of their boards), so perhaps it was bundled with that.
You could use asm11.exe from http://www.aspisys.com/asm11.htm ("Click title for binaries" link) instead. That even runs natively on current Windows versions, something that AS11 (at least the one I have) does not. The listing produced by that gives some additional information too, like the cycle counts for each instruction.
For today's assembly language lesson, take a look at the generated code for these four instructions:
0020 0110 86 48 ldaa #72 ; send "H" to serial
0021 0112 86 48 ldaa #$48 ; send "H" to serial
0022 0114 86 48 ldaa #%01001000 ; send "H" to serial
0023 0116 86 48 ldaa #'H' ; send "H" to serial
For what you were doing, which of those do you think makes the most sense?
I'm familiar with the first 3 lines, but I never tried "#'H'. The reason I was so familiar with the first 3 lines was because I had to learn to and distinguish them to even understand what the EEG firmware is doing, and after knowing them, figuring out the missing codes the manufacturer deleted on purpose.
They reason they bricked the old 1999 EEG unit was because it was once free to use. Now you must pay for limited time use and very expensive. When I bought it in 1999 I didn't even use it. I planned to explore it last year October and I ran the manufacturer latest software which bricked them. Fortunately. My old software in a 1.44M diskette still worked after 22 years. I How long is the 1.44M diskette you have tried to read and no bad sectors? Then I open the unit and found out it has an HC11 inside and I read everything about HC11 until I know how to write simple codes, and analyze loops. The THRsim11 has helped me a lot. Also in the 7 pages firmware. Only 3 are required, the rest creates many loops that are meant to confuse those who are seeing the firmware. It took me 2 weeks to analyze them after writing each register on paper and tracing the loop. And usng THRsim11 simulator. Had I know how to trace in Buffalo that time, It could have helped me a lot.
If you used identical label names inside loop. It can jump incorrectly, and it took 2 days to discover it last November. In the latest asm11 copy you shared above. The following is the error now. (the reason I still use multiple labels is just to quickly display Hello at serial, that's why I didn't use any subroutine for the serial which I know how to do. I don't use the Hc11 for other purposes except just exploring the EEG thing and I forgot about not using multiple labels because my AS11 copy not showing error.. Ataradov kept asking me why I still use the HC11. It's primarily to fix the bricked EEG which I did successfully):
C:\Users\AlbeP\Downloads\asmw32\hw.txt(27): Error: Possibly duplicate symbol "read_again"
C:\Users\AlbeP\Downloads\asmw32\hw.txt(33): Error: Possibly duplicate symbol "read_again"
C:\Users\AlbeP\Downloads\asmw32\hw.txt(39): Error: Possibly duplicate symbol "read_again"
C:\Users\AlbeP\Downloads\asmw32\hw.txt(45): Error: Possibly duplicate symbol "read_again"
C:\Users\AlbeP\Downloads\asmw32\hw.txt(51): Error: Possibly duplicate symbol "read_again"
Assembled hw.txt (56 lines) [Errs: 5]
1 file processed! (Elapsed time: 0:00:00)
The following is when the loop has unique names
Assembled hw.txt (56 lines) 90 bytes, RAM: 0, CRC: $EEF8
1 file processed! (Elapsed time: 0:00:00)
What web sites can one upload files that you can download? The as11 is open source. I want to upload you my as11 copy which doesn't show any error even if all identical labels used. It can run only in 32bit Windows DOS. Your as11 link is great because I can now run it in my 64 bit windows without having to use Oracle Virtual box just to run it in windows 32 bit and dos.
My Microsoft Surface Pro 7 can only run Windows 64 bit and not 32 bit. But with your programming skill guys, can you share how to run windows 32 bit in the Microsoft Surface notebooks?