OpenBOR for MiSTer

Kernel, Main, Utilities & Applications, Miscellaneous Devices.
User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Thanks for the suggestion. Will try it later.

Another question: What is the correct path if i want to start OpenBor from my external SSD, which is Device usb0? Is this possible? It doesnt start (no error).

OPENBOR_HOME_DIR="/media/usb0/OpenBOR"

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Nice find! I had a path reference bug in OpenBOR.sh which passed on sdcard because it's FAT and thus case-insensitive. Your usb drive must be formatted to a case sensitive filesystem.

I pushed up a fix. Run the install script then update openbor.sh once you move it to your usb drive.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

This doesn't help i'm afraid. Still waiting on the "Setting Video Mode.. Press any key to continue" screen, and then it quits back to the MiSTer start menu.
Will check later if i didn't something wrong.

The file system is Exfat.

PikWik
Posts: 279
Joined: Sat May 30, 2020 7:00 pm
Has thanked: 207 times
Been thanked: 74 times

Re: OpenBOR for MiSTer

Unread post by PikWik »

woah, openBOR looks fun, lots of content to dive into. thanks so much!

do you think this openBOR project would work with this?
https://gamejolt.com/games/pocket-dimen ... h-2/194726
Pocket Dimensional Clash 2

it looks to use openBOR, but im unsure of which version to use on the MiSTer
(maybe the android port. it has the slimmest install with just an APK and a PAK file)

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Game looks to be in widescreen mode. This means you may have to comment out vmode 320 240 from OpenBOR.sh or specify a higher resolution. But this will only work if your mister is connected via hdmi. If connected via RGB then no it's not compatible due to resolution limit.

--- UPDATE ---

