What's new
NAMCO have a tendency to check for special IO strings.

Look in the dump for Ninja Assault and see if you can find a gun io string.
 
You where right on that special string check! Boots with no error now, but guns still only shoot in the top right hand corner, and i'm sending them a fixed middle position so I'm not quite sure whats going on. Going to investigate more with the reicast-emulator to see what it does - I'm wondering if theres a speed of reply issue or something going on.
 
guns still only shoot in the top right hand corner, and i'm sending them a fixed middle position
it's possible that it might only use 8 bits of a 16 bit number... maybe try some different coordinates to make sure.
 
Thanks for the suggestion, will have a look.

https://github.com/libretro/flycast/issues/399

It actually looks like they've got the same issues as I do. I'm wondering if:

1. It uses some Digital I/O as well for the shooting, like an on screen off screen type thing? I noticed when I pressed one of the digital I/Os that wasn't in the test menu, it makes the border around the shooting test area change colour?
2. There is some weird timing issue, that both myself and libretro/flycast don't get right.
3. They've got the bit depth wrong / it uses more guns or something strange?

//u16 x = mo_x_abs[player_num] * 0xFFFF / 639 + 0.5f;
//u16 y = (479 - mo_y_abs[player_num]) * 0xFFFF / 479 + 0.5f;
// Correct for Ninja Assault. Revisit for other games
u32 xr = 0x19d - 0x37;
u32 yr = 0x1fe - 0x40;
s16 x = mo_x_abs[player_num] * xr / 639 + 0x37;
s16 y = mo_y_abs[player_num] * yr / 479 + 0x40;
LOGJVS("P%d lightgun %4x,%4x ", player_num + 1, x, y);
JVS_OUT(x >> 8); // X, MSB
JVS_OUT(x);// X, LSB
JVS_OUT(y >> 8); // Y, MSB
JVS_OUT(y);// Y, LSB

* the code insert button is super bugged out for me, and just opens another dialog every time I click save.
 
Last edited:
I'm wondering if:

1. It uses some Digital I/O as well for the shooting, like an on screen off screen type thing? I noticed when I pressed one of the digital I/Os that wasn't in the test menu, it makes the border around the shooting test area change colour?
The IR based NAOMI gun games have an "off-screen" signal on one of the button inputs since the analog channels have no way to relay an off-screen position otherwise, so it's possible that this game uses something similar.

though if this input type is intended for touch-screens, it should have some way to relay a difference between an on-screen coordinate and no-touch. Maybe they're doing something funny with the coordinate data?

I think this is likely the instance where seeing the JVS output on a real cab would provide some good insights.
 
I was thinking about that, to make an RS485 sniffer, I would think all you'd need to do is get a USB -> RS485 converter, and then a USB cable. Cut the cable in half, and wire both sides into the RS485 converter. Then if you opened it's stream, and didn't send anything you should get both sides data? So should be a super simple job?
 
Just ordered a bunch of different RS485 converters + some usb extension cables to chop up. I'm going to start writing a little C program to output the traces nicely as well, and hopefully this will help debug the JVS problems.
 
  • Like
Reactions: rtw
The way I did it in the past, was connecting the JVS I/O directly to the com port of the PC via RS485-RS232 adapter that can be easily found around. Let me see if I can find a picture.

After that I did a small piece of code that was connecting to the port and sending the basic commands. I think the port was fixed in this code.

See attached. I hope you find it useful.

Another way is to "hook" into the communication, using also a RS232-rs485 adapter to a PC and read the communication using a RS232 logger.
 

Attachments

  • JVS_Read_Info.zip
    2.3 KB · Views: 304
Update:

Maps - We've got more maps down, so lots of Naomi games can be played with a PS4 controller. I'll be adding a set of USB wheel maps soon. For anyone that doesn't know, the 'maps' are the files which translate the information coming from a USB device, to information that an arcade system understands. So for example a map would include, which USB device to listen to, and that its accelerator pedal for example, should map to player 1 analogue channel 2 on the arcade system.

Netbooting - You can now directly netboot a Naomi/Triforce/Chihiro game from OpenJVS. There is a roms directory in `/etc/OpenJVS/roms/`, where you can put a rom with the same name as a map in. If you then run `openjvs <map_name>` then OpenJVS will boot the game on the system at startup. The netbooting is written in C, and seems to be to be faster than netbooting from a python script. One more thing I'll add to Netbooting is the ability for the system to search for the arcade system on the network, rather than using a static IP. This means that if the IP changes etc. it will continue to work. Another thing I'd like to do is continue the research of the people who where trying to save the game settings information between reboots on the Naomi, but that will be for a lot later down the line.

