Chess GUI

Posted by ALB42 on 16. Oktober 20214 Comments

Maybe you remember when I improved the TProcess implementation for MorphOS using a Chess GUI and an uci chess client. The Author of that chess client contacted me to ask if I could publish the Chess GUI. I did not plan to publish it because it was really just a test, but ok, why not. It also includes the Source (LGPL) and some engines (also the mentioned predateur, which works nicely)

Download MUIeschecs with Source and engines

4 comments to "Chess GUI"

  1. Wow, thanks a lot, Marcus !

    It works splendidly on MorphOS !

    I also tried to compile it for OS4.1 and after quite some* sweat, got a seemingly working version running well… at least for human vs human. Because when I select Prédateur, Eschecs just hangs :

    Have you met such a problem ?

    *an awful lot of

    • ALB42 sagt:

      Hi Julien,

      nice work, 😉 what was the reason for the sweat? the MUIClass dependancy?

      The hanging is to be expected (and before you ask the same will happen on AROS and Amiga68k, will work for human/human but hang with external chess machines)
      The reason is simple, see also the original Blog Entry. The purpose of this program was to try and debug the MorphOS TProcess and Pipe implementation in FreePascal. The Pipe in MorphOS has some new features which makes it possible to do this.

      Usually on Amiga if you Open() a file you can read the size or just Read() until you get an EOF (end of file). But thats not true for files inside Pipe: because a Read() call will never reach EOF. And size will be always 0. If you try to Read() more chars than there are currently in the piped file it will just hang and wait for more chars to come, forever if no chars arrive, no timeout or so. That is still true for MorphOS but here you can use ExamineFH() to get how many chars there are to read, preventing to read too many… and therefore lock. (if you look into the code you will also see some {$ifdef MorphOS})

      • Oh, I see, thanks for the explanations. I actually did a first try with pipes seven years ago (here’s the discussion on MorphZone : ) and it appeared that the most hopeful way to get a chess engine talk with a chess interface on the Amiga would be to design an ad hoc DOS handler… which was a bit out of my league back then.
        Still, someone managed to create a working chess interface for OS4 and AROS, although, as it is closed source, I don’t know what technique he used :

        As for the time it took me to build Eschecs for OS4.1, it’s maily because I emulate OS4.1 in Qemu and it is very slow : compiling Eschecs and all its dependecies took nearly three hours. More, actually, as I encountered several errors that needed fixing. 🙂

        • ALB42 sagt:

          There is an other way to do it, instead of Read() one can use FGetS to get the Pipe: file contents which more or less works (also on MorphOS I use that atm) so in principle it should be possible to do that. (I guess AmiChess uses that, if you look into the engines folder you will find it there as well 😉 )
          The most easy solution would be to kick out the TProcess stuff from the program and directly code the process starting and pipe: handling maybe then it should work also on OS4.
          3 Hours :-O omg would’nt it be much more clever to use crosscompile? in 3 hours you should be able to install a cross compiler for yourself 😉
          or you even use the docker container I provide for that? Also possible to directly compile without need for the GUI.

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert