Releases: polpo/picogus
v3.2.1
Fixes/improvements
pgusinit
Fixes several regressions in pgusinit:
- Fixes issue where port settings are parsed as decimal, not hex (fixes /mpuport, /gusport, /cdport, etc.)
- Fixes /sbport and /gusport commands not passing through option
- Fixes /wifistatus command
- Restores /defaults command
General
- Gives VREG a bit more time to settle at bootup/reset. Should improve stability on initial poweron, after changing modes, or flashing firmware.
v3.2.0
Fixes/improvements
General
- Settings saved in flash with
pgusinit /saveare now preserved when upgrading to a firmware version that introduces new settings - Volume control is now available for all sources. For example, in SB mode, the SB DSP, OPL2, and CD-ROM audio volumes can be independently controlled. Thanks to Daniel Arnold (Delphius) for contributing this!
- DualShock 4 gamepad support has been fixed
SB mode
Sound Blaster playback has been almost completely rewritten, removing a major bottleneck and freeing up way more CPU time.
- Crashing on titles with simultaneous SB DSP & OPL2 fixed
- High-quality assembly optimized FIR polyphase resampler for much better sounding OPL2 output. Huge thanks to korneliuszo for contributing this and other optimizations!
- Direct DAC mode is back after being dropped in firmware v3.0.0
- Too-slow MPU-401 output in SB mode fixed (main symptom was long delay until music starts in Sierra titles)
- CD-ROM speed now faster in SB mode - improved from 2x to 3x
pgusinit
pgusinit has been almost completely refactored, thanks again to Daniel Arnold (Delphius). It not only helps future maintainability but brings new quality of life features:
- Long output like CD image listing and extended help text now pauses instead of scrolling off the screen
- Progress bar when flashing firmware instead of filling the screen with dots
- More helpful text if there are missing arguments
- Values can be set back to their default values with a
defaultargument. Example:pgusinit /cdport default - Added support for volume control via commands like /sbvol, /cdvol, etc.
v3.1.0
Fixes
CD-ROM emulation
Many fixes/improvements to CD image handling:
- Add ability to load image by name
- Fix memory leak when changing images (file handle not freed, causing crash after switching images several times)
- Less memory usage all over
- Longer max file length limit (127 chars)
- Better errors when USB not present
- Fix polling of CD status register when listing images
- Many weird edge cases with image loading state fixed
v3.0.1
Fixes
SB and USB modes
Fixes MPU-401 output in SB and USB modes. It was broken by the introduction of CD-ROM emulation in SB mode and it never actually worked in USB mode!
v3.0.0
(note: please use firmware v3.0.1, which fixes issues with MPU emulation in SB and USB modes)
New features/changes
CD-ROM emulation
PicoGUS now supports CD-ROM emulation (in other words, PicoGUS is now an ODE)! It emulates a Panasonic/MKE interface and drive and supports CD images in ISO or BIN/CUE stored on a USB drive plugged into the USB port on the PicoGUS. CD-ROM emulation has been tested in DOS and Windows 9x and CD audio playback is fully supported.
CD-ROM emulation is available in Sound Blaster and USB modes. Sound Blaster mode really pushes the limit of the RP2040: it mixes CD audio, SB DSP, and OPL sound while simultaneously supporting CD data and MPU-401 emulation. The emulated drive is approximately 2x speed in SB mode and 3x-4x speed in USB mode. Disc images can be swapped on the fly with pgusinit, and multi-disc games are supported by removing and reinserting the USB drive to advance the current disc image.
For more information and a guide on how to use CD-ROM emulation on PicoGUS with recommended drivers, known limitations, etc., visit the new CD-ROM emulation wiki page.
Massive thanks to Kevin Moonlight (yyzkevin) for reverse engineering the Panasonic/MKE interface and contributing the bulk of the underlying code for this emulation.
Also major thanks to rppicomidi for greatly improving mass storage speed for the RP2040 in TinyUSB and Artem Vasilev (wbcbz7) for additional fixes and rebasing on a more recent state of the repository. Without their work, USB mass storage would not be nearly fast enough to support CD-ROM emulation on the RP2040. These improvements are still not merged into the upstream project, so here's hoping that can be completed.
And thanks to all who tested this firmware before release to surface bugs and edge cases I wouldn't have been able to find myself. Cue sheets are the wild west of formats!
Tandy/CMS modes combined into new PSG (programmable sound generator) mode
To reduce firmware size and prepare for future support for other PSG sound chips (here's a hint, it's the AY-3 as used on the Mindscape Music Board), Tandy and CMS modes have been combined into a single PSG mode. It can be selected with pgusinit /mode psg, but the old /mode tandy and /mode cms switches still work for backwards compatibility.
Fixes
pgusinit
When pgusinit couldn't detect a PicoGUS, it would erroneously continue trying to configure the card. This would result in a strange firmware version mismatch error. This has now been fixed.
Known issues
Sound Blaster mode
Due to the addition of CD-ROM emulation to SB mode, SB DSP audio now runs through a FIFO. This may result in some playback issues that are being worked on. Also "Direct DAC" mode (mostly used by older titles) is not currently supported.
General
Due to the addition of new settings, any saved settings done with /pgusinit save on previous firmware versions will be reset to defaults when upgrading to firmware v3.0.0.
v2.2.0
New features/changes
NE2000 emulation/WiFi
Please note that this mode is not supported on PicoGUS 2.0! It needs a v1.1, v1.2, or Femto version of the PicoGUS that takes a Raspberry Pi Pico and requires a Pico W! I made this mode mainly just so I could use WiFi on my Pocket386 with a Femto card plugged into it. At least for now, NE2K mode comes in its own separate firmware file (pg-ne2k.uf2) and no other emulation is enabled when this firmware is loaded. Due to this limitation and the fact that the PCB design of the PicoGUS 1.x is not ideal for WiFI reception, consider this mode just a bit of a nice bonus. Config options have been added to pgusinit for NE2000 and WiFi SSID/password settings.
Fixes
Sound Blaster 2.0 emulation
- Fixes detection in Windows 9x, allowing SB mode to work in Windows 9x. Thanks to Ian Hanschen (@ianhan) for contributing the fix.
- Fixes detection in Tyrian and Dig-It! Thanks again to Ian Hanschen for the fix.
- Fixes detection in STMIK-based demos (Mental Surgery by Future Crew, SX by Substance, Min Monitor Briner by Syntax Error, probably others)
GUS emulation
- Fixes intelligent mode MIDI buffer overrun and slow MIDI output in GUS mode. Usually showed up as an "Exc. Checksum Error" on the MT-32 screen.
General
- Fixes issue with setting port numbers less than 0x100 or ending in 00. This fixes common port settings like 0c0 for Tandy or 0x300 for NE2000
- Refactors timers to be less jittery; shouldn't be noticeable in practice but may fix some GUS emulation edge cases.
v2.1.0
New features/changes
MPU-401 simultaneous with all modes
MPU-401 emulation is now available in all modes. This can enable simultaneous digital sound effects in SB or GUS modes with MIDI output. If you have another MPU-401 card in the system, to prevent conflicts this can be disabled or moved to a different port with the /mpuport option to pgusinit.
The original MPU mode is still available for titles that require MPU interrupts (titles on this list marked with a 1 require MPU interrupts).
v2.0.0
New features/changes
Serial mouse emulation
Now you can use a USB mouse as a serial mouse on your PC. Features a configurable report rate defaulting to 60Hz so the emulated serial mouse is much smoother and more responsive than a real serial mouse. Also supports configurable sensitivity and protocol support, including Microsoft, Logitech, Mouse Systems, and Intellimouse with wheel support. Note that being a serial port, this does use an IRQ so the IRQ jumper on the PicoGUS must be set to IRQ 4 or 3 depending on which serial port is configured, or use a mouse driver like ctmouse that can use a custom IRQ. Serial mouse can be emulated simultaneously with sound card modes that do not require IRQ such as AdLib, CMS, and Tandy (MPU coming in future firmware for games that don't need MPU IRQ).
Thanks to Artem Vasilev (wbcbz7) for implementing mouse and 8250 UART emulation.
"Multifw" - all modes in one firmware
All emulation modes (GUS, SB, MPU, etc.) are now contained within the same firmware. This means switching between modes is much faster than before, taking 1-2 seconds on average. Switching also no longer involves writing new firmware to the card's flash, alleviating flash wear concerns (each sector on the flash is rated for at least 100,000 cycles, so there wasn't much to worry about, but it's still nice for peace of mind).
Many thanks to Jeroen Taverne for developing the original proof of concept and smymm for implementing it within the PicoGUS codebase.
Card settings can now be saved in flash
Once you're satisfied with your PicoGUS's settings, they can now be saved in the card's flash. Saved settings persist across reboots or power cycle without needing to run pgusinit each boot.
For example, when using serial mouse emulation, some BIOSes like MRBIOS need to see the emulated serial port right at boot. Also as a bonus if you want to use emulation modes outside of DOS, settings will apply in those other operating systems. Want to use GUS in OS/2 or Linux, or serial mouse when setting up NeXTStep? This will help!
Overhaul of pgusinit
To support the above new features, adding more options to pgusinit meant I ran out of single letters for its various switches that make mnemonic sense. I've moved to longer yet hopefully still fast to type names for each of the switches.
Also, each pgusinit option now persists between invocations of pgusinit. Previously, most but not all options had to be given in the same invocation of pgusinit. Each option that would enable a feature (e.g. joystick support) has been turned into an on/off option so it can be turned off as well as on.
Running pgusinit by itself will now show all the currently applied settings for the current firmware mode.
See the pgusinit README for more details on running pgusinit.
Fixes
Sound Blaster 2.0:
- Added speaker on/off commands
- Greatly increased quality of output in "Direct DAC" mode
OPL2 emulation
- Fixed "missing notes" issue, most commonly heard in Prince of Persia. Thank you to TerryFi for discovering the issue and coming up with a preliminary fix, then incorporating the final fix from the upstream emu8950 repository.
v1.2.0
New features/fixes
Sound Blaster 2.0 emulation:
The AdLib mode (pg-adlib.uf2) has been replaced with a new Sound Blaster 2.0 mode (pg-sb.uf2)! Code to emulate the Sound Blaster DSP was contributed by Kevin Moonlight - huge thanks to him.
- Sound Blaster 2.0 DSP support is pretty well tested but you may run into issues. Please consult the Compatibility List for titles with known issues, and feel free to file an issue on GitHub to report any problems.
- AdLib/OPL2 emulation has been improved, fixing issues with missing/wrong notes.
- The SB base port can be set with pgusinit with the
/poption, and the OPL/AdLib base port with the new/ooption. - Some older titles supporting AdLib are "speed sensitive" and have weird playback on fast systems (even with a genuine OPL2/OPL3). A new
/woption in pgusinit can work around these issues in most circumstances.
MPU-401 emulation:
- Fixes an issue reported by zuldan on Vogons where running pgusinit in MPU-401 mode wouldn't work on certain systems. Fixed by initing the MPU-401 and sending the reset MIDI data asynchronously, preventing IOCHRDY from being held low for too long.
- Sysex delay handled without busy wait. Shouldn't have much effect presently, but may allow MPU-401 to be emulated simultaneously with other modes in the future.
General:
- Allows the volume of the wavetable header to be set with the
/voption in pgusinit in all modes. This is useful if you want to use the wavetable header to mix in other external audio sources like a CD-ROM drive (connection guide coming to the Wiki).
v1.1.0
New features/fixes
GUS emulation:
- Works around a hardware bug in the PCM510xA DAC that results in ~10% of chips to be silent at 22.05kHz sampling rate. This is the rate produced by the GUS at 28 channels, and is used by Doom and the demo "Dope". The workaround is to run the DAC at 44.1kHz, linearly interpolating the 22.05kHz output.
- Increased fractional precision of wave addresses to 10 bits from 9.
- New EXPERIMENTAL fixed 44.1kHz output. Normally the GF1 varies its output sample rate from 44.1kHz at 14 voices to 19.2kHz at 32 voices. Using this option enables 44.1kHz output for all numbers of voices, similar to the Interwave. This gives much higher quality output when playing lots of channels. This will result in stuttering in most games that use streaming DMA for sound effects like Doom, hence it is EXPERIMENTAL. It can be enabled with the
/4switch in pgusinit. Thanks to wbcbz7 for contributing this support along with the increased wave address precision. - Known issue: Impulse Tracker constantly re-inits the GUS to get the best sampling rate and if it passes through 28 channels rapidly, audio artifacts can be heard. To work around, run PicoGUS in fixed 44.1kHz output mode.
pgusinit
- New
/4switch when in GUS mode to enable fixed 44.1kHz output.