Sense Line - You can now run the sense line from one of the I/O pins on the Raspberry Pi. You need 4 resistors, but the circuit is just that, 1 wire and 4 resistors in series. I'll do a write up about how to set that up soon - but this means that you can now use OpenJVS on Naomi, Naomi 2, Triforce, Chihiro, Lindbergh etc. etc. basically everything!

Custom Board - I would really now like to make a custom raspberry pi hat which will have the RS485 converter, sense line circuit etc. on one simple board that people can just plug onto their Pi. I'm thinking that using the onboard RS232 the pi has might make this work with raspberry pi 1s which are cheaper. If anyone is interested in helping with making the boards, I'd be really interested to have someone help me design them.

Force Feedback - This is probably the most exciting update. I'm adding force feedback capability from the Lindbergh com port into OpenJVS. My current target wheel is the Mirosoft Sidewinder FFB Wheel, however I think that once it's setup any wheel that can be recognized in Linux should work fine. I get the wheel in about a week, so expect FFB support in about 2 weeks if all goes well.

Auto Start - I've added functionality for this to auto start with the pi, so when you turn your Pi on, it will boot with the default configuration - so in essence it can now be used as a replacement for a JVS I/O without any user interaction normally. I've currently got my Pi powered off one of the USB ports on the Lindbergh, so when you turn the Lindbergh on, OpenJVS boots up as well.

Questions for people:

If I where to make a dedicated board for a Pi, how would people want to select the maps/games that this should start?

- I could include some dip switches which would allow you to switch between maps, for example an Aimtrak for Lindbergh games or a USB wheel for Naomi games etc. There could be folders on the root of the sd card named 0001 and 0101 etc. which would be read for the maps/roms dependent on the dip switch position.
- I could include an lcd screen with some switches, but I'd really rather not do this as it makes the cost bigger and its more likely to break.
- I could just make it so you have 1 map and 1 rom in the root of a readable partition on the SD card and you just pop it into your computer to change it?
- I could just make instructions on how to adapt the current Pi Netboot solution with the LCD, so that my software was selectable from that LCD, and you just had to add in the sync wire.
- I could make it have a web page, where you can select the game and configuration etc. which remains upon reboot.
First of all thank you very much for this great project and I'm glad to hear about all this progress.
I already looked through all the code and I might also contribute in the future. Unfortunately this will take some time (might be a couple of month) before I can actually start testing it for I just ordered a Lindbergh and it will take some time before I'll get it.

Anyways - did you already document how your working Sense-Line circuit looks like?
Does somebody know what the pull-up resistor (to 5V) at the JVS Master's side is and so what current needs to be ran through the Raspberry's IO Pin when the line needs to be pulled down to ground (for the 0V after addressing)?
 
Gents,
Is this interesting project on hold?
I don't see any new post, I also see some references about a opnjvs 2.0 but that's about 6 months ago.

Anyway, thank you for the effort
Best regards
Fed
 
@Fredobedo007 Hey there, I've not made any interesting updates to the project of late as I've had a lot of university work and other arcade projects that I've been messing with. OpenJVS as it stands will work fine if you want to set it up, OpenJVS2 isn't going to be released as I'm not happy with how it went. Myself and a friend are currently starting to build OpenJVS3 which is a completely new code base (based on JVSCore) and should be much more robust and convinient than the old one. Development for that will happen here: https://github.com/bobbydilley/OpenJVS3.
 
Thank you for giving feedback so fast! I wish you the very best with your study and hope you will still have fun developing version 3 :)

My interest in your project is being able to connect my Logitech G27 to my Naomi and probably or2 Lindbergh with ffb. I would use a pi 4 for this purpose.
I'll give it a try within 1 or 2 months.

And congrats with your achievement.
Fred from Belgium.
 
I try to read the source code, no mention about drive board test? How to run game with wheel?
 
In terms of force feedback it doesn't work - I've not managed to get it working for OutRun2 SP: https://github.com/bobbydilley/OpenJVS/blob/master/src/FFB.c.

If you literally just mean how do you get it to work with a wheel, a USB Wheel is exactly the same as any other input device. You just need to write a map file to map from your USB wheels inputs to the inputs the game expects. Theres a tutorial video on how to do that earlier in this thread.
 
thx very much. I saw on OR2 manul chihiro version for upright no FFB. Do you know how to bypass check hardwar or say at the mobo is in upright for no check?
 
Back
Top