Howtos - cayce-msx/msxpp-quick-ref GitHub Wiki

Howtos

how to install SD-BIOS

Note:

  • the name says it: this is a full MSX BIOS - on a μSD card
  • basic steps: load the BIOS file onto the μSD card on a computer, insert into the SX1's μSD-slot, and press the power button
  • The system BIOS (called EP-BIOS - I have no idea what "EP" stands for) will be skipped
    • note that EP-BIOS is equal to SD-BIOS with all default options selected
  • The SD-BIOS must be written to the root directory and have name OCM-BIOS.DAT
  • For OCM-PLD firmware version 3.9 and earlier, this file must be written directly after formatting/partitioning; deleting all existing files and then copying it is not enough
    • it must follow directly after the FATs and root directory, in cluster 2
    • and, it must not be fragmented
    • luckily, this process is scripted, so you don't have to do it manually
  • Make sure you have a backup of the files on the card before starting!

Required hardware:

  • computer (Linux, macOS, Windows) with μSD-card reader (either internal or external)
  • SX1 (or other OCM-compatible)
  • μSD-card

Required files:

  • SD-BIOS from https://gnogni.altervista.org/
    • click on the link "OCM-SDBIOS Pack vx.y (YYYY.MM.DD)" (currently "OCM-SDBIOS Pack v3.7 (2024.01.13)") and send an email to receive a download link
    • download the OCM-SDBIOS Pack using the link you receive in the reply email

Steps:

  1. extract OCM-SDBIOS Pack using 7Zip.
  2. insert μSD-card in computer
  3. follow Win/Linux/macOS steps below
  4. add your own favourite applications & games to the card
  5. insert it into your MSX++ device, and enjoy!

Windows:

  1. Windows key > type "CMD" > click 'run as Administrator'
  2. type CD <path where you unpackaged the SDBIOS Pack>
  3. type cd make
  4. type new-sdcard.cmd
    1. this will first invoke make\make-sdb.cmd (which creates your custom OCM-BIOS.DAT),
      then make\sdcreate\sdcreate.cmd (which erases your μSD-card and copies the SD-BIOS there)
  5. Choose base firmware:
    1. MSX2+ OCM-PLD v3.0 to v3.3.3 (when your device contains an older OCM-PLD firmware)
    2. MSX2+ OCM-PLD v3.4 or later (default)
    3. MSXtR OCM-PLD v3.4 or later (Turbo-R - experimental)
    4. 512kB dummy blank file to run the EPBIOS
  6. Choose disk ROM:
    1. MegaSDHC FAT16X Single SD-slot (default - drive A: maps first SD-card partition)
    2. MegaSDHC FAT16X Double SD-slot (drive A: SD-card partition, B: mappable using EP.COM)
    3. Nextor
  7. Choose main ROM:
    1. MSX2+:
      1. FS-A1WSX Yen symbol ("¥")
      2. FS-A1WSX Backslash symbol ("" - default)
      3. FS-A1WSX Western layout (see charset description)
    2. Turbo-R:
      1. FS-A1GT Yen symbol ("¥")
      2. FS-A1GT Backslash symbol ("" - default)
  8. MSX2+ - choose logo: 0. No logo
    1. MSX2+ logo fix
    2. MSX++ official logo (default)
    3. SONY unofficial logo
    4. PHILIPS unofficial logo
    5. Zemmix Neo Korean logo
    6. Zemmix Neo Brazilian logo
    7. SX-1 logo by 8bits4ever
    8. SM-X logo by Victor Trucco
    9. 1chipMSX-Kai logo by HRA!
    10. SX-2 logo by 8bits4ever
    11. OCM generic unbound logo
  9. Choose option ROM:
    1. MSX2+:
      1. None (default)
      2. ESP8266 Wi-Fi
    2. Turbo-R: 0. No logo
      1. Turbo-R logo (default)
      2. ESP8266 Wi-Fi, no logo
      3. ESP8266 Wi-Fi + Turbo-R logo
  10. Choose extra ROM:
    1. None
    2. BASIC'n plus v2.0
    3. BASIC'n turbo v2.1 (default)
  11. Enter μSD-card drive letter
  12. Enter label name
  13. the card will be partitioned and formatted, then SD-BIOS and the contents of make\sdcreate\help,
    make\sdcreate\os and make\sdcreate\utils are copied onto it

