<?xml version="1.0" ?>
<!DOCTYPE msxconfig SYSTEM 'msxconfig2.dtd'>
<msxconfig>

  <info>
    <manufacturer>Yamaha</manufacturer>
    <code>CX5MII/128</code>
    <release_year>1985</release_year>
    <description>Japanese MSX with MSX2 videochip, 128kB RAM and SFG-05 module built in.</description>
    <type>MSX</type>
    <region>jp</region>
  </info>

  <MapperReadBackBits>largest</MapperReadBackBits>

  <CassettePort/>

  <devices>

    <PPI id="ppi">
      <sound>
        <volume>16000</volume>
      </sound>
      <io base="0xA8" num="8"/> <!-- S-3527 mirrors -->
      <keyboard_type>jp_ansi</keyboard_type>
      <has_keypad>false</has_keypad>
      <key_ghosting_sgc_protected>true</key_ghosting_sgc_protected>
      <code_kana_locks>false</code_kana_locks>
      <graph_locks>false</graph_locks>
    </PPI>

    <VDP id="VDP">
      <io base="0x98" num="8" type="O"/> <!-- S-3527 mirrors -->
      <io base="0x98" num="8" type="I"/> <!-- S-3527 mirrors -->
      <version>V9938</version>
      <vram>128</vram>
    </VDP>

    <PSG id="PSG">
      <type>YM2149</type> <!-- in S-3527 MSX-ENGINE -->
      <sound>
        <volume>21000</volume>
      </sound>
      <io base="0xA0" num="8" type="IO"/> <!-- S-3527 mirrors -->
      <ignorePortDirections>true</ignorePortDirections> <!-- not sure, but guess based on use of Engine IC -->
    </PSG>

    <PrinterPort id="Printer Port">
      <io base="0x90" num="8" type="IO"/> <!-- S-3527 mirrors -->
      <status_readable_on_all_ports>true</status_readable_on_all_ports> <!-- S-3527 property -->
    </PrinterPort>

    <primary slot="0">
      <ROM id="MSX BIOS with BASIC ROM">
        <rom>
          <sha1>ea4a723cf098be7d7b40f23a7ab831cf5e2190d7</sha1> <!-- From Gerrit's machine -->
          <sha1>521928db7bc81a8db4cac1e666851e2bf01c8d53</sha1>
          <filename>cx5mii-128_basic-bios1.rom</filename>
        </rom>
        <mem base="0x0000" size="0x8000"/>
      </ROM>
    </primary>

    <primary external="true" slot="1"/>

    <primary external="true" slot="2"/>

    <primary slot="3">

      <secondary slot="0">
        <ROM id="MSX Sub ROM">
          <rom>
            <sha1>c2340313bfda751181e8a5287d60f77bc6a2f3e6</sha1> <!-- From Gerrit's machine -->
            <sha1>df503d6f5d72a2a355db53c35950348fb7c767bf</sha1>
            <filename>cx5mii-128_sub.rom</filename>
          </rom>
          <mem base="0x4000" size="0x4000"/>
        </ROM>
      </secondary>

    <!-- Note that this device can be plugged out. What is left is not a standard MSX cartridgeslot, but a kind of mini cartridgeslot. -->
      <secondary slot="1">
        <ROM id="FM Voicing Program II">
          <rom>
            <sha1>30747a56f45389be76362f7fc55d673f1bff8312</sha1>
            <filename>cx5mii-128_fmvoicingprogramii.rom</filename>
          </rom>
          <mem base="0x4000" size="0x4000"/>
        </ROM>
      </secondary>

      <secondary slot="2">
        <MemoryMapper id="Main RAM">
          <size>128</size>
          <mem base="0x0000" size="0x10000"/>
        </MemoryMapper>
      </secondary>

    <!-- Note that this device can be plugged out. What is left is not a
    standard MSX cartridgeslot, but a 60 pins card edge connector, carrying all
    MSX cartridgeslot signals. -->
      <secondary slot="3">
        <YamahaSFG id="Yamaha SFG-05">
          <variant>YM2164</variant>
          <mem base="0x0000" size="0x10000"/>
          <sound>
            <volume>30000</volume>
          </sound>
          <rom>
            <sha1>6680d7118d85418813f1db9449bf3e20942b16da</sha1>
            <filename>sfg-05.rom</filename>
          </rom>
        </YamahaSFG>
      </secondary>

    </primary>

  </devices>

</msxconfig>
