APLawrence.com -  Resources for Unix and Linux Systems, Bloggers and the self-employed

Old computers, old ads, old memories - and short programs

© August 2004 Tony Lawrence

Tue Aug 3 10:46:19 2004 Old computers, Referencing: https://oldcomputers.net/

Take a trip down memory lane. I liked the old ads particularly - I remember many of those.

I'm sure that the "new kids" can't imagine actually writing programs in 2K of memory or less - truth be told, even though I did it, I can't imagine it either.

Of course, we were big on assembly language - and even direct machine language in extreme circumstances. Doing things tight was important, so self modifying code was never out of the question at all. It may have been beyond difficult to understand, but by gum it fit!

The shortest useful program I ever wrote was for Tandy's Model II. I worked at a Tandy Computer Center (Chestnut Hill, MA), so there were several Model II's around the showroom. A Model 16 ran Xenix, but the II's ran TRSDOS.

TRSDOS was a bit short of "user friendly". For example, if you wanted to delete a bunch of .DAT files, you'd type "KILL */DAT". Because the designers of TRSDOS had low expectations for your intelligence, the KILL program would ask you to confirm every single deletion. There were other commands that were similarly annoying, and of course these machines, while speedy for their day, still took a bit of time to do things, especially if it involved disk I/O (the disks were 8 inch floppies, of course). So the natural behavior of most people who had typed such a command was to immediately follow it with a long series of quickly typed Y ENTER's or N ENTER's and then walk away. The command would read its responses from the filled up keyboard buffer. Automation, circa 1982.

But often the command would run out of questions before the keyboard would empty its buffer. The Y's or N's were then fed to TRSDOS itself, which would take great offense and respond with an "ERROR 31" (File not found) message. You'd see the screens filled with these things anywhere Model II's were unattended.

Well, I didn't like that message. It annoyed me, and I didn't think it was good for potential customers to see screens full of errors. Computers were scary enough to most people back then. Now, I could have written something that would feed answers to other programs, but that would have been complicated and no one would have used it. People were used to filling up that keyboard. So I wrote a little program. A very little program.

This was a Z80 processor, and with TRSDOS you could just put machine language bytes on disk and run 'em - no headers necessary, just like DOS .COM programs. The program I wrote was one byte - a hex C9, which is just a RETURN in Z80 language. I named it Y, and copied it to N. Now when the keyboard buffer asked TRSDOS to do "Y", it could. The program did nothing - just returned to TRSDOS, but no error messages were produced.

I later wrote a longer and more complicated version that flushed the keyboard buffer of all input before returning. That was sometimes useful for the case of fat fingered typists or little kids banging away on the keyboard. I've forgotten everything I ever knew about Z80 machine language and TRSDOS, but I do remember C9 - the shortest useful program I ever wrote.

Got something to add? Send me email.

(OLDER)    <- More Stuff -> (NEWER)    (NEWEST)   

Printer Friendly Version

-> Old computers, old ads, old memories - and shortprograms

Inexpensive and informative Apple related e-books:

Take Control of iCloud

Take control of Apple TV, Second Edition

Take Control of IOS 11

Take Control of the Mac Command Line with Terminal, Second Edition

Take Control of Preview

More Articles by © Tony Lawrence

The model II had a 68K MPU? I didn't know that. I thought it was Z-80 powered. Goes to show you learn something new every day.


---August 4, 2004

Ooops - I'm thinking Mod 16!

And C9 is Z80.

Article corrected :-)


Printer Friendly Version

Have you tried Searching this site?

This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more.

Contact us

Printer Friendly Version

May you live long enough to regret your opinions - (Tony Lawrence)

Linux posts

Troubleshooting posts

This post tagged:



Unix/Linux Consultants

Skills Tests

Unix/Linux Book Reviews

My Unix/Linux Troubleshooting Book

This site runs on Linode

SCO Unix Sales, Support, & Service

Phone:  707-SCO-UNIX (707-726-8649Toll Free: 833-SCO-UNIX (833-726-8649)