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

  <info>
    <manufacturer>Philips</manufacturer>
    <code>NMS 8220</code>
    <release_year>1986</release_year>
    <description/>
    <type>MSX2</type>
  </info>

  <!-- There are two ROM chips: the "1M MASK ROM" which says M531000-52 KYOCERA INT
                                                            (C) 1986 68517 MICROSOFT
       Note that this is a 128kB mask ROM of which only 48kB is used. It even contains
       a disk ROM! Thanks to Tristan Zondag for finding this out.
       and the APPLICATION ROM (containing the Designer program).
   -->

  <MapperReadBackBits>largest</MapperReadBackBits>

  <CassettePort/>

  <devices>

    <PPI id="ppi">
      <sound>
        <volume>16000</volume>
      </sound>
      <io base="0xA8" num="4"/>
      <keyboard_type>int</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">
      <version>V9938</version>
      <vram>128</vram>
      <io base="0x98" num="8" type="O"/> <!-- S-3527 mirrors -->
      <io base="0x98" num="8" type="I"/> <!-- S-3527 mirrors -->
    </VDP>

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

    <RTC id="Real time clock">
      <sramname>nms_8220.cmos</sramname>
      <io base="0xB4" num="2" type="O"/>
      <io base="0xB5" num="1" type="I"/>
    </RTC>

    <PrinterPort id="Printer Port">
      <io base="0x90" num="2"/>
    </PrinterPort>

    <primary slot="0">
      <ROM id="MSX BIOS with BASIC ROM">
        <rom>
          <filename>NMS8220SystemROM.bin</filename>
          <sha1>e761e7081c613ad4893a664334ce105841d0e80e</sha1> <!-- 1M MASK ROM dump by Tristan Zondag -->
          <window base="0x10000" size="0x8000"/>
        </rom>
        <rom>
          <filename>nms8220_basic-bios2.rom</filename>
          <sha1>6103b39f1e38d1aa2d84b1c3219c44f1abb5436e</sha1>
        </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>
            <filename>NMS8220SystemROM.bin</filename>
            <sha1>e761e7081c613ad4893a664334ce105841d0e80e</sha1> <!-- 1M MASK ROM dump by Tristan Zondag -->
            <window base="0x18000" size="0x4000"/>
          </rom>
          <rom>
            <filename>nms8220_msx2sub.rom</filename>
            <sha1>f5eb0a396097572589f2a6efeed045044e9425e4</sha1> <!-- confirmed by Luc on 8220/00 -->
          </rom>
          <mem base="0x0000" size="0x4000"/> <!-- NO mirroring -->
        </ROM>
      </secondary>

      <secondary slot="1"/>

      <secondary slot="2">
        <MemoryMapper id="Main RAM">
          <size>64</size>
          <initialContent encoding="gz-base64">eNpj+M8wouEI9z4DAJBx/wE=</initialContent> <!-- (chr(0) + chr(255)) * 128 + (chr(255)+ chr(0)) * 128) -->
          <mem base="0x0000" size="0x10000"/>
        </MemoryMapper>
      </secondary>

      <secondary slot="3">
        <ROM id="MSX Designer">
          <rom>
            <filename>nms8220_designer.rom</filename>
            <sha1>cb754aed85b3e97a7d3c5894310df7ca18f89f41</sha1> <!-- version 12-06-1986 -->
            <sha1>5df95d033ae70b107697b69470126ce1b7ae9eb5</sha1> <!-- version 13-08-1986 -->
          </rom>
          <mem base="0x4000" size="0x8000"/> <!-- ROM is mirrored in page 2 -->
        </ROM>
      </secondary>

    </primary>

  </devices>

</msxconfig>