Not compatible... it uses a newer version of the engine.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Just tried Crisis Evil RE 2. But the game quits to MiSTer menu shortly after the loading screen. Is this a space/ game unpacking issue? I have only 770MB left on my SD card (external SSD load won't work somehow).

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Please share the log file and I can investigate what's wrong because it runs on my setup.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Must be a SD card space issue, right?

Any other hint why i can't load OpenBor via external SSD? I doesn't seem to be a case sensitive matter. I've copied the whole OperBOR folder to the SSD, changed the path to SSD and then started via OpenBor.sh script from SD card.

Attachments
OpenBorLog.txt
(25.18 KiB) Downloaded 148 times
Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Oh that is a different version of Crisis Evil 2. That one is newer and is not supported by this version. You can find a few mods on my old website..... http://lavalit.com:8080/index.php?actio ... oads;cat=6

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Nice, seems to work. Thanks for the links. I will try this ones first.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Reviewing the log it's looking for newer functionality not implemented in this version. As for ssd/usb0 I would need to test it on mine to see why it doesn't work for you.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

No stress. If you find some time you could check it. For now i'll try some of your linked games.

Generally for game pads: I think OpenBor is confused by similar designed pads. I have different controllers from 8bitdo like the M30, Pro/Pro2/ Neo Geo etc (mostly Xbox 360 controller classes). OpenBor loads fine with all plugged in. But the controller mapping isn't working properly then. It's a mess, what buttons and directions work in which way. You have to unplug nearly all pads.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Yeah... that's an area that needs an overhaul. Problem is that the backend is based on SDL 1.2 and joystick support was lousy back then. There is no concept of dpad.... so everything is a button. I could remap the axis sticks easy enough.... but that still doesn't solve dpad issues which seem to have been solved with SDL 2.0 but SDL 2.0 seems to have dropped framebuffer support which is necessary on the MiSTer platform.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Is something like Raw input possible? This should work fine then.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Maybe.... I would need to look into it. Alternatively maybe a fix would be to save the address of the controller and its name with the assigned player. That would resolve your issues most likely.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Would be great. I assume this issue could confuse a lot of people.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

I understand the issue now with how the controls are behaving on your setup. The way the engine maps the joysticks to players is based on individual button assignments and the problem here is that depending on when you plug in or where you plug in your gamepads it breaks the association due to the order of which the gamepad is detected and reported by SDL. Meaning index alone is not good enough as it breaks rather easily. I will have to come up with a means for mapping a controller name to player in order to retain the button assignments regardless of the order of when the pad was detected.

Essentially I have to create a database which keeps the button assignments mapped to a device and associate the device to a player.

Keep in mind that most people back then did not normally have more than 2 controllers..... or if they did it was because openbor was running on a game console..... but here on mister.... well that's a different story.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Retro-Nerd wrote: Mon Apr 29, 2024 10:18 pm

Would be great. I assume this issue could confuse a lot of people.

I have pushed up a new version which should now be able to recall the order of joysticks as they were previously configured. However, if joysticks have the same name, there is no good solution for this but I'm hoping this will work better for you. Also once you setup all 4 players the keyboard will continue to work unlike before.

This new version will wipe your previous settings. You will have to map all your player inputs and then once you have it setup I recommend you perform the following for all your games to have the same mapping:

Options -> System Options -> Config Settings -> Save Settings to Default.cfg

This will allow for any new games which have not been configured to acquire your Control Layout.

Just run Install_OpenBOR.sh to grab the latest.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

The new version is actually worse.

With all my pads plugged in the button A is registered as "down" in the Frontend Gui. And if i unplug all but one pad none of the buttons work (direction seems fine.)

I've deleted all previous configs in the "Saves" folder.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

You will need to use your keyboard to navigate until you have at least one controller assigned. Once they are assigned everything should be fine. This is how it's normally done for OpenBOR due to how the engine maps key/button events and without rewriting the input handling portion within the engine it will require a keyboard for initial setup. I will update the instructions to clarify this limitation.

Now if there were dedicated controllers like a game console for example this would not be an issue as they could have been coded specifically for their button layout but this is not the case with a vanilla port of the codebase targeted to run on linux without a heavy rewrite.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Ah, ok. Starting and configure works now with all pads plugged. But games that support 2-player automatically selects the 2Player mode. Very strange.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

I will look into that

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

And they crash after a few seconds back to the Mister menu. This even happens with only one pad plugged (the one with the default control mappings), 2-Player automatically and then a crash after a few seconds playing ingame.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Reverted these changes.... there is a bad bug in SDL1.2 where the joystick name is not always reported and is causing these issues. I apologize for the inconvenience. Just run Install_OpenBOR.sh to revert back.

I think I am going to leave this alone for now.... just remember to assign the players to your favorite gamepads that you know will always be available before starting OpenBOR. I will have to rethink the gamepad handling as a whole across the backend and engine.

Slightly different topic I think we need two versions of the startup script. One for CRT and another for HDMI. This way if I upgrade the engine to support new games which have higher resolutions then you can just select the hdmi version.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

No problem. The old way works with one pad plugged.

For the HDMI script: Sounds like a plan. Looking forward to test your new script then.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Ok I've pushed up support for both OpenBOR_CRT.sh and OpenBOR_HDMI.sh. The later will allow for you to play more OpenBOR modules at different resolutions. Deprecated OpenBOR.sh and should be automatically removed when you next run the Install_OpenBOR.sh script.

However, I did make changes to the repo and this will require you to manually replace Install_OpenBOR.sh within /media/fat/Scripts/

Hopefully this will not need to be done again moving forward. I didn't like how the downloaded master.zip file did not match the branch name. So I renamed the branch from main to master.

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Ok, the HDMI script seems to work. But the frontend is then very tiny on my 4k TV.

In the game -> video settings i can select 2x = 640x480 which is way too small on a 4K TV, but it works in full speed. I can scale it though via Retrotink 4k.

When i select 4x (the maximum) = 1280x960 the game is lagging as hell, everything is delayed (controls too). Maybe runs in 10-15 fps. Too much for the DE10 Nano Arm CPU?

The screen generally jitters and shows some weird glitches for a split-second every 2-3 seconds (looks like the Mister menu). Happens in all resolutions, 240p, 480p, 960p.

The new CRT script doesn't seem to work. I get a line 15 "808 Segmantation fault" error.

edit: the Segmantation fault number differs at every new start.

Sumolx
Posts: 68
Joined: Sun Jun 07, 2020 1:50 am
Been thanked: 20 times

Re: OpenBOR for MiSTer

Unread post by Sumolx »

Yeah I don't expect good performance when scaling because all the drawing is being to by the CPU directly to the framebuffer. But it allows you to play the mod at its native resolution. 320x240, 480x272, 640x480.... whatever the game maker choose.

As for the CRT script that script is for those that use analog output but I do find it strange that it stopped working for you unless you were trying to run a game at higher than 320x240 which then makes sense or you enabled scaling and are trying to run the crt script which caps to 320x240 and that would cause a failure.

Trying disabling the scaling via hdmi script then try CRT script again.

Maybe the two openbor binaries should be in their own respective directories for hdmi and crt but share the same paks directory? That way if you enable scaling for hdmi it doesn't impact crt version.

User avatar
dickhardpill
Posts: 285
Joined: Tue Apr 09, 2024 9:28 pm
Location: Not Portland, OR
Has thanked: 73 times
Been thanked: 59 times
Contact:

Re: OpenBOR for MiSTer

Unread post by dickhardpill »

I'm using an analog IO to component and it displays properly on my CRT using a custom MiSTer.ini

I has a you tube
Analog IO
USB board
VGA > Component
HDMI > FPM

User avatar
Retro-Nerd
Posts: 279
Joined: Fri Jul 08, 2022 2:47 am
Has thanked: 11 times
Been thanked: 80 times

Re: OpenBOR for MiSTer

Unread post by Retro-Nerd »

Two binaries? I have only one in media/fat/OpenBor.

Huh? Just had a look at the current the build number. It's 3.1 Build 3009 Apr 28 2024. How did that happen? :shock:

I guess i stay with the CRT script (disabling the ingame scaling fixed it). I can scale it to 4K fullscreen via Retrotink perfectly fine. :)

Noticed something strange: When i start the HDMI script the colored bottom sections are somehow garbled with overlapping letters one into the other. This happens then too for the CRT script. But if i delete everthing and install again it's fine...FOR CRT script. Starting HDMI script again, overlapping text. Strange.

Attachments
IMG_20240501_053500.jpg
IMG_20240501_053500.jpg (2.22 MiB) Viewed 5141 times
Post Reply