X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=engine-intf.html;h=02166eac3156192f31dc75b77504fc6472c67040;hb=c3790f0d51cada3077e31626098a0de1f7c52df3;hp=3fac3643087a46296fb010aee81f9506af577da5;hpb=05bc30b15e31c427ce208495a889e9ff36e6642b;p=xboard.git diff --git a/engine-intf.html b/engine-intf.html index 3fac364..02166ea 100644 --- a/engine-intf.html +++ b/engine-intf.html @@ -1,4 +1,3 @@ -
-Last modified on Mon Feb 5 23:23:16 PST 2001 by mann
+$Id$
Version 2; implemented in xboard/WinBoard 4.2.1 and later.
Changes since version 1 are indicated in red.
-There are two reasons I can imagine someone wanting to do this: +There are two reasons I can imagine someone wanting to do this:
I'd like to hear from everyone who is trying to interface their own -chess engine to xboard/WinBoard. Please email me, tim.mann@compaq.com. Also, please join -the mailing list for authors of xboard/WinBoard compatible chess -engines. The list is now hosted by egroups.com; you can join at http://www.egroups.com/group/chess-engines, or you can read the +chess engine to xboard/WinBoard. Please join the mailing list for +authors of xboard/WinBoard compatible chess engines and post a message +about what you're doing. The list is now hosted by Yahoo Groups; you +can join at http://groups.yahoo.com/group/chess-engines, or you can read the list there without joining. The list is filtered to prevent spam.
@@ -98,7 +96,7 @@ implemented in Win32 and work fine. You don't have to use DDE, COM, DLLs, BSOD, or any of the other infinite complexity that Microsoft has created just to talk between two programs. A WinBoard chess engine is a Win32 console program that simply reads from its -standard input and writes to its standard output. See sections +standard input and writes to its standard output. See sections 5 and 6 below for additional details. @@ -155,14 +153,14 @@ features to be slightly different from what GNU Chess 4 does. This release of the protocol specification is the first to carry a version number of its own -- version 2. Previous releases simply -carried a last-modified date and were loosely tied to specific +carried a last-modified date and were loosely tied to specific releases of xboard and WinBoard. The version number "1" applies generally to all those older versions of the protocol.Protocol version 2 remains compatible with older engines but has -several new capabilities. In particular, it adds the +several new capabilities. In particular, it adds the "feature" command, a new mechanism for making backward-compatible changes and extensions to the protocol. Engines that do not support a particular new feature do not have to use it; new features are not @@ -173,8 +171,8 @@ features can be selected by the feature command in version 2, including the "ping" command (recommended for all engines), the "setboard" command, and many optional parameters. Additional features will probably be added in future versions. -
+Here are details for the curious. If xboard needs to send a command -when it is the chess engine's move (such as before the "?" command), +when it is the chess engine's move (such as before the "?" command), it sends a SIGINT first. If xboard needs to send commands when it is not the chess engine's move, but the chess engine may be pondering (thinking on its opponent's time) or analyzing (analysis or analyze @@ -368,7 +366,7 @@ file mode), xboard sends a SIGINT before the first such command only. Another SIGINT is not sent until another move is made, even if xboard issues more commands. This behavior is necessary for GNU Chess 4. The first SIGINT stops it from pondering until the next move, but on some -systems, GNU Chess 4 will die if it receives a SIGINT when not +systems, GNU Chess 4 will die if it receives a SIGINT when not actually thinking or pondering.
@@ -404,7 +402,7 @@ position. It will later send the initString again to start a new game. If your engine can't play multiple games, you can disable reuse either with the "feature" command (beginning in protocol version -2; see below) or +2; see below) or with xboard's -xreuse (or -xreuse2) command line option. xboard will then ask the process to quit after each game and @@ -420,9 +418,9 @@ user input, you must turn off the prompt and output a newline when the "xboard" command comes in.
-
-
-
-
@@ -533,17 +531,17 @@ reply.
-
+
-
+
This sequence is used to avoid the "black" command, which is now -considered obsolete and which many engines never did implement as +considered obsolete and which many engines never did implement as specified in this document.
@@ -833,23 +831,23 @@ your default is for pondering or whether "new" affects this setting.- +
- +
rating 2600 1500
-
-
-
-
Here are the features that are currently defined.
+
-Generally, xboard will never send an ambiguous move, so it does not -matter whether you respond to such a move with an Illegal move message +Generally, xboard will never send an ambiguous move, so it does not +matter whether you respond to such a move with an Illegal move message or an Error message.
@@ -1238,9 +1309,9 @@ Machine Black, or Two Machines mode, the offer is considered valid until your engine has made two more moves.
-
-
-
-
-
@@ -1379,30 +1450,30 @@ units. Example:
If your engine is pondering (thinking on its opponent's time) in post
@@ -1503,11 +1574,11 @@ on one move does not accumulate for use on later moves.
xboard supports analyzing fresh games, edited positions, and games
from files. However, all of these look the same from the chess
engine's perspective. Basically, the engine just has to respond to the
-"analyze" command.
+"analyze" command.
Beginning in protocol version 2,
if your engine does not support analyze mode, it should use
-the feature command to set analyze=0.
+the feature command to set analyze=0.
The older method of
printing the error message "Error (unknown command): analyze" in
@@ -1515,7 +1586,7 @@ response to the "analyze" command will also work, however.
-To enter analyze mode, xboard sends the command sequence "post", "analyze".
+To enter analyze mode, xboard sends the command sequence "post", "analyze".
Analyze mode in your engine should be
similar to force mode, except that your engine thinks about what move
it would make next if it were on move. Your engine should accept the
@@ -1526,19 +1597,18 @@ following commands while in analyze mode:
If the user selects "Periodic Updates", xboard will send the string
".\n" to the chess engine periodically during analyze mode, unless the
@@ -1602,7 +1672,7 @@ figure this out itself.
Some engines have variant interpretations of the force/go/white/black,
-time/otim, and hard/easy command sets.
+time/otim, and hard/easy command sets.
In order to accommodate these older engines, xboard uses these commands
only according to the stylized patterns ("idioms") given in this section.
The obsolete white and black commands
@@ -1623,7 +1693,7 @@ playing the opposite color.
- 2. 14 0 38 d1d2 e8e7
- 3+ 78 0 65 d1d2 e8e7 d2d3
- 3& 14 0 89 d1d2 e8e7 d2d3
- 3& 76 0 191 d1e2 e8e7 e2e3
- 3. 76 0 215 d1e2 e8e7 e2e3
- 4& 15 0 366 d1e2 e8e7 e2e3 e7e6
- 4. 15 0 515 d1e2 e8e7 e2e3 e7e6
- 5+ 74 0 702 d1e2 f7f5 e2e3 e8e7 e3f4
- 5& 71 0 1085 d1e2 e8e7 e2e3 e7e6 e3f4
- 5. 71 0 1669 d1e2 e8e7 e2e3 e7e6 e3f4
- 6& 48 0 3035 d1e2 e8e7 e2e3 e7e6 e3e4 f7f5 e4d4
- 6. 48 0 3720 d1e2 e8e7 e2e3 e7e6 e3e4 f7f5 e4d4
- 7& 48 0 6381 d1e2 e8e7 e2e3 e7e6 e3e4 f7f5 e4d4
- 7. 48 0 10056 d1e2 e8e7 e2e3 e7e6 e3e4 f7f5 e4d4
- 8& 66 1 20536 d1e2 e8e7 e2e3 e7e6 e3d4 g7g5 a2a4 f7f5
- 8. 66 1 24387 d1e2 e8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