]> git.unchartedbackwaters.co.uk Git - francis/winuae.git/commitdiff
3600b8
authorToni Wilen <twilen@winuae.net>
Sun, 19 Nov 2017 15:03:00 +0000 (17:03 +0200)
committerToni Wilen <twilen@winuae.net>
Sun, 19 Nov 2017 15:03:00 +0000 (17:03 +0200)
22 files changed:
archivers/wrp/warp.cpp
autoconf.cpp
cfgfile.cpp
expansion.cpp
filesys.cpp
hardfile.cpp
include/autoconf.h
include/filesys.h
include/options.h
include/zfile.h
inputrecord.cpp
main.cpp
memory.cpp
od-win32/resources/resource.h
od-win32/resources/winuae.rc
od-win32/rp.cpp
od-win32/win32.h
od-win32/win32gui.cpp
od-win32/winuae_msvc15/winuae_msvc.vcxproj
od-win32/winuaechangelog.txt
savestate.cpp
zfile.cpp

index 6fe49f08be63c2c2cee3a421d8e9dfbece157448..204235a0a2dfb1ce39df4084c1a1b579abe544ff 100644 (file)
@@ -456,7 +456,7 @@ struct zfile *unwarp(struct zfile *zf)
                } else {
                        uae_u16 crc2;
                        int os = zfile_ftell (tmpf);
-                       data = zfile_getdata (tmpf, 0, os);
+                       data = zfile_getdata (tmpf, 0, os, NULL);
                        crc2 = wrpcrc16 (wrpcrc16table, data, os);
                        if (crc != crc2)
                                write_log (_T("WRP crc error %04x<>%04x, track=%d,side=%d\n"), crc, crc2, track, side);
@@ -464,7 +464,7 @@ struct zfile *unwarp(struct zfile *zf)
                }
                if (dstpos >= 0) {
                        zfile_fseek (nf, dstpos, SEEK_SET);
-                       data = zfile_getdata (tmpf, 0, outsize);
+                       data = zfile_getdata (tmpf, 0, outsize, NULL);
                        zfile_fwrite (data, outsize, 1, nf);
                }
                zfile_fseek (zf, pos + size, SEEK_SET);
index 44048f25995806f12e7954097f8dbe5786c52313..9e2b6bac13b460a24f64f059c5dc05bb4f5b6ba8 100644 (file)
@@ -364,6 +364,12 @@ void dl (uae_u32 data)
        rtarea_bank.baseaddr[rt_addr++] = data;
 }
 
+void df(uae_u8 b, int len)
+{
+       memset(&rtarea_bank.baseaddr[rt_addr], b, len);
+       rt_addr += len;
+}
+
 uae_u8 dbg (uaecptr addr)
 {
        addr -= rtarea_base;
@@ -394,6 +400,13 @@ uae_u32 ds (const TCHAR *str)
        return v;
 }
 
