How to setup a position with the XBoard protocol?

Programming Topics (Computer Chess) and technical aspects as test techniques, book building, program tuning etc

Moderator: Andres Valverde

How to setup a position with the XBoard protocol?

Postby kinderchocolate » 18 Jul 2013, 12:48

Is the XBoard protocol stupid? It's common to have a FEN for a position. But unlike the UCI, the XBoard protocol doesn't understand FEN! So my question is, if I have a FEN, how do I setup it up on a XBoard engine?
kinderchocolate
 
Posts: 12
Joined: 14 Oct 2010, 11:05

Re: How to setup a position with the XBoard protocol?

Postby Pedro Castro » 18 Jul 2013, 17:35

Xboard protocol version 2 has "setboard" command. You must use a GUI like Arena or Winboard to configure the position and GUI send this position to engine in FEN format if engine supports the setboard command.

Some engines will have an option to set a position from the console, but most do not.

It is engine who understands the FEN format, not the protocol.
Best wishes,

Pedro Castro
User avatar
Pedro Castro
 
Posts: 180
Joined: 28 Jan 2005, 01:09
Location: Pays Basque (Spain)

Re: How to setup a position with the XBoard protocol?

Postby kinderchocolate » 19 Jul 2013, 18:56

I need some help. I tried to edit a position with a king on h1 and a king on h8.


_adapter->write("new");
_adapter->write("random");
_adapter->write("force");
_adapter->write("edit");
_adapter->write("#");

_adapter->write("Kh1");
_adapter->write("c");
_adapter->write("Kh8");

_adapter->write(".");
_adapter->write("force");



The commands don't work... Anybody knows why?
kinderchocolate
 
Posts: 12
Joined: 14 Oct 2010, 11:05

Re: How to setup a position with the XBoard protocol?

Postby Pedro Castro » 19 Jul 2013, 19:34

It is difficult to help you if you do not give more information.

For example you are using a engine? Which?

you are using a GUI? Which?

It seems that the GUI is sending a position with the old edit command of xboard protocol, perhaps the engine you're using does not support the xboard protocol version 2 and therefore does not receive a FEN position with setboard command. And maybe the engine also not supports the edit command.
Best wishes,

Pedro Castro
User avatar
Pedro Castro
 
Posts: 180
Joined: 28 Jan 2005, 01:09
Location: Pays Basque (Spain)


Return to Programming and Technical Discussions

Who is online

Users browsing this forum: No registered users and 4 guests