Giter Site home page Giter Site logo

Comments (6)

dciabrin avatar dciabrin commented on June 21, 2024

TL;DR: Yes the examples are compatible with both GnGeo and MAME.
you can run the example from the ./01-helloworld directory directly with e.g.:

mame -rp rom puzzledp -w -noautosave -skip_gameinfo

The checksum complains are normal, both GnGeo and MAME have a fixed list of games that you're allowed to emulate, so the example ROMs reuse names, and obviously their checksum don't match.

What's odd though is the neogeo BIOS that is being loaded by MAME doesn't seem to be the one built by ngdevkit.

000-lo.lo WRONG LENGTH (expected: 00020000 found: 00010000)

MAME has loaded a zip that contains a zoom precalc with is 64KB long, whereas ngdevkit's stub BIOS is 128KB as expected.

$ unzip -l rom/neogeo.zip
Archive:  rom/neogeo.zip
nullbios 0.4, an open source BIOS for Neo Geo
https://github.com/dciabrin/ngdevkit
  Length      Date    Time    Name
---------  ---------- -----   ----
   131072  03-18-2024 18:26   000-lo.lo
   131072  03-18-2024 18:26   sfix.sfix
   131072  03-18-2024 18:26   sm1.sm1
   131072  03-18-2024 18:26   sp-s2.sp1
   131072  03-18-2024 18:26   aes-bios.bin
---------                     -------
   655360                     5 files

from ngdevkit.

videlanicolas avatar videlanicolas commented on June 21, 2024

TL;DR: Yes the examples are compatible with both GnGeo and MAME. you can run the example from the ./01-helloworld directory directly with e.g.:

mame -rp rom puzzledp -w -noautosave -skip_gameinfo

It works! Thanks!

MAME has loaded a zip that contains a zoom precalc with is 64KB long, whereas ngdevkit's stub BIOS is 128KB as expected.

Searching through Google I found similar issues: https://www.google.com/search?q=%22000-lo.lo+WRONG+LENGTH%22

Seems like an old version of the BIOS?

nullbios 0.4, an open source BIOS for Neo Geo

So this BIOS is supposed to replace the original NeoGeo BIOS? But given it's open source it has no license implications for its use?

from ngdevkit.

dciabrin avatar dciabrin commented on June 21, 2024

MAME has loaded a zip that contains a zoom precalc with is 64KB long, whereas ngdevkit's stub BIOS is 128KB as expected.

Searching through Google I found similar issues: https://www.google.com/search?q=%22000-lo.lo+WRONG+LENGTH%22

Seems like an old version of the BIOS?

Most likely, yes

nullbios 0.4, an open source BIOS for Neo Geo

So this BIOS is supposed to replace the original NeoGeo BIOS? But given it's open source it has no license implications for its use?

This is a made-from-scratch, very minimal stub that is sufficient to make emulators run your programs without requiring the original BIOS. It provides a zoom lookup table for the emulators, an empty sound driver, and it implements a handful of functions [1] e.g. read inputs and reset the watchdog timer for you. It does not implement the entire API from the original BIOS like memcard load/save, multiplayer inputs, and whatnot.

[1] https://wiki.neogeodev.org/index.php?title=BIOS_calls

from ngdevkit.

videlanicolas avatar videlanicolas commented on June 21, 2024

Would this open source BIOS work for MAME or only for GnGeo? I just tried replacing it in MAME and it's throwing errors, as if MAME can't find some necessary files to run the game.

The reason is that I like the MAME debug console, although I'm fine using gdb if I can't run the game on MAME with this BIOS.

I'm looking to develop a game for the MVS, and honestly don't care about storing saves or highscores, so I'm fine not having memcard calls.

from ngdevkit.

dciabrin avatar dciabrin commented on June 21, 2024

This is supposed to work for recent MAME (I use 0.263) and the GnGeo fork that ships with ngdevkit. I'm using this stub BIOS with MAME's z80 debugger to develop nullsound, the sound driver that comes with the devkit.
The BIOS should contain the necessary file names to boot the emulator in AES or MVS mode. I only tested AES on GnGeo, but both emulators are similar, I expect it to work fine on MAME.

However, you can't just use this BIOS in place of the original and expect existing games/ROMs to work. This won't work.
Makes sense, or are you hitting a specific issue?

from ngdevkit.

videlanicolas avatar videlanicolas commented on June 21, 2024

Makes sense, or are you hitting a specific issue?

This makes sense, I was hoping it worked until the game made a call to an unknown BIOS call and stop the emulation.

I removed all files from roms/neogeo and replaced it with the files inside neogeo.zip that came from the 01-helloworld example:

$ /usr/share/games/mame/roms/neogeo$ unzip neogeo.zip 
Archive:  neogeo.zip
nullbios 0.4, an open source BIOS for Neo Geo
https://github.com/dciabrin/ngdevkit
  inflating: 000-lo.lo               
  inflating: aes-bios.bin            
  inflating: sfix.sfix               
  inflating: sm1.sm1                 
  inflating: sp-s2.sp1

Then copied the helloworld example rom contents under roms/puzzledp (I thought the folder name had to match the game name, but I don't think this is necessary):

$ /usr/share/games/mame/roms/puzzledp$ cp ~/examples/01-helloworld/rom/* .
$ /usr/share/games/mame/roms/puzzledp$ ls
202-c1.bin  202-c1.c1  202-c2.bin  202-c2.c2  202-m1.bin  202-m1.m1  202-p1.bin  202-p1.p1  202-s1.bin  202-s1.s1  202-v1.bin  202-v1.v1  neogeo.zip  puzzledp.zip

Then run the game with mame:

$ mame -version
0.242 (unknown)
$ mame -rp rom puzzledp -w -noautosave -skip_gameinfo -debug
ALSA lib confmisc.c:855:(parse_card) cannot find card '0'
ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_card_inum returned error: No such file or directory
ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings
ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
ALSA lib confmisc.c:1334:(snd_func_refer) error evaluating name
ALSA lib conf.c:5178:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5701:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM default
Debug Build: Disabling input grab for -debug
Debug Build: Disabling input grab for -debug
Debug Build: Disabling input grab for -debug
202-p1.p1 NOT FOUND (tried in puzzledp neogeo)
202-s1.s1 NOT FOUND (tried in puzzledp neogeo)
sfix.sfix NOT FOUND (tried in puzzledp neogeo)
000-lo.lo NOT FOUND (tried in puzzledp neogeo)
sp-s2.sp1 NOT FOUND (tried in puzzledp neogeo)
sm1.sm1 NOT FOUND (tried in puzzledp neogeo)
202-m1.m1 NOT FOUND (tried in puzzledp neogeo)
202-v1.v1 NOT FOUND (tried in puzzledp neogeo)
202-c1.c1 NOT FOUND (tried in puzzledp neogeo)
202-c2.c2 NOT FOUND (tried in puzzledp neogeo)
Fatal error: Required files are missing, the machine cannot be run.

I'll keep debugging this when I have more time, but you answered my original question here (thanks!) so I think we can close this bug.

from ngdevkit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.