Schachcomputer.info Community

Schachcomputer.info Community (https://www.schachcomputer.info/forum/index.php)
-   Mess Emu & andere Emulationen / Mess Emu and other Emulations (https://www.schachcomputer.info/forum/forumdisplay.php?f=53)
-   -   MessEmu: A patch for AT mode of the Novag Sapphire (https://www.schachcomputer.info/forum/showthread.php?t=7152)

Mychess 04.08.2024 15:28

A patch for AT mode of the Novag Sapphire
 
Hello,

I propose this patch for the Novag Sapphire.
I've obtained a behavior that seems correct (even if it's difficult to determine), but I'm waiting for test results from those interested in this mode.

Code:


0D24: 5E 00 74 9A 00 00     

5E84: 0D 50 5E 00 74 72   

6B91: 04 5E 00 74 66 5E 00 74
6B99: 80 00 00               

7466: 79 02 FB F6 6B 00 FF 60
746E: 29 63 54 70 5E 00 74 80
7476: 0D 05 FE 00 10 8D 12 05
747E: 54 70 6D F5 0D 05 11 05
7486: 13 0D 11 05 13 0D 11 05
748E: 13 0D 11 05 13 0D 19 50
7496: 6D 75 54 70 F9 28 A8 08
749E: 45 02 F9 01 38 65 39 63
74A6: 54 70   

CRC(8E45A395) SHA1(C4C43C5328227A35E34A5D19EEFECC48B1571B3D)

Cordialy,

mychess.

fhub 04.08.2024 16:36

AW: A patch for AT mode of the Novag Sapphire
 
Zitieren:

Zitat von Mychess (Beitrag 127825)
I propose this patch for the Novag Sapphire.
I've obtained a behavior that seems correct (even if it's difficult to determine), but I'm waiting for test results from those interested in this mode.

Thanks for this patch, Mychess!

I'll try it when I have time - at the moment I'm still busy with improving the Blitz plugin. ;)

Regards,
Franz

fhub 06.08.2024 14:19

AW: A patch for AT mode of the Novag Sapphire
 
Hi Mychess,

I've now tested your patch (with level AT 4) and after a few games it seems to work - it's not falling back to blitz mode anymore. :)

But of course it would take a lot of further testing to determine whether the Sapphire actually sticks to the set times, especially without knowing what exactly your additional code is doing.
Since I don't speak this H8 language and therefore can't analyze this code, it would be nice if you could give a short explanation of what exactly you did.

Weiter auf Deutsch:
Falls jemand diesen Sapphire-Patch von Mychess für die fehlerhaften AT-Stufen testen möchte - ich hab eine spezielle MessNew-Version dafür gemacht, wo man im Tab-Menü unter 'BIOS Selection' zwischen den ROM-Versionen 'original' und 'modified' (von Mychess) wählen kann.

Um das zu vereinfachen, findet ihr im Anhang eine 'Sapphire_Testversion', die man nur ins MessNew-Verzeichnis entpacken braucht. Da ist bereits alles auf diese 'modified'-Version voreingestellt (z.B. auch fix_AT_level_bug = false im Plugin gesetzt), sodaß beim Aufruf des Sapphire mit MessChess (bzw. WinBoard oder Arena) man automatisch mit der von Mychess gepatchten Version spielt und damit testen kann, ob die AT-Stufen nun wirklich funktionieren - nur den zum Testen gewünschten AT-Level muß man natürlich einstellen.
Auf den ersten Blick sieht es jedenfalls gut aus. :)

Edit: Link entfernt, da dieser modifizierte Sapphire in der aktuellen CB-Emu-Version bereits enthalten ist - allerdings muß er nun selbst in 'File > Show Tab Menu > BIOS Selection' ausgewählt werden.
Und bei Verwendung mit MessChess (bzw. WinBoard oder Arena) muß man bei Verwendung von AT-Stufen selbst im Plugin 'sapphire.lua' auf 'fix_AT_level_bug = false' umstellen.

Grüße,
Franz

Robert 08.08.2024 09:24

AW: A patch for AT mode of the Novag Sapphire
 