For Linux & macOS you can use the scripts I ported. Note that they haven't been tested on macOS. And, unfortunately, cannot copy the OCM-BIOS.DAT file to the correct location on disk. I hope to find a fix in the near future.

  1. open a terminal
  2. cd <choose a nice location>
  3. git clone https://github.com/cayce-msx/msxpp-quick-ref.git
  4. cd msxpp-quick-ref/scripts
  5. ./make-sdbios.sh <path to extracted OCM-SDBIOS Pack>
    1. answer the dialog questions; same as for Windows above
  6. ./sdcreate.sh /dev/<device> <path to extracted OCM-SDBIOS Pack> [label (default: MSXFAT16)]
    1. this step requires sudo rights
    2. ⚠ does not work yet! Somehow, the Linux fat filesystem insists on placing the first file in cluster 3, leaving cluster 2 empty. Which is not where the firmware IPL (Initial Program Loader) looks for it. Not a problem if you have firmware v3.9.1 - that firmware looks for the file by name.

how to enable Wi-Fi

So, you've got an SD-BIOS running with the ESP8266 Wi-Fi Option ROM. If not, go back to the SD-BIOS howto.

Note: OCM-PLD Pack history.txt says at version 3.9.1 (2022.09.24): "The ESP8266 Wi-Fi BIOS has NOT been integrated into EPBIOS because its full maturity has not yet been reached."

Steps to take:

  1. Start ESPSETUP.COM
  2. enter your SSID
  3. enter password
  4. wait for the connection
  5. Using a modern computer, download UNAPI tools - or clone the whole MSX-Development github repo, and put the .COM files on the μSD-card you use on your MSX++ device, in a directory that is on the PATH.
  6. type HGET https://www.msx.org

Once you have set up an access point, a bright red LED will light up all the time. A Wi-Fi connection attempt is made at boot. When SNTP date/time sync has been enabled, this may take up to 10 seconds. To enter the boot menu, e.g., to update accesspoint settings, press&hold F1 - before you see the text "waiting for connection".

At reset (either cold or warm, with external button or via software) Wi-Fi will not be reinitialized - only after powering the unit off & on.

Note that the Wi-Fi ROM is at slot 0-3, so it will load before any cartridge ROMs.

A somewhat faint blue LED on the ESP board will blink when data is being transferred.

Wi-Fi connectivity is unstable for me. Home Wi-Fi router connected just once, and mobile tethering (in 'maximize compatibility' mode) drops the connection regularly.

To disable Wi-Fi, enter setup (either via ESPSETUP.COM or holding F1 at boot), option 4, choice 3.

All UNAPI tools:

  • HGET: like wget
  • INSTAGR8: Instagram Viewer
  • MSXHUB: HUB v1.3 - cmdline MSX package manager
  • HUBG: HUBG v0.80 - HUB GUI-based MSX package manager (type ESC to quit)
  • SNTP: retrieve date & time via SNTP servers. Already done automatically at boot.
  • TELNET: open an (unencrypted) shell to another machine
  • TFTP: trivial FTP client
  • WAITWIFI: (same as SD-BIOS tools) wait (max 10s) until Wi-Fi comes available - or timeout occurs. Suggestion: place it in AUTOEXEC.BAT as first command.

For more information, see:

For the inquisitive: I/O ports 06-07h (ESP) and F2h (ESP8266 BIOS) are used to interface to the ESP8266 board.

Using Wi-Fi without the ESP8266 BIOS ROM

Even without the optional ESP8266 BIOS ROM loaded via SDBIOS, the ESP-01 module can be used. So Wi-Fi can also be used with the built-in EPBIOS. The driver will be loaded into RAM.

