Sunday, 5 March 2023

6502 : BEN2 : A new start

Avid readers of this blog will notice that there have been no updates on my 6502 journey since October/November last year.  In November I decided that my latest 6502 board, which I called DON, was not fit for purpose and was not likely to improve.  My other two boards, BEN and JON, are also unreliable so the best way forward seems to be new hardware in the form of a fourth board.

Objective

BEN was the original Ben Eater design on breadboard.  I/O was provided using a VIA chip and buttons / LCD character display.  JON and DON used an ACIA chip for serial I/O which provides a much superior interface.

I decided the new board should be based on BEN and will be called BEN2.  In Ben's 6502 videos he covers adding the 1MHz clock chip (part 9) and I need to gain confidence in the circuit running at full-speed.  Additionally there is more I can learn from Ben's videos and by looking at projects by other Ben acolytes.  To do this I need a board which is similar to the original so that I can try out more ideas.

The downside of basing BEN2 on BEN, which I need to accept, is that I wont have a serial interface.  I can either build a new board later with an ACIA, or perhaps create a daughter board for BEN2.

Design

ROM programming

The circuit diagram for BEN2 is based on BEN.  One enhancement I must incorporate is the improved capability to program ROM.  My programming is not good so it is vital I have an easy way to modify programs so that I can build them up incrementally or include debugging checks.   This will be achieved in two ways.  Firstly I will use a ZIF holder for the ROM so it can be changed easily.  Secondly I will modify Ben's circuit so that I can program the ROM in situ using the Arduino Mega.

Stripboard

I need to build the circuit on stripboard as breadboard circuits are unreliable and I am not good enough with the tools to design a PCB which can be fabricated.  Many of the frustrating errors I have encountered were due to loose wiring.  Even worse, I always suspect loose wires and need to check them when something is not working properly.  The stripboard design for DON was unsatisfactory as it used two interconnected stripboards, which introduced errors.  I will use a 48x30 stripboard which is very well suited to IC components and will allow me to place the main ICs on a single board.

Headers

All ICs will be in holders and have an adjacent row of header pins.  This allows a lot of hardware debugging to be carried out.  Signals on individual pins can be measured, an Arduino can be connected to control the chip or an alternative chip / circuit amendment can be tested externally.

The Arduino MEGA testing interface is particularly important.  All RAM pins will be interfaced to the Mega using dupont wires together with a few extras.  The MEGA GPIO will be configured so that we can use block connectors both at the board and the MEGA ends.  This will make it easier to attach / detach the MEGA for different purposes.  

Headers on the 6502 chip will allow our solution to be extended to a second board, if desirable.

Offboard

There is limited space on the board.  I/O components, LEDs, character LCD will be offboard, controlled by the VIA chip.  Also the clock, which may be a 555, an Arduino or 1 MHZ chip will be off board.  As mentioned earlier, if an ACIA or other functional chip is added it will also be off board.

Basic chip holder placement is shown below, from left to right the chips are ROM (ZIF holder), RAM and NAND on the upper row, 6502 and VIA on lower row.



Schematic


Note 1 : An extra pull-up resistor and a pull-down resistor are added to the ROM so that it can be put into write mode and programmed.
Note 2 : Components to the right of the blue line are offboard.

Layout



MEGA Connections


Note: MEGA is connected to RAM header pins; a couple of extra pins are provided for required ROM signals and one for the most significant address bit.





No comments:

Post a Comment