Hallo Franz,

ich bekomme eine Fehlermeldung, wenn ich die Datei entpacken will...

fhub 08.08.2024 09:38

AW: A patch for AT mode of the Novag Sapphire
 
Zitieren:

Zitat von Robert (Beitrag 127887)
ich bekomme eine Fehlermeldung, wenn ich die Datei entpacken will...

Ja, hab's eben auch nochmal probiert - die heruntergeladen ZIP-Datei ist um ca. 1MB zu klein.
Da muß wohl auf dem Forum-Server irgendwas schiefgegangen sein. :(

Vielleicht kann die Datei ja jemand anderer nochmal posten - ich hab gerade keine Zeit ...

Robert 08.08.2024 09:39

AW: A patch for AT mode of the Novag Sapphire
 
Zitieren:

Zitat von fhub (Beitrag 127888)
Vielleicht kann die Datei ja jemand anderer nochmal posten - ich hab gerade keine Zeit ...

Na ja, es eilt ja nicht... ;)

fhub 08.08.2024 09:51

AW: A patch for AT mode of the Novag Sapphire
 
Zitieren:

Zitat von Robert (Beitrag 127889)
Na ja, es eilt ja nicht... ;)

Zum Glück hatte ich die Datei noch, also hab ich sie nochmals hochgeladen -
leider wieder mir gleichem Ergebnis: der Download ist wieder fehlerhaft! :(

Keine Ahnung, was da mit dem Forum-Server los ist ...

Robert 08.08.2024 10:41

AW: A patch for AT mode of the Novag Sapphire
 
Das scheint mit der Größe zusammenzuhängen: Wenn ich eine andere, ähnlich große Datei hochlade, ist sie nach dem Download auch fehlerhaft und ca. 1 MB kleiner.

Bei einer kleineren (1,4 MB) passiert das nicht.

Aber normalerweise wird eine Datei ja abgewiesen, wenn sie zu groß ist...

fhub 08.08.2024 12:17

AW: A patch for AT mode of the Novag Sapphire
 
Zitieren:

Zitat von Robert (Beitrag 127892)
Das scheint mit der Größe zusammenzuhängen: Wenn ich eine andere, ähnlich große Datei hochlade, ist sie nach dem Download auch fehlerhaft und ca. 1 MB kleiner.

Ja, ist schon seltsam, was da vor sich geht.

Ich hab die Datei jetzt auf meinem Download-Verzeichnis nochmal hochgeladen (Link im Original-Posting ist auch geändert):

Sapphire_Testversion:
Edit: Link entfernt, da dieser modifizierte Sapphire in der aktuellen CB-Emu-Version bereits enthalten ist - allerdings muß er nun selbst in 'File > Show Tab Menu > BIOS Selection' ausgewählt werden.

Grüße,
Franz

Robert 08.08.2024 14:38

AW: A patch for AT mode of the Novag Sapphire
 
Gerade läuft die zweite Testpartie mit BearChess; schaut gut aus! :top:

@Mychess: Thank you for the patch! It doesn't change the time-management of the AT-levels, only this nasty bug is fixed, correct?

Btw.: How about a patch for the Emerald classic plus? :zwinker:

Mychess 11.08.2024 11:15

Re: A patch for AT mode of the Novag Sapphire
 
Hello,

Sorry for the late reply, but I was entertaining my family on vacation.

I decoded about 750 lines of H8 assembler to make this patch.
There were 3 main bugs, including the treatment according to the color to move, and the calculation of the new average time after each move.

In the end, I ONLY took the AT mode code from the Sapphire II and adapted it (different offsets) to the Sapphire.

For the Emerald Classic Plus, I'll have a look at the code.

Cordialy,

mychess.

fhub 14.08.2024 13:30

AW: Re: A patch for AT mode of the Novag Sapphire
 
Hi Mychess!

Similar to your Sapphire patch, I have now also made a patch for the Diamond, which shouldn't be particularly difficult because the two programs are practically identical (apart from the hardware control).

The easiest task was to adjust the addresses. Only some values ​​(registers?) were different on the Diamond than on the Sapphire, so I changed those accordingly (these values are ff62/ff65/ff67 in the Diamond but ff60/ff63/ff65 in the Sapphire).

Here is an assembly list of my changes - maybe you can take a look at these changes and let me know if everything is ok?
I've also attached the modified Diamond ROM with exactly these changes - I've already tried it here in MessNew and it seems to work correctly.

Regards,
Franz

Code:

changed from:
0E9A: F928      mov.b  #h'28, r1l
0E9C: 3867      mov.b  r0l, @h'ff67
0E9E: 3965      mov.b  r1l, @h'ff65
to:
0E9A: 5E00 7568 jsr    h'7568
0E9E: 0000      nop

changed from:
6090: FE00      mov.b  #h'00, r6l
6092: 108D      shal.b  r5l
6094: 1205      rotxl.b r5h
to:
6090: 0D50      mov.w  r5, r0
6092: 5E00 7540 jsr    h'7540

changed from:
6CA0: 4A0A      bpl    h'6cac
6CA2: 7902 FBF6 mov.w  #h'fbf6, r2
6CA6: 6B00 FF62 mov.w  @h'ff62, r0
6CAA: 2965      mov.b  @h'ff65, r1l
to:
6CA0: 4A04      bpl    h'6ca6
6CA2: 5E00 7534 jsr    h'7534
6CA6: 5E00 754E jsr    h'754e
6CAA: 0000      nop

added:
7534: 7902 FBF6 mov.w  #h'fbf6, r2
7538: 6B00 FF62 mov.w  @h'ff62, r0
753C: 2965      mov.b  @h'ff65, r1l
753E: 5470      rts
7540: 5E00 754E jsr    h'754e
7544: 0D05      mov.w  r0, r5
7546: FE00      mov.b  #h'00, r6l
7548: 108D      shal.b  r5l
754A: 1205      rotxl.b r5h
754C: 5470      rts
754E: 6DF5      mov.w  r5, @-r7
7550: 0D05      mov.w  r0, r5
7552: 1105      shlr.b  r5h
7554: 130D      rotxr.b r5l
7556: 1105      shlr.b  r5h
7558: 130D      rotxr.b r5l
755A: 1105      shlr.b  r5h
755C: 130D      rotxr.b r5l
755E: 1105      shlr.b  r5h
7560: 130D      rotxr.b r5l
7562: 1950      sub.w  r5, r0
7564: 6D75      mov.w  @r7+, r5
7566: 5470      rts
7568: F928      mov.b  #h'28, r1l
756A: A808      cmp.b  #h'08, r0l
756C: 4502      bcs    h'7570
756E: F901      mov.b  #h'01, r1l
7570: 3867      mov.b  r0l, @h'ff67
7572: 3965      mov.b  r1l, @h'ff65
7574: 5470      rts


Mychess 14.08.2024 15:47

Re: A patch for AT mode of the Novag Sapphire
 
Hi Fhub,

I don't have the diamond roms so I couldn't make this patch.
But you have made a perfect patch.

Concerning the Emerald Classic Plus, complicated time management but it seems that the patch is just that:

47E7: 20 (in place of 10)

Best Regards.

mychess

fhub 14.08.2024 16:04

AW: Re: A patch for AT mode of the Novag Sapphire
 
Hi Mychess,
Zitieren:

Zitat von Mychess (Beitrag 127950)
I don't have the diamond roms so I couldn't make this patch.
But you have made a perfect patch.

thanks - my first patch for a H8 program (although I don't understand a single line of this code :D).
But it wasn't very difficult to make it after your Sapphire patch.
Zitieren:

Concerning the Emerald Classic Plus, complicated time management but it seems that the patch is just that:
47E7: 20 (in place of 10)
Oh, that would be simple - I'll test it!

Regards,
Franz

Mychess 14.08.2024 16:19

Re: AW: Re: A patch for AT mode of the Novag Sapphire
 
Zitieren:

Zitat von fhub (Beitrag 127951)
Hi Mychess,

thanks - my first patch for a H8 program (although I don't understand a single line of this code :D).
But it wasn't very difficult to make it after your Sapphire patch.

Oh, that would be simple - I'll test it!

Regards,
Franz

Beware that AT level is very special, and difficult to follow (for me).

"The computer will use half of the specified time to calculate the counter-move and use the remaining time to complete the search. The time varies in the opening game, the middle game and end game position accordingly. The
computer tends to play faster in the openings and endgame positions, but in complicated middle game positions it may take longer to make its move. Depending on the position the computer may take up to four times the set time on these levels." from Novag.

Best Regards,

mychess

fhub 14.08.2024 17:32

AW: A patch for AT mode of the Novag Sapphire
 
Hi,

ich hab jetzt eine MessNew_Test-Version hochgeladen, die alle 3 Patches für den AT-Level-Bug bei Diamond/Emerald/Sapphire enthält.
Falls das jemand testen möchte - hier ist der Link:
https://c.gmx.net/@31720685988479052...SP23WQRnVaGfmw

Diese Datei braucht man nur über das bestehende MessNew-Verzeichnis entpacken. Die gepatchten Versionen aktiviert man am besten, indem man die Engine(s) direkt in MessNew startet, unter 'File > Show Tab Menu > BIOS Selection' das System 'modified' auswählt, und auf 'Reset' doppelklickt - danach wird diese gepatchte Version auch beim Start in MessChess verwendet.

Beim Emerald habe ich noch Zweifel, ob dieser Patch auch tatsächlich etwas bringt - irgendwie erscheint mir diese 1-Byte-Änderung zu einfach!?
Außerdem merke ich eigentlich auch beim originalen Emerald diesen angeblichen AT-Level-Bug nicht wirklich (oder er setzt erst viel später ein als ich bisher probiert habe).

Grüße,
Franz

Robert 20.08.2024 00:02

AW: A patch for AT mode of the Novag Sapphire
 
Hallo Franz,

Zitieren:

Zitat von fhub (Beitrag 127953)
Beim Emerald habe ich noch Zweifel, ob dieser Patch auch tatsächlich etwas bringt - irgendwie erscheint mir diese 1-Byte-Änderung zu einfach!?
Außerdem merke ich eigentlich auch beim originalen Emerald diesen angeblichen AT-Level-Bug nicht wirklich (oder er setzt erst viel später ein als ich bisher probiert habe).

Allzuviel bringt dieser Patch tatsächlich nicht: In einer Partie über 76 Züge verbrauchte der ECP laut eigener Uhr 18'29" (laut BearChess 22'43"); das ist zwar deutlich besser als vorher, aber immer noch weit entfernt von dem, was man erwarten würde.

Also würde ich immer noch empfehlen, auf die entsprechenden Turnierstufen auszuweichen bzw. den Level-Fix zu verwenden.

fhub 20.08.2024 00:19

AW: A patch for AT mode of the Novag Sapphire
 
Hallo Robert,
Zitieren:

Zitat von Robert (Beitrag 128014)
Allzuviel bringt dieser Patch tatsächlich nicht: In einer Partie über 76 Züge verbrauchte der ECP laut eigener Uhr 18'29" (laut BearChess 22'43"); das ist zwar deutlich besser als vorher, aber immer noch weit entfernt von dem, was man erwarten würde.

nun, das sind ja ohnehin etwa 15 sec/Zug - so lange denkt er im Durchschnitt ja auch am Beginn der Partie bei Level AT 6 (30 sec/Zug), also wo ist denn da eine Verkürzung der Zugzeit nach einigen Zügen (bzw. im Verlauf der Partie) zu erkennen wie bei Sapphire und Diamond?
Zitieren:

Also würde ich immer noch empfehlen, auf die entsprechenden Turnierstufen auszuweichen bzw. den Level-Fix zu verwenden.
Das kann ja jeder halten wie er will, die Möglichkeiten dafür sind ja da.

Grüße
Franz


Alle Zeitangaben in WEZ +2. Es ist jetzt 09:57 Uhr.

Powered by vBulletin (Deutsch)
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
©Schachcomputer.info