Reset

When the computer is switched on, it is important that the 6502 starts in a known state. The 6502 has a RESET pin (40). To reset the 6502, this pin needs to be driven low for a minimum of two clock cycles. The RESET pin should then be returned to +V. I will connect a switch between the RESET pin and ground and a pull-up resistor between the RESET pin and +5V. The RESET pin is active-low, so using a pull-up resistor will keep the RESET pin at +5V, until the switch is pressed and brings it low. With a 1MHz clock, two clock cycles is 2 millionths of a second, which will easily be met in this setup, as even the shortest press of the switch would result in many clock cycles passing!

I envisage that this solution for resetting the 6502 will be temporary because switch bounce could cause problems. Switch bounce is a problem caused by the contacts of switches making contact multiple times before settling down. To neutralise this problem I will need to add a switch debouncer.

When the 6502 is reset, there is a reset sequence that takes place, which is loaded from FFFC and FFFD. This reset sequence lasts for seven clock cycles and after this, the computer will be usable.

As more components are added to the computer, there will be other components that need to be reset into a known state when the computer is started. I will be able to reset these components by connecting them to this circuitry.


Summary

I have added reset circuitry that resets the 6502, ensuring that it starts in a stable and known state. As more components are added to the computer, there will be other components that need to be reset into a known state when the computer is started. I will be able to reset these components by connecting them to this circuitry. Figure 1 shows the circuit so far.

6502 reset circuit
Figure 1. Circuit so far