Let's Make Robots!

MyRobotLab Plays Chess with Patrick?

Hi,

This is a blog post for PM and anyone else interested.  I have been doing many updates to mrl, and have begun working on some tutorial videos.  Patrick Mccabe and I spoke a couple times regarding hooking up his great chess robot to mrl for a game engine.  

Well, he beat me to it and found one to interface with Apple Script - but I still thought it would be fun to try.  It did not take me more than 30 mins to find, download, and wrap a chess game engine and gui with mrl.

Once the chessgame is a Service it can be loaded through the gui and integrated with other services.  In the video I show how to start it up and have it send a command string to the serial port and gui/logger.

The mrl GUI can be put into an applet so it can be played over the inter tubes too..

GroG

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Great, sounds like a good plan Patrick...

In the interim, since you are mrl's second most experienced user .... what would be the best improvement for it? Or what is the most aggravating thing?

Like I said, I do not know how the code works but it sure would be nice to be able to save configurations... Might be asking too much. Besides that, I can set it up pretty quickly.

I do not know what caused this error.

log file sent to your email.

Last login: Thu May 12 19:35:07 on console

Patrick-Mccabes-iMac:~ patrickmccabe$ cd myrobotlab-0002

Patrick-Mccabes-iMac:myrobotlab-0002 patrickmccabe$ sh b.sh

Exception in thread "Thread-43" java.lang.ArrayIndexOutOfBoundsException: 6

at org.myrobotlab.chess.Board.attack(Unknown Source)

at org.myrobotlab.chess.Board.inCheck(Unknown Source)

at org.myrobotlab.chess.Board.makeMove(Unknown Source)

at org.myrobotlab.control.ChessGameGUI$Thinker.run(Unknown Source)

Exception in thread "AWT-EventQueue-0" java.lang.ArrayIndexOutOfBoundsException: 6

at org.myrobotlab.chess.Board.gen(Unknown Source)

at org.myrobotlab.control.ChessGameGUI.youGotToMoveItMoveIt(Unknown Source)

at org.myrobotlab.control.ChessGameGUI.vetoableChange(Unknown Source)

at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:335)

at java.beans.VetoableChangeSupport.fireVetoableChange(VetoableChangeSupport.java:252)

at javax.swing.JComponent.fireVetoableChange(JComponent.java:4483)

at org.op.chess.ChessBoard.selected(ChessBoard.java:210)

at org.op.chess.Square$SquareMouseListener.mouseClicked(Square.java:68)

at java.awt.Component.processMouseEvent(Component.java:6377)

at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)

at java.awt.Component.processEvent(Component.java:6139)

at java.awt.Container.processEvent(Container.java:2085)

at java.awt.Component.dispatchEventImpl(Component.java:4736)

at java.awt.Container.dispatchEventImpl(Container.java:2143)

at java.awt.Component.dispatchEvent(Component.java:4566)

at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4621)

at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4291)

at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4212)

at java.awt.Container.dispatchEventImpl(Container.java:2129)

at java.awt.Window.dispatchEventImpl(Window.java:2478)

at java.awt.Component.dispatchEvent(Component.java:4566)

at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:680)

at java.awt.EventQueue.access$000(EventQueue.java:86)

at java.awt.EventQueue$1.run(EventQueue.java:639)

at java.awt.EventQueue$1.run(EventQueue.java:637)

at java.security.AccessController.doPrivileged(Native Method)

at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)

at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)

at java.awt.EventQueue$2.run(EventQueue.java:653)

at java.awt.EventQueue$2.run(EventQueue.java:651)

at java.security.AccessController.doPrivileged(Native Method)

at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)

at java.awt.EventQueue.dispatchEvent(EventQueue.java:650)

at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)

at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)

at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)

at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

 

I think I will have to try plugging my computer directly into the bot becuase I think those bad moves the engine is recieving is because of my series 2 xbees failing for some reason. I have never found their 2-way com to be reliable any way. Might have to buy some series 1 if that turns out to be the problem. How hard would it be to run this on windows? I know I said Mac, but I have a windows netbook that would work well. Dont waste your time if it takes a while. 

It should work on x86 - Windows just fine.
For that matter it should work on x86 - Linux too

Currently, I'm going through a fair amount of effort to try to support as many architectures and os's as possible.

Download the latest - 0004 currently - you just need the base install at this point, until you start dealing with voice recognition and speech generation... http://code.google.com/p/myrobotlab/downloads/list

 

The serial part on windows should be rock solid..  But, I am having some issues with the computer vision parts (on windows & mac)..  Maybe you could help me squash that bug?  I have an XP virtual machine running on my Linux box.. but I think some of my problem is using virtual box drivers for the USB webcam...

Could you do a test at some point with your windows netbook - if it has a webcam? 

Ok cool, now only if the window fit on my screen...

All of my computers have a webcam so I can test what ever you want. I am running windows 7 and also have a laptop that runs windows vista. 

Ok cool, now only if the window fit on my screen... <-- what is the screen resolution?  It's not fitting?  show me a picture of what is viewable... I "thought" I did 800x600

Resolution is 1024x600

Yarrg! - of course the button you need is below the screen ... isn't that how it always is ?!?!

Alright - I put the button you need at the top... I'll get to the other parts later.

Just replace the myrobotlab.jar (quick update) from here http://code.google.com/p/myrobotlab/downloads/list