As with many others, I got started playing with the 6502 after watching Ben Eater's series of videos. I quickly became frustrated with all of the wires and flakiness of a breadboard and decided to design a simple PCB to continue exploring the 6502. During research for my PCB design project, I quickly found my way to Mr. Wilson's excellent site and tried to follow many of his suggestions and guidelines. The result is what I call the u6502. My overall goal was to make something simple enough that I could understand it but capable enough to be a useful long-term learning platform. With that in mind, I started with Mr. Wilson's example schematic and added a second VIA and an ACIA along with some simple additional support circuitry.
My initial schematic revision: I used a 100mm^2 4-layer PCB design with a signal, ground, ground, signal stack up to keep production costs low.
PCB Front: PCB Back: The following image shows the rev0 PCB in place in my "development system". The Problem
My initial testing seems to show that the VIAs are working as expected and I am able to drive a common 16-character LCD with only minor issues. However, I have been completely unsuccessful in my attempts at interacting with the ACIA. I have not been able to get any serial data into or out of the RX/TX pins on the ACIA. I have tried the following troubleshooting steps:
- Validate CS logic with a logic analyzer. I think the chip is being correctly addressed, however, I only have a cheap 8-channel LA and am not 100% certain.
- Validate clock signals on PHI2 and XTAL1. Both the PHI2 clock and 1.8432MHz baud rate clock seem to be producing clean signals and are connected to the correct pins.
- Review assembly listing file and compare with known working examples.
Code: Select all
008092 1 .include "serial.s"
008092 2 ; ACIA Include File
008092 2
008092 2 ACIA_DATA = $4400
008092 2 ACIA_STATUS = $4401
008092 2 ACIA_CMD = $4402
008092 2 ACIA_CTRL = $4403
008092 2
008092 2 .segment "CODE"
008092 2
008092 2 init_acia:
008092 2 48 pha
008093 2 9C 01 44 stz ACIA_STATUS ; clear status register
008096 2 A9 1E lda #%00011110 ; 8-N-1, 9600 baud
008098 2 8D 03 44 sta ACIA_CTRL ; set control register
00809B 2 A9 0B lda #%00001011 ; No parity or rcv echo, RTS true, receive IRQ but no
00809D 2 8D 02 44 sta ACIA_CMD ; set command register
0080A0 2 68 pla
0080A1 2 60 rts
0080A2 2
0080A2 2 acia_send_char:
0080A2 2 48 pha
0080A3 2 8D 00 44 sta ACIA_DATA
0080A6 2 A9 FF lda #$FF
0080A8 2 @tx_delay:
0080A8 2 3A dec
0080A9 2 D0 FD bne @tx_delay
0080AB 2 68 pla
0080AC 2 60 rts