Note, dusasp says: "RAMHELPR is incompatible with Kanji and other stuff." The BIOS solution is also easier and faster. Using SDBIOS remains the preferred way to enable Wi-Fi.

Steps:

  1. Download an 'OCM-SM Unapi Pack' at https://github.com/ducasp/MSX-Development/releases
  2. Extract the following files:
    • CFG8266.com
    • ESP8266.com
    • ramhelpr.com
    • waitwifi.com (optional)
    • sntp.com (optional)
  3. Run CFG8266 to configure your access point (only needs to be done once)
  4. Create a file ENA_WIFI.BAT with this content:
    SET PATH=A:\;A:\UNAPI;A:\WIFI  # or other paths where you placed ESP8266.com, waitwifi.com & sntp.com  
    SET TIMEZONE=-03:00            # edit for your time zone
    ESP8266
    waitwifi                       # optional
    sntp pool.ntp.org -03:00 /v    # optional
    
  5. Add this command to your AUTOEXEC.BAT (or type it in manually): RAMHELPR.COM I ENA_WIFI.BAT
    • make sure RAMHELPR.COM is on the PATH

Now you can use the same tools as described in the previous section.

how to put multiple SD-BIOS versions on one μSD-card

Requires OCM-PLD firmware v3.9.1.

Store SD-BIOS variants on the μSD-card using filenames OCM-BIOS.DA0 through .DA9.

Switch using SDBIOS.BTM <number> [-r] where selects OCM-BIOS.DA<number> and specifying -r reboots after enabling the selected variant.

Note that the script will rename all OCM-BIOS.DAi files except the one you selected to ALT-BIOS.DAi. The 'magic' behind this is that OCM-PLD firmware v3.9.1 looks for OCM-BIOS.DAT, OCM-BIOS.DA0, .., OCM-BIOS.DA9, starting the first one it finds.

How to upgrade Nextor inside SD-BIOS

SD-BIOS Pack 3.9.1 comes with Nextor 2.1.1. This quickref is updated to 2.1.2 (Dec 1, 2023).

Follow these steps:

  1. download Nextor release - you'll need Nextor-x.y.z.OCM.ROM and NEXTOR.SYS. Note: only changed files are released, so you might have to scroll a bit to find the latest of each.
  2. copy (overwrite) the ROM to make\roms\nextsd1s.rom and SYS file to make\sdcreate\os\NEXTOR.SYS
  3. follow the howto to build & install a custom SD-BIOS.

How to run ROMs

SofaRun

For lazy penguins! (Well, you do have to download it to your μSD card yourself🙂)
Works out of the box.

If you experience issues using SofaRun, you may need to increase the loading delay from the game settings.

SofaRun has a few settings specific to OneChipMSX-compatible devices. Open the Settings menu. Under 'OCM' you're able to set:

  • CPU speed: 3.58 (standard) up to 8.06MHz (turbo)
  • VDP speed: normal or fast
  • keyboard layout: Japanese or non-Japanese
  • slot 1 mode: external or SCC
  • slot 2 mode: external or SCC

Unfortunately, it's not possible to configure generic SETSMART commands; only the ones mentioned here. If you, for example, want to enable OPL3 and/or second PSG, set Turbo Pana Redirect mode or Vertical Offset, then you'll have to do that before starting SofaRun.

MGLOAD

Part of the SD-BIOS utilities.

  1. Make sure slot 2 is enabled in MegaSCC or MegaRAM mode; use Shift-ScrollLock or run SLOTMODE /2 or another applicable mode (2 through 7)
  2. run MGLOAD <file>.ROM /S2. When there is no MegaRAM detected, will say that - and hang!
  3. run getreset /w
  4. game should start. Not all do. In that case, try another slotmode or use SofaRun.

Note: SLOTMODE /1^MGLOAD <file>.ROM /S1^getreset /w will also work - loads in slot 1.

mglOCM

Version 2.3b is part of the SD-BIOS utilities. It has 16 Mbit (2MiB) ROM support.

To use:

  1. run MGLOCM <file>.ROM

