Monday, August 3

Hacking the Digital and Social System

When you live in a totalitarian, controlled and “happy” society, and you want to be a hacker, you have to hack the social system first. Being just an engineer doesn’t cut it, you have to be a hypocrite, dissident and a smuggler at the same time. That’s the motto of my personal story, which starts in Yugoslavia, and ends in Serbia. No, I didn’t move, I’m still in Belgrade, only the political borders have changed.

Half a century ago, when I was in elementary school, I discovered the magical world of HAM radio. I became a member of two amateur radio clubs, passed all exams and got my licence and callsign, which was YU1OPC. I was delighted, but after five years, the party was over. What happened? Well, one day the police paid a visit to all registered owners of CB Band equipment and simply took that equipment away. No one knows why they did it, but it was probably off the books, as we never got any written confirmation, and no one ever saw their equipment again.

I wondered why they didn’t take our HAM Radio units as well, which were as legal as any CB unit. I guess they didn’t know how to use it… for their own personal needs. Nothing will disuade me from calling it uniformed robbery.

Actually, I was not too sad about it. I lost only a Japanese 5W CB transceiver, but I was not interested in HAM radio anymore. Since the first commercial HAM radio equipment appeared on the market, the profile of users has changed dramatically – instead of people who could build HAM units with their own hands, now you had people who had enough money to buy them. Maybe I was overreacting, maybe there were still a lot of enthusiasts, but the magic of my own enthusiasm was destroyed and I moved to digital technology. I didn’t know that in just about two decades, the same thing would happen again with computers.

The “Pen and Paper” Development System

The migration from electronic tubes to transistors was fascinating. Such a small tube, with a cold cathode and a low anode voltage, so cheap and simple to use! I bought my first germanium transistors from my pocket money, and built… guess what? The flip-flop! I thought I invented it. How could I have known that it had already been invented fifty years ago?

Just a few years after Intel’s 4004, I was head over heels in love with microprocessors. I had ordered two Z80s from the USA, but soon discovered that one of them was inoperative – I most likely burned it somehow without realizing it. Still, I had the second one, so I could start building my first microprocessor project. What should I use it for?

life_frontIt was an easy question. I was fascinated with Conway’s Game Of Life, and all the walls in my room were covered by papers with hand drawn cell groups, in hundreds of generations. There were two consequences of my wall art: the fact that my parents and half of my friends thought that I had gone crazy, and my first project – Game Of Life, with a 16×16 LED matrix. The LEDs were so expensive back then that I finalized the firmware with less than half of them, and filled the matrix gradually in the coming months.

I didn’t have a computer, so I assembled the firmware manually, by pen and paper, and then entered the code in my programmer, byte by byte, using rotary switches. However, the debugging process was relatively fast, as I had two 2708 EPROMs – in fact, I had four to start with, but burned (literally) two of them trying to debug my DIY EPROM programmer. So while one of them was in the UV eraser (built from an old sun-tanning lamp), I could debug the code and program another one.

However weird it may seem to assemble the code manually, I didn’t know there might be another way to do it. And when you don’t have a better idea, there is no reason to be unsatisfied with the current one. So, I went on and finished my Game Of Life. Unfortunately, I don’t have it any more, but I replicated it a few years later and it still runs in my workshop after almost 40 years – even the EPROM still keeps its content. Maybe I should describe it at the Hackaday.io projects page, as one of the old MPU DIY projects that still work?

No Computers, Please

The personal computers of that time were pretty expensive, but it was not the main problem. If you lived in Yugoslavia, you simply couldn’t buy them. It was not specifically forbidden, but you couldn’t import anything worth above 50 Deutschmarks. So I asked a friend of mine from the US to split my freshly ordered TRS-80 model 1 into two units and send them to me in separate packages, as inconspicuously as possible. Having to cut the ribbon cable that went between two PCBs (there was no connector) was frustrating but, after some hesitation, he grabbed a pair of scissors and went for it. A good while later, I received them tax-free, labeled as “technical junk”, then “repaired” it. My own computer revolution had started.

