Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: How to implement autoplay

Author: Gerd Isenberg

Date: 08:07:35 11/11/02

Go up one level in this thread


On November 11, 2002 at 10:13:52, Robert Hyatt wrote:

>On November 11, 2002 at 06:11:27, Gerd Isenberg wrote:
>
>>As a kind of illiterate in internet chess protocols, sockets and WinBoard, i am
>>looking for some help to implement automatic playing for ICC in IsiChess without
>>using WinBoard. Using MSC++ i guess to use a CSocket or CAsyncSocket class.
>>
>>Are there any descriptions or code samples how to do it?
>>
>>Thanks in advance,
>>Gerd
>
>
>In the unix world, it is trivial.
>
>The steps are:
>
>look up the hostname (chessclub.com) using gethostbyname().  Copy the
>ip address into a sockaddr structure.
>
>You need to fill in the port number, which for ICC is 5000.  (I will attach
>a simple example at the end of this).
>
>
>create a socket.
>
>Do a connect using the above socket and sockaddr structure and you will get an
>open full-duplex socket that you can use to read/write data from/to the chess
>server.  All you have to figure out is how to handle the data you get, parse
>the style-12 chessboard description which will give you the current position
>and move (you can use either or both).


Thanks Bob, that should help.

>
>The obvious question is "why not use xboard/winboard?"  That gives you already-
>working code, with a nice GUI to watch the games on, zippy to parse/accept
>match requests automatically, etc...

I really don't know, what's the best way for me.

I made my own Windows-GUI with some kind of Multiple Document Interface, and a
lot of debug/statistic windows.
Documents are associated with one "SearchTree"-Objects. It is possible to open
several game-documents, for eg. playing simultaniously, but even i can open
several chess-windows on the same chess-document eg. to analyze several
positions from one game with a shared transposition table etc.

I have simply no experience with WinBoard at all.

I had no problems a few years ago with my DOS-Program to implement Donningers
auto232 "protocol" with low level USART (8055?) programming.

May be i am affected by some GUI and proprietary MS-Windows stuff, like event
driven applications with a message loop rather than sequential console
applications.

Another point is some laziness to snatch up with some topics i am not so
interesting in and familar with.

Gerd

<snip>



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.