Building Ben Eater's 8-bit CPU Clock (part 1)
Okay so, I know I said I'd cover continuous integration in Azure this week, but I've been putting off this 8-bit CPU project for too long, and today is the day. If you don't know, Ben Eater runs a fantastic YouTube channel on digital electronics.
For me, spending most of my career doing high-level software engineering, this channel served as both an excellent intro into digital electronics, but also to demystify the topic entirely.
Getting Started
Now, you don't need to actually buy the kit from Ben, you can see the parts list that he has kindly included for you. I'm not that ambitious, I'd rather save the time and effort and just get the kit. But if you're short on cash, you can pick up these parts on the cheap.
Tools
You'll also want an oscilloscope. You can spend lots of money on really fancy oscilloscopes, but I'd recommend just picking up this one off Amazon:
https://www.amazon.ca/Digital-Oscilloscope-Handheld-Pocket-Sized/dp/B08VWD9J1W/ref=sr_1_41?dchild=1&keywords=oscilloscope&qid=1623624075&sr=8-41
Now, I'm admittedly no expert on oscilloscopes, but this one lets me freeze and zoom in on the waveform, and for the price, gets the job done.
So Now You Own a CPU Kit
Next you'll want to connect the power supply with the power plug adapter included in the kit. Don't plug it in yet, we're going to cut a length of red and black wire, and screw it in, so we can power our circuit.
Am I an Electrical Engineer Yet?
So Ben will do a way way better job than I ever could explaining how this circuit is supposed to work, but what I'd like to do is point out any head scratching moments, such that you might save a bit of time.
If, like me, you're trying to follow Ben along in his video, you'll notice at one point he has a 100k Ohm resistor going into pin 7 on your 555 chip. Mystified, I didn't actually have a 100k Ohm resistor in the clock kit. So, the trick is to watch your video through to the end; Ben installs a 1 M-Ohm variable resistor, which is what you'll need to do to get up and running.
The resistors are direction agnostic, so you don't need to worry about installing them backwards, but the capacitors in the kit are slightly different than what you see in the video. Make sure your capacitor is installed in the right direction. On some, the stripe is marking a positive end, on others, the stripe is marking the ground. A little googling will get you a bunch of picture examples which should clear things up. In my case, the stripe was marking the ground side with a bunch of 0's on the stripe.
Finally, keep in mind your components can be defective too. I had a bad LED, which led to much head-scratching until I finally tried a different LED. (Okay I might have cooked the LED by accident, but I'm not sure; there have been worse casualties in my time with hardware).
Let There Be [a] Light
As you can see I wound up with a nice little square wave on my oscilloscope, and a flashing LED light for each cycle. I've still got a long way to go in the world of digital circuits, but I have a great grasp on what's going on thanks to Ben and his fantastic educational content.
I'll do some additional posts as I work through the rest of this clock module, and the rest of the CPU project. I'm definitely looking forward to getting it up and running.
Comments
Post a Comment