That's it - program will autostart! Mapper should be autodetected, and no slotmode hassle like with MGLOAD.

Note, a new version of mglOCM is available. Includes documentation and code.

Documentation for 2.3b is available in OCM-PLD msxtools:

msxtools\mglunch\mglocme.txt
msxtools\mglunch\mglunche.txt

Optional parameters:

- /o = execute on Konami Classic Mapper
- /s =    on Konami-SCC Mapper
- /8 =    on Ascii-8 Mapper
- /f =    on Ascii16 Mapper
- /l =    on Linear  Mapper
- /r = execute with alternative method
- /t = Z80b 5.37MHz V9958 Fast mode
- /k = Konami 2nd Cartridge secret option
- /m = Sony Inside-Magic Key option
- /j = set Japanese keyboard layout
- /d = back to DOS after loading

ROMLOAD

ROMLOAD is created by TNI (⚠ not available as secure HTTPS!). The latest version, 1.99w, is part of the SD-BIOS utilities.

Requires ESE-MegaSCC+; ESE-MegaRAM is not supported. Easiest is to use SLOTMODE /1 or SLOTMODE /2.

  1. ROMLOAD.COM /S <file>.ROM

Some applications require extra parameters to run properly, e.g., /A to use ASCII-8K mapper.

Add the /H parameter to enable skipping the rom by holding Graph while booting. To change Graph to another key for one time, use /H:<row><bit> where you take <row> and <bit> from HOTKEY /M.
Using HOTKEY.COM it is also possible to view and permanently change the default hotkey in the ROMLOAD.COM file in the current directory.

Also in the SD-BIOS utils directory:

  • ROMLOAD.LST: 451 commands tailored to specific games
  • ROMLOAD.TXT: an extensive manual

Full Usage:

ROMLOAD <pathspec> [/S] [/R] [/I:P-S] [/F] [/{J|E}] [/V:N] [/{A|1|L|O|2|0|B}] [/7xx] [/5] [/D:<type>] [/T:<mode>] [/H] [/P:<data>]

<pathspec> = Full path & filename of ROM image (default extension: ROM)
        /S = Start ROM when loaded
        /R = Reset system after loading ROM image
        /I = Ignore detection in slot P-S
        /F = Force ROM image load
        /J = Force Japanese language
        /E = Force non-Japanese language
        /V = Force different MSX version
        /A = Convert from ASCII8
        /1 = Convert from ASCII16
        /L = Super Lode Runner (16 kB)
        /O = Cross Blaim (16 kB)
        /2 = MSX-DOS 2 Kernel (16 kB)
        /0 = ROM image in Page 0
        /B = BASIC in ROM
        /7 = Double cartridge
        /5 = SCC-I mode
        /D = DAC mode
        /T = Select CPU mode
        /H = Add hot-key to disable the ROM image
        /P = Patch blocks (x,yyyy,zz:x,yyyy,zz:...)

How to load 2 Konami ROMs

Tool KONAMICC.BAT will load 2 KONAMI [C]artridges in [C]ombination. It uses ROMLOAD to load the roms, and SETSMART to enable the required slotmodes. It even puts your MSX++ in turbo mode to speed up the loading!
One rom, the file mentioned as first argument to KONAMICC.BAT, goes into slot 1, the other into 2.

The openMSX equivalent is openmsx -carta NEMESIS2-GRADIUS2.ROM -cartb penguin.rom.

This can be used for, e.g.:

  • Gradius+Nemesis 2 ("You get an extra stage, so you can defeat Venom and finish the game.")
  • Salamander Enhanced (with SCC voice set)
  • Game Master 1 or 2 (most games require Game Master in slot 1!)

BiFi has compiled a list of working combinations (⚠ not available as secure HTTPS!).

How to run disk images

SofaRun

For lazy penguins! Works out of the box. Even for concatenated multidisk images. Uses SofaRunIt, which is based on RunIt.

If you experience issues using SofaRun, you may need to increase the loading delay from the game settings.

See the section above on running ROMs with SofaRun for information about settings for OneChipMSX-compatible devices.

