What's new

yosai

Enthusiast
Joined
Sep 29, 2015
Messages
220
Reaction score
143
Location
London
Thanks guys. Ill give that Hyperspin link a try.


i think mame actually has an issue with reading the inputs generated by the tool i havent looked at this for quite awhile so not 100% on that
I compiled another that only used alpha and numeric keys only. That didn't work either, so that could be the case... Or I haven't compiled them properly, but they do work well in Windows.
 

yosai

Enthusiast
Joined
Sep 29, 2015
Messages
220
Reaction score
143
Location
London
The dinput version of MAME was required, thanks.

The version of MAME linked wouldn't run up, maybe mislabelled 64bit version? Anyway I followed the steps below with an older 32 binary. All working well.


1) Open the Mame or MameUI executable with any hexadecimal editor. There are tons of free options out there.
2) Find the string "Root#RDP_" (try to find it in Ansi and Unicode). If your text editor doesn't support string searches, try in hexadecimal: Ansi hexadecimal "52 6F 6F 74 23 52 44 50 5F" or Unicode hexadecimal "52 00 6F 00 6F 00 74 00 23 00 52 00 44 00 50 00 5F 00").
3) Once you found the pattern, simply replace it by hexadecimal zeros and save the file.

Note for non-programmers: don't confuse the 0 (zero) character with the 00 (hex zero). We need hex zeros here.
 

cyclemat

Student
Joined
Oct 18, 2016
Messages
31
Reaction score
4
I mean the problem with the most mame version and this problem is that we didnt use the newest direct input version in the code oh a experiment last night build process sayed that the version is not declared and it you any standard version
 

cyclemat

Student
Joined
Oct 18, 2016
Messages
31
Reaction score
4
!!!!!!!! DANGER !!!!!!!!



So Have test but one Problem after 2 to 3 hours the I/Os are Dead the Keys

Board 1 837-13551 MG-L V0
Player 1 Button 1-3 Are Pressed alltime on Real Hardware and RS485 Converter

Board 2 837-13551 MDK332V-0
Player 1 Start Button is Pressed all Time

Have Desolder the PS2801-4 Chip on PC8 Key is Pressed no way to Fixit
 

Asure

Professional
Joined
Jul 24, 2015
Messages
398
Reaction score
423
Location
Netherlands
Wait, you broke two i/o's with this?
What was your setup? Which hardware did you have as output.. ?
 

tinchen3112

Student
Joined
Jul 29, 2015
Messages
41
Reaction score
23
Location
Germany
This Tool works very good for Com Port 1-4
but i would like to get it running on Port13, sadly this doesnt work.
@'corey, do you have an idea what to do to get in working on port13?
 

Niko

Champion
Joined
Sep 22, 2015
Messages
974
Reaction score
1,426
Location
Louisville, Kentucky
This Tool works very good for Com Port 1-4
but i would like to get it running on Port13, sadly this doesnt work.
@'corey, do you have an idea what to do to get in working on port13?
There shouldn't be any difference.

Are you sure the device is on COM13?
 

tinchen3112

Student
Joined
Jul 29, 2015
Messages
41
Reaction score
23
Location
Germany
Yes, 100% sure.

edit: port 1 to 9 works, >=10 not........
any idea?

edit again......
TCHAR *pcCommPort = TEXT("\\\\.\\COM13");
solved this.......
 
Last edited:

thejew

Student
Joined
May 16, 2016
Messages
60
Reaction score
13
Location
northwest Iowa
Is there any chance this could support trackball as mouse. That would be awesome!

And what's going on with dead IO I hope that was just a wiring mistake.

Also do you use (white=tx+) (red=tx-) on the cable? No green
 

corey

Professional
Joined
Jan 20, 2016
Messages
611
Reaction score
438
Location
Victoria, Australia
its possible but would be alot of work

this was built purely for digital inputs
 

yosai

Enthusiast
Joined
Sep 29, 2015
Messages
220
Reaction score
143
Location
London
Could this be modified to talk to a Capcom IO? As in directly using a USB cable between the IO and a PC.
 

Niko

Champion
Joined
Sep 22, 2015
Messages
974
Reaction score
1,426
Location
Louisville, Kentucky
Could this be modified to talk to a Capcom IO? As in directly using a USB cable between the IO and a PC.
While JVS I/O boards use USB cables as a medium for communication, they are not USB devices. Instead they use RS485 serial to communicate.

Since PCs do not speak RS485 serial, they need to use a RS232 -> RS485 transceiver in order to communicate with the I/O board. These are built into most PC based arcade hardware such as the Taito X2.
 

Wesker13

Beginner
Joined
Oct 17, 2019
Messages
26
Reaction score
0
Location
France
https://mega.nz/#!5thiHBrb!SXGuljtAPTATKNpbJfTwrH_Xdbjd_QDUfcmlyHZ8JiA

RE-Uploaded Niko's source setup to use keyboard.

For the non programmers.
You will need Visual Studio (VS). VS 2015 express will be fine and is free.

Once VS is installed open the file cjvs.sln.
This should open VS automatically.
On the right side panel you should see a file called key_config.h.
This is the file you will need to edit for your desired layout.

At the top of the file is a link to a site which has all the hex scancodes you can use.
Eg. the Enter key's scan code is 0x1C so
#define P1_START 0xFF would become #define P1_START 0x1C if you wanted to use Enter for start.

I have preset player one joystick to arrow keys as they require a little extra code in the main program file to work correctly.
Player 1 start + button 1 will execute what ever #define S_ESC is set to.
Once you have edited the file to your liking press CTRL + S to save the file.

Now on the top panel you will see 2 drop down boxes one saying debug and another x64.
You will need to change debug to release and x64 to x86.
Once you have them selected. click on build in the top bar menu and select build solution.
This will create a folder called release in the folder cjsv.sln is. Inside this folder is your program you can use.
cjvs.exe.

If you have any issues or questions don't hesitate to ask.

Also a big shout out to Niko for his jvs code he has done some amazing work with it.
hi, quick question how to change in the source code the button 1+ start combination to another combination for esc? Thank you in advance.
 

yosai

Enthusiast
Joined
Sep 29, 2015
Messages
220
Reaction score
143
Location
London
Looks like it's defined in cjvs.cpp

Code:
        //printf("START\n");
        ip->ki.dwFlags = KEYEVENTF_SCANCODE;
        ip->ki.wScan = P1_START;
        SendInput(1, ip, sizeof(INPUT));
        jkey->kstart_flag = 1;
        if (jdata[3] & 0x02)
        {
            ip->ki.dwFlags = KEYEVENTF_SCANCODE;
            ip->ki.wScan = S_ESC;
            SendInput(1, ip, sizeof(INPUT));
            jkey->kesc_flag = 1;

        }
        else if (jkey->kesc_flag == 1)
        {
            ip->ki.dwFlags = KEYEVENTF_SCANCODE | KEYEVENTF_KEYUP;
            ip->ki.wScan = S_ESC;

            SendInput(1, ip, sizeof(INPUT));
            jkey->kesc_flag = 0;
 

Layer33

Student
Joined
Jul 22, 2017
Messages
115
Reaction score
75
hi, quick question how to change in the source code the button 1+ start combination to another combination for esc? Thank you in advance.

I personally used buttons start + test to exit.
Open cjvs.cpp, find the code posted above by yosai, and replace the line :
if (jdata[3] & 0x02)
with that one :
if (jdata[2] & 0x80)
to exit with start + test instead.
 
Top