June 26, 2019, 12:26:51 am


Upload your images to this forum!.  The internet can't be trusted.  NFG can.  (probably)

SNES Controller: All Buttons Firing At Once?!

Started by T_O, June 15, 2019, 10:26:16 am

Previous topic - Next topic


Hello Forum,

New guy, here. NFG themselves recommended (on Twitter) that I bring my issue to the forum. I hope others can benefit from this if the issue is resolved.

So I'm designing a circuit based on NFG's 2 x 4021 shift register schematic, attempting a SNES/NES dual-purpose controller, basically. I have everything wired up correcty on my breadboard (after quadruple-checking, trust me!), and yet after every troubleshoot, the same thing keeps happening.

The test cart: SMB World. The intro, within seconds, goes to the game select screen on its own; sometimes it selects a game and then selects 1 or 2 player, sometimes it goes to player select and then back, sometimes the selection cursor moves on its own. Obviously buttons are firing on their own. There is a very brief time window in which I can give an input command on my own, and the correct buttons do the correct things.

Map screen: I'll explain what happens in 2-player mode, as more buttons are utilized in the map. The map screen won't be on for one second after fade-in before a button command fires on its own. Sometimes it's B to start the level I'm on; sometimes it's Select to bring up the player switch menu; sometimes it's Down; and sometimes it's Start to bring up the map view mode. Inputting any direction will simultaneously fire Start.

Gameplay: This is where all hell really breaks loose. More often than not, the level will begin with Mario/Weegee crouched down. He'll remain crouched for about 5 seconds, and no buttons or directional inputs will work during this time. Atter that, there will be a very brief time window (1-5 seconds? it varies) in which I can input button commands, and they all seem to work, from what I can tell after numerous test cycles. Then what happens is what I can only presume is several/all buttons firing at once, usually Start and Select firing first in a split-second "one-two" manner, which pauses and immediately exits the level; this will happen on its own, even if I press no buttons. The process then repeats over and over from the map screen.

I tested all leads, the ICs and even the breadboard rows, and even tried swapping in new ICs. I've tried swapping the yellow (CLK) and red (DATA) wires, thinking maybe the colors were switched. I've tried disconnecting leads, one by one--even the +5V rail, and the only thing that seems to have an effect is disconnecting DATA (which results in no input commands fired and no response from any buttons) and disconnecting pin 8 of the first IC (the top one in the schematic) from GND (B still works, and pressing any of the directions will fire other simultaneous commands, but no other button seemed to work). I also tried removing the resistor networks. None of these methods seemed to identify a clear problem nor get me any closer to a solution.

What would cause this behavior? The common pattern seems to be [Down for 5 seconds with input disabled...input enabled for a very brief moment...multiple buttons firing at once, starting with Start and Select...repeat].


I just posted a video to YouTube for your reference. In this footage, I simply powered the console on and kept my hands off of the controller; not one button was pushed. Observe what it does on its own.



I tried something different with how the resistors connected to the voltage rail on the breadboard, and it worked!

I’m using 47kOhm arrays for this project, so I reinstalled them but differently. Forgive the 30-second iPhone finger drawing [LMAO]. Instead of putting the voltage lead of the array in the same row as the VCC and pin 16, I connected the array directly to VCC and connected pin 16 to the rail separately. Did the same with the second array and the second 4021.

Lo and behold, it works now! I'm not even sure this is the solution, I'm just sharing what I did; for all I know, there was a bad connection somewhere on the board originally.

And NOW a follow-up question: does resistance level matter when it comes to the buttons' responsiveness? Like, is there a worthwhile difference between 47kOhm pull-ups and 10kOhm, and which way? This is eventually going to be an arcade stick, so responsiveness is important to me.   Thanks again!


I can't be sure what it is you've done with your diagram, did you just double up on the arrays?


Quote from: NFG on June 16, 2019, 07:30:45 am
I can't be sure what it is you've done with your diagram, did you just double up on the arrays?

No. The first image is of the common pin of the array (bold black line) in the same row as pin 16 (VCC) of the 4021 and a jumper to the 5v rail.

The second image is what worked for me--the common pin of the array separate from pin 16, with each going to the 5v rail.