Making Punch Card Programming A Snap

About thirty years ago [H. P. Friedrichs] pulled off a hack that greatly improved the process of programming with punch cards. At the time, his school had just two IBM 029 keypunch machines. One of them is shown in the upper right and it uses a keyboard to choose which parts of each card should be punched out. This was time-consuming, and one misplaced keystroke could ruin the card that you were working on. Since you had to sit at the machine and type in your source code these machines were almost always in use.

But wait, the school acquired a dozen of the TRS-80 computers seen in the lower left. They were meant to be used when teaching BASIC, but [HPF] hatched a plan to put them to task for punch card generation. He built his own interface hardware that connected to the expansion port of the new hardware. Using his custom interface a student could create a virtual card deck that could be rearranged and revised to correct mistakes in the source code. The hardware then allows the virtual deck to be dumped in to the punching machine. This broke the bottleneck caused by students sitting at the punch card terminal.

We think that [HPF] sent in this project after seeing the antiquated hardware from that 1970’s calculator. These hacks of yore are a blast to revisit so don’t be afraid to tip us off if you know of a juicy one.

47 thoughts on “Making Punch Card Programming A Snap

  1. @jeicrash

    That’s because you’re here looking back.

    In 20 years you’ll be saying, “How did I miss the cutting edge of x when I was right in the middle of it?”

    Suggested values of x: any area of biotech; commercial space flight; cloud computing (the dream of abstracting away all hardware).

  2. Yes but biotech, space flight, cloud computing etc is not something the average dude can whip up in his spare time. For this you need to be employed by a massive corporation who is spending big money on research.

    Back in the 70’s, it was the average guy who was creating the cutting edge of technology.

  3. my first computer was TRS 80, but i didn’t have a tape recorder, so i had to keep it switched on all the time. i wrote a paint program(ascii art) and a word processor.
    when it got hot it would get ramdom flipped bits in memory and i’d have to rewrite the affected lines in the program. i kept it running for about a month before it finaly got an error i couldn’t recover from and its screen went matrix style ascii giberish.

  4. Back in 1980 I built a phone interface a relay and an old telephone through the casette port. I wrote a program in BASIC for my tricked out TRS-80 model 1 (16K RAM)that stored phone numbers and dialed them. There was also an option to repeatedly dial a single number at random intervals.

  5. @bob cloud computing was in then too, in fact in those days it was all dumb terminals connected to a ‘cloud’
    Cloud nonsense is ancient and a stupid thing for the general public.
    In fact I think the guys who came up with bringing back the concept will try to reintroduce punch card next, just as soon as they thought up a new catchy name for it, maybe ‘hole computing’ or something.

  6. @Whatnot What’s stupid about wanting to be able to access all of my information on any computer and not have to drag around a flash drive that can’t hold everything, or a portable hard drive?

  7. @jeicrash Ditto. The real problem in the old days was access. Unless you were an engineering student at a major university you didn’t get time on a machine. I didn’t get unfettered access to a machine until 79. HP front ended by dumb terminals and acoustical modems. Ahh.. The good old days. :)

  8. Back in that same time frame (late 70’s) we had a similar hack for punched cards used on an IBM 1800 at Scripps Oceanography. As much as I hated punched cards, I still have a box of them squirreled away somewhere.

  9. At some point one start to wonder, why not remove the punch card fully and just wire the trs-80 up to the punchcard inputs so that it appears to be a punchcard being read?

    And then i find myself reminded that this is why the virtual consoles of a linux box is called tty. Because back in the early days they used to be teletype devices wired in to act as consoles. And teletypes developed out of the telegraph system by converting typewriters into devices that could spit out reams of morse code on a paper tape that could be fed into a automated telegraph key.

    What is missing today is the ease of hackability, thanks to going from breadboards to microchips.

  10. @turn.self.off I think you might have had something there, but IIRC the cost of a TRS-80 floppy drive was probabaly about 10x higher than the punch machine would have been. Certainly, the cost of a 5.25 or 8 inch floppy disk would have been more than a stack of cards at that time.

  11. @turn.self.off As a way old-school guy relearning all this, it really isn’t that bad. I will say that electronics and programming now have quite a bit of overlap, but having experienced wire wrapping I must say you ‘kids’ have it easy. I had to walk 10 miles in the snow to get to my local Radio Shack, back when they had parts. :)

  12. I remember my older brother… Who was about 13 when I was six… in the 70’s. He “invented” the television remote control.

    It was full of working parts, wasn’t hand held, could be used from any room and save him from ever getting off the couch.

    Unfortunately the remote control was ME. “Hey, go change the channel…next…next..wait a min…next…next..hang on…wait…no, stay there…next…wait..ok!”

    :)

  13. “At some point one start to wonder, why not remove the punch card fully and just wire the trs-80 up to the punchcard inputs so that it appears to be a punchcard being read?”

    Georgia Tech, circa 1983 – The terminals were not TRS-80s but VT100 and other variations.

    My fellow freshmen were most confused when the system replied “INVALID CONTROL CARD”.. by 1984 the message was changed to “SYNTAX ERROR”

  14. I remember using a IBM 029 keypunch machine in college to run COBOL jobs. My favorite error message generated by the COBOL compiler running on a Honeywell machine was “Error – Correct and re-submit.” Getting that error was almost as bad as dropping your deck of cards on the floor and having to pick them up and put them back in the proper order.

  15. Not sure if it was before or after the system described here, but this technology was developed at and patented by Florida State University. Their product was called “key2disc” and run on CP/M machines. It was sold along with a HASP emulator. The duo replace both an 029 and a RJE station.

    You can see an advertisement in an early edition of InfoWorld by going to http://books.google.com/books?id=ADAEAAAAMBAJ&pg=PA27&dq=key2disc&hl=en&ei=fDwmTcTHG4Sq8AaIheStAQ&sa=X&oi=book_result&ct=result&resnum=1&ved=0CCEQ6AEwAA#v=onepage&q&f=false

  16. Boy does this bring back memories. Unfortunately, the site doesn’t mention Pete’s TRS-80 Interface rev 1 that used very tediously wound homemade matching transformers. There was some confusion as to the voltage level present on the bus and the smoke was let out of a number of them. The computer teacher had some issues letting him get near the interface port for a while. Great story!

    Been to your site many times but didn’t realize it was you.

    Dave Wilcox

  17. “At some point one start to wonder, why not remove the punch card fully and just wire the trs-80 up to the punchcard inputs so that it appears to be a punchcard being read?”

    Because if you read on, the computer itself is located somewhere else completely in town. In those days computers were rare, and very, very, expensive, and lots of technicians in white coats spent their days trying to maximise and optimise the time they spent processing stuff. Hence schools only got a machine or two to punch the cards. You’re thinking of the computer as a sort of photocopying shop where the teacher made just the one visit and hung around for a few minutes waiting for the printouts, when it was more like the dry-cleaners – “If Sir would care to return next Thursday …”

  18. yea Jim but its being sent over serial lines, something most home micro’s had or had access to even in the early days

    My counterargument is, think as punch cards as USB sticks, development is done offline with a personal computer not while there is a line to use either punchcard machines or video terminals

    you just dump your program in and your good to go, much faster for everyone (that had a home computer)

  19. Ahhh… I took my first programming course as what would now be called an AP High School student in ’72, across the street from my HS at RPI in Troy, NY.
    Those cards were the bane of my existence, never having taken a typing course…I was (incorrectly) sure I would never be a programmer.
    It’s been a wild 39-year techno-ride since then!

  20. I agree with jeicrash and smoker_dave. I just got done building a parallel port DAC for my old 486 laptop. I wish I grew up in a time when this was actually considered useful.

  21. Model ‘029 keypunch? Newbs! I learned on an 026, including the programming drum. We didn’t have a real computer, just an IBM 403 printer, which read cards and printed data from them by shuffling 132 metal bars up and down (each one had the whole character set on it), driving by a program on a plugboard (which only the Responsible Adult was aloud to touch) and a paper tape (which we could program our own settings for.) We also had a card sorter, a big thing that you’d feed 1000 or so cards into the hopper and 998-999 of them would get sorted into bins, with the other ones getting randomly shredded.
    In high school we had a tty33 connecting to a PDP-11 at the university, and in college I had to use punchcards again for a couple of years (with ‘029 keypunches.) The mainframes I used after college had batch environments that emulated punchcards with “decks” that you could edit on a CRT. By then I was doing most of my work on Unix, fortunately.

  22. @mike “What’s stupid about wanting to be able to access all of my information on any computer and not have to drag around a flash drive that can’t hold everything, or a portable hard drive?”
    How about losing control of all of your information?
    A flash drive in my pocket can’t be read by any jackass out in the “cloud” with “authorized” access or a new exploit.

  23. Punch cards are one part of old tech I sure don’t miss. I took fortran in the early 80’s and aside from the fact that one typo meant redoing the cards I HATED the 4 runs a day for testing your programs. For those who never experienced it imagine only being able to execute your programs at 8:00,12:00,4:00 and 7:00 runs. Makes for a slow debugging process. Not to mention the time I saw a guy in compiler construction class almost have a breakdown after dropping a 12″ x 16″ box full of his class project, scattering the cards over about 200 square feet of floor.

  24. @mike and his responders, ‘cloud storage’ isn’t the same as ‘cloud computing’ either I have to reminds you.
    And of course there is ample room on mobile devices now and you can set up a server on your homecomputer to access a central file storage.

    In reality the catch phrase “cloud computing” is pushed by software companies that look at it as a way to get more control over you while at the same time have you pay them for the privilege, and thus they hope to have a steady stream of income from those people.
    But so much can go wrong, and early versions of this in operation show so much WILL go wrong, and you are robbed of your control and half the time to your immediate decrement.
    And I’m not even getting into the current interest of governments in all your private stuff, and their happiness in making rules and laws allowing ‘authorities’ complete access to it, and pardoning those that work for the government and take illegal access to your private stuff.

    Anyway my original remark was about it not being ‘new’ at all, and I think we all know it isn’t a new invention, regardless if it’s now more feasible, which is true, it still isn’t new.

    Excuse the lengthy comment.

  25. Something I never understood about punch cards:

    I always heard the horror stories about dropping the box of cards with your program in it, and then having a suitable physical or psychological breakdown.

    Didn’t it occur to anyone to simply number the cards with a pencil?

  26. I’d have to say my favorite old time hack was done by the electronics teacher at my old high school. Back in the 80’s he was teaching his class and started getting fed up by getting interrupted by the “Damn intercom” as he put it. So he quickly took it off the wall drilled a hole in the bottom and installed a pot in it so he could “mute it”. Other teachers saw it and had him put them in their intercoms. Of course the administration had to be dicks and say “no no no no, put them back!”

  27. @ Brian

    Your Radio Shack had PARTS?

    Why, when I was a lad they didn’t even HAVE parts!
    They would just hit you with a stick until you had to walk back home through a snow squall with no shoes and no solder.

    Thems was they days, kiddies! HEE HEE

  28. Ahh…memories!

    It was about 1974, and UMass/Amherst had just received their new Cyber 74 from Control Data, and I signed up for the assembly language course. It was explained in the first class, that we would be punching card decks with our assignments and submitting them, then waiting for our jobs to be run and printed output to be returned to us. I did that exactly once.

    I had discovered remote job entry. By using a text file representing the card deck (one line = one card), typed in and edited from the Teletype I happened to have in my dorm room, I could completely bypass the punched card step. No more trudging down the hill from dorm to computer center in the snow, but more importantly, *vastly* improved turnaround times!

    Most of the 029 keypunches were IBM property back then, only leased to you. I suppose by 1980, they were cheap and plentiful on the surplus market. IBM would have taken a dim view of someone hooking up a TRS-80 to their keypunch!

  29. @dave: “Back in 1980 I built a phone interface a relay and an old telephone through the casette port. I wrote a program in BASIC for my tricked out TRS-80 model 1 (16K RAM)that stored phone numbers and dialed them. There was also an option to repeatedly dial a single number at random intervals. Posted at 10:51 am on Jan 6th, 2011 by dave”

    I saw the documentary they made of you doing this back in the 1980s. It was called “Wargames” and Matthew Broderick played you. :)

  30. @strider_mt2k You must be younger than I am, hitting with a stick wasn’t implemented until I was a college student. It was my yearly Christmas break job. :)

    @[C] Yes, it did. But numbering several hundred cards was insanely time consuming. What was more common was to stack the cards and run a marker down the splines at an angle. You could do a rough sort using the marks. Later someone invented a card sorter but these were a luxury.

    Useless trivia. A 3 min .mp3 file at 128k would require over 40k cards read at a rate of over 280 a second. The stack would be 5’9″ tall. See what we had to deal with! :)

  31. Only colleges could afford the big machines with the punch cards.

    In high school, we had the old yellow teletypes with the “cup” modems, where you dial a phone number and place the handset into the cups. But the programs were punched onto the yellow paper tapes. Not as fast as the punch cards though, but no worries about dropping the cards on the floor. The clear plastic “chads container” were a problem if someone dropped them and spilled the millions of punched dots onto the carpet.

    Those that remember connecting the old teletypes to a remote computer service can appreciate the fun we had making simple BASIC programs that generated punched words on those yellow paper tapes.

    I think those times from about 1970 to 1985 were the most fun when it comes to computers. And as others mentioned, Radio Shack was a real electronic store.

    Oh, the memories.

  32. [C] and Brian,

    Numbering the punchcards worked and so did the marker stripe–people did both, but the COBOL/Fortran teacher had us write a simple program and then add features to it for subsequent projects. Eventually you ran out of marker and pen colors from renumbering the deck week after week.

  33. I wonder if I could use a CraftRobo to make punchcards. ;o

    I love my CraftRobo. If I could somehow use it to make PCBs, it would be the perfect desktop tool… (As it is, I haven’t tried it, but I’ll bet it can contour-cut flex PCBs after they’ve been etched.)

Leave a Reply to DavidCancel reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.