nfg.forums

NFG Forums => Controller Technic => Topic started by: NFG on July 02, 2009, 12:49:53 AM

Title: PC Engine 6-button Pad Schematic
Post by: NFG on July 02, 2009, 12:49:53 AM
I whipped this up today, after Gravis pointed out that I'd never actually done one before.

Please point out anything I may have missed, working this late into the night is not really conducive to error-free results.  =)

(http://gamesx.com/grafx/PCEpad6T.png) (http://gamesx.com/grafx/PCEpad6.png)
Click for full size
Title: Re: PC Engine 6-button Pad Schematic
Post by: NFG on July 03, 2009, 10:09:52 AM
Schematic updated to version 1.1.  Now includes autofire circuit, proper chip designations (74LS157) and a correction to the connector pin names.
Title: Re: PC Engine 6-button Pad Schematic
Post by: Heffa on October 12, 2009, 10:12:45 PM
Hey Lawrence - perhaps a stupid question, but what values does the resistor arrays have?  ???
Title: Re: PC Engine 6-button Pad Schematic
Post by: l_oliveira on October 12, 2009, 11:48:53 PM
I'm not Lawrence, but I can safely inform you that 4k7 will suffice. :)
Since they're simply pull-ups, you can just use anything from 2k2 to 10k range.
Title: Re: PC Engine 6-button Pad Schematic
Post by: Heffa on October 13, 2009, 06:23:33 AM
Quote from: l_oliveira on October 12, 2009, 11:48:53 PM
I'm not Lawrence, but I can safely inform you that 4k7 will suffice. :)
Since they're simply pull-ups, you can just use anything from 2k2 to 10k range.

Thanks!  :)
Title: Re: PC Engine 6-button Pad Schematic
Post by: sonofx51 on November 18, 2010, 04:09:40 PM
sorry to dig up an old thread, but where would I put a toggle switch to select between 2 button mode and 6 button mode?
Title: Re: PC Engine 6-button Pad Schematic
Post by: NFG on November 18, 2010, 04:15:55 PM
Pin 1 of the '157 chip closest to the connector. 

Your switch should connect it as shown OR connect it to GROUND.
Title: Re: PC Engine 6-button Pad Schematic
Post by: sonofx51 on November 19, 2010, 05:29:11 AM
thank you.
Title: Re: PC Engine 6-button Pad Schematic
Post by: bigsanta on December 30, 2010, 02:11:09 PM
Quote from: Lawrence on July 02, 2009, 12:49:53 AM
I whipped this up today, after Gravis pointed out that I'd never actually done one before.

Please point out anything I may have missed, working this late into the night is not really conducive to error-free results.  =)

One detail i think will help out those making a demultiplexer circuit ,what is the clk speed that's used on the 74157's select pin ?Is it near what the mega drive's is for the 3 button pad about 60 hz or so ?

[EDIT by Lawrence: removed massive image in quote]
Title: Re: PC Engine 6-button Pad Schematic
Post by: NFG on December 30, 2010, 02:25:10 PM
I don't have any way to measure that, and I think it's software dependent.  If the game doesn't need an input, it doesn't have to ask.

I think 60Hz is a reasonable speed anyway, beyond that you won't have any effect on the game (since nothing can be seen more frequently than that) and slower could result in old/no input when it's required.   Try 120Hz to be safe, why not?  =D

EDIT: I have it on good authority that it IS software controlled but the standard is during vblank, so yeah, 60Hz.
Title: Re: PC Engine 6-button Pad Schematic
Post by: bigsanta on December 31, 2010, 01:52:45 AM
Great thanks ,now i'll just make up a 555 astable and see what we get when it's hooked up to a simple control interface like jamma.
Title: Re: PC Engine 6-button Pad Schematic
Post by: bigsanta on January 04, 2011, 03:29:34 AM
Quote from: Lawrence on July 02, 2009, 12:49:53 AM
I whipped this up today, after Gravis pointed out that I'd never actually done one before.

Please point out anything I may have missed, working this late into the night is not really conducive to error-free results.  =)

Isn't it the RUN button ,not START ?!

[EDIT by Lawrence: removed massive image in quote]
Title: Re: PC Engine 6-button Pad Schematic
Post by: bigsanta on January 04, 2011, 09:54:36 AM
Say we build this circuit and don't want the rapid fire part, the 74163,how will/can the third 74157 be connected to get its select signal ?
Title: Re: PC Engine 6-button Pad Schematic
Post by: NFG on January 04, 2011, 10:11:47 AM
You can't make this without the autofire chip, it's responsible for flicking back and forth between the two chips.  If you want to remove this chip you'll have to find something else to do the job.

That's probably why all the six-button pads had autofire - it's basically a free byproduct of the chip select mechanism. 
Title: Re: PC Engine 6-button Pad Schematic
Post by: bigsanta on January 05, 2011, 08:29:07 AM
Quote from: l_oliveira on October 12, 2009, 11:48:53 PM
I'm not Lawrence, but I can safely inform you that 4k7 will suffice. :)
Since they're simply pull-ups, you can just use anything from 2k2 to 10k range.
I'm looking at my avenue pad 6 pcb and it has the 330 ohms printed on the pcb (as in the schematic aswell) ,but for each pull up resistor on the buttons etc,those values are all printed  as 47k on the pcb .
Title: Re: PC Engine 6-button Pad Schematic
Post by: bigsanta on January 05, 2011, 08:31:46 AM
Quote from: Lawrence on January 04, 2011, 10:11:47 AM
You can't make this without the autofire chip, it's responsible for flicking back and forth between the two chips.  If you want to remove this chip you'll have to find something else to do the job.

That's probably why all the six-button pads had autofire - it's basically a free byproduct of the chip select mechanism. 
Bummer,i'll just take that ic from an old core grafx pad then and stick the finished  circuit in my joystick .
Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on February 19, 2017, 12:50:42 PM
Just an FYI for those of you following along at home: the '157s and '163 all have Vcc and GND pins on each of the DIPs. Those have to be connected to 5v and GND, respectively (the schematic omits those for the sake of neatness).
Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on March 01, 2017, 06:00:12 PM
Hi Lawrence,

Thanks again for the schematic.  I breadboarded this up and I'm running into a little glitch.  For ease of reading, I'll call the '157 that handles dpad, 1 and 2, run, and select as "mux1", the other '157 that handles 3,4,5,6 as "mux2."

First off, I have hooked up everything except the pins on mux 1 and 2 that correspond to the buttons, and the autofire pins on the '163 (those pins are just floating right now).  As well, I have hooked up all the Vccs and GNDs on all the '157s and the '163

I'm testing individual buttons right now, jumping a pin on the mux to a pull-up array, and then jumping that to ground to get my button press. Mux2 acts as mux 1 (i.e. 1B on mux2 gives me UP), and mux1 doesn't work at all.  If I disconnect Vcc on mux2, then mux1 works properly again (and as expected, mux2 won't work).  Any idea what's happening?  Are my breadboard connections failing?  Did you ever make a physical prototype and have pictures of it?

Thanks,
Myung
Title: Re: PC Engine 6-button Pad Schematic
Post by: NFG on March 03, 2017, 05:39:56 PM
That's an interesting problem.  I can't see immediately why it would do this, except that...  Based on my quick reading of the datasheet, the 74157 doesn't have an internal pullup, so if you aren't giving it Vcc or GND on the inputs, it may be freaking out a little bit.  You may need to connect every button, either to your pullup resistor array or ground, before it behaves.
Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on May 14, 2017, 04:59:45 PM
Hi Lawrence,

So, an interesting development.  I laid out the PCB for these and got them prototyped. 

(http://i.imgur.com/6xvB48Y.jpg)

They seem to work fine (works nicely in the input tester and in Street Fighter II), EXCEPT when plugged in through a multitap.  When I do that, it thinks all the D-pad buttons are pressed, and shorting individual buttons to ground activates chords (i.e. 2 buttons at once). 

(http://i.imgur.com/xY0peWp.jpg)

The normal Avenue Pad 6 doesn't seem to exhibit this behavior.  Any suggestions?

P.S. I added a switch that connects the Select line of the 3rd '157 (the one that feeds into the DIN 8 pins) either to ground (for 2 button mode) or into the '163's QA (for 6 button mode).

Thanks,
Myung
Title: Re: PC Engine 6-button Pad Schematic
Post by: NFG on May 14, 2017, 10:19:17 PM
OK, well you've sort of stumped me.  Obviously the multi-tap should work with the six button pad or we'd never have two-player Street Fighter.

If you're getting ULDR all at the same time, you're definitely getting a reading from the second '157 when the app expects the first.  I don't know what would cause this -only- via the multi-tap.  I assume the pad is in 6-button mode and you're reading it with a 6-button-aware soft, like Street Fighter, when this happens?

Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on May 15, 2017, 01:26:52 PM
Hi Lawrence,

I shot a quick video to give a little more context to the behavior:

https://www.youtube.com/watch?v=EG4YVa2SCjA

I took a look in side the Avenue Pad 6 and found a few caps across some lines, as well as what looks to be a transistor on the '163.  Could these function to stabilize or filter whatever is causing the malfunction?

(http://i.imgur.com/Q8mNxAO.jpg)

-Myung
Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on May 20, 2017, 07:26:58 AM
Lawrence, would it help if I sent you the prototype board I made?

Title: Re: PC Engine 6-button Pad Schematic
Post by: NFG on May 21, 2017, 09:10:56 PM
Sorry for the delay. I'm travelling overseas at the moment. I'll be back 6th June.

For sure I'm happy to check it out.  Maybe playing with it will give me some insights. I'll have to find my PCE multitap  tho. =)
Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on June 27, 2017, 09:06:19 AM
Hi Lawrence.  I just had a thought; could the 74LS chips be the problem?  I noticed in the Avenue Pad, it uses 74HC chips, which use CMOS instead of the transistors (like the in the 74LS's).  Could it be that when driving 2 muxes and the multitap, the current (and maybe even voltage) drop is enough to be causing that glitch?
Title: Re: PC Engine 6-button Pad Schematic
Post by: RDC on June 29, 2017, 12:40:12 PM
Have you tried powering it on with your controller already switched to the 6 button mode? Something may be getting out of time there and causing that issue from the way you're doing it 'on the fly' there.

It's a 5v console, so HC or LS shouldn't really matter there. You should have a 0.1uF or 0.001uF on the VCC pin to ground (decoupling) for each IC, then a single 1uF to 10uF on the 5v line to ground. I'd give that a try first and see how it acts, as they are easy enough to bung on the board there.

I had the Logic Analyzer on that multi-tap awhile back, trying to find that data now, but may have not saved it. I also did up a schematic for making a 2 or 6 button controller awhile back, and know it worked on the TG16 alone, but don't recall testing it on the multi-tap. http://www.acidmods.com/RDC/TG16/TurboPad_2_6_Button.pdf

I'll dig that all back out and bread board it up again and see what is going on there if yours still acts weird with some decoupling caps and already switched to 6 button mode while cold booting.



Title: Re: PC Engine 6-button Pad Schematic
Post by: RDC on June 29, 2017, 05:06:25 PM
OK, interesting. I've built the controller again per my schematic, and I'm using 74HC chips here, but it does the exact same thing thru the multi-tap. I get what is going wrong, just not sure how to correct it yet as I don't have an actual 6 button controller here to reverse or to connect up and see what it is doing different thru the multi-tap.

For whatever reason, the timing is getting off and it's reading the chips all screwy, as Lawrence mentioned earlier it's reading the wrong one for the D-pad. Notice how the one 157 has 4 lines just tied to ground? That's the one it's reading for the D-pad input and why they are all registering pressed at the same time, because they technically are, as far as the console is concerned anyway, but the console is supposed to know this and detect it as a 6 button pad and rearrange the data accordingly. Swapping the outputs of them around has 0 effect also, been there done that, so there is something else going on in that Avenue pad in relation to the multi-tap that's causing the homebrew ones to act stupid.

I'll try and hunt one down that's not from freaking Japan and see what's going on with it on the LA here. IN the meantime, can you get a good pic of the other side of you Avenue PCB there totoroslayer?
Title: Re: PC Engine 6-button Pad Schematic
Post by: RDC on June 30, 2017, 03:50:17 AM
Alright, might have this kind of figured out.

See that capacitor on the CLK line close to the 163 chip? It's CX on my schematic and 820pF, though I can't recall where I measured that value from. It's the 100pf on your Avenue board there close to the 163 chip. Do you have that cap installed? and is it the correct value?
Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on June 30, 2017, 08:22:41 AM
Hey RDC,

Interesting finds!  Thanks for your research.  Unfortunately the other side of this pcb is pretty bare. http://imgur.com/a/Y51RU The schematics I followed didn't have any decoupling caps for the mux chips.  I'll try installing a 100pf on the CLK line, as you suggested.  If that doesn't work, I'll try installing the other decoupling caps for all the other muxes and see if that works.  Now to order some 100pf s....
Title: Re: PC Engine 6-button Pad Schematic
Post by: RDC on June 30, 2017, 10:03:47 AM
Also, if you're not using 47k Resistors for the Pull-Ups, I'd order those also. There is something going on with that CLK line that is giving all the grief as I can almost get this one here working, but it's also spazing out for no reason sometimes.

Thanks for the pic, I was mainly after it for the traces to see what went where, to see if they did anything weird or different was all.
Title: Re: PC Engine 6-button Pad Schematic
Post by: RDC on July 04, 2017, 12:45:20 AM
Alright, this is almost enough to drive a person to drink, more than usual I mean, but it has to be some kind of timing issue. Something is causing the timing to get just a hair out of wack, which in this case is more than enough to wreck everything.

I can't even have my test cable in line here as it jacks the thing all up. I removed it and the 'controller' works fine in 6 button mode now, though in 2 button mode it seems to not care one bit how long the cable is.

Not sure how long of a controller cable you're using there on your home made 6 button there, but if you can, try to shorten it up and see how it acts. Mine here is around 3ft to the Tap, and then the Tap is directly into the TG-16, and it seem to work fine. I know that's not ideal, nor really a fix, but if yours works there as well with a shorter cable then we'll at least have that as more information as to what is really going on and what does/doesn't work.

I have an Avenue pad on the way as well now, so hopefully it will act properly with and without the test cable in there and then I can hopefully figure out where the exact fudge up is coming from, as it's really been kind of irking me the way it's acting here, as these are just a pile of logic chips, acting illogically.

I tore into the Tap as well, found the only decoupling cap in there had a cold solder joint, but correcting that solved nothing and it was still well within tolerance.

Having any kind of extension cable between the Tap and TG-16 causes issues, likewise so does having an extension cable between the 6 button and the Tap, if running in 6 button mode. I'm about to the point of trying some buffers on a minimum of the CLK and EN lines, either inside the Tap or the TG-16, to see if it straightens up or changes at all, because it really should not be acting this way.
Title: Re: PC Engine 6-button Pad Schematic
Post by: totoroslayer on July 04, 2017, 03:01:45 AM
Ah, I've been using a 6 foot cable on mine (as those are really the only length of mini din 8 cable available). Should I try chopping that in half (or maybe even a third)?  I did notice that the cables on PCE controllers are rather short, even by 16 bit system standards.
Title: Re: PC Engine 6-button Pad Schematic
Post by: RDC on July 04, 2017, 06:34:21 AM
Give it a hack in the middle and try it out, as the one I'm testing with here is only 3ft or so and it does work connected straight to the Tap. This is probably why I recall the thing working when I built it on the breadboard almost a year ago, I just never had that test cable in there when I did back then. As soon as the 6ft test cable goes in there things go to pot, and even a 3ft extension cable I have here screws it all up. They should work fine at twice the length they are having the issue at, and they do as long as you stick to using it as a 2 button, so there is still something screwy with all of this.