Skip to content

MiSTer FPGA: Setup and usage

Dale Whinham edited this page Mar 8, 2023 · 4 revisions

The quickest way to get up and running with MiSTer FPGA is to use the new interactive mt32-pi installer script.

Otherwise, for a manual installation, follow the quick-start guide in the main README, but ignore the last two steps regarding MIDI and audio connections.

You must then edit the mt32-pi.cfg file to make the MiSTer user port interface fully functional. The settings shown below will work for the MiSTer mt32-pi HAT:

[audio]
output_device = i2s

[control]
# Required for physical buttons
scheme = simple_buttons

# Required for OSD controls
mister = on

[lcd]
# Required for OSD "LCD-On" and "LCD-Auto" modes even if you don't have a real OLED display connected
type = ssd1306_i2c

# You can use either 32 or 64 pixel height
height = 64

πŸ’‘ Tip: Take a look at the configuration file page for some hints on how to edit the file successfully.

Usage

  1. Connect the Raspberry Pi to the user port on the MiSTer and switch it on. mt32-pi should start up.
  2. If you see Low voltage! Chk PSU on the Raspberry Pi's LCD, see the next section.
  3. On the MiSTer, start a core that includes mt32-pi support (currently AO486, Atari ST, or Minimig).
  4. You should see the MiSTer logo appear on the Raspberry Pi's LCD briefly - this means that IΒ²C communications between Pi and MiSTer are working.
  5. mt32-pi is now ready for use - try some games!

MiSTer OSD options

If mt32-pi is detected by the MiSTer, a new "MT32-pi" submenu will appear in the MiSTer's OSD.

When changing these options, remember to save your configuration to ensure they persist.

  • Use MT32-pi: Enables/disables MIDI output to mt32-pi.
  • Show Info: Selects OSD information display mode.
    • No: Disables information display.
    • Yes: Brief "pop-up" notifications (similar to video mode/joystick notifications) are shown when mt32-pi's synthesizer/MT-32 ROM/SoundFont are changed, e.g. via button press, or sending a custom SysEx message from within the core.
    • LCD-On(non-FB): Shows a copy of mt32-pi's LCD display on your MiSTer's video output (may not work for certain higher-resolution video modes).
    • LCD-Auto(non-FB): As above, but automatically hides when the display is idle.
  • Default Config section: Allows you to set the synth, MT-32 ROM and SoundFont you'd like the core to start up with. mt32-pi will switch immediately when you change these from the OSD, and will also switch when the core is re-loaded.
  • Current Config: Shows the currently selected configuration as reported by mt32-pi. This may not necessarily match the Default Config above if you have changed the configuration from a button press or custom SysEx message.
  • Reset Hanging Notes: Tells mt32-pi to switch off all notes on all synthesizers. Useful for if a game crashes and you want to silence any stuck notes.

πŸ’‘ Tip: If you reset the AO486 core using CTRL-ALT-ALT instead of CTRL-ALT-DEL, a core hardware reset will be performed, and mt32-pi will silence all notes. This may be a more convenient way to recover from a crashed system with hanging notes.

Low voltage warnings

It is possible that some voltage drop may occur if the Raspberry Pi is being powered by the MiSTer, which could cause mt32-pi to display Low voltage! Chk PSU on the LCD. Although it's not ideal, in practice there shouldn't be any issues so long as the voltage reaching the Pi isn't too far below +4.8V.

In most cases, this is completely normal and you just need to disable the warnings as explained below. You should not need to replace your power supply with a stronger one unless the Pi or MiSTer is rebooting spontaneously or crashing.

The voltage drop is believed to be caused by a current protection circuit within the DE-10 Nano and so it is unavoidable when powering the Pi using the MiSTer, even with a strong 4A 5V power supply. For example, the popular Mean Well GST25B05-P1J is more than capable of delivering enough current for both MiSTer and Pi, and will measure +5V across the DC barrel connector with everything powered. However, by the time power makes its way through the DE-10 Nano, I/O board and USB cable, there's just enough voltage drop to exceed the Pi's detection threshold.

The "low voltage" message is triggered by the Raspberry Pi's GPU-based firmware, which will also throttle the CPU when it notices a low voltage condition. This will cause the audio to stutter. This mechanism exists to prevent data loss when using the Raspberry Pi as a computer, but for mt32-pi we should be able to safely disable it.

To do this, edit your config.txt and uncomment the following line (remove the #). This disables the warnings and the throttling:

avoid_warnings=2

⚠ Note: Please ensure your Raspberry Pi's CPU is heatsinked, as it's not known if this option disables thermal throttling!

Alternatively, you can cut the +5V connection between MiSTer and Raspberry Pi, and use a dedicated power supply for the Raspberry Pi. If you use the MiSTer HAT, simply turn off the switch to achieve this.

⚠ Note: Make sure you turn off the switch when powering the Raspberry Pi externally. Otherwise, the Pi's PSU will begin powering the MiSTer, resulting in further loss of power to the Pi.

Clone this wiki locally