The ANALOG Card File

16K Disk
by David Plotkin


As I was doing my income taxes this year, I found that I needed a tool to organize and catalog the veritable mountain of receipts. This little utility was just what the doctor ordered. It allows you to type just about anything you want on the screen, save the screen to disk, edit it in the future and print it out for posterity.

The first thing you are presented with is the general menu screen, offering various options: 1. getting a disk directory and purging files from the disk; 2. starting with a new screen; or 3. Editing an old screen. Also on this screen are some brief instructions.

If you choose a new screen, you'll need to specify the filename to store the screen under, then you are presented with a blank lined screen, similar to a 5" x 7" index card. On the first line is the title; this doesn't get printed out when you dump the screen to the printer. Be careful not to scroll the screen, or some of your information will move up into the title area, with some pretty strange-looking results. If you do inadvertently have this problem, you can just RESET and RUN the program again. If you choose to edit an old screen, you'll need to give the filename of the screen, which will then be presented for editing. Press SELECT to print the screen, START to save the screen to disk, and OPTION to start over without saving the screen. The major sections of the program are as follows:

Lines 0-20
Set up, initialize and modify the display list.
Lines 25-60
Draw the menu screen with instructions and get the users choice.
Lines 100-120
The New Screen routine.
Lines 130-160
Read the keyboard directly from the memory location 764. Also check for pressing of the console buttons (START, SELECT, and OPTION).
Lines 700-720
Delete a file.
Line 800
Get the name of the file to edit, then go get it.
Lines 900-960
The disk directory.
Lines 1000-1030
Write a screen to disk. The write is done using the fast IOCB routines, which are set up in Lines 1020 and 1030, then called in Line 2030 by the USR call.
Lines 2000-2030
Read a screen from disk. This routine also uses the high speed IOCB call.
Lines 3000-3010
Print out the screen. Each character in a line is PEEKed from the screen. The memory address of the beginning of each line is looked up in the array LINE; this is much faster than calculating the address each time. Before the character PEEKed from the screen can be printed, however, it must be translated from Internal Code to ATASCII, which is what the printer understands. The variable IC is a value of Internal Code. HOLD$ is an array of ATASCII codes in Internal Code order, so looking up HOLD$(IC+l) returns the ATASCII code HOLD$(IC+1). It's pretty fast, too.
Lines 3100-3150
This section of code fills the array HOLD$ with ATASCII codes in Internal Code order, for use in the printer dump routine.
Lines 3200-3260
Set up the Player/Missile graphics. What Player/Missile graphics? What do you think those nice, thin lines are? They are single-line resolution Player/Missiles, in triple width, butted edge-to-edge to fill the screen. By proper positioning, there is no overlap between the lines and the letters.

I have found this program to be quite useful for keeping records, since I can set up full screens of data in any format I want.

BASIC Listing

CARDFILE.LST is available in ATASCII format.

This BASIC listing uses an image to display special characters

Checksum Data
0 DATA 854,987,465,241,702,995,615,302
,260,3,508,874,214,229,790,8039
25 DATA 436,318,575,582,603,712,728,68
3,526,15,389,7,607,425,558,7164
140 DATA 958,403,693,738,713,830,564,5
48,14,330,266,420,338,467,628,7910
930 DATA 769,786,6,849,540,748,337,789
,57,990,268,331,426,725,214,7835
2999 DATA 21,853,992,562,105,145,168,1
28,319,151,136,16,481,609,426,5112
3250 DATA 978,265,761,24,16,603,741,61
3,46,4047

Previous | Contents | Next

Original text copyright 1984 by ANALOG Computing. Reprinted with permission by the Digital ANALOG Archive.