The basic model had 4KB of dynamic RAM, so when I saw the commercials for the 16KB expansion kit, I wondered who would ever need more than 4KB! Ironically, I soon found myself using not 16, but 48KB, arranged in three piggyback layers. The main PCB got numerous hardware upgrades: Shift hold, 2×clock, single step mode, speaker, and an additional EPROM with my own disassembler and editor/assembler.

Step by step, microcomputers were spreading everywhere, but the government still did not recognize the potential of the new technology. We asked for a new legal treatment of computers, but nothing had changed for an entire decade. Our main argument was that we need the technically skilled people and young software experts, and one politician gave us the famous, widely known answer: “I’ve heard that Americans will create self-programming computers, so we shall need no programmers.”

There was no other way but to continue smuggling, bribing and hiding the equipment deep under the laundry in a suitcase.

Computer Animation from 1979

While I was a student at the Faculty of Dramatic Arts in late 1970s, I was enchanted by computer animation. I acted as quite a rookie in here, since I had to start from scratch. I simply had never even seen the equipment that was used for it. First I built the graphical interface, which contained 90 static RAMs 2114 (4×1Kbit), one Z80A and a lot of glue logic. The resolution was 400×300, with a 3-bit monochromatic pixel. I borrowed a 16 mm Bolex camera which could operate in a frame-by-frame mode, and built a solenoid trigger with corresponding computer interface. I also wrote the animation software in BASIC, which could draw geometric shapes in a wireframe mode. Everything was defined in 3D, including the camera, which could move, pan and zoom. All of that, including the amber monitor, was enclosed in a large wooden box, which looked a lot like a coffin, but it did the job of protecting the system from ambient light, and my ears from the noisy solenoids. The animation software was executed on my DIY TRS-80 clone with the 6MHz Z80B microprocessor, so one frame took a mere 10 minutes of rendering time, which translated to 24 hours for an average shot.

I had shown the result to my professor [Marko Babac], who was delighted. He asked me if it would ever be possible to animate human figures, but I said, with a lot of authority and self-confidence: “No way”! He suggested to me that I prepare a short TV broadcast with a few animated examples. I was up for it, but I couldn’t find anyone who was interested in my technological wonder. The only topic being covered by the media at the time was President Tito’s illness.

After 36 years, there are only two short shots left. I never managed to find someone who could digitize them, so I used a flat-bed scanner and improvized backlight to digitize this one.

Galaksija: DIY Microcomputer from 1983

It was not possible to buy a microcomputer legally and nobody was trying to produce it in Yugoslavia – similar problems were faced in all Eastern Bloc countries. Everything pointed to us being stuck in the Stone Age on the matter. We had no computer magazines or other way to educate people about technology, so the media coverage was limited to “a strange contraption called an electronic brain, which can even play chess”.

Regarding microcomputer projects of that time, the most expensive part was the video interface. I knew that the ZX81 and ZX Spectrum had ULA (uncommitted logic array) chips which generated video signals aided by software, but I couldn’t even dream of having that. So I had to hack the microprocessor to make the video controller unit as simple as possible, with the existing TTL chips.

The Z80 microprocessor has one transparent counter, called the R register, which is used for dynamic memory refreshing. It is simply incremented and output to the Address bus after every instruction execution. It could be used to generate the fastest portion of the video signal, and the slower portion of video hardware could be simply replaced by software. So I needed just one shift register driven by a pixel clock and the charracter generator, and I saved on the video address counters, selectors, tri-state buffers and blanking logic. That was a concept worth trying.

Just a few days later it worked perfectly, and I started building the operating system. Memory chips were expensive, so I decided to use only 4KB (expandable to 8K) of ROM, and 3×2K of static RAM. I stole the arithmetic routines from TRS-80 Level I Basic, and started creating my own line editor and a BASIC interpreter.

