
I’ve built my first computer with soldering all the parts and then started debugging it with oscilloscope to see signals from chips and analyse them to find the problem. And in doing so I have quickly realised that I am missing something. This something was ‘How chips actually work’. Turned out it was called Digital electronics so I’ve decided to learn this on the way.
My treasure and source of inspiration at school time was this book: Digital Electronics by Roger Tokheim. I was dragging it to school and back every day just like people cary notebooks these days. This was my bible back then. Boys in the school made fun of me for this. The book was amazing and I think it still is.
I remember it all as very exciting time.
Now FPGA seems like a nice opportunity to revisit all of this after many years of programming and developing a new point of view about many paradigms.
May be you can direct me and others like me toward a good community and tips for shortening a learning curve. Possibly many things I am familiar with already and yet with FPGA I didn’t find a good/easy way to start so far. Perhaps you can advice something about ‘how’ and ‘were’ to begin.
When I am trying to recall my childhood the memory of ‘dreaming about writing my own program in assemly’ is more vivid then actually writing it. You see it took some time and a few preparation steps:
1. Preparing computer:
1.1 Discovering the opportunity: Turns out it can be soldered by myself which makes it cheap enough and thus actually even possible.
1.2 Convincing parents that even though I had no interest in electronics before it’s a good idea to build something called “computer”. Never mind what it is, it only needs a few chips and some other electronic components. I’ve seen one. It can work!
1.3 Hunting all components for weeks. Not an easy task where I have been back then.
1.4 Soldering all components to the board. Learning soldering on-the-go. I had zero interest in electronics before my friend had shown me a computer. It was the first time in my life I took soldering iron in my hands. Noticing expression of shock on faces of my parents I was calming down them with phrases like: How hard it should be? What could possibly go wrong? Right? :)
1.5 Discovering that computer would not work after soldering. It needs something called Power Supply and they don’t sell it. So the only way is to build one.
1.5.1 Hunting for components again. Power supply had to be build with short-circuit protection because burning computer would mean no second chance.
1.5.2 Building special power supply with basic components transistors, resistors, condensers, diods etc.
1.5.3 Learning some basic things about electronics and how power supplies function. Finding problems. Fixing them and making it work properly.
1.6 Discovering there is no way to buy a keyboard and recalling :) that computer actually needs Input device.
1.6.1 Hunting for old calculators.
1.6.2 Disassembling few calculators to extract buttons
1.6.3 Making keyboard with extracted buttons.
1.7 Turning On the computer. Discovering it’s not working and needs debugging.
1.8 Learning Digital electronics for some time from the book “Digital Electronics” by Tokhaim. Discovering that local schematics are not the same as in the foreign book. Oops! :) Tracing all kind of problems. Fixing them one by one and arriving to the stage where something should be shown on the screen.
1.9 Discovering that home TV doesn’t have ‘video in’.
1.9.1 Disassemble TV partially, study schematics and how TV works.
1.9.2 Make add-on with ’Video-In’ to make TV function as a Monitor.
1.10 Turn On the computer and Debug it with visual feedback. Much better! :)
1.11 Debugging computer with oscilloscope and learning how it should work on the go.
1.12 Celebrate first successfull start and making sure that everything works as it should.
2. Running Computer with visual feedback(monitor) and input device (keyboard) while everything is working properly :) Much better :)3. Discovering how to run own programs. BIOS had no documentation. With ‘try and error’ discover how to put codes into the memory and what command will actually execute them. Then locate where the video memory starts. To at least see something! Calling builtin BIOS functions was not an option.
4. Learning codes of CPU from the table by ‘try and error’ . Table had only mnemonics without any detailed descriptions. So you basically just guess the meaning. Sometimes you guess wrong. For example HLT will not stop the program properly :) Meaning you write program again :)
And then finally , after those preparation steps I wrote my first assembly program. I believe it was some 8 dots moving horizontally.
So I had a lot of time for that “dreaming about my first program” … :)
It was Sunday, and it worked. Small white line sliding in the center of the screen. Lovely. What you wouldn’t do for that!? :)
It's really important to have a specific goal in mind regardless of whether you prefer to learn how to solve it with structured or unstructured materials, and to have an initial idea of what level of detail you want to go in order to accomplish the goal. The lower level you want to learn the less up-to-date your resources have to be, our understanding of electricity hasn't fundamentally changed since Maxwell's equations. :) Something like "I want to turn on a smart light of this type when there is motion in this area, and turn it off after 5 minutes" is a nice goal. And you can accomplish it at many different levels of hackery, and learn very deeply if you want about each component of your solution (for instance there's the entire field of RF if you want to know how the antenna works).