Fun with reset signals
Posted: Sun Sep 30, 2012 10:35 pm
Trying to diagnose a startup issue on the Genesis, so I figured I'd document what the reset signals do. There are a lot of them:
Reset signals
WRES - Active high reset signal, pressing the RESET switch shorts it to +5V. Normally held low with a pull-down resistor. No debouncing.
VRES# - To 68000 and cartridge connector, generated by 315-5364. Asserted for 128 VCLKs (Thanks Eke!) which is approx. 130ns/cycle x 128 cycles = 16.7ms. Triggered by the rising edge of either SRES (power-up reset) or WRES (reset button) being asserted.
MRES# - Directly from the RC reset circuit (R=47K, C=10uF), goes to cartridge connector.
SRES# - Output of a LM358 that compares the output of the charging capacitor on MRES# to Vref (measured at 2.0V) from the CXA1145 Vref pin. The output is 0V when MRES#<Vref and 5V when MRES#>= Vref.
FRES - Active high reset signal. The falling edge is synchronous with SRES#. Goes to the expansion connector.
Reset button
When the reset button is pressed, VRES# is pulsed low starting a variable amount of time from the rising edge of WRES. Minimum is 2.1ms. The VRES# low pulse is always 128 VCLKs (16.7us). This means that jamming on the reset button will not send malformed reset pulses to the 68000.
Power up
When power is applied, MRES# rising edge to SRES# rising edge is about 166ms. VRES# rising edge is always 12.8ms after SRES#.
On a VA6 MegaDrive (315-5433 ASIC), the SRES# rising edge to VRES# rising edge is 98304 VCLKs (256*384) consistently.
Power down
When power is removed, SRES# falls first, then VRES# about 2.5ms later. MRES# stays high for quite a while the capacitor discharges.
In general
MRES# is the main reset signal.
SRES# is derived from MRES# and is asserted earlier than VRES#. It goes to the 315-5313, 315-5309, and 315-5364 such that these chips are reset well before the 68000 starts running. It is only asserted on a cold boot.
The 315-5364 ensures VRES# is asserted for the correct amount of time based on the SRES# and WRES inputs.
For cartridges, MRES# indicates a power-up reset (cold boot), VRES# is for both power-up and reset-button resets.
Executing a RESET instruction on the 68000 will pulse VRES# for 128 VCLKs like normal, and no other reset signals will be affected.
A circuit in the cartridge can drive MRES# low using an open collector output, which will in turn trigger SRES# and then VRES#. This will fake a cold-boot event without cycling the power.
Reset signals
WRES - Active high reset signal, pressing the RESET switch shorts it to +5V. Normally held low with a pull-down resistor. No debouncing.
VRES# - To 68000 and cartridge connector, generated by 315-5364. Asserted for 128 VCLKs (Thanks Eke!) which is approx. 130ns/cycle x 128 cycles = 16.7ms. Triggered by the rising edge of either SRES (power-up reset) or WRES (reset button) being asserted.
MRES# - Directly from the RC reset circuit (R=47K, C=10uF), goes to cartridge connector.
SRES# - Output of a LM358 that compares the output of the charging capacitor on MRES# to Vref (measured at 2.0V) from the CXA1145 Vref pin. The output is 0V when MRES#<Vref and 5V when MRES#>= Vref.
FRES - Active high reset signal. The falling edge is synchronous with SRES#. Goes to the expansion connector.
Reset button
When the reset button is pressed, VRES# is pulsed low starting a variable amount of time from the rising edge of WRES. Minimum is 2.1ms. The VRES# low pulse is always 128 VCLKs (16.7us). This means that jamming on the reset button will not send malformed reset pulses to the 68000.
Power up
When power is applied, MRES# rising edge to SRES# rising edge is about 166ms. VRES# rising edge is always 12.8ms after SRES#.
On a VA6 MegaDrive (315-5433 ASIC), the SRES# rising edge to VRES# rising edge is 98304 VCLKs (256*384) consistently.
Power down
When power is removed, SRES# falls first, then VRES# about 2.5ms later. MRES# stays high for quite a while the capacitor discharges.
In general
MRES# is the main reset signal.
SRES# is derived from MRES# and is asserted earlier than VRES#. It goes to the 315-5313, 315-5309, and 315-5364 such that these chips are reset well before the 68000 starts running. It is only asserted on a cold boot.
The 315-5364 ensures VRES# is asserted for the correct amount of time based on the SRES# and WRES inputs.
For cartridges, MRES# indicates a power-up reset (cold boot), VRES# is for both power-up and reset-button resets.
Executing a RESET instruction on the 68000 will pulse VRES# for 128 VCLKs like normal, and no other reset signals will be affected.
A circuit in the cartridge can drive MRES# low using an open collector output, which will in turn trigger SRES# and then VRES#. This will fake a cold-boot event without cycling the power.