The resulting price/performance ratio was so good that I decided to publish it as a DIY project in a magazine. As the first issue of the first Yugoslav computer magazine was just about to get published, I met the author [Dejan Ristanovic], and made an agreement with him to let me write the DIY manual. [Jova Regasek], the editor of the issue, insisted that the microcomputer name be “Galaksija” (Galaxy). In August 1983, Galaksija was presented to the readers.

galaxy_sch galaksija_1

The magazine was named “Računari u vašoj kući” (Computers in Your Home), and the release was scheduled for the very end of December 1983. So I had five months to finalize the firmware, sometimes with Dejan’s help with the general concept. It’s amazing how much you can pack into 4 KB of EPROM space as long as you do your best to optimize the code! One of many ideas I’ve described in my project page is how to use more than 100% of program memory.

A few days before the deadline, I was at the editorial, talking to Jova and Dejan. Jova asked the intriguing question: How many readers will build the microcomputer? I said “maybe 50″, Dejan said “I think that there will be at least 200″, and Jova said “Dont be silly, there will be more than 500″. We laughed at him, as it seemed too much. But we’ve had more than 8000 letters from people who built it. The computer revolution had started in my country.

In the same year, my friend [Zoran Modli], a famous radio host, started broadcasting programs for all current microcomputers in his weekly show on the FM radio, and even on TV! There were no floppy nor hard disks at that time, so the only magnetic media were compact cassettes. Data coding was performed in audio range, which made it convenient for broadcasting. So we had the wireless network (or at least its predecessor) in 1983!

You might think only the pirated video games were broadcast, but actually the vast majority were original programs written by enthusiasts. Zoran even created a digital magazine, which was broadcast in digital form.

In the next few years, there was approximately one new microcomputer in Yugoslavia every year. Most of them were in limited production, and they were predominantly Apple II clones with Microsoft Basic.

War and No Peace

Starting in 1991, Yugoslavia was disintegrated in the bloody war. When I saw the military Jeep under my window, I knew that I had no choice but to take my toothbrush, razor, walkman and some garments and let those guys take me to the quarters outside of town. Tomorrow morning, my officer asked me about my current job. When I said that I deal with computers, he sent me to the headquarters, to check out an old Apple II: “It’s inoperative for more than a year, nobody could get it back to life”. I offered to try to fix it back at my workshop, and thus was given a ride back by the same Jeep.

Home again! It took me a few minutes to see that the only problem was in the video monitor. I disassembled it, replaced a burned diode, and everything worked fine. The next day the officer gave me back my ID and sent me home, saying the words which I remember to this day: “Take care of yourself, I need you alive. Who knows when this peace of shit might get broken again”.

Feeling like I woke up after deep sleeping, I joined several anti-war and anti-Milosevic campaigns, writing articles against terror.

In 1995, after a few tragic events in my family, I was left alone with my two-year-old son, no money, and three days during which we had to leave our flat. Then I did a very stupid thing: I threw away almost all of my projects, including the documentation and five prototypes of the Galaksija microcomputer.

Hope and Punishment

probe2Living during war time was very stressful, so I sunk deep into my work to pull myself together. In 1998, I built a small hand-held instrument with a single-chip MCU design. Using a PIC16F84, it was a logic probe, single channel logic analyzer, 50 MHz frequency counter, RS 232 analyzer and a battery charging manager – all that in only 1K of code. I sent mail to Microchip and offered it as an Application Note. The answer was very encouraging: “We are very impressed with the level of integration that you have achieved with the PIC16F84…”. First they asked for one, then for three more samples, so that they can use them as a demonstration tool during their conferences.

They promised me not only to publish the Application Note, but also exposure in US and European magazines, together with an official consultant status. Asked about the compensation, I refused money and said I’d rather have their in-circuit emulator.

I prepared an article and soon the project appeared on Microchip’s site as AN689. At last, there was a hope that finally I shall rise, after all the pitfalls and disappointments. But only a few weeks later, I received the following message from Microchip:

“Evidently, the United States has some type of a trade embargo against Yugoslavia…” and so on. They were apologetic but were still certain that some kind of an arrangement could be made…

