]> git.unchartedbackwaters.co.uk Git - francis/winuae.git/commitdiff
imported winuaesrc1530b7.zip
authorToni Wilen <twilen@winuae.net>
Sun, 2 Nov 2008 12:14:26 +0000 (14:14 +0200)
committerToni Wilen <twilen@winuae.net>
Mon, 22 Feb 2010 19:43:33 +0000 (21:43 +0200)
14 files changed:
a2091.c
cia.c
custom.c
hardfile.c
include/cia.h
main.c
memory.c
od-win32/direct3d.c
od-win32/picasso96_win.c
od-win32/win32.h
od-win32/win32gfx.c
od-win32/win32gui.c
od-win32/winuaechangelog.txt
scsi.c

diff --git a/a2091.c b/a2091.c
index cf7ce78b963b8dfa3fb2bf3ea8520efc7778093f..eed6ad5922f03815af1ce68c1c5117147fbc89b9 100755 (executable)
--- a/a2091.c
+++ b/a2091.c
@@ -1305,7 +1305,7 @@ void a2091_init (void)
     roms[2] = 53;
     roms[3] = 56;
     roms[4] = -1;
-    //roms[0] = 56;
+    roms[0] = 53;
 
     rombankswitcher = 0;
     rombank = 0;
diff --git a/cia.c b/cia.c
index 98ceaa83236226defffd19b4ee79d5df62490802..bb8d5100c47a60ad748469d9ed4a1dead62304f1 100755 (executable)
--- a/cia.c
+++ b/cia.c
@@ -35,6 +35,7 @@
 #include "keyboard.h"
 #include "uae.h"
 #include "amax.h"
+#include "ersatz.h"
 
 //#define CIAA_DEBUG_R
 //#define CIAA_DEBUG_W
@@ -68,10 +69,6 @@ static int div10;
 static int kbstate, kback, ciaasdr_unread;
 static unsigned int sleepyhead;
 
-#ifdef TOD_HACK
-static int tod_hack, tod_hack_delay;
-#endif
-
 static uae_u8 serbits;
 static int warned = 10;
 
@@ -335,6 +332,54 @@ STATIC_INLINE void ciaa_checkalarm (int inc)
     }
 }
 
+
+#ifdef TOD_HACK
+static uae_u64 tod_hack_tv, tod_hack_tod, tod_hack_tod_last;
+static void tod_hack_reset (void)
+{
+    struct timeval tv;
+    gettimeofday (&tv, NULL);
+    tod_hack_tv = (uae_u64)tv.tv_sec * 1000000 + tv.tv_usec;
+    tod_hack_tod = ciaatod;
+    tod_hack_tod_last = tod_hack_tod;
+}
+#endif
+
+static void do_tod_hack (int dotod)
+{
+    struct timeval tv;
+    static int oldrate;
+    uae_u64 t, rate;
+    int docount = 0;
+
+    if (currprefs.cs_ciaatod == 0)
+        rate = vblank_hz;
+    else if (currprefs.cs_ciaatod == 1)
+        rate = 50;
+    else
+        rate = 60;
+    if (rate != oldrate || ciaatod != tod_hack_tod_last) {
+        tod_hack_reset ();
+        oldrate = rate;
+       docount = 1;
+       write_log ("TOD HACK reset %d\n", rate);
+    }
+    if (!dotod && currprefs.cs_ciaatod == 0)
+       return;
+    gettimeofday (&tv, NULL);
+    t = (uae_u64)tv.tv_sec * 1000000 + tv.tv_usec;
+    if (t - tod_hack_tv >= 1000000 / rate) {
+        tod_hack_tv += 1000000 / rate;
+       docount = 1;
+    }
+    if (docount) {
+        ciaatod++;
+        ciaatod &= 0x00ffffff;
+       tod_hack_tod_last = ciaatod;
+        ciaa_checkalarm (0);
+    }
+}
+
 static int resetwarning_phase, resetwarning_timer;
 
 static void setcode (uae_u8 keycode)
@@ -400,14 +445,17 @@ static void resetwarning_check (void)
     }
 }
 