+uae_u32 dsf(uae_u8 b, int len)
+{
+       rt_straddr -= len;
+       memset(rtarea_bank.baseaddr + rt_straddr, b, len);
+       return addr(rt_straddr);
+}
+
 uae_u32 ds_bstr_ansi (const uae_char *str)
 {
        int len;
index fd869a46ad00587e3f75030e120ab3425efa36ef..efd838b666b9b064a390c4cdf581fab76be0b8c6 100644 (file)
@@ -241,6 +241,7 @@ static const int leds_order[] = { 3, 6, 7, 8, 9, 4, 5, 2, 1, 0, 9 };
 static const TCHAR *lacer[] = { _T("off"), _T("i"), _T("p"), 0 };
 /* another boolean to choice update.. */
 static const TCHAR *cycleexact[] = { _T("false"), _T("memory"), _T("true"), 0  };
+static const TCHAR *unmapped[] = { _T("floating"), _T("zero"), _T("one"), 0 };
 
 struct hdcontrollerconfig
 {
@@ -286,6 +287,13 @@ static const TCHAR *uaeboard[] = {
        _T("full+indirect"),
        NULL
 };
+static const TCHAR *uaeboard_off[] = {
+       _T("disabled_off"),
+       _T("min_off"),
+       _T("full_off"),
+       _T("full+indirect_off"),
+       NULL
+};
 
 static const TCHAR *serialcrlf[] = {
        _T("disabled"),
@@ -1838,7 +1846,10 @@ void cfgfile_save_options (struct zfile *f, struct uae_prefs *p, int type)
        cfgfile_write_bool (f, _T("synchronize_clock"), p->tod_hack);
        cfgfile_write (f, _T("maprom"), _T("0x%x"), p->maprom);
        cfgfile_dwrite_str (f, _T("boot_rom_uae"), uaebootrom[p->boot_rom]);
-       cfgfile_dwrite_str(f, _T("uaeboard"), uaeboard[p->uaeboard]);
+       if (p->uaeboard_nodiag)
+               cfgfile_write_str(f, _T("uaeboard"), uaeboard_off[p->uaeboard]);
+       else
+               cfgfile_dwrite_str(f, _T("uaeboard"), uaeboard[p->uaeboard]);
        if (p->autoconfig_custom_sort)
                cfgfile_dwrite(f, _T("uaeboard_options"), _T("order=%d"), p->uaeboard_order);
        cfgfile_dwrite_str (f, _T("parallel_matrix_emulation"), epsonprinter[p->parallel_matrix_emulation]);
@@ -2147,7 +2158,7 @@ void cfgfile_save_options (struct zfile *f, struct uae_prefs *p, int type)
        cfgfile_dwrite_bool(f, _T("z3_autoconfig"), p->cs_z3autoconfig);
        cfgfile_dwrite_bool(f, _T("1mchipjumper"), p->cs_1mchipjumper);
        cfgfile_dwrite_bool(f, _T("color_burst"), p->cs_color_burst);
-       cfgfile_dwrite_bool(f, _T("unmapped_zero"), p->cs_unmapped_zero);
+       cfgfile_dwrite_str(f, _T("unmapped_address_space"), unmapped[p->cs_unmapped_space]);
        cfgfile_dwrite (f, _T("chipset_hacks"), _T("0x%x"), p->cs_hacks);
 
        if (is_board_enabled(p, ROMTYPE_CD32CART, 0)) {
@@ -4163,7 +4174,7 @@ static void get_filesys_controller (const TCHAR *hdc, int *type, int *typenum, i
 static bool parse_geo (const TCHAR *tname, struct uaedev_config_info *uci, struct hardfiledata *hfd, bool empty)
 {
        int found = 0;
-       TCHAR section[200];
+       TCHAR tmp[200], section[200];
        struct ini_data *ini;
        bool ret = false;
 
@@ -4171,21 +4182,26 @@ static bool parse_geo (const TCHAR *tname, struct uaedev_config_info *uci, struc
        if (!ini)
                return ret;
 
-       _tcscpy(section, _T("empty"));
-       if (empty && ini_getstring(ini, section, NULL, NULL)) {
+       _tcscpy(tmp, _T("empty"));
+       section[0] = 0;
+       if (empty && ini_getstring(ini, tmp, NULL, NULL)) {
+               _tcscpy(section, tmp);
                found = 1;
        }
-       _tcscpy(section, _T("default"));
-       if (!empty && ini_getstring(ini, section, NULL, NULL)) {
+       _tcscpy(tmp, _T("default"));
+       if (!empty && ini_getstring(ini, tmp, NULL, NULL)) {
+               _tcscpy(section, tmp);
                found = 1;
        }
-       _tcscpy(section, _T("geometry"));
-       if (ini_getstring(ini, section, NULL, NULL)) {
+       _tcscpy(tmp, _T("geometry"));
+       if (ini_getstring(ini, tmp, NULL, NULL)) {
+               _tcscpy(section, tmp);
                found = 1;
        }
        if (hfd) {
-               _stprintf(section, _T("%llu"), hfd->virtsize);
-               if (ini_getstring(ini, section, NULL, NULL)) {
+               _stprintf(tmp, _T("%llu"), hfd->virtsize);
+               if (ini_getstring(ini, tmp, NULL, NULL)) {
+                       _tcscpy(section, tmp);
                        found = 1;
                }
        }
@@ -4199,8 +4215,12 @@ static bool parse_geo (const TCHAR *tname, struct uaedev_config_info *uci, struc
                for (;;) {
                        TCHAR *key = NULL, *val = NULL;
                        int v;
+
                        if (!ini_getsectionstring(ini, section, idx, &key, &val))
                                break;
+
+                       //write_log(_T("%s:%s\n"), key, val);
+
                        if (val[0] == '0' && _totupper (val[1]) == 'X') {
                                TCHAR *endptr;
                                v = _tcstol (val, &endptr, 16);
@@ -5010,7 +5030,6 @@ static int cfgfile_parse_hardware (struct uae_prefs *p, const TCHAR *option, TCH
                || cfgfile_yesno(option, value, _T("ics_agnus"), &p->cs_dipagnus)
                || cfgfile_yesno(option, value, _T("z3_autoconfig"), &p->cs_z3autoconfig)
                || cfgfile_yesno(option, value, _T("color_burst"), &p->cs_color_burst)
-               || cfgfile_yesno(option, value, _T("unmapped_zero"), &p->cs_unmapped_zero)
                || cfgfile_yesno(option, value, _T("1mchipjumper"), &p->cs_1mchipjumper)
                || cfgfile_yesno(option, value, _T("agnus_bltbusybug"), &p->cs_agnusbltbusybug)
                || cfgfile_yesno(option, value, _T("gfxcard_hardware_vblank"), &p->rtg_hardwareinterrupt)
@@ -5107,11 +5126,20 @@ static int cfgfile_parse_hardware (struct uae_prefs *p, const TCHAR *option, TCH
                || cfgfile_strval (option, value,  _T("z3mapping"), &p->z3_mapping_mode, z3mapping, 0)
                || cfgfile_strval (option, value,  _T("scsidev_mode"), &p->uaescsidevmode, uaescsidevmodes, 0)
                || cfgfile_strval(option, value, _T("boot_rom_uae"), &p->boot_rom, uaebootrom, 0)
-               || cfgfile_strval(option, value, _T("uaeboard"), &p->uaeboard, uaeboard, 0)
                || cfgfile_strval (option, value,  _T("serial_translate"), &p->serial_crlf, serialcrlf, 0)
+               || cfgfile_strval(option, value, _T("unmapped_address_space"), &p->cs_unmapped_space, unmapped, 0)
                || cfgfile_strboolval (option, value, _T("comp_flushmode"), &p->comp_hardflush, flushmode, 0))
                return 1;
 
+       if (cfgfile_strval(option, value, _T("uaeboard"), &p->uaeboard, uaeboard_off, 1)) {
+               p->uaeboard_nodiag = true;
+               return 1;
+       }
+       if (cfgfile_strval(option, value, _T("uaeboard"), &p->uaeboard, uaeboard, 0)) {
+               p->uaeboard_nodiag = false;
+               return 1;
+       }
+
        if (cfgfile_path (option, value, _T("kickstart_rom_file"), p->romfile, sizeof p->romfile / sizeof (TCHAR), &p->path_rom)
                || cfgfile_path (option, value, _T("kickstart_ext_rom_file"), p->romextfile, sizeof p->romextfile / sizeof (TCHAR), &p->path_rom)
                || cfgfile_path (option, value, _T("kickstart_ext_rom_file2"), p->romextfile2, sizeof p->romextfile2 / sizeof (TCHAR), &p->path_rom)
@@ -7144,7 +7172,7 @@ void default_prefs (struct uae_prefs *p, bool reset, int type)
        p->cs_slowmemisfast = 0;
        p->cs_resetwarning = 1;
        p->cs_ciatodbug = false;
-       p->cs_unmapped_zero = false;
+       p->cs_unmapped_space = 0;
        p->cs_color_burst = false;
 
        for (int i = APMODE_NATIVE; i <= APMODE_RTG; i++) {
@@ -7753,7 +7781,7 @@ static int bip_cd32 (struct uae_prefs *p, int config, int compa, int romcheck)
        p->nr_floppies = 0;
        p->floppyslots[0].dfxtype = DRV_NONE;
        p->floppyslots[1].dfxtype = DRV_NONE;
-       p->cs_unmapped_zero = true;
+       p->cs_unmapped_space = 1;
        set_68020_compa (p, compa, 1);
        p->cs_compatible = CP_CD32;
        built_in_chipset_prefs (p);
@@ -7976,7 +8004,7 @@ static int bip_super (struct uae_prefs *p, int config, int compa, int romcheck)
        p->cart_internal = 0;
        p->picasso96_nocustom = 1;
        p->cs_compatible = 1;
-       p->cs_unmapped_zero = true;
+       p->cs_unmapped_space = 1;
        built_in_chipset_prefs (p);
        p->cs_ide = -1;
        p->cs_ciaatod = p->ntscmode ? 2 : 1;
@@ -8110,7 +8138,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
        p->cs_z3autoconfig = false;
        p->cs_bytecustomwritebug = false;
        p->cs_1mchipjumper = false;
-       p->cs_unmapped_zero = false;
+       p->cs_unmapped_space = 0;
 
        switch (p->cs_compatible)
        {
@@ -8122,7 +8150,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
                        p->cs_ide = -1;
                        p->cs_mbdmac = 0;
                        p->cs_ramseyrev = 0x0f;
-                       p->cs_unmapped_zero = true;
+                       p->cs_unmapped_space = 1;
                } else if (p->cpu_compatible) {
                        // very A500-like
                        p->cs_df0idhw = 0;
@@ -8161,7 +8189,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
                p->cs_ksmirror_a8 = 1;
                p->cs_ciaoverlay = 0;
                p->cs_resetwarning = 0;
-               p->cs_unmapped_zero = true;
+               p->cs_unmapped_space = 1;
                break;
        case CP_A500: // A500
                p->cs_df0idhw = 0;
@@ -8210,7 +8238,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
                p->cs_rtc = 1;
                p->cs_ciaatod = p->ntscmode ? 2 : 1;
                p->cs_ciatodbug = true;
-               p->cs_unmapped_zero = true;
+               p->cs_unmapped_space = 1;
                break;
        case CP_A3000: // A3000
                p->cs_rtc = 2;
@@ -8220,7 +8248,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
                p->cs_ksmirror_e0 = 0;
                p->cs_ciaatod = p->ntscmode ? 2 : 1;
                p->cs_z3autoconfig = true;
-               p->cs_unmapped_zero = true;
+               p->cs_unmapped_space = 1;
                break;
        case CP_A3000T: // A3000T
                p->cs_rtc = 2;
@@ -8230,7 +8258,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
                p->cs_ksmirror_e0 = 0;
                p->cs_ciaatod = p->ntscmode ? 2 : 1;
                p->cs_z3autoconfig = true;
-               p->cs_unmapped_zero = true;
+               p->cs_unmapped_space = 1;
                break;
        case CP_A4000: // A4000
                p->cs_rtc = 2;
@@ -8242,7 +8270,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
                p->cs_ksmirror_e0 = 0;
                p->cs_ciaoverlay = 0;
                p->cs_z3autoconfig = true;
-               p->cs_unmapped_zero = true;
+               p->cs_unmapped_space = 1;
                break;
        case CP_A4000T: // A4000T
                p->cs_rtc = 2;
@@ -8254,7 +8282,7 @@ int built_in_chipset_prefs (struct uae_prefs *p)
                p->cs_ksmirror_e0 = 0;
                p->cs_ciaoverlay = 0;
                p->cs_z3autoconfig = true;
-               p->cs_unmapped_zero = true;
+               p->cs_unmapped_space = 1;
                break;
        }
        if (p->cpu_model >= 68040)
index 52fed2f9ec997ab861bac194cc8d9f22fe865463..a153615c59e166cec2a7c2766d5c1ad18c84a5b9 100644 (file)
@@ -1369,6 +1369,24 @@ static bool set_params_filesys(struct uae_prefs *prefs, struct expansion_params
        return true;
 }
 
+static void add_rtarea_pointer(struct autoconfig_info *aci)
+{
+       if (aci->doinit) {
+               uaecptr addr = 0;
+               if (aci->prefs->uaeboard > 1) {
+                       addr = aci->start + 0x10000;
+               } else if (aci->prefs->uaeboard == 1) {
+                       addr = rtarea_base;
+               }
+               if (addr) {
+                       expamem[0x48] = addr >> 24;
+                       expamem[0x49] = addr >> 16;
+                       expamem[0x4a] = addr >> 8;
+                       expamem[0x4b] = addr >> 0;
+               }
+       }
+}
+
 static bool expamem_init_uaeboard(struct autoconfig_info *aci)
 {
        bool ks12 = ks12orolder();
@@ -1382,7 +1400,7 @@ static bool expamem_init_uaeboard(struct autoconfig_info *aci)
        aci->set_params = set_params_filesys;
 
        expamem_init_clear();
-       expamem_write(0x00, (p->uaeboard > 1 ? Z2_MEM_128KB : Z2_MEM_64KB) | zorroII | (ks12 || !rom ? 0 : rom_card));
+       expamem_write(0x00, (p->uaeboard > 1 ? Z2_MEM_128KB : Z2_MEM_64KB) | zorroII | (ks12 || !rom || p->uaeboard_nodiag ? 0 : rom_card));
 
        expamem_write(0x08, no_shutup);
 
@@ -1393,10 +1411,12 @@ static bool expamem_init_uaeboard(struct autoconfig_info *aci)
        expamem_write(0x18, 0x00); /* ser.no. Byte 0 */
        expamem_write(0x1c, 0x00); /* ser.no. Byte 1 */
        expamem_write(0x20, p->uaeboard); /* ser.no. Byte 2 */
-       expamem_write(0x24, 0x02); /* ser.no. Byte 3 */
+       expamem_write(0x24, 0x03); /* ser.no. Byte 3 */
 
        uae_u8 *ptr = uaeboard_bank.baseaddr;
 
+       add_rtarea_pointer(aci);
+
        if (rom) {
 
                int diagoffset = 0x80;
@@ -1787,43 +1807,24 @@ static addrbank *expamem_map_filesys (struct autoconfig_info *aci)
 }
 
 #if KS12_BOOT_HACK
-static void add_ks12_boot_hack(void)
-{
-       uaecptr name = ds(_T("UAE boot"));
-       align(2);
-       uaecptr code = here();
-       // allocate fake diagarea
-       dl(0x48e73f3e); // movem.l d2-d7/a2-a6,-(sp)
-       dw(0x203c); // move.l #x,d0
-       dl(0x0300);
-       dw(0x7201); // moveq #1,d1
-       dl(0x4eaeff3a); // jsr -0xc6(a6)
-       dw(0x2440); // move.l d0,a2 ;diag area
-       dw(0x9bcd); // sub.l a5,a5 ;expansionbase
-       dw(0x97cb); // sub.l a3,a3 ;configdev
-       dw(0x4eb9); // jsr
-       dl(ROM_filesys_diagentry);
-       dl(0x4cdf7cfc); // movem.l (sp)+,d2-d7/a2-a6
-       dw(0x4e75);
-       // struct Resident
-       uaecptr addr = here();
-       dw(0x4afc);
-       dl(addr);
-       dl(addr + 26);
-       db(1); // RTF_COLDSTART
-       db((uae_u8)kickstart_version); // version
-       db(0); // NT_UNKNOWN
-       db(1); // priority
-       dl(name);
-       dl(name);
-       dl(code);
+extern uaecptr ks12_resident;
+static void set_ks12_boot_hack(bool enable)
+{
+       uaecptr old = here();
+       org(ks12_resident);
+       dw(enable ? 0x4afc : 0x0000);
+       org(ks12_resident + 9);
+       db((uae_u8)kickstart_version);
+       org(old);
 }
 #endif
 
 static bool expamem_init_filesys(struct autoconfig_info *aci)
 {
+       struct uae_prefs *p = aci->prefs;
        bool ks12 = ks12orolder();
-       bool hide = currprefs.uae_hide_autoconfig;
+       bool hide = p->uae_hide_autoconfig;
+       bool rom = !(ks12 || !do_mount || p->uaeboard_nodiag);
 
        if (aci) {
                aci->label = ks12 ? _T("Pre-KS 1.3 UAE FS ROM") : _T("UAE FS ROM");
@@ -1852,25 +1853,27 @@ static bool expamem_init_filesys(struct autoconfig_info *aci)
        };
 
        expamem_init_clear ();
-       expamem_write (0x00, Z2_MEM_64KB | zorroII | (ks12 || !do_mount ? 0 : rom_card));
+       expamem_write (0x00, Z2_MEM_64KB | zorroII | (rom ? rom_card : 0));
 
        expamem_write (0x08, no_shutup);
 
-       expamem_write (0x04, currprefs.maprom && !currprefs.cpuboard_type ? 2 : 82);
+       expamem_write (0x04, p->maprom && !p->cpuboard_type ? 2 : 82);
        expamem_write (0x10, uae_id >> 8);
        expamem_write (0x14, uae_id & 0xff);
 
        expamem_write (0x18, 0x00); /* ser.no. Byte 0 */
        expamem_write (0x1c, 0x00); /* ser.no. Byte 1 */
        expamem_write (0x20, 0x00); /* ser.no. Byte 2 */
-       expamem_write (0x24, 0x01); /* ser.no. Byte 3 */
+       expamem_write (0x24, 0x03); /* ser.no. Byte 3 */
 
        /* er_InitDiagVec */
-       expamem_write (0x28, 0x20); /* ROM-Offset hi */
+       expamem_write (0x28, rom ? 0x20 : 0x00); /* ROM-Offset hi */
        expamem_write (0x2c, 0x00); /* ROM-Offset lo */
 
        expamem_write (0x40, 0x00); /* Ctrl/Statusreg.*/
 
+       add_rtarea_pointer(aci);
+
        if (aci && !aci->doinit) {
                memcpy(aci->autoconfig_raw, expamem, sizeof aci->autoconfig_raw);
                return true;
@@ -1880,7 +1883,7 @@ static bool expamem_init_filesys(struct autoconfig_info *aci)
        memcpy (expamem + FILESYS_DIAGAREA, diagarea, sizeof diagarea);
 
        put_word_host(expamem + FILESYS_DIAGAREA + FILESYS_DIAGPOINT + 0,
-               0x7000 | (currprefs.uaeboard > 2 ? 1 : 0) | (currprefs.uae_hide_autoconfig || currprefs.uaeboard > 1 ? 0 : 2)); // MOVEQ #x,D0
+               0x7000 | (p->uaeboard > 2 ? 1 : 0) | (p->uae_hide_autoconfig || p->uaeboard > 1 ? 0 : 2)); // MOVEQ #x,D0
        /* Call hwtrap_install */
        put_word_host(expamem + FILESYS_DIAGAREA + FILESYS_DIAGPOINT + 2, 0x4EB9); /* JSR */
        put_long_host(expamem + FILESYS_DIAGAREA + FILESYS_DIAGPOINT + 4, filesys_get_entry(9));
@@ -1892,8 +1895,7 @@ static bool expamem_init_filesys(struct autoconfig_info *aci)
        put_word_host(expamem + FILESYS_DIAGAREA + FILESYS_BOOTPOINT, 0x4EF9); /* JMP */
        put_long_host(expamem + FILESYS_DIAGAREA + FILESYS_BOOTPOINT + 2, EXPANSION_bootcode);
 
-       if (ks12)
-               add_ks12_boot_hack();
+       set_ks12_boot_hack(ks12);
 
        return true;
 }
@@ -4985,6 +4987,12 @@ const struct expansionromtype expansionroms[] = {
                NULL, 0,
                false, EXPANSIONTYPE_CUSTOM | EXPANSIONTYPE_SCSI
        },
+       {
+               _T("wedge"), _T("Wedge"), _T("Reiter Software"),
+               wedge_preinit, wedge_init, NULL, wedge_add_scsi_unit, ROMTYPE_WEDGE | ROMTYPE_NOT, 0, 0, BOARD_NONAUTOCONFIG_BEFORE, true,
+               NULL, 0,
+               false, EXPANSIONTYPE_CUSTOM | EXPANSIONTYPE_SCSI
+       },
        {
                _T("tecmar"), _T("T-Card/T-Disk"), _T("Tecmar"),
                NULL, tecmar_init, NULL, tecmar_add_scsi_unit, ROMTYPE_TECMAR | ROMTYPE_NOT, 0, 0, BOARD_PROTOAUTOCONFIG, true,
index d83d8386d784223c89229add22cd1d31d3af9f2e..f43a60fc666ab9c474757e93e7723d8d09391f21 100644 (file)
@@ -133,7 +133,8 @@ static void aino_test_init (a_inode *aino)
 
 #define UAEFS_VERSION "UAEfs 0.5"
 
-uaecptr filesys_initcode, filesys_initcode_ptr;
+uaecptr filesys_initcode, filesys_initcode_ptr, filesys_initcode_real;
+uaecptr ks12_resident;
 static uaecptr bootrom_start;
 static uae_u32 fsdevname, fshandlername, filesys_configdev;
 static uae_u32 cdfs_devname, cdfs_handlername;
@@ -7572,6 +7573,12 @@ static uae_u32 REGPARAM2 filesys_diagentry (TrapContext *ctx)
                put_word_host(baseaddr + 0x2112, 1 | 2 | 8 | 16);
 
                resaddr = resaddr_tmp;
+       } else {
+               // undo possible KS 1.2 hack
+               uaecptr temp = here();
+               org(filesys_initcode_ptr);
+               dl(filesys_initcode_real);
+               org(temp);
        }
 
        trap_set_areg(ctx, 0, last_resident);
@@ -9036,6 +9043,36 @@ void filesys_install (void)
        dw(RTS);
 
        org (loop);
+
+       // KS 1.2 boot resident
+       uaecptr name = ds(_T("UAE boot"));
+       align(2);
+       uaecptr code = here();
+       // allocate fake diagarea
+       dl(0x48e73f3e); // movem.l d2-d7/a2-a6,-(sp)
+       dw(0x203c); // move.l #x,d0
+       dl(0x0300);
+       dw(0x7201); // moveq #1,d1
+       dl(0x4eaeff3a); // jsr -0xc6(a6)
+       dw(0x2440); // move.l d0,a2 ;diag area
+       dw(0x9bcd); // sub.l a5,a5 ;expansionbase
+       dw(0x97cb); // sub.l a3,a3 ;configdev
+       dw(0x4eb9); // jsr
+       dl(ROM_filesys_diagentry);
+       dl(0x4cdf7cfc); // movem.l (sp)+,d2-d7/a2-a6
+       dw(0x4e75);
+       // struct Resident
+       ks12_resident = here();
+       dw(0x0000);
+       dl(ks12_resident);
+       dl(ks12_resident + 26);
+       db(1); // RTF_COLDSTART
+       db((uae_u8)kickstart_version); // version
+       db(0); // NT_UNKNOWN
+       db(1); // priority
+       dl(name);
+       dl(name);
+       dl(code);
 }
 
 uaecptr filesys_get_entry(int index)
index 971c88019715cb538225462c53c6719c3d4700aa..f82f7fefe43bad98f16f5d90341659137201ddc9 100644 (file)
@@ -1470,11 +1470,16 @@ int scsi_hd_emulate (struct hardfiledata *hfd, struct hd_hardfiledata *hdhfd, ua
                break;
        case 0x06: /* FORMAT TRACK */
        case 0x07: /* FORMAT BAD TRACK */
-               // do nothing
                if (nodisk (hfd))
                        goto nodisk;
                if (is_writeprotected(hfd))
                        goto readprot;
+               // do nothing
+               if (cmdbuf[5] & 0x40) {
+                       // data from sector buffer
+               } else {
+                       // data is static 0x6c
+               }
                scsi_len = 0;
                break;
        case 0x09: /* READ VERIFY */
@@ -1528,8 +1533,20 @@ int scsi_hd_emulate (struct hardfiledata *hfd, struct hd_hardfiledata *hdhfd, ua
                        goto checkfail;
                scsi_len = (uae_u32)cmd_readx(hfd, scsi_data, offset, len);
                break;
+       case 0x0e: /* READ SECTOR BUFFER */
+               len = hfd->ci.blocksize;
+               scsi_len = len;
+               memset(scsi_data, 0, len);
+               if (len > sizeof(hfd->sector_buffer))
+                       len = sizeof(hfd->sector_buffer);
+               memcpy(scsi_data, hfd->sector_buffer, len);
+               break;
        case 0x0f: /* WRITE SECTOR BUFFER */
-               scsi_len = hfd->ci.blocksize;
+               len = hfd->ci.blocksize;
+               scsi_len = len;
+               if (len > sizeof(hfd->sector_buffer))
+                       len = sizeof(hfd->sector_buffer);
+               memcpy(hfd->sector_buffer, scsi_data, len);
                break;
        case 0x0a: /* WRITE (6) */
                if (nodisk (hfd))
@@ -2849,5 +2866,6 @@ void hardfile_install (void)
        dl (functable);
        dl (datatable);
        filesys_initcode_ptr = here();
+       filesys_initcode_real = initcode;
        dl (initcode);
 }
index 2077e7a0c7c03353bd9b94ef597c6132afa19b03..0dbf21b0946ac2b4be6b6407e52564bf3b853f8b 100644 (file)
@@ -62,7 +62,9 @@ extern uae_u32 addr (int);
 extern void db (uae_u8);
 extern void dw (uae_u16);
 extern void dl (uae_u32);
-extern uae_u32 ds_ansi (const uae_char*);
+extern void df(uae_u8 b, int len);
+extern uae_u32 dsf(uae_u8, int);
+extern uae_u32 ds_ansi(const uae_char*);
 extern uae_u32 ds (const TCHAR*);
 extern uae_u32 ds_bstr_ansi (const uae_char*);
 extern uae_u8 dbg (uaecptr);
@@ -91,7 +93,7 @@ extern uaecptr ROM_filesys_resname, ROM_filesys_resid;
 extern uaecptr ROM_filesys_diagentry;
 extern uaecptr ROM_hardfile_resname, ROM_hardfile_resid;
 extern uaecptr ROM_hardfile_init;
-extern uaecptr filesys_initcode, filesys_initcode_ptr;
+extern uaecptr filesys_initcode, filesys_initcode_ptr, filesys_initcode_real;
 
 extern int is_hardfile(int unit_no);
 extern int nr_units(void);
index bd3335b0d893d3f292e4bd84250e89bad40fcdce..15d3db67b5e416a435b101d2f2d61d4017d3c597 100644 (file)
@@ -69,6 +69,7 @@ struct hardfiledata {
 
        struct hdf_cache bcache[MAX_HDF_CACHE_BLOCKS];
        uae_u8 scsi_sense[MAX_SCSI_SENSE];
+       uae_u8 sector_buffer[512];
 
        struct uaedev_config_info delayedci;
        int reinsertdelay;
index b3da613f0809fea8e4b42cedfc8b0eaf0b16d83e..074f938bdb9ab1a276d5b6da8ff2546e8764a666 100644 (file)
@@ -612,7 +612,7 @@ struct uae_prefs {
        bool cs_cia6526;
        bool cs_bytecustomwritebug;
        bool cs_color_burst;
-       bool cs_unmapped_zero;
+       int cs_unmapped_space;
        int cs_hacks;
 
        struct boardromconfig expansionboard[MAX_EXPANSION_BOARDS];
@@ -692,6 +692,7 @@ struct uae_prefs {
        uae_u32 custom_memory_sizes[MAX_CUSTOM_MEMORY_ADDRS];
        uae_u32 custom_memory_mask[MAX_CUSTOM_MEMORY_ADDRS];
        int uaeboard;
+       bool uaeboard_nodiag;
        int uaeboard_order;
 
        bool kickshifter;
index ac3c0739039b16474a7da0a8af074ec1b758c52a..878e5b772b94966a6a4666c4bcbe25573050c9e5 100644 (file)
@@ -64,7 +64,7 @@ extern size_t zfile_fputs (struct zfile *z, const TCHAR *s);
 extern int zfile_getc (struct zfile *z);
 extern int zfile_putc (int c, struct zfile *z);
 extern int zfile_ferror (struct zfile *z);
-extern uae_u8 *zfile_getdata (struct zfile *z, uae_s64 offset, int len);
+extern uae_u8 *zfile_getdata (struct zfile *z, uae_s64 offset, int len, int *outlen);
 extern void zfile_exit (void);
 extern int execute_command (TCHAR *);
 extern int zfile_iscompressed (struct zfile *z);
index eddb639e33ce528c0ddd5d1b53f7dfe4d1a90ef4..c58a7608f115866e8a9f9ba9b08fd228ff2dca6f 100644 (file)
@@ -845,7 +845,7 @@ static int savedisk (const TCHAR *path, const TCHAR *file, uae_u8 *data, uae_u8
                        struct zfile *zfd = zfile_fopen (tmp, _T("wb"));
                        if (zfd) {
                                int size = zfile_size (zf);
-                               uae_u8 *data = zfile_getdata (zf, 0, size);
+                               uae_u8 *data = zfile_getdata (zf, 0, size, NULL);
                                zfile_fwrite (data, size, 1, zfd);
                                zfile_fclose (zfd);
                                xfree (data);
@@ -876,14 +876,14 @@ void inprec_save (const TCHAR *filename, const TCHAR *statefilename)
        if (zf) {
                TCHAR fn[MAX_DPATH];
                uae_u8 *data;
-               data = zfile_getdata (inprec_zf, 0, header_end);
+               data = zfile_getdata (inprec_zf, 0, header_end, NULL);
                zfile_fwrite (data, header_end, 1, zf);
                xfree (data);
                getfilepart (fn, MAX_DPATH, statefilename);
                char *s = uutf8 (fn);
                zfile_fwrite (s, strlen (s) + 1, 1, zf);
                int len = zfile_size (inprec_zf) -  header_end2;
-               data = zfile_getdata (inprec_zf, header_end2, len);
+               data = zfile_getdata (inprec_zf, header_end2, len, NULL);
                uae_u8 *p = data;
                uae_u8 *end = data + len;
                while (p < end) {
@@ -940,8 +940,8 @@ void inprec_getstatus (TCHAR *title)
        p = title + _tcslen (title);
        int mvp = current_maxvpos ();
        _stprintf (p, _T("%03d %02d:%02d:%02d/%02d:%02d:%02d"), replaypos,
-               lasthsync / (vblank_hz * mvp * 60), ((int)(lasthsync / (vblank_hz * mvp)) % 60), (lasthsync / mvp) % (int)vblank_hz,
-               endhsync / (vblank_hz * mvp * 60), ((int)(endhsync / (vblank_hz * mvp)) % 60), (endhsync / mvp) % (int)vblank_hz);
+               (int)(lasthsync / (vblank_hz * mvp * 60)), ((int)(lasthsync / (vblank_hz * mvp)) % 60), (lasthsync / mvp) % (int)vblank_hz,
+               (int)(endhsync / (vblank_hz * mvp * 60)), ((int)(endhsync / (vblank_hz * mvp)) % 60), (endhsync / mvp) % (int)vblank_hz);
        p += _tcslen (p);
        _tcscat (p, _T("] "));
 
index bcf2575dcd4a65893b867ad0837495bec49fb9a3..5c3ef4617b5b01fa0dacdfbd6e5ae15d5bd7852d 100644 (file)
--- a/main.cpp
+++ b/main.cpp
@@ -169,6 +169,9 @@ void fixup_prefs_dimensions (struct uae_prefs *prefs)
                struct apmode *ap = &prefs->gfx_apmode[i];
                ap->gfx_vflip = 0;
                ap->gfx_strobo = false;
+               // no llvs support yet
+               if (currprefs.gfx_api > 1)
+                       ap->gfx_vsyncmode = 0;
                if (ap->gfx_vsync < 0) {
                        // adaptive sync
                        ap->gfx_vsyncmode = 0;
index 4963987a547fb3bdfe742fc7639c010380e955da..0a4f96ce0420a589f4bc5db46f997ce65f0bc3d8 100644 (file)
@@ -307,8 +307,10 @@ uae_u32 dummy_get_safe(uaecptr addr, int size, bool inst, uae_u32 defvalue)
        if (addr >= 0x10000000)
                return v & mask;
        // CD32 and B2000
-       if (currprefs.cs_unmapped_zero)
+       if (currprefs.cs_unmapped_space == 1)
                return 0;
+       if (currprefs.cs_unmapped_space == 2)
+               return 0xffffffff & mask;
        if ((currprefs.cpu_model <= 68010) || (currprefs.cpu_model == 68020 && (currprefs.chipset_mask & CSMASK_AGA) && currprefs.address_space_24)) {
                if (size == 4) {
                        v = regs.db & 0xffff;
@@ -2430,7 +2432,7 @@ bool read_kickstart_version(struct uae_prefs *p)
                if (kickstart_version > 33)
                        kickstart_version = 0;
        }
-       write_log(_T("KS ver = %04x\n"), kickstart_version);
+       write_log(_T("KS ver = %d (0x%02x)\n"), kickstart_version & 255, kickstart_version);
        return true;
 }
 
@@ -2479,6 +2481,7 @@ void memory_reset (void)
        currprefs.cs_ide = changed_prefs.cs_ide;
        currprefs.cs_fatgaryrev = changed_prefs.cs_fatgaryrev;
        currprefs.cs_ramseyrev = changed_prefs.cs_ramseyrev;
+       currprefs.cs_unmapped_space = changed_prefs.cs_unmapped_space;
        cpuboard_reset();
 
        gayleorfatgary = ((currprefs.chipset_mask & CSMASK_AGA) || currprefs.cs_pcmcia || currprefs.cs_ide > 0 || currprefs.cs_mbdmac) && !currprefs.cs_cd32cd;
index 36d806aea13c2aba6da1e782dc6925a920adeb51..91313f8613ad331005ce8c34ec9f044e26508c1f 100644 (file)
 #define IDC_DBG_MEM                     1756
 #define IDC_CS_COMPOSITECOLOR           1756
 #define IDC_DBG_DASM                    1757
-#define IDC_CS_UNMAPPEDZERO             1757
 #define IDC_DBG_MEMDOWNFAST             1758
 #define IDC_DBG_MEMTOPC                 1759
 #define IDC_DBG_MEMUPFAST               1760
 #define IDC_PATH_GEOMETRY_SELECTOR      1856
 #define IDC_EDIT1                       1857
 #define IDC_EXPANSIONBOARDSTRINGBOX     1857
+#define IDC_CS_UNMAPPED                 1858
 #define ID__FLOPPYDRIVES                40004
 #define ID_FLOPPYDRIVES_DF0             40005
 #define ID_ST_CONFIGURATION             40010
 #define _APS_3D_CONTROLS                     1
 #define _APS_NEXT_RESOURCE_VALUE        407
 #define _APS_NEXT_COMMAND_VALUE         40050
-#define _APS_NEXT_CONTROL_VALUE         1858
+#define _APS_NEXT_CONTROL_VALUE         1859
 #define _APS_NEXT_SYMED_VALUE           101
 #endif
 #endif
index a2d7c842e68cce79c5de5fe83ae39301d6f646c2..c0c3759518e5caa291e1c0af58d682702aa532f8 100644 (file)
@@ -779,7 +779,7 @@ BEGIN
     CONTROL         "Vertical Sync",IDC_CS_CIAA_TOD1,"Button",BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,41,64,86,10
     CONTROL         "Power Supply 50Hz",IDC_CS_CIAA_TOD2,"Button",BS_AUTORADIOBUTTON | WS_TABSTOP,133,64,109,10
     CONTROL         "Power Supply 60Hz",IDC_CS_CIAA_TOD3,"Button",BS_AUTORADIOBUTTON | WS_TABSTOP,248,64,116,10
-    GROUPBOX        "Chipset Features",IDC_STATIC,0,84,395,132
+    GROUPBOX        "Chipset Features",IDC_STATIC,0,84,395,137
     CONTROL         "CIA ROM Overlay",IDC_CS_CIAOVERLAY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,98,104,11
     CONTROL         "CD32 CD",IDC_CS_CD32CD,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,111,104,11
     CONTROL         "CDTV CD",IDC_CS_CDTVCD,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,124,105,11
@@ -805,10 +805,10 @@ BEGIN
     CONTROL         "C00000 is Fast RAM",IDC_CS_SLOWISFAST,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,264,163,125,11
     CONTROL         "A1000 Agnus (8361/8367)",IDC_CS_DIPAGNUS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,264,176,125,11
     CONTROL         "Composite color burst",IDC_CS_COMPOSITECOLOR,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,264,189,125,12
-    GROUPBOX        "Internal SCSI Hardware",IDC_STATIC,0,218,395,39
-    CONTROL         "A3000 WD33C93 SCSI",IDC_CS_DMAC,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,236,108,11
-    CONTROL         "A4000T NCR53C710 SCSI",IDC_CS_DMAC2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,130,236,125,11
-    CONTROL         "CDTV WD33C93 SCSI",IDC_CS_CDTVSCSI,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,236,121,11
+    GROUPBOX        "Internal SCSI Hardware",IDC_STATIC,0,224,395,33
+    CONTROL         "A3000 WD33C93 SCSI",IDC_CS_DMAC,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,239,108,11
+    CONTROL         "A4000T NCR53C710 SCSI",IDC_CS_DMAC2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,130,239,125,11
+    CONTROL         "CDTV WD33C93 SCSI",IDC_CS_CDTVSCSI,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,239,121,11
     GROUPBOX        "Chipset Revision",IDC_STATIC,1,259,393,46
     CONTROL         "Ramsey revision:",IDC_CS_RAMSEY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,34,275,97,11
     CONTROL         "Fat Gary revision:",IDC_CS_FATGARY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,34,289,97,11
@@ -818,7 +818,8 @@ BEGIN
     CONTROL         "Denise/Lisa revision:",IDC_CS_DENISE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,200,289,107,11
     EDITTEXT        IDC_CS_AGNUSREV,311,274,45,13,ES_AUTOHSCROLL
     EDITTEXT        IDC_CS_DENISEREV,311,289,45,13,ES_AUTOHSCROLL
-    CONTROL         "Unmapped returns zero",IDC_CS_UNMAPPEDZERO,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,202,104,11
+    COMBOBOX        IDC_CS_UNMAPPED,126,202,113,75,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP
+    RTEXT           "Unmapped address space:",IDC_STATIC,15,205,101,9
 END
 
 IDD_AVIOUTPUT DIALOGEX 0, 0, 396, 260
index 4d6268abce4c0864eebdb013f439e102aa6d7088..36106e6dba8be735d71d1f36fa89107505bf9706 100644 (file)
@@ -89,7 +89,7 @@ static const TCHAR *getmsg (int msg)
 {
        switch (msg)
        {
-       case RP_IPC_TO_HOST_REGISTER: return _T("RP_IPC_TO_HOST_REGISTER");
+       case RP_IPC_TO_HOST_PRIVATE_REGISTER: return _T("RP_IPC_TO_HOST_PRIVATE_REGISTER");
        case RP_IPC_TO_HOST_FEATURES: return _T("RP_IPC_TO_HOST_FEATURES");
        case RP_IPC_TO_HOST_CLOSED: return _T("RP_IPC_TO_HOST_CLOSED");
        case RP_IPC_TO_HOST_ACTIVATED: return _T("RP_IPC_TO_HOST_ACTIVATED");
index 80707e918ffd3fe0579f8c89db5fb979a7fe6924..0a2305d98eabb0dcfa25990a28c4757389abf6b8 100644 (file)
 #define LANG_DLL_FULL_VERSION_MATCH 1
 
 #if WINUAEPUBLICBETA
-#define WINUAEBETA _T("7")
+#define WINUAEBETA _T("8")
 #else
 #define WINUAEBETA _T("")
 #endif
 
-#define WINUAEDATE MAKEBD(2017, 10, 29)
+#define WINUAEDATE MAKEBD(2017, 11, 19)
 
 //#define WINUAEEXTRA _T("AmiKit Preview")
 //#define WINUAEEXTRA _T("Amiga Forever Edition")
@@ -91,7 +91,7 @@ extern int sound_available;
 extern int framecnt;
 extern TCHAR VersionStr[256];
 extern TCHAR BetaStr[64];
-extern int os_admin, os_64bit, os_vista, os_win7, cpu_number, os_touch;
+extern int os_admin, os_64bit, os_vista, os_win7, os_win8, cpu_number, os_touch;
 extern BOOL os_dwm_enabled;
 extern OSVERSIONINFO osVersion;
 extern int paraport_mask;
index 6ad5ee399bc053db7f57eaaafc7b8cad7304ba1a..621cb7dec82c4f6c89e4497ecda0a373420a7d00 100644 (file)
@@ -127,7 +127,7 @@ struct uae_prefs workprefs;
 static int currentpage = -1;
 static int qs_request_reset;
 static int qs_override;
-int gui_active;
+int gui_active, gui_left;
 
 extern HWND (WINAPI *pHtmlHelp)(HWND, LPCWSTR, UINT, LPDWORD);
 
@@ -2198,13 +2198,14 @@ static void m (void)
        mm++;
 }
 
-static void flipgui (bool opengui)
+static void flipgui (int opengui)
 {
        D3D_guimode (opengui);
-       if (opengui)
-               DirectDraw_FlipToGDISurface ();
-       else
-               vblank_reset (-1);
+       if (opengui) {
+               DirectDraw_FlipToGDISurface();
+       } else {
+               vblank_reset(-1);
+       }
 }
 
 static int GetSettings (int all_options, HWND hwnd);
@@ -2221,7 +2222,7 @@ void gui_display (int shortcut)
 
        if (isfullscreen() > 0 && currprefs.gfx_api == 0)
                screenshot_prepare();
-       flipgui(true);
+       flipgui(1);
 
        if (setpaused (7)) {
                inputdevice_unacquire ();
@@ -2267,7 +2268,7 @@ void gui_display (int shortcut)
                inputdevice_acquire (TRUE);
                setmouseactive (1);
        }
-       flipgui(false);
+       flipgui(0);
        fpscounter_reset ();
        screenshot_free ();
        write_disk_history ();
@@ -8102,7 +8103,7 @@ static void values_to_chipsetdlg2 (HWND hDlg)
        CheckDlgButton(hDlg, IDC_CS_1MCHIPJUMPER, workprefs.cs_1mchipjumper || workprefs.chipmem_size >= 0x100000);
        CheckDlgButton(hDlg, IDC_CS_BYTECUSTOMWRITEBUG, workprefs.cs_bytecustomwritebug);
        CheckDlgButton(hDlg, IDC_CS_COMPOSITECOLOR, workprefs.cs_color_burst);
-       CheckDlgButton(hDlg, IDC_CS_UNMAPPEDZERO, workprefs.cs_unmapped_zero);
+       SendDlgItemMessage(hDlg, IDC_CS_UNMAPPED, CB_SETCURSEL, workprefs.cs_unmapped_space, 0);
        txt[0] = 0;
        _stprintf (txt, _T("%d"), workprefs.cs_rtc_adjust);
        SetDlgItemText(hDlg, IDC_CS_RTCADJUST, txt);
@@ -8193,7 +8194,9 @@ static void values_from_chipsetdlg2 (HWND hDlg, UINT msg, WPARAM wParam, LPARAM
        workprefs.cs_1mchipjumper = ischecked(hDlg, IDC_CS_1MCHIPJUMPER);
        workprefs.cs_bytecustomwritebug = ischecked(hDlg, IDC_CS_BYTECUSTOMWRITEBUG);
        workprefs.cs_color_burst = ischecked(hDlg, IDC_CS_COMPOSITECOLOR);
-       workprefs.cs_unmapped_zero = ischecked(hDlg, IDC_CS_UNMAPPEDZERO);
+       LRESULT val = SendDlgItemMessage(hDlg, IDC_CS_UNMAPPED, CB_GETCURSEL, 0, 0L);
+       if (val != CB_ERR)
+               workprefs.cs_unmapped_space = val;
 
        cfgfile_compatibility_romtype(&workprefs);
 
@@ -8280,7 +8283,7 @@ static void enable_for_chipsetdlg2 (HWND hDlg)
        ew(hDlg, IDC_CS_1MCHIPJUMPER, e && workprefs.chipmem_size < 0x100000);
        ew(hDlg, IDC_CS_BYTECUSTOMWRITEBUG, e);
        ew(hDlg, IDC_CS_COMPOSITECOLOR, e);
-       ew(hDlg, IDC_CS_UNMAPPEDZERO, e);
+       ew(hDlg, IDC_CS_UNMAPPED, e);
 }
 
 static INT_PTR CALLBACK ChipsetDlgProc2 (HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam)
@@ -8293,6 +8296,10 @@ static INT_PTR CALLBACK ChipsetDlgProc2 (HWND hDlg, UINT msg, WPARAM wParam, LPA
                pages[CHIPSET2_ID] = hDlg;
                currentpage = CHIPSET2_ID;
                cs_compatible = workprefs.cs_compatible;
+               SendDlgItemMessage(hDlg, IDC_CS_UNMAPPED, CB_RESETCONTENT, 0, 0L);
+               SendDlgItemMessage(hDlg, IDC_CS_UNMAPPED, CB_ADDSTRING, 0, (LPARAM)_T("Floating"));
+               SendDlgItemMessage(hDlg, IDC_CS_UNMAPPED, CB_ADDSTRING, 0, (LPARAM)_T("All zeros"));
+               SendDlgItemMessage(hDlg, IDC_CS_UNMAPPED, CB_ADDSTRING, 0, (LPARAM)_T("All ones"));
        case WM_USER:
                recursive++;
                values_to_chipsetdlg2 (hDlg);
@@ -18120,7 +18127,7 @@ static void values_to_hw3ddlg (HWND hDlg)
                        TCHAR *ext = _tcsrchr (wfd.cFileName, '.');
                        if (ext && (
                                !_tcsicmp (ext, _T(".png")) ||
-                               !_tcsicmp (ext, _T(".bmp"))))
+                               (!_tcsicmp (ext, _T(".bmp")) && workprefs.gfx_api != 2)))
                        {
                                SendDlgItemMessage (hDlg, IDC_FILTEROVERLAY, CB_ADDSTRING, 0, (LPARAM)wfd.cFileName);
                                if (!_tcsicmp (wfd.cFileName, overlaytype == 0 ? workprefs.gf[filter_nativertg].gfx_filteroverlay : workprefs.gf[filter_nativertg].gfx_filtermask[filterstackpos]))
@@ -20567,6 +20574,7 @@ static int GetSettings (int all_options, HWND hwnd)
                        MapDialogRect (dhwnd, &dialog_rect);
 
                        hGUIWnd = dhwnd;
+                       flipgui(2);
 
                        for (;;) {
                                HANDLE IPChandle;
index a53ce3836fbde3be780fab980af1f9d17a619760..c670ef0be099d898d5e69b6278ae1b364e6dd8da 100644 (file)
     <EmbedManifest Condition="'$(Configuration)|$(Platform)'=='FullRelease|Win32'">true</EmbedManifest>
     <IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">C:\dev\include;C:\Program Files %28x86%29\Microsoft DirectX SDK %28June 2010%29\Include;$(IncludePath)</IncludePath>
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">C:\dev\lib\x64;C:\Program Files %28x86%29\Microsoft DirectX SDK %28June 2010%29\Lib\x64;$(LibraryPath)</LibraryPath>
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|x64'">C:\dev\include;$(IncludePath)</IncludePath>
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Test|x64'">C:\dev\include;$(IncludePath)</IncludePath>
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|x64'">C:\dev\include;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\winrt;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\um;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\shared;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\ucrt;$(IncludePath)</IncludePath>
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Test|x64'">C:\dev\include;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\winrt;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\shared;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\ucrt;$(MSBuildProgramFiles32)\Windows Kits\10\Include\10.0.16299.0\um;$(IncludePath)</IncludePath>
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|x64'">C:\dev\lib\x64;$(LibraryPath)</LibraryPath>
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Test|x64'">C:\dev\lib\x64;$(LibraryPath)</LibraryPath>
     <IncludePath Condition="'$(Configuration)|$(Platform)'=='FullRelease|x64'">C:\dev\include;C:\Program Files (x86)\Windows Kits\10\Include\10.0.16299.0\ucrt;C:\Program Files (x86)\Windows Kits\10\Include\10.0.16299.0\shared;C:\Program Files (x86)\Windows Kits\10\Include\10.0.16299.0\winrt;C:\Program Files (x86)\Windows Kits\10\Include\10.0.16299.0\um;$(IncludePath)</IncludePath>
index c78fc2595f23f0126a86fd128171316cd1058ba6..4aa329c8dba5ca05622d735288dc00239abc7a8a 100644 (file)
@@ -4,6 +4,25 @@ JIT Direct current rules are less complex now. It automatically switches off onl
   - RTG VRAM is outside of reserved natmem space. Workaround: Move RTG in earlier position using Hardware info GUI panel.\r
   Note that in 64-bit version RTG VRAM must be inside of reserved natmem space. (Outside = error message and return back to GUI)\r
 \r
+Beta 8:\r
+\r
+- Replaced b7 unmapped zero checkbox with a 3 option select menu. Different A2000/B2000 variants can have either pullup or pulldown resistors connected to CPU data lines.\r
+- CD SCSI emulator READ CD-DA and READ CD-DA MSF emulated.\r
+- Single console output max write size was limited to about 4000 characters. It truncated or corrupted for example 100+ line disassembly.\r
+- D3D11 RTG mode supported, D3D9X dependency should be gone, screenshots/recording supported, filter scaling/position options enabled, shaders are built-in, scanlines and masks/overlays supported.\r
+- D3D11 mode not yet supported: transparent OSD, low latency vsync (need totally different logic), custom shaders (won't be implemented in next official version).\r
+- D3D11 didn't restore back to fullscreen (or to blank fullscreen) from minimized state in certain situations.\r
+- D3D11 fullscreen mode + GUI can work strangely. (GUI may open on desktop with black background, exiting GUI may not restore fullscreen or cause mode to become minimized)\r
+- Fall back to D3D9 if D3D11 fails to init, only fall back to DirectDraw if D3D9 also fails to init.\r
+- GamePorts panel custom mapping incorrectly parsed joystick autofire state from config file.\r
+- On the fly switching from KS 1.2 to KS 1.3+ properly undoes possible previously added KS 1.2 autoboot UAE rom patches.\r
+- Added Reiter Software Wedge HD controller emulation.\r
+- Added 3.07 GVP Series I ROM.\r
+\r
+Reiter Software Wedge:\r
+- Simple XT adapter hardware. Emulation only supports OMTI controller based harddrives.\r
+- No autoconfig, no boot ROM, no interrupts.\r
+\r
 Beta 7:\r
 \r
 - Added support for npcap without winpcap backwards compatibility option, fall back to winpcap if not found. (https://nmap.org/npcap/, fully Windows 10 1607+ compatible, original winpcap is not and win10pcap has at least one annoying bug.)\r
index 5c07265338cc6100571a92b5f8459200a834ad21..3e91adb3ed23fda075c19268ac5a8591ebdc0135 100644 (file)
@@ -1792,7 +1792,7 @@ void statefile_save_recording (const TCHAR *filename)
        struct zfile *zf = zfile_fopen (filename, _T("wb"), 0);
        if (zf) {
                int len = zfile_size (staterecord_statefile);
-               uae_u8 *data = zfile_getdata (staterecord_statefile, 0, len);
+               uae_u8 *data = zfile_getdata (staterecord_statefile, 0, len, NULL);
                zfile_fwrite (data, len, 1, zf);
                xfree (data);
                zfile_fclose (zf);
index 59c3618d8340df3f1c60d4ac9521c19c5e4b5faf..805381c6bf889a058d42c21937cd583287702b71 100644 (file)
--- a/zfile.cpp
+++ b/zfile.cpp
@@ -1040,7 +1040,7 @@ static struct zfile *dsq (struct zfile *z, int lzx, int *retcode)
                zi = z;
        }
        if (zi) {
-               uae_u8 *buf = zfile_getdata (zi, 0, -1);
+               uae_u8 *buf = zfile_getdata (zi, 0, -1, NULL);
                if (!memcmp (buf, "PKD\x13", 4) || !memcmp (buf, "PKD\x11", 4)) {
                        TCHAR *fn;
                        int sectors = buf[18];
@@ -2367,7 +2367,7 @@ int zfile_ferror (struct zfile *z)
        return 0;
 }
 
-uae_u8 *zfile_getdata (struct zfile *z, uae_s64 offset, int len)
+uae_u8 *zfile_getdata (struct zfile *z, uae_s64 offset, int len, int *outlen)
 {
        uae_s64 pos = zfile_ftell (z);
        uae_u8 *b;
@@ -2380,6 +2380,8 @@ uae_u8 *zfile_getdata (struct zfile *z, uae_s64 offset, int len)
        zfile_fseek (z, offset, SEEK_SET);
        zfile_fread (b, len, 1, z);
        zfile_fseek (z, pos, SEEK_SET);
+       if (outlen)
+               *outlen = len;
        return b;
 }