Peer-to-peer GUI connection adapter

Discussion of anything and everything relating to chess playing software and machines.

Moderator: Ras

User avatar
hgm
Posts: 28353
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Peer-to-peer GUI connection adapter

Post by hgm »

I just released the first (beta) version of an adapter that can be used to connect GUIs over the internet without the need for using an ICS as intermediary. Because I casted it in the form of a WB (pseudo-)engine, it should in principle be able to connect any two GUIs that both can run WB engines.

The idea is that when both sides run this p2p.exe as an engine, one of them can instruct it to connect to the other through the engine-configuration menu, by entering the IP address of the other, and pressing the Connect button.

Image

After that they can start a game, and play against each other by each starting a game against p2p with compatible parameters (i.e. if one plays white, the other had better play black!). Their respective GUIs will think they are playing an engine, but p2p will shuttle the moves between them. They can also exchange text messages, which will appear as 'thinking output' of the pseudo-engine.

For more information, see a thread in the programming forum.

Download available at http://hgm.nubati.net/p2p.zip .
User avatar
gleperlier
Posts: 1033
Joined: Sat Feb 04, 2012 10:03 pm

Re: Peer-to-peer GUI connection adapter

Post by gleperlier »

hgm wrote:I just released the first (beta) version of an adapter that can be used to connect GUIs over the internet without the need for using an ICS as intermediary. Because I casted it in the form of a WB (pseudo-)engine, it should in principle be able to connect any two GUIs that both can run WB engines.

The idea is that when both sides run this p2p.exe as an engine, one of them can instruct it to connect to the other through the engine-configuration menu, by entering the IP address of the other, and pressing the Connect button.

Image

After that they can start a game, and play against each other by each starting a game against p2p with compatible parameters (i.e. if one plays white, the other had better play black!). Their respective GUIs will think they are playing an engine, but p2p will shuttle the moves between them. They can also exchange text messages, which will appear as 'thinking output' of the pseudo-engine.

For more information, see a thread in the programming forum.

Download available at http://hgm.nubati.net/p2p.zip .
Looks good :wink:
User avatar
hgm
Posts: 28353
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Peer-to-peer GUI connection adapter

Post by hgm »

My main motivation to build it was to allow internet play with WinBoard of variants not supported by any ICS (e.g. Tenjiku Shogi). For plain Chess connecting to FICS is of course a superior alternative. But then again, there are GUIs that cannot connect to ICS, but can run WB engines...

And apart from human vs human play, it can of ocurse also be used to play engines. One simply has to load p2p plus another engine in the GUI, and start an engine-engine game. If you would start a lengthy match, you could even use it as a server that runs unattended: the GUI would automatically start a new game after the previous one finishes, and after a client disconnects p2p will simply go on listening for new connections, (meanwhile stalling the match), and continue to play games when one shows up.
IWB
Posts: 1539
Joined: Thu Mar 09, 2006 2:02 pm

Re: Peer-to-peer GUI connection adapter

Post by IWB »

That is out there for years already: http://home.arcor.de/bernhard.wallner/netChess.html

Works like a charm. Besides that, but more complicated, an SSH is always possible

Regards
Ingo


EDIT: Ahh, I dont know, maybe the difference is is Winboard. I don't know anything about that.
User avatar
hgm
Posts: 28353
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Peer-to-peer GUI connection adapter

Post by hgm »

No, that is not the same at all. The thing you mention is for connecting a GUI with a remote engine:

Image

What I made is for connecting two GUIs, so two humans can play against each other, each having a game display. EngineClient and EngineServer are the same p2p.exe in that case. The EngineServer must emulate a GUI, to connect with an engine. But p2p only connects with a GUI, and thus only has to emulate an engine.
Last edited by hgm on Sun Jul 15, 2012 8:54 pm, edited 1 time in total.
IWB
Posts: 1539
Joined: Thu Mar 09, 2006 2:02 pm

Re: Peer-to-peer GUI connection adapter

Post by IWB »

Ahh ok. Human play... I did not think about that possibility :-)

Thanks
Ingo
User avatar
hgm
Posts: 28353
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Peer-to-peer GUI connection adapter

Post by hgm »

Now also available as Linux binary:

http://hgm.nubati.net/p2p
User avatar
hgm
Posts: 28353
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Peer-to-peer GUI connection adapter

Post by hgm »

I now uploaded version 0.1, which has some bugs fixed, and also checks if both sides are using the same time control. (Same links.)
User avatar
hgm
Posts: 28353
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Peer-to-peer GUI connection adapter

Post by hgm »

Again a new version (0.2), with improved security:

This one supports a password, and refuses connections that will not have the same setting of the password option. An option to limit the length of lines sent to the GUI is also added (for the benefit of GUIs that are not secure in this respect).

Image
User avatar
abik
Posts: 823
Joined: Fri Dec 01, 2006 10:46 pm
Location: Mountain View, CA, USA
Full name: Aart Bik

Re: Peer-to-peer GUI connection adapter

Post by abik »

And binary available for ARM-based Android devices (under H.G. Muller's Engines and Tools):

p2p for Android