-void CIA_hsync_handler (void)
+void CIA_hsync_handler (int dotod)
 {
-    if (ciabtodon) {
+    if (ciabtodon && dotod) {
        ciabtod++;
        ciabtod &= 0xFFFFFF;
        ciab_checkalarm (1);
     }
 
+    if (currprefs.tod_hack && ciaatodon)
+       do_tod_hack (dotod);
+
     if (resetwarning_phase) {
        resetwarning_check ();
        while (keys_available ())
@@ -456,23 +504,11 @@ void CIA_hsync_handler (void)
            if (ciaasdr_unread == 3)
                ciaaicr |= 8;
            if (ciaasdr_unread < 3)
-               ciaasdr_unread = 0;          /* give up on this key event after unread for a long time */
+               ciaasdr_unread = 0;     /* give up on this key event after unread for a long time */
        }
     }
 }
 
-#ifdef TOD_HACK
-static void tod_hack_reset (void)
-{
-    struct timeval tv;
-    uae_u32 rate = currprefs.ntscmode ? 60 : 50;
-    gettimeofday (&tv, NULL);
-    tod_hack = (uae_u32)(((uae_u64)tv.tv_sec) * rate  + tv.tv_usec / (1000000 / rate));
-    tod_hack -= ciaatod;
-    tod_hack_delay = 10 * 50;
-}
-#endif
-
 static int led_times;
 static unsigned long led_on, led_cycle;
 
@@ -507,36 +543,14 @@ static void led_vsync (void)
     led_cycle = get_cycles ();
 }
 
-void CIA_vsync_handler (void)
+void CIA_vsync_handler (int dotod)
 {
     led_vsync ();
 #ifdef TOD_HACK
-    if (currprefs.tod_hack && ciaatodon) {
-       struct timeval tv;
-       uae_u32 t, nt, rate = currprefs.ntscmode ? 60 : 50;
-
-       if (tod_hack_delay > 0) {
-           tod_hack_delay--;
-           if (tod_hack_delay == 0) {
-               tod_hack_reset ();
-               tod_hack_delay = 0;
-               write_log ("TOD_HACK re-initialized CIATOD=%06X\n", ciaatod);
-           }
-       }
-       if (tod_hack_delay == 0) {
-           gettimeofday (&tv, NULL);
-           t = (uae_u32)(((uae_u64)tv.tv_sec) * rate + tv.tv_usec / (1000000 / rate));
-           nt = t - tod_hack;
-           if ((nt < ciaatod && ciaatod - nt < 10) || nt == ciaatod)
-               return; /* try not to count backwards */
-           ciaatod = nt;
-           ciaatod &= 0xffffff;
-           ciaa_checkalarm (0);
-           return;
-       }
-    }
+    if (currprefs.tod_hack)
+       return;
 #endif
-    if (ciaatodon) {
+    if (ciaatodon && dotod) {
        ciaatod++;
        ciaatod &= 0xFFFFFF;
        ciaa_checkalarm (1);
@@ -884,10 +898,6 @@ static void WriteCIAA (uae_u16 addr,uae_u8 val)
            ciaatod = (ciaatod & ~0xff) | val;
            ciaatodon = 1;
            ciaa_checkalarm (0);
-#ifdef TOD_HACK
-           if (currprefs.tod_hack)
-               tod_hack_reset ();
-#endif
        }
        break;
     case 9:
@@ -1090,7 +1100,8 @@ void CIA_inprec_prepare (void)
 void CIA_reset (void)
 {
 #ifdef TOD_HACK
-    tod_hack = 0;
+    tod_hack_tv = 0;
+    tod_hack_tod = 0;
     if (currprefs.tod_hack)
        tod_hack_reset ();
 #endif
index 02fd41bda11107dbad0403060b4634b3811f57ec..b658bea51d3f9072903c1db06fb5706fe220bbb4 100755 (executable)
--- a/custom.c
+++ b/custom.c
@@ -2503,8 +2503,12 @@ void init_hz (void)
        hzc = 1;
     if (beamcon0 & 0x80)
        hack_vpos = -1;
+    if (beamcon0 != new_beamcon0)
+       write_log ("BEAMCON0 %04x -> %04x\n", beamcon0, new_beamcon0);
     beamcon0 = new_beamcon0;
-    isntsc = beamcon0 & 0x20 ? 0 : 1;
+    isntsc = (beamcon0 & 0x20) ? 0 : 1;
+    if (!(currprefs.chipset_mask & CSMASK_ECS_AGNUS))
+       isntsc = currprefs.ntscmode ? 1 : 0;
     if (hack_vpos > 0) {
        if (maxvpos == hack_vpos)
            return;
@@ -3027,7 +3031,7 @@ static void BEAMCON0 (uae_u16 v)
        if (v != new_beamcon0) {
            new_beamcon0 = v;
            if (v & ~0x20)
-               write_log ("warning: %04X written to BEAMCON0\n", v);
+               write_log ("warning: %04X written to BEAMCON0 PC=%08X\n", v, M68K_GETPC);
        }
     }
 }
@@ -4609,9 +4613,9 @@ static void copper_check (int n)
     }
 }
 