No magazine articles, no consultant status, no in-circuit emulator. Even the Application Note was removed from the site.

I was thinking that my luck couldn’t be any worse than this, but only a few months later Serbia was attacked by NATO and intensively bombed for 78 days. Without a single day off, 24 hours a day, we were listening to the war sirens, supersonic blasts, guided missiles and frequent detonations over the city.

Technology and the Legacy of Five Decades

In 2006, after several mails, I have finally received my In-Circuit Debuggers from Microchip and the Application Note was put back in place. I strongly believe they did everything they could, so I can’t really blame them. I stilll like the PIC platform and I’ve never stopped using it for my medium-scale projects.

mDSC_0758For a long time, I was listening to “experts” telling me my Galaksija computer is X times slower than the modern PC and Y times slower than their smartphone. Lately though, it seems like we entered a sort of a renaissance of technological culture. People grow nostalgic and more appreciative of older stuff. Now there are numerous retro computer emulators for PC, including a Galaxy emulator, and also the single chip FPGA replica named μGalaksija, created bu [Dušan Grujić].

I was honored by the Muzej Nauke i Tehnike (Museum of Science and Technology) in Belgrade, when I was asked to donate a sample of the Galaksija computer. How can I donate it, if I don’t have it? Fortunately, I found one forgotten prototype in my cellar, cleaned it and now it is a part of the museum exhibition.

The last decade of the 20th century was a disaster for my country, but the worst damage was done to the people’s minds. Corruption spread, social values suffered the most. Not unlike in the Middle Ages, various clairvoyants, prophets, quacks and pseudoscientists flooded the media, and there was not a single voice from the side of reason.

So I thought I could try to hack the system again. I wrote and published two books and a lot of newspaper articles and light fiction, promoting a skeptical view on the paranormal phenomena. And it worked, at least partly. I was invited to many TV shows, and a certain number of intellectuals started to raise their voices against the modern superstition. Some deceivers and quacks were even jailed, I like to think, at least partly as a result of my efforts.

Unfortunately, the ’90s crisis left us with some serious consequences. A lot of young scientists and experts, which were the better part of the generation, left the country. One prominent politician said that there’s no harm done, as during the period we also received an equal number of refugees. Numerically speaking, we are the same.

Here is how I see the consequences of that brain drain. In 1960, Yugoslavia was one of six countries which had its own computer, CER-10. It was created by our engineers at the Mihailo Pupin Institute, which is just a few hundred meters from my home. Guess what those “scientists” are producing today? Magnetic slippers! Well, you may have pseudoscience in your media, but we’ve gone a step further – we have the pseudoscience in our science!

Still, one gets used to everything. At this point I would be surprised if things turned out any better. As for myself, all I need are four walls and peace, so I can do my work and create. I don’t need a lot of money, that’s why my projects are open. I never counted them, but I guess that I have between 50 and 100 open projects published in computer magazines.

Last year I met [Mitch Altman], who is known not only for TV-B-Gone, but also for teaching introductory electronics workshops around the world. When we were talking about the creative work in general, I told him my problem is that I fall in love with each of my projects, and he laughed and said “What a nice problem to have”! He was right, it’s the best possible problem, and that’s why my projects are open – when you’re in love, then you want to tell it to the whole world and to show the object of your love to everybody. Maybe you won’t get rich that way, but you will surely spend the life worth living.

[Illustration by Bob Zivkovic]


​​Voja_AntonicVoja Antonic works as a freelance microcontroller engineer in Belgrade. His first microprocessor projects, based on Z80, date back to 1977, just a few years after the appearance of the first Intel’s 4004. He assembled the firmware manually, by pen and paper. In 1983, he published his original DIY microcomputer project called Galaksija, which was built by around 8000 enthusiasts in the former Yugoslavia. To date he has published more than 50 projects, mostly based on microcontrollers, and released all of them in the public domain.


Filed under: computer hacks, Featured

No comments:

Post a Comment