To switch disk for multidisk images, use the following controls. Note that these must be pressed during disk access (CAPS LED will be on to simulate the drive LED). That might be a bit tricky to get the timing right!

Keyboard:

[1]-[9]: Select disk 1-9
[0]:     Select disk 10
[Shift]+[1]-[9]: Select disk 11-19
[Shift]+[0]: Select disk 20
[R]:     Make current disk read-only
[W]:     Make current disk writable

Joystick:

  1. Press and hold (A) or (B)
  2. Press the other button x times to select disk x (CAPS blinks)
  3. Release both buttons

Using Nextor

First install SD-BIOS with Nextor - see howto below. Then use Nextor tools mapdrv.com or emufile.com.

  1. MapDrive - for single disks (260/720KiB) with regular FAT12 structure

Example: MAPDRV B: 512x5125.DSK^B:^BASIC AUTOEXEC.BAS

  1. EmuFile - for full disks and multidisk images.

First, you create a .EMU file that is stored for reuse. Individual files have to be consecutive!

Example:

EMUFILE MY_APP IMAGE1.DSK IMAGE2.DSK   # create MY_APP.EMU - a one-time action

EMUFILE SET MY_APP                     # enable the image, and resets the MSX to boot from it

With EP-BIOS, or SD-BIOS with MegaSDHC

RunIt

One option is to use RunIt, which is part of OCM-PLD msxtools.

Example: RUNIT 512x5125.DSK

Uses EMUDSK.ROM and optionally ADAPT.COM.

See the following documentation for how to start specific games:

msxtools\runit\runit.nfo
msxtools\runit\games.txt
msxtools\runit\runit.txt
msxtools\runit\readme.txt
Mega-SCSI tools

Another option is to use Mega-SCSI tools ESET.COM and EP.COM.

Note: they are not fully compatible with MegaSDHC.

Japanese-to-English translation attempts for both tools:

Two additional documents, translated:

For more information, see MRC.

Maximum 16 disk images can be defined for a multidisk application.

There are 3 ways to mount .DSK files:

A. use EP.COM directly: EP IMAGE.DSK /B /R

If that doesn't work, try by adding option /D.

Syntax:

EP filename.ext d: [/F][/W]
or
EP filename.ext [/B|/Bx][/D][/R][/W]

Wildcards are allowed, to load multiple disk images. Note that files will be loaded in the order they are found on disk, which might not be sequential!

In that case, invoke EP.COM multiple times, in the order required. For example:

EP GAZZEL1.DSK /B /D    ' existing table is cleared (with /D) and the disk image is added and set as boot disk
EP GAZZEL2.DSK          ' disk image added to the table
EP GAZZEL3.DSK          ' disk image added to the table
EP GAZZEL4.DSK /R       ' disk image added to the table & system will reboot, with GAZZEL1.DSK as active disk

Note: after each invocation, the added disk image number (0 through F) and name are printed. There is no way to print out the full table. When trying to add a 17th image, an error is printed.

All options:

d  : drive letter to assign (A:~H:)
/F : force allocation of partitions that are already assigned
/W : write-protect the drive
/B : start the software, i.e., boot
/Bx: number of disks to boot from (0~Fh)
/D : initialize, then set ("destroy") the extended partition table
/R : reset after loading

For multidisk games, SPLITIT.COM (included in OCM-SDBIOS Pack tools and OCM-PLD msxtools) might come in handy. Whereas SofaRun expects one concatenated image for all disks combined, EP expects one file per disk image.

SPLITIT [/Dn]|[/L] [D:][PATH]FILENAME.EXT
    -Dn extract disk nummer from image
      n = 0 to 9
     /L extract last disk from image 

EP IMAGE*.DSK /B/D/R

To select a disk image:

  • hold KANA (F7 on MSX++) until the CAPS LED flashes
    • hold KANA during boot in case the images were not ordered sequentially
    • ⚠ KANA is only checked when the disk is being accessed by the application, just like SofaRun. So you can't change disks whenever.
  • press 0, 1, .., 9 to select disk image 1 through 10
    • On the numeric keypad, '0123456789.,+-*/' corresponds to disks 0 through 15