-static void CIA_vsync_prehandler (void)
+static void CIA_vsync_prehandler (int dotod)
 {
-    CIA_vsync_handler ();
+    CIA_vsync_handler (dotod);
 #if 0
     if (input_recording > 0) {
        inprec_rstart(INPREC_CIAVSYNC);
@@ -4702,12 +4706,12 @@ static void hsync_handler (void)
 
     eventtab[ev_hsync].evtime += get_cycles () - eventtab[ev_hsync].oldcycles;
     eventtab[ev_hsync].oldcycles = get_cycles ();
-    CIA_hsync_handler ();
+    CIA_hsync_handler (!(bplcon0 & 2) || ((bplcon0 & 2) && currprefs.genlock));
     if (currprefs.cs_ciaatod > 0) {
        static int cia_hsync;
        cia_hsync -= 256;
        if (cia_hsync <= 0) {
-           CIA_vsync_prehandler ();
+           CIA_vsync_prehandler (1);
            cia_hsync += ((MAXVPOS_PAL * MAXHPOS_PAL * 50 * 256) / (maxhpos * (currprefs.cs_ciaatod == 2 ? 60 : 50)));
        }
     }
@@ -4767,7 +4771,7 @@ static void hsync_handler (void)
 #endif
        vsync_counter++;
        if (currprefs.cs_ciaatod == 0)
-           CIA_vsync_prehandler ();
+           CIA_vsync_prehandler (!(bplcon0 & 2) || ((bplcon0 & 2) && currprefs.genlock));
     }
 
     DISK_hsync (maxhpos);
index cb22d0b9a758dc3384514c66c500ce643c1a0c52..80d0a2b587754e00f95c930499152f1946a65ad3 100755 (executable)
@@ -39,6 +39,8 @@
 #define hf_log write_log
 #undef hf_log2
 #define hf_log2 write_log
+#undef hf_log3
+#define hf_log3 write_log
 #undef scsi_log
 #define scsi_log write_log
 #endif
@@ -559,7 +561,7 @@ int scsi_emulate(struct hardfiledata *hfd, struct hd_hardfiledata *hdhfd, uae_u8
        offset *= hfd->blocksize;
        len = rl (cmdbuf + 7 - 2) & 0xffff;
        len *= hfd->blocksize;
-       if (checkbounds(hfd, offset, len))
+       if (checkbounds (hfd, offset, len))
            scsi_len = (uae_u32)cmd_readx (hfd, scsi_data, offset, len);
        break;
        case 0x2a: /* WRITE (10) */
@@ -569,9 +571,35 @@ int scsi_emulate(struct hardfiledata *hfd, struct hd_hardfiledata *hdhfd, uae_u8
        offset *= hfd->blocksize;
        len = rl (cmdbuf + 7 - 2) & 0xffff;
        len *= hfd->blocksize;
-       if (checkbounds(hfd, offset, len))
+       if (checkbounds (hfd, offset, len))
            scsi_len = (uae_u32)cmd_writex (hfd, scsi_data, offset, len);
        break;
+#if 0
+       case 0x2f: /* VERIFY */
+       {
+           int bytchk = cmdbuf[1] & 2;
+           if (nodisk (hfd))
+               goto nodisk;
+           offset = rl (cmdbuf + 2);
+           offset *= hfd->blocksize;
+           len = rl (cmdbuf + 7 - 2) & 0xffff;
+           len *= hfd->blocksize;
+           if (checkbounds (hfd, offset, len)) {
+               uae_u8 *vb = xmalloc (hfd->blocksize);
+               while (len > 0) {
+                   int len = cmd_readx (hfd, vb, offset, hfd->blocksize);
+                   if (bytchk) {
+                       if (memcmp (vb, scsi_data, hfd->blocksize))
+                           goto miscompare;
+                       scsi_data += hfd->blocksize;
+                   }
+                   offset += hfd->blocksize;
+               }
+               xfree (vb);
+           }
+       }
+       break;
+#endif
        case 0x35: /* SYNCRONIZE CACHE (10) */
        if (nodisk (hfd))
            goto nodisk;
@@ -624,6 +652,14 @@ err:
        s[12] = 0x24; /* ILLEGAL FIELD IN CDB */
        ls = 12;
        break;
+miscompare:
+       lr = -1;
+       status = 2; /* CHECK CONDITION */
+       s[0] = 0x70;
+       s[2] = 5; /* ILLEGAL REQUEST */
+       s[12] = 0x1d; /* MISCOMPARE DURING VERIFY OPERATION */
+       ls = 12;
+       break;
     }
     *data_len = scsi_len;
     *reply_len = lr;
index dd61df70cad43a8ad667980bfa6d6cac4016c5e5..b76d5888aed47f77e03f3b014a9f8dae88122d71 100755 (executable)
@@ -7,8 +7,8 @@
   */
 
 extern void CIA_reset (void);
-extern void CIA_vsync_handler (void);
-extern void CIA_hsync_handler (void);
+extern void CIA_vsync_handler (int);
+extern void CIA_hsync_handler (int);
 extern void CIA_handler (void);
 
 extern void diskindex_handler (void);
diff --git a/main.c b/main.c
index 4dafce199c98d7fc4f7c413fd83fa6e08d1c4dc7..6496946d36beb69cc27cc83814e44e1454b0e76b 100755 (executable)
--- a/main.c
+++ b/main.c
@@ -398,6 +398,8 @@ void fixup_prefs (struct uae_prefs *p)
 #endif
     if (p->maprom && !p->address_space_24)
        p->maprom = 0x0f000000;
+    if (p->tod_hack && p->cs_ciaatod == 0)
+       p->cs_ciaatod = p->ntscmode ? 2 : 1;
     target_fixup_options (p);
 }
 
index cee76cf72d737a5fee93fc15ad1d9a3f7c9b0565..23d46859ccd4135aba6e3a4bffca8954c32224f8 100755 (executable)
--- a/memory.c
+++ b/memory.c
@@ -317,23 +317,23 @@ static struct romdata roms[] = {
     { "Freezer: HRTMon v2.30 (built-in)", 0, 0, 0, 0, "HRTMON\0", 0, 63, 0, 0, ROMTYPE_HRTMON, 0, 1, NULL,
        0xffffffff, 0, 0, 0, 0, 0, "HRTMon" },
 
-    { "A590/A2091 SCSI boot ROM", 0, 0, 6, 0, "A590\0A2091\0", 16384, 53, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
+    { "A590/A2091 SCSI boot ROM", 6, 0, 6, 0, "A590\0A2091\0", 16384, 53, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
        0x8396cf4e, 0x5E03BC61,0x8C862ABE,0x7BF79723,0xB4EEF4D2,0x1859A0F2 },
     ALTROM(53, 1, 1, 8192, ROMTYPE_ODD  | ROMTYPE_8BIT, 0xb0b8cf24,0xfcf40175,0x05f4d441,0x814b45d5,0x59c19eab,0x43816b30)
     ALTROM(53, 1, 2, 8192, ROMTYPE_EVEN | ROMTYPE_8BIT, 0x2e77bbff,0x8a098845,0x068f32cf,0xa4d34a27,0x8cd290f6,0x1d35a52c)
-    { "A590/A2091 SCSI boot ROM", 0, 0, 6, 6, "A590\0A2091\0", 16384, 54, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
+    { "A590/A2091 SCSI boot ROM", 6, 6, 6, 6, "A590\0A2091\0", 16384, 54, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
        0x33e00a7a, 0x739BB828,0xE874F064,0x9360F59D,0x26B5ED3F,0xBC99BB66 },
     ALTROM(54, 1, 1, 8192, ROMTYPE_ODD  | ROMTYPE_8BIT, 0xe536bbb2,0xfd7f8a6d,0xa18c1b02,0xd07eb990,0xc2467a24,0x183ede12)
     ALTROM(54, 1, 2, 8192, ROMTYPE_EVEN | ROMTYPE_8BIT, 0xc0871d25,0xe155f18a,0xbb90cf82,0x0589c15e,0x70559d3b,0x6b391af8)
-    { "A590/A2091 SCSI boot ROM", 0, 0, 7, 0, "A590\0A2091\0", 16384, 55, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
+    { "A590/A2091 SCSI boot ROM", 7, 0, 7, 0, "A590\0A2091\0", 16384, 55, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
        0x714a97a2, 0xE50F01BA,0xF2899892,0x85547863,0x72A82C33,0x3C91276E },
     ALTROM(55, 1, 1, 8192, ROMTYPE_ODD  | ROMTYPE_8BIT, 0xa9ccffed,0x149f5bd5,0x2e2d2990,0x4e3de483,0xb9ad7724,0x48e9278e)
     ALTROM(55, 1, 2, 8192, ROMTYPE_EVEN | ROMTYPE_8BIT, 0x2942747a,0xdbd7648e,0x79c75333,0x7ff3e4f4,0x91de224b,0xf05e6bb6)
-    { "A590/A2091 SCSI Guru boot ROM", 0, 0, 6, 14, "A590\0A2091\0", 32768, 56, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
+    { "A590/A2091 SCSI Guru boot ROM", 6, 14, 6, 14, "A590\0A2091\0", 32768, 56, 0, 0, ROMTYPE_A2091BOOT, 0, 0, NULL,
        0x04e52f93, 0x6DA21B6F,0x5E8F8837,0xD64507CD,0x8A4D5CDC,0xAC4F426B },
-    { "A4091 SCSI boot ROM", 0, 0, 40, 9, "A4091\0", 32768, 57, 0, 0, ROMTYPE_A4091BOOT, 0, 0, NULL,
+    { "A4091 SCSI boot ROM", 40, 9, 40, 9, "A4091\0", 32768, 57, 0, 0, ROMTYPE_A4091BOOT, 0, 0, NULL,
        0x00000000, 0, 0, 0, 0, 0 },
-    { "A4091 SCSI boot ROM", 0, 0, 40, 13, "A4091\0", 32768, 58, 0, 0, ROMTYPE_A4091BOOT, 0, 0, NULL,
+    { "A4091 SCSI boot ROM", 40, 13, 40, 13, "A4091\0", 32768, 58, 0, 0, ROMTYPE_A4091BOOT, 0, 0, NULL,
        0x54cb9e85, 0x3CE66919,0xF6FD6797,0x4923A12D,0x91B730F1,0xFFB4A7BA },
 
     { "Arcadia OnePlay 2.11", 0, 0, 0, 0, "ARCADIA\0", 0, 49, 0, 0, ROMTYPE_ARCADIABIOS, 0, 0 },
index 00eb0cb4f53ae460b28bb828e34e29f7629484f0..3a8d5d5e7a917630e8e5a8d7fb650d4148cda28c 100755 (executable)
@@ -818,8 +818,10 @@ static void createscanlines (int force)
     osl2 = currprefs.gfx_filter_scanlineratio;
     sl4 = currprefs.gfx_filter_scanlines * 16 / 100;
     sl42 = currprefs.gfx_filter_scanlinelevel * 16 / 100;
-    if (sl4 > 15) sl4 = 15;
-    if (sl42 > 15) sl42 = 15;
+    if (sl4 > 15)
+       sl4 = 15;
+    if (sl42 > 15)
+       sl42 = 15;
     l1 = currprefs.gfx_filter_scanlineratio & 15;
     l2 = currprefs.gfx_filter_scanlineratio >> 4;
 
@@ -829,11 +831,11 @@ static void createscanlines (int force)
        return;
     }
     sld = (uae_u8*)locked.pBits;
-    for (y = 0; y < window_h; y++)
-       memset (sld + y * locked.Pitch, 0, window_w * 2);
-    for (y = 1; y < window_h; y += l1 + l2) {
-       for (yy = 0; yy < l2 && y + yy < window_h; yy++) {
-           for (x = 0; x < window_w; x++) {
+    for (y = 0; y < required_sl_texture_h; y++)
+       memset (sld + y * locked.Pitch, 0, required_sl_texture_w * 2);
+    for (y = 1; y < required_sl_texture_h; y += l1 + l2) {
+       for (yy = 0; yy < l2 && y + yy < required_sl_texture_h; yy++) {
+           for (x = 0; x < required_sl_texture_w; x++) {
                /* 16-bit, A4R4G4B4 */
                uae_u8 sll = sl42;
                p = &sld[(y + yy) * locked.Pitch + (x * 2)];
index 3e67f1227bdf27df00d0321b47c825bd0ff60a50..040ea4b08098b6453dcbf857841d14df85172a72 100755 (executable)
@@ -130,6 +130,7 @@ static uae_u32 cursorrgb[4], cursorrgbn[4];
 static int reloadcursor, cursorvisible, cursordeactivate;
 static uaecptr boardinfo;
 static int interrupt_enabled;
+int p96vblank;
 
 static uaecptr uaegfx_resname,
     uaegfx_resid,
@@ -3272,18 +3273,16 @@ void picasso_handle_hsync (void)
 
 void init_hz_p96 (void)
 {
-    int rate;
-
     p96syncrate = maxvpos * vblank_hz;
     if (currprefs.win32_rtgvblankrate < 0) 
-       rate = DirectDraw_CurrentRefreshRate ();
+       p96vblank = DirectDraw_CurrentRefreshRate ();
     else if (currprefs.win32_rtgvblankrate == 0)
-       rate = abs (currprefs.gfx_refreshrate);
+       p96vblank = vblank_hz;
     else
-       rate = currprefs.win32_rtgvblankrate;
-    if (rate <= 0)
-       rate = 60;
-    p96syncrate /= rate;
+       p96vblank = currprefs.win32_rtgvblankrate;
+    if (p96vblank <= 0)
+       p96vblank = 60;
+    p96syncrate /= p96vblank;
 }
 
 /* NOTE: Watch for those planeptrs of 0x00000000 and 0xFFFFFFFF for all zero / all one bitmaps !!!! */
index 0aa29d88ca5152733a0de497abd738ac4f7978bf..49abe4be3d75bf834ff225949509e98f6c0e0994 100755 (executable)
@@ -17,8 +17,8 @@
 
 #define WINUAEPUBLICBETA 1
 
-#define WINUAEBETA "6"
-#define WINUAEDATE MAKEBD(2008, 10, 26)
+#define WINUAEBETA "7"
+#define WINUAEDATE MAKEBD(2008, 11, 2)
 #define WINUAEEXTRA ""
 #define WINUAEREV ""
 
index 3779d9d3a140f92b7dac6e12db857a3a8738a514..60d18814db39ea398ea653059dc0c9acbb7cd44e 100755 (executable)
@@ -1028,7 +1028,7 @@ int check_prefs_changed_gfx (void)
     c |= currprefs.gfx_filter_saturation != changed_prefs.gfx_filter_saturation ? (1|8) : 0;
     c |= currprefs.gfx_filter_gamma != changed_prefs.gfx_filter_gamma ? (1|8) : 0;
     //c |= currprefs.gfx_filter_ != changed_prefs.gfx_filter_ ? (1|8) : 0;
-
+    
     c |= currprefs.gfx_resolution != changed_prefs.gfx_resolution ? (2 | 8) : 0;
     c |= currprefs.gfx_linedbl != changed_prefs.gfx_linedbl ? (2 | 8) : 0;
     c |= currprefs.gfx_lores_mode != changed_prefs.gfx_lores_mode ? (2 | 8) : 0;
index 55a2daf7da5f2a92c6f2bb2640f734bf97e24007..1012fa117a4c06d44554fe15a3a736f7e963b3ef 100755 (executable)
@@ -11825,7 +11825,7 @@ void gui_led (int led, int on)
        tt = dfx[led - 1];
        tt[0] = 0;
        if (strlen (p + j) > 0)
-           sprintf (tt, "%s (CRC=%08X)", p + j, gui_data.crc32[led - 1]);
+           sprintf (tt, "%s [CRC=%08X]", p + j, gui_data.crc32[led - 1]);
     } else if (led == 0) {
        pos = 3;
        ptr = strcpy (drive_text + pos * 16, "Power");
@@ -11836,9 +11836,13 @@ void gui_led (int led, int on)
        pos = 5;
        ptr = strcpy (drive_text + pos * 16, "CD");
     } else if (led == 7) {
+       extern int p96vblank;
        pos = 2;
        ptr = drive_text + pos * 16;
-       sprintf (ptr, "FPS: %.1f", (double)(gui_data.fps  / 10.0));
+       if (picasso_on)
+           sprintf (ptr, "%d [%.1f]", p96vblank, (double)(gui_data.fps  / 10.0));
+       else
+           sprintf (ptr, "FPS: %.1f", (double)(gui_data.fps  / 10.0));
        if (pause_emulation)
            strcpy (ptr, "PAUSED");
     } else if (led == 8) {
index 6dc9bfdf76fe30910b04188f6ab5166771341d8c..f44a0bb362c2e45923b05f9177199550e8a0a98c 100755 (executable)
@@ -1,4 +1,22 @@
 
+Beta 7:
+
+- fixed D3D scanline missing right edge
+- OCS NTSC chipset always used PAL rates
+- windowed RTG mode FPS counter shows both RTG and chipset refresh
+  rates "<RTG> [<chipset]"
+- CIA TOD didn't stop when genlock mode was enabled without genlock
+  (caused KS to detect wrong timing mode, result was most OS time
+  functions, including CLI wait-command, counted incorrectly if
+  configured chipset refresh rate was different than current refresh
+  rate. Bug since the beginning of time but genlock option made this
+  worse because old "genlock always connected" feature hide this bug..
+  (CIA-A TOD configured to PS tick didn't have this problem)
+- Syncronize clock improved. Automatically enables PS supply tick mode
+  (CIA-A TOD = sysclock only if it uses PS supply tick) and also counts
+  "lost" ticks when emulation is stopped (for example GUI is open)
+  This is still a hack but at least it seems to work now :)
+
 Beta 6:
 
 - Picasso96 vblank rewritten again, now uses build-in Picasso96 vblank
diff --git a/scsi.c b/scsi.c
index 211e1accbe86390d28dea67bf4e6c3973f3acd7a..a1fdf9421019db9368414a068de267e824b982fd 100755 (executable)
--- a/scsi.c
+++ b/scsi.c
@@ -15,7 +15,7 @@
 #include "filesys.h"
 #include "blkdev.h"
 
-static int outcmd[] = { 0x0a, 0x2a, 0xaa, -1 };
+static int outcmd[] = { 0x0a, 0x2a, 0x2f, 0xaa, -1 };
 static int incmd[] = { 0x03, 0x08, 0x12, 0x1a, 0x25, 0x28, 0x37, 0x42, 0x43, 0xa8, -1 };
 static int nonecmd[] = { 0x00, 0x35, -1 };