MAME configuration file help
I recently saw a question about MAME configuration files in the #coco-pi Discord channel and wanted to provide a bit of information about them. I plan to cover more about it in a future video.
“…that mame.ini writeable flag is important. people can tweak with some mame settings without fear because whatever they try and fail with goes away when restarting. but once the tweaks we want are tested we can enable write and carefully put them back in.
[5:42 AM] erroneus: but what happens when I make it not write? I thought I saw it go back to defaults. I will test further but the tweak needed for controllers, specifically the speed of analog is a pain.”
It’s important to understand the differences between the mame.ini file and the *.cfg files located in the cfg sub-folder.
When you enable the writeconfig option in the mame.ini file, that tells make to write out a new mame.ini, but using the name of the driver you were running (like coco3). In that case, a new ini will be written called coco3.ini and it will be located in the .mame folder.
In all cases (whether the writeconfig option is enabled or not) mame will write out/update a *.cfg file for any driver you use. These will be located in the cfg sub-folder and uses a similar naming convention. It’s the name of the driver (i.e. coco3) and a cfg extension. Those are written out and updated each time you run mame.
It’s also very important to note that specific settings can be found in the *.ini files and the others in the *.cfg. This is why a combination of both types of files are needed with MAME in order to tweak things.
CoCo-Pi makes heavy use of the *.cfg files. In fact, many of the launch scripts for the various menu items copy over a known working cfg prior to running. In some cases, this could be making sure the Beckerport is enabled, or RGB over composite, artifacting disabled, etc…
I do this as someone could make a change and that may impact one of the launch scripts from the menu. I realize there may be changes someone WANTS to keep, regardless of what I set things for.
To address that, there is a menu option to disable CoCo-Pi from using it’s pre-configured *.cfg files and allow the user full control. This can be toggled on and off whenever someone wants. In addition, there is a menu option to backup ALL emulator config files (on demand) and restore them back (if needed).
This is where you need to read the actual MAME docs for specifics as it goes beyond me teaching all settings that are available. Most of what you want is kept in the *.ini and *.cfg files. There really isn’t anywhere else MAME stores it’s settings.
Another thing to keep in mind is that “driver” is another word for the machine name you are running in MAME.
For example, coco3, mc10, etc..
In the case of the 2nd menu option in the CoCo 3 menu, it’s a coco3 with a 6309 processor. That driver name would be coco3h, not coco3. A CoCo 3 with Drivewire support would be coco3dw1.
It’s important to understand driver names if you want to make changes to your configuration files. You can peek at any of the CoCo-Pi launch scripts and look for the mame command line to see the driver name.
I want to be clear that we are only talking about MAME here. XRoar and OVCC use different ways to configure their emulators.
More to come.