EP will "eject" the floppy by pushing GRAPH + INS during boot - but that is only useful when doing a soft boot; the OCM reset button will wipe the VFD settings as well.

B. when using EP.COM directly ends in a black screen (for programs that expect 2 drives):

  1. run ESET.COM to connect drive B:, as follows:
    • [E]ASY setup
    • [C]onnect drive
    • [N]umber of drives
    • enter '2' for two drives (A: and B:) - observe the following output: (B: has now been added; ignore the '-- error')
      A: ID0 -- error
      B: ID1 -- error
         ID2 -- error
      (etc)
      
    • [S]etup
    • press 'y' to confirm the choice for 2 drives
    • press ESC
    • [Q]uit
  2. GETRESET
    • after boot you'll notice drive B is known (B: works; C: fails with *** Invalid drive) but has no data (DIR B: fails with *** Invalid drive)
  3. insert .DSK with EP.COM
    • EP IMAGE.DSK B: will now work, but you'll probably want to run EP IMAGE.DSK /B /R which will boot the program with 2 drives recognized

C. last resort

  1. create and boot into an SDBIOS with two drives with Disk-ROM choice "MegaSDHC FAT16X Double SD-slot"
  2. mount .DSK like in A.

Note that this last alternative is incompatible with games that require CTRL held at boot to initialize a single drive (to conserve memory). As KdL describes it: "the MegaSD kernel is unable to disable the B: drive by pressing CTRL key."

How to save RTC data

