What's new

Arthrimus

Champion
Joined
May 18, 2018
Messages
483
Reaction score
1,594
Location
Arkansas
RJ45 to DB15 Controller Converter for MC Cthulhu/PS360+/Brook Retro Board
A47auQSh.jpg


Hello, I wanted to post this project here since it seem right up this forum's alley.

I have been working on a cable for connecting my MC Cthulhu equipped arcade sticks to my DB15 equipped arcade setup. My original thought was to put together a Sega Saturn controller converter, since that can be built using discrete logic and doesn't require any programming, and then connect it to my MC Cthulhu with a Saturn to RJ45 cable. What I didn't like about this method was that it required 7 ICs to demultiplex 2 controllers, which is kind of ridiculous. Also Saturn controller ports of decent quality are not in production so even though the discrete method works, it still pretty much sucks.

imag01151.jpg


Recently I returned to this project with some fresh ideas. I switched from discrete logic to an ATMEGA328p and wrote up some Sega Saturn Demultiplexer code for it. This worked great and was much more reasonable to build, but I still didn't have a good source for Saturn controller ports. A couple of days ago I decided to nix the controller port all together and just wire an RJ45 cable directly to my adapter PCB. Since I wasn't using Saturn ports anymore I decided to switch to a different controller protocol that makes use of the select button so I could use the coin pin on the DB15 connector. I wrote code for the SNES protocol, but ran into some bugs that I still haven't sorted out. I also wrote code for the Playstation controller protocol using an existing arduino library that works beautifully. I think that is the protocol I'm going to stick with for the RJ45 adapter.

Here is the prototype PCB, It's small enough to fit inside of the DB15 backshell for a very clean look.

TIJHO9uh.jpg


I have a newer PCB, which incorporates the additional wiring that you see on my prototype, that I have posted on OSHPark

Edit
7510998c51d640703d87a13c1a3b2e64.png

2fcc8649222dad3f14bb01ffca579fdf.png


Currently I have 3 different flavors of firmware you can run on the board.
  1. Sega Saturn mode: Works great with the Retro Board, doesn't support the select button natively, but does support select via button combination (START + K1 + K2 + K3)
  2. SNES mode: Fully working in MC Cthulhu. Works with Brook retro boards also, but "Brook fix" mode has to be enabled or else the adapter will occasionally drop held inputs. Brook fix adds 1/2 of a frame of lag.
  3. Playstation mode: Works on Mc Cthulhu only. Has no bugs to speak of but only works on the MC Cthulhu, not the Retro Board or PS360+. This may change in the future.
Pinout Info:
  • The DB15 end of this board follows the same pinout as Undamned uses for the USB to DB15 adapter.
  • The cable end has each pad labelled following the MC Cthulhu naming convention. The pad layout on the board also matches the Sega Saturn connector layout since that's what the board was originally designed for.

Future plans.
  • I'd like to add switchable button maps for NEO-GEO or normal 6 button operation. Preferably these would be toggled by holding certain button combinations. Done!
  • A more ambitious feature I'd like to add is fully customizable on the fly button remapping, but that is probably going to take some time to figure out. Done!
I have tested this with the MC Cthulhu and got great results, however I don't have a Brook Retro board or a PS360+, If you have one of these boards and would like to volunteer to do some testing, PM me and we can see about sending a prototype your way.

Well, that's my project so far, thanks for reading, any feedback would be appreciated.
 
Last edited:
Sorry I can’t help out, I don’t have a Retro board or a PS360+ anymore, I only run MC Cthulhu’s and the newer Universal Fighting Board.

But if this turns out to be made available for sale, I’m interested in picking up a couple.
 
Sent you a PM. Got a PS360 and a PS360+ here I can test with for you.
 
Seems like a neat idea with the RJ45. I also don't like the Saturn ports found in the aftermarket Saturn extension cables, they don't provide enough support and grip. My only (small) criticism is about your code - it will be safer to configure the outputs as open drain. Another good practice in AVR programming is setting the output ports pins all at once if possible - in case of these adapters it is possible.

To give you the idea (I used parts of your PSX code):
C:
ouput = 0;
if (data & psxDown)
	ouput |= 1;                    
if (data & psxLeft)
	ouput |= 2; 
if (data & psxRight)
	ouput |= 4;                     
DDRA = output;
 
Last edited:
Thanks for the advice. I will look into this and try to figure out how to make this work in my code. I'm not very experienced with programming AVRs so I was sure that my code was pretty inefficient.

On a separate note, I have already managed to implement the alternate NEO-GEO button map in the current PSX code on my github. You can switch between modes by pressing Start + Select + X simultaneously. When it's in NEO-GEO mode it remaps K1 as P1, P1 as P2, P2 as P3 and P3 as K1 which should make more sense for playing four button NEO-GEO games on a six button stick.
 
Last edited:
Seems like a neat idea with the RJ45. I also don't like the Saturn ports found in the aftermarket Saturn extension cables, they don't provide enough support and grip. My only (small) criticism is about your code - it will be safer to configure the outputs as open drain. Another good practice in AVR programming is setting the output ports pins all at once if possible - in case of these adapters it is possible.

To give you the idea (I used parts of your PSX code)
Sorry to bump this thread, but I have done a major rewrite of the PSX to DB15 code which now implements the improvements suggested by RGB. It works great and should also be safer to use this way. I learned a lot about AVR programming from this also so I am grateful to RGB for setting me on the right path.

With that said I am still looking for volunteers that would like to test one of these devices with their own setup. I need people who have either a PS360+ or Brook Retro board in their arcade stick who can test one of these adapters on their supergun or NEO-GEO hardware. If you qualify and are interested please let me know.
 
Great, the code looks way better now, look how many if/else conditions you got rid of! :)
 
The word is in from testers, and I have now confirmed it myself. Brook Retro Boards and PS360+ boards DO NOT LIKE my Playstation or SNES code. They must use a much more strict interpretation of the controller protocols than the MC Cthulhu. I am working on the issue, but at this point I haven't made any real headway. On the bright side my Saturn code works beautifully with the Retro Board so I went ahead and updated it with all of the safety improvements and extra features that I had already added to the PS1 code.

Changes in the Saturn code:

  1. All output pins are configured as open drain for safety.
  2. Switchable buttonmaps for Six Button and Neo-Geo have been added.
  3. Select/Coin can now be pressed via button combination (START + P3)
  4. The code is much better organized and well documented now.

To switch between Six button mode and Neo-Geo mode you must press the corresponding button combination.

Six Button mode = START + K1
Neo-Geo mode = START + K2

Six Button mode is the default starting configuration. Buttonmaps can be switched on the fly.

The Github link in the first post has been updated with the latest Saturn code.
 
Last edited:
Damn I would have tested had I found out earlier. My stick is running a dual UFB and Retro Board setup. I also have a DB15 port on it (running wires from the UFB's terminal post to a DB15 breakout) but I have it wired up for Neo Geo use. I'm just about to move so my supergun and arcade gear is in storage now. Once I know my head from ass in Japan I'll probably order a supergun from @RGB : )
 

Attachments

  • IMG_7193.jpg
    IMG_7193.jpg
    78.3 KB · Views: 483
  • IMG_7194.JPG
    IMG_7194.JPG
    67.7 KB · Views: 471
  • IMG_7195.JPG
    IMG_7195.JPG
    80.9 KB · Views: 485
  • IMG_7196.jpg
    IMG_7196.jpg
    127.5 KB · Views: 454
  • Like
Reactions: RGB
Back
Top