sronco / mame-chessengine

MAME Chess UCI/XBoard Interface plugin
10 stars 6 forks source link

Support for mephisto and glasgow drivers #2

Closed sshivaji closed 6 years ago

sshivaji commented 7 years ago

I am not an expert in LUA. I tried to go over the other code. Whats a good way to add support to a whole family of engines under mephisto? The engine names can be different

sshivaji commented 7 years ago

I tried a few things for mephisto and glasgow mode. I get some output, but its not fully working. How do I reverse engineer the C++ file to the right init and send commands in LUA? Any suggestions? Thx in advance!

sronco commented 7 years ago

glasgow is one of those drivers that uses internal chess piece simulation and is a bit tricky to support, I'm also suspecting there is an emulation bug in the driver because I can't finish a game.

In general for writing new interfaces you need simulate in Lua what you do when play the game, the easy way to identify input ports tag/mask is to analyze the layout. In the layout you can search for inputtag and inputmask to map input of each chess board square, you can also use the port definitions in the driver source.

If multiple drivers (which are not parent/clone) needs to use the same interface you can use the load_interface function, see montreux.lua.

sshivaji commented 7 years ago

Thanks for the reply. I have a pull request for documentation changes which I will send soon.

Ok, we can skip glasgow for now.

How about mephisto? I don't have enough reference documentation in mame to understand the layout of mephisto. Is there a way to get the input ports and the layout from Lua when it is live?

sshivaji commented 7 years ago

However, thx for the general advice, I will try to debug this later today.

sronco commented 7 years ago

How about mephisto?

mephisto.cpp is not working in MAME since the GPL re-licensing. I'll see if I can fix it before the next MAME release.

Is there a way to get the input ports and the layout from Lua when it is live?

I don't think it's currently possible.

sshivaji commented 7 years ago

The Mephisto emulation is working for me for mame 0187 (and so is Glasgow btw). However, it's possible that I need to refer to the older Mephisto.cpp to try to make it work via lua.

Shiv

On Sun, Aug 13, 2017 at 12:59 PM Sandro Ronco notifications@github.com wrote:

How about mephisto?

mephisto.cpp is not working in MAME since the GPL re-licensing. I'll see if I can fix it before the next MAME release.

Is there a way to get the input ports and the layout from Lua when it is live?

I don't think it's currently possible.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/sronco/mame-chessengine/issues/2#issuecomment-322063849, or mute the thread https://github.com/notifications/unsubscribe-auth/ABXUGl3dUoiDwohG3nZ1L8Rpu7oze9Ucks5sX1WpgaJpZM4OpZar .

sronco commented 7 years ago

mm2, rebel5, mm4, mm4tk, mm5, mm50 and mm5tk are the drivers that are in mephisto.cpp and no one seems to works for me in mame 0.188, which driver did you try?

sshivaji commented 7 years ago

Mephisto works for me. You can download the roms from http://rebel13.nl/dedicated/dedicated%20as%20uci.html and I used mame0187. A tree that works for me is https://github.com/sshivaji/mame. I use the chess branch for a customized tiny build. Let me know what problems you see. Both mephisto and glasgow work for me in regular mode but not via your cool Lua solution.

On Sun, Aug 13, 2017 at 2:02 PM, Sandro Ronco notifications@github.com wrote:

mm2, rebel5, mm4, mm4tk, mm5, mm50 and mm5tk are the drivers that are in mephisto.cpp and no one seems to works for me in mame 0.188, which driver did you try?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/sronco/mame-chessengine/issues/2#issuecomment-322067313, or mute the thread https://github.com/notifications/unsubscribe-auth/ABXUGvALUBqPHbQaZfM2cPRA81afBW5Nks5sX2RkgaJpZM4OpZar .

sronco commented 7 years ago

I have added an interface for mephisto mm4, mm4tk, mm5, mm50, mm5tk and rebel5, but you need the latest MAME (0.189) to work properly.

sshivaji commented 7 years ago

Thanks, will try out this weekend and comment!

sronco commented 6 years ago

Fixed in 8f63119eb7c2139c6f7eb308b286c3bc765e92fa, requires MAME 0.196