So, there is no (battery-powered or otherwise) persistent CMOS on an MSX++. The tool RTCSAVE.COM comes to the rescue. It requires SD-BIOS; does not work for (internal) EPBIOS. What it will do is patch your OCM-BIOS.DAT file at the appropriate MSX Main & Sub ROM locations. This has the effect that the next time you boot up your MSX++, these values are used inside the BIOS as the initial values! So if you expected to see a new file being created on your μSD-card, like me, then you would have been as confused as I was. (I actually had to look into the code to find this out; the documentation doesn't mention this.)

Note that RTCSAVE.COM V3.0 expects to find OCM-BIOS.DAT at a specific location on disk. If you have firmware v3.9.1 (or newer) and booted from an OCM-BIOS.DAi (i=T,0-9) not stored at the very first cluster, RTCSAVE will damage your files. Make sure to use RTCSAVE V3.1, released with OCM-PLD v3.9.2.

To verify the update, run SETSMART -F8FD (on SX2 and related). Or hold the reset button (>1sec). This will reload the SDBIOS.

OCM-PLD msxtools comes with an example BASIC program that demonstrates the usage:

10 SCREEN 0,2,0,1,0,0: WIDTH 80: COLOR 15,4,7: LOCATE ,,0
20 KEY ON: SET BEEP 1,3: SET TITLE "",1: SET ADJUST (0,0)
30 SET SCREEN: CALL SYSTEM("RTCSAVE^ECHO")

More information about these commands:

  • SCREEN: six parameters, a.o., key click, cassette 1200/2400 baud, printer, interlace mode
  • LOCATE
  • KEY
  • BEEP
  • ADJUST
  • only one of these can be active at a time:
    • TITLE - including boot screen color palette!, or
    • PROMPT

As you can see in that example, the MSX RTC contains more than just date/time. In fact, all RTC ("Real Time Clock") data is saved except date & time. What do you think about that? 🙂 That makes the name 'RTCSAVE' a bit of a misnomer. Use ESP8266 Wi-Fi to get an NTP-synchronised clock at boot.

For those interested: from the code of RTCSAVE I read that blocks 1-3, register 0-13 are saved. (Note that, strictly speaking, register 13 isn't defined, but this makes it an even amount.) That RTC data is stored in the Sub-ROM at addresses 3FC6-3FDB (3 * 14 nibbles = 21 Bytes). The Sub-ROM has been patched at 037B-037C (hook) and 3F9C-3FE7 (code, jump back, data and marker) for this purpose. The active color is also stored in the Main-ROM at 3F90-3F92, unless you run RTCSAVE.COM /X.

There are three other command line options:

  • /A: save COLOR foregr,border,border as found in RTC memory
  • /B: save fixed COLOR white,black,black: (15,0,0)
  • /C: save COLOR from System Variables in RAM

Even more detail:

  • As said, date&time are not stored - that makes up block 0.
  • Block 1 contains AM/PM or 24-hour display setting (MSX2 and up seems to always use 24h, 2-bit leap year counter, optional alarm date/time
    • which "Fire Hawk - Thexder The Second Contact" uses to store start stage number!
  • Block 2 stores most of the settings in the BASIC example above
    • Register 12 stores the area code (0-10) but it seems not well-used. It cannot easily be read & written in BASIC.
  • Block 3 stores the password, prompt or title. Some applications use it to instead store specific data.

How to use MIDI out

The 8bits4ever page simply says: "MIDI out (joystick port 2)."

In the OCM-PLD Pack there is docs\joystick to midi cable.pdf, which is just 1 page. The arduino.cc URL mentioned there is no longer valid; now see https://web.archive.org/web/20170223221407/https://www.arduino.cc/en/Tutorial/Midi/. It describes how to do the same using an Arduino.

You'll have to solder the cable yourself. And of course you need a MIDI-in device to turn the notes into audible music.

Cable wiring:

DB9/DE9 female DIN5 male
Joy pin-1 (DATA) 220 Ohm resistor MIDI jack pin-5
Joy pin-5 (+5V) 220 Ohm resistor MIDI jack pin-4
Joy pin-9 (GND) direct wire MIDI jack pin-2

The MIDRY tool (1995-1997) can be used to play MIDI files: MIDRY.COM /i5 <file>.MID. Unfortunately, this tool is not widely described on the internet. The accompanying manual is all in Japanese.

A Japanese-to-English translation attempt:

The above joystick-to-MIDI-cable setup is described on MRC as JoyMIDI. For JoyMIDI, no additional ICs are required, like a serial UART, to do all the data transfer. Instead, this setup relies totally on the Z80. This simplicity comes at the cost of CPU capacity. MRC calls this 'bitbanging'. The JoyMIDI cable is not specific to MSX++. Once you have soldered it, you can use it on any MSX.

But wait! Parameter /i5, according to the translated documentation, selects: "MSX-MIDI 1 series [..] or internal"! OCM-PLD indeed implements MSX-MIDI I/O ports E8-E9h, with UART to offload the Z80. It is not a full implementation of MSX-MIDI, but appears to be just enough.

Running MIDRY.COM /i32 <file>.MID should have the same result (on any MSX!): MIDI played over joystick port 2 (/i31 selects joystick port 1). Although then, the Z80 is actually doing hard work on bitbanging.

JoyMIDI, Tada MIDI & more

JoyMIDI is also described by Henrik Gilvad (1992) in the archive of the Dutch MSX Computer Magazine. It mentions the same resistors as the Arduino project, and suggests an optional Zener diode. There is FAC SoundTracker 2 driver software & code available in the Hans Otten archive.

Another project called Tada MIDI uses the MSX Centronics printer port. Schematics are published in MSX-FAN magazine Oct-1994. It uses the same resistors and DIN5 pins, except MIDI pin-2 (GND) - that isn't connected. Note that Tada MIDI and JoyMIDI aren't compatible, since one uses the printer port and the other a joystick port. So different software is required - although MIDRY supports both.

Final note: this youtube video called "MSX Arduino MIDI test (Midry)" is captioned: "Playing a MIDI file on MSX (SX1-mini+) running Midry [..]" - which initially led me to think it's showing how to set up MIDI on MSX++. But the rest of the caption reads: "[..] using an Arduino Mega and a MIDI shield attached through the cartridge port, MIDI out to Edirol SD-20 sound module." So, although there are a few common parts, this video does something more complicated.

⚠️ **GitHub.com Fallback** ⚠️