Hub-1 protocol

Discussion about development of draughts in the time of computer and Internet.
Maurits Meijer
Posts: 221
Joined: Thu Nov 27, 2008 19:22
Contact:

Re: Hub-1 protocol

Post by Maurits Meijer » Tue May 02, 2017 20:49

Thanks,

I will figure it out, np.

I am not a fan of textbased protocols, I know very little about them. Perhaps the definition should state it's in random order. Don't read to much into it i'm not a fan of reading.

I'm working on a scan based bot for the live playing on Slagzet.com; I hope to have something working well enough by tomorrow evening.

Cheers,
Maurits
http://slagzet.com

Fabien Letouzey
Posts: 299
Joined: Tue Jul 07, 2015 07:48
Real name: Fabien Letouzey

Re: Hub-1 protocol

Post by Fabien Letouzey » Wed May 03, 2017 08:23

Maurits Meijer wrote:I am not a fan of textbased protocols, I know very little about them. Perhaps the definition should state it's in random order. Don't read to much into it i'm not a fan of reading.

I'm working on a scan based bot for the live playing on Slagzet.com; I hope to have something working well enough by tomorrow evening.
You can have a look at what Mig did in JoclyBoard, which is written in JS. He only used a subset of the protocol to run a game.

If you strip the captured pieces from the move string, you more or less obtain standard notation. But then, it doesn't work for ambiguous moves anymore.

Fabien.

mig
Posts: 33
Joined: Thu Mar 16, 2017 13:09
Real name: Michel Gutierrez

Re: Hub-1 protocol

Post by mig » Wed May 03, 2017 10:30

What i do with JoclyBoard, is that i order the captured pieces in the capture moves returned by scan, i do the same for the moves generated by my own Jocly implementation, so i can compare identically coded moves.
Fabien Letouzey wrote:
Maurits Meijer wrote:I am not a fan of textbased protocols, I know very little about them. Perhaps the definition should state it's in random order. Don't read to much into it i'm not a fan of reading.

I'm working on a scan based bot for the live playing on Slagzet.com; I hope to have something working well enough by tomorrow evening.
You can have a look at what Mig did in JoclyBoard, which is written in JS. He only used a subset of the protocol to run a game.

If you strip the captured pieces from the move string, you more or less obtain standard notation. But then, it doesn't work for ambiguous moves anymore.

Fabien.

Maurits Meijer
Posts: 221
Joined: Thu Nov 27, 2008 19:22
Contact:

Re: Hub-1 protocol

Post by Maurits Meijer » Wed May 03, 2017 13:06

mig wrote:What i do with JoclyBoard, is that i order the captured pieces in the capture moves returned by scan, i do the same for the moves generated by my own Jocly implementation, so i can compare identically coded moves.
Thanks. I'm just gonna sort all the field numbers.
http://slagzet.com

ArthurK
Posts: 22
Joined: Wed Mar 19, 2014 12:59
Real name: Arthur Kalverboer
Location: Groningen, The Netherlands

Re: Hub-1 protocol

Post by ArthurK » Fri Aug 31, 2018 13:00

Web interface for Scan.
I have created a web interface to play draughts against an engine that supports the hub protocol.
Practically speaking, it means you can use your web browser to play against the Scan engine of Fabien Letouzey.
I expect it is platform independent so you can use it with Windows, macOS or Linux.
To make it working, what you have to do is:
- Install Scan locally or on your network.
- Copy the executable file for your OS from the site: WebSocket daemon.
- Start Scan in the terminal with the WebSocket daemon (***).
- Start the web interface with your browser, make a connection with Scan and start the initialization.
- You are now ready to play a game against Scan.

(***) Reserve some time to find out which command you had to use to start Scan.
On my Linux OS I use the command: ./websocketd --port=27532 ./scan hub
The port I use is the default port number of the web interface.
To keep it simple I put the WebSocket daemon executable in the same folder as the scan executable.
See the WebSocket daemon page to understand how to start Scan.

For me it works great. You can find the web interface [url=http://svg_experimenten.deds.nl/whub_client/whub.html]here[/url].
For the sake of fun I included two very simple build-in engines: a random player and a minimax player.
Enjoy!

Sidiki
Posts: 322
Joined: Thu Jan 15, 2015 16:28
Real name: Coulibaly Sidiki

Re: Hub-1 protocol

Post by Sidiki » Sun Sep 02, 2018 22:37

ArthurK wrote:Web interface for Scan.
I have created a web interface to play draughts against an engine that supports the hub protocol.
Practically speaking, it means you can use your web browser to play against the Scan engine of Fabien Letouzey.
I expect it is platform independent so you can use it with Windows, macOS or Linux.
To make it working, what you have to do is:
- Install Scan locally or on your network.
- Copy the executable file for your OS from the site: WebSocket daemon.
- Start Scan in the terminal with the WebSocket daemon (***).
- Start the web interface with your browser, make a connection with Scan and start the initialization.
- You are now ready to play a game against Scan.

(***) Reserve some time to find out which command you had to use to start Scan.
On my Linux OS I use the command: ./websocketd --port=27532 ./scan hub
The port I use is the default port number of the web interface.
To keep it simple I put the WebSocket daemon executable in the same folder as the scan executable.
See the WebSocket daemon page to understand how to start Scan.

For me it works great. You can find the web interface [url=http://svg_experimenten.deds.nl/whub_client/whub.html]here[/url].
For the sake of fun I included two very simple build-in engines: a random player and a minimax player.
Enjoy!
Thank very much Arthurk
After severals try, i succefully done it with Windows OS.
connected.JPG
connected.JPG (150.83 KiB) Viewed 8448 times

My main question it's how to connect Scan with the websocketd on a network or on an server? ie is'it possible to upload scan on a server and play without our physical computer. Play o Android for example.
Thank

Sidiki..
Attachments
whub1.JPG
whub1.JPG (84.41 KiB) Viewed 8448 times

ArthurK
Posts: 22
Joined: Wed Mar 19, 2014 12:59
Real name: Arthur Kalverboer
Location: Groningen, The Netherlands

Re: Hub-1 protocol

Post by ArthurK » Mon Sep 03, 2018 10:07

Web interface for Scan.
Congratulations Sidiki! I am glad to hear it works for you on a Windows computer.
Indeed, it is possible to upload scan (and websocketd) on a server and play without your physical computer.
In the section "Engine control" of the web interface fill the host item with the name of the server (ip-adres or host name).
I expect it works for an Android client but I have not tested it.

Sidiki
Posts: 322
Joined: Thu Jan 15, 2015 16:28
Real name: Coulibaly Sidiki

Re: Hub-1 protocol

Post by Sidiki » Mon Sep 03, 2018 12:22

ArthurK wrote:Web interface for Scan.
Congratulations Sidiki! I am glad to hear it works for you on a Windows computer.
Indeed, it is possible to upload scan (and websocketd) on a server and play without your physical computer.
In the section "Engine control" of the web interface fill the host item with the name of the server (ip-adres or host name).
I expect it works for an Android client but I have not tested it.
Thank Arthurk, i will read this section carefully. It can help us to play anywhere our draughts programs that use dxp.

For Android can you test it or if possible do a Kind of hub that locate scan engine on the phone. Scan engine for Android has already be created and uploaded by a user of this forum, ardik.

Someone also done for iOS Scan all in one, ie with a board, all implemented into it.
Thank again.

Sidiki

Post Reply