Last night I had some time to sit down and troubleshoot more efficiently. I made some progress, but not the best in the world.
Once chips were seated, I initially tried to get my LCD printing "Hello World". It worked first try! just kidding. No, it did not. The LCD powered up but didn't initialize, let alone write Hello World. Time to take a step back and see whats working and whats not.
First, I spent a lot of time making sure that each VIA out pin was properly connected to the expansion header, and that the expansion header was properly wired to each LCD pin. I had made a few mistakes manually wiring, and, rather tragically, a few of the header pins aren't providing a super stable power line. I looked more closely at my solder job, and I definitely rushed (or just didn't properly attach) the headers. I was using 1x40 female headers that I snapped, taped into place, and soldered on. The joints are a little weak and the headers are lifted off the board more than I want. BDD - this is what I meant by my IO Port having issues, not the chip but my poorly hacked together physical connector/port.
Despite this, I decided to keep debugging with my $20 sparkfun logic analyzer. I switched to a simple program that loads $#50 into the ORB of my VIA and then ror, store to ORB, loop ad naseum. I'm honestly not sure how best to use PulseView to do logic debugging. My guess is that I should use a 1Mhz sample rate (my clock rate) but I don't know if that's actually a valid idea. Once I added a few NOPS in the loop and the reset, I was able to start visibly seeing lines from the VIA go on and off. However, I would frequently lose one or more channels worth of information (they'd randomly pull high or low and stay there). When I have everything laid out perfectly flat, nothing underneath, no wires in weird bends, things pushed in very far, I mostly get clear lines, but still see some noise.
Now I know some of this is due to my cheap logic analyzer, messy desk, loose dupont connects, etc... But I honestly do believe a lot of this may be due to the rushed job I did soldering the board together. It was still 84degrees Farenheit indoors when I pulled out the soldering iron.
So, I could keep troubleshooting RevASer1... But today the Jameco box came-high quality sockets and fresh resistors and caps. real IDC connectors and 2x07 shrouded headers instead of cheap snapped off headers. Even a DC barrel jack that I can shove onto the footprint of my terminal block connector.
So my thinking for this long weekend is to construct a second of the RevA boards. That way, I'll have a better "known quantity" to work from. But here's the differences:
- Mise-en-place. After cleaning up my desk space, I want to build a workspace laid out specifically for the board construction. That means not balancing things on top of books. That means all the parts in a little kit box organized and laid out for the project.
- Reference materials. As BDD suggested (thank you!), I'd like to print out a schematic and board layout to have to reference while building. Important pins are highlighted. Chip names and component values are included. This will ensure I only have to socket each chip once! I already have the datasheets for the WDC chips printed out, put in full page plastic protectors, and bindered up. This makes it super easy to flip to a pin out or register layout and see whats needed. I will print and binder at least the pinout page for the rest of the components on the board. All this (including schematic, layout, BOM) can go in the final binder.
- Quality sockets, quality construction. I'm going to use the new good Jameco parts and take my time to carefully attach components. Not trying to solder any joints with the board vertical. Similarly, take my time while socketing chips.
- Physically I'm using male shrouded headers instead of female headers for the IO Ports. And a DC Barrel jack for power instead of terminal blocks.
And, looking to RevB design, which I'd like to draw up next week...
- As mentioned earlier, decoupling caps and power traces in general need some love
- Lots of board footprint only changes, for cap sizes, headers, and more
- Silkscreen around the IO Ports (including standardizing on IO(X)P(Y) where X is the VIA's number (1 or 2) and Y is the port on the VIA (A or B). Will also switch to clockwise pinout instead of odd-even. Also silkscreen needs to label +5 and GND on all the ports
- mounting holes drilled in the four corners, for standoffs at the very least.
- Add LED indicators for Power, SYNC, and RESETB. (consider test points as well)
- Maybe add a UART, maybe not yet I'm leaning toward an SPI UART driven by a VIA, but I _am_ interested in learning the 6551 programming model.
I do have a question about decoupling caps. I see you mentioned not all MLCC are made the same. I've been buying ceramic disc caps (0.1uF) from Jameco for about $.15c per. The MLCC you linked from Mouser is about 45c per. I found ceramic disc caps on Mouser, but they were well over a dollar, sometimes $4. They had much higher voltage ratings. Am I missing an obvious listing for something in the sub-20c range thats a good enough 0.1uF cap? Otherwise I'll just keep snapping up the Jameco part that I already know well.
I've been thinking a lot about the goals of my board. As someone else mentioned, I'm working backward. From Elements of Computing Systems to Rodnay Zaks. I don't feel compelled to keep my board "period accurate" but I also appreciate the creativity that can emerge from constraints. That's why I'm still considering learning how to use the 6551 even if it's just going to talk to a pi pico that does the rest of what I want. Well, OTOH I just got some of Geoff's VT100 terminal kits mailed from Tindie, so maybe I should go full on RS232.
In any case, here's my list of priorities/next steps
- Construct RevAB2 with my notes above and more attention to detail. Hopefully get it doing something obvious on the logic analyzer so we can move forward to LEDs and then an LCD.
- Design RevB (to use a very similar BOM).