Sunday, August 4, 2024

Changed my toolchain for the demo programs

CLUNKY TOOLCHAIN FELL DOWN DEALING WITH DMES ASSEMBLER COMMANDS

The assembler offers a command DMES which creates a string of characters in the encoding of the console printer/typewriter, 1132 or 1403 printer. This is a great convenience compared to laboriously looking up characters from tables and typing hex numbers into DC commands. 

              DMES    'R'RWELCOME TO THE 1130 FLOATING ' 

              DMES    CRAP GAME.'R'RFIRST ENTER A ' 

              DMES    FOUR DIGIT POSITIVE NUMBER.'E

The above statements allow for easily comprehensible construction and editing of strings to be printed. Control commands such as 'R (carrier return) can be requested clearly. Contrast that to the actual coding I would need for those statements without using the DMES:

                    WEL   DC      /8181

                          DC      /9034

                          DC      /5C1C

                          DC      /5070

                          DC      /3421

                          DC      /9C50

                          DC      /219C

                          DC      /2434

                          DC      /21FC

                          DC      /FCDC

                          DC      /C421

                          DC      /105C

                          DC      /503C

                          DC      /9C20

                          DC      /7414

                          DC      /211C

                          DC      /603C

                          DC      /5421

                          DC      /143C

                          DC      /7034

                          DC      /0081

                          DC      /8110

                          DC      /2060

                          DC      /989C

                          DC      /2134

                          DC      /749C

                          DC      /3460

                          DC      /213C

                          DC      /2110

                          DC      /50B0

                          DC      /6021

                          DC      /3020

                          DC      /1420

                          DC      /9C21

                          DC      /5450

                          DC      /9820

                          DC      /9C20

                          DC      /B434

                          DC      /2174

                          DC      /B070

                          DC      /1834

                          DC      /60FF

THE ASSEMBLER DOES NOT SHOW THE DATA VALUES GENERATED BY DMES

The output listing for the assembler does not show any data for the messages - only the address ranges consumed. This means that my prior toolchain which grabs the data values from the listing is incapable of benefiting from DMES. 

That coupled with prior issues with directives such as BSS were downsides that I had to carefully work around as I worked on demo programs. It was time to take a new approach.

NEW APPROACH - USE ASSEMBLER OUTPUT AND DUP DUMP TO PRINT

The assembler (and all the compilers) produce output in the working storage area of the disk, which is then input to store the programs on disk, combine them, or execute them. The Disk Utility Program (DUP) has a function to dump the contents of working storage to the printer (as well as to cards, paper tape or libraries on the disk). 

This is a printout, but it has a very specific format that is used by DUP and other system functions, which I can use to extract the contents to load into memory. I whipped up a python program to process those dump listings, which now addresses all those issues I faced in the past dealing with regular assembly listings. 

No comments:

Post a Comment