This is what I was able to discover about chess on the OLPC. I just got it a couple of days ago, so I probably missed a lot.
There are three chess Activities that you can install using xo-get.
- chessTutorial Learn chess.
- chessPartyend Play chess against a friend.
- chessComputer Play chess against the computer.
Launch Etoys, open a new project, drag out the "Object Catalog" from the treasure box in the menu, go to "Games" category and drag out "Chess".
Single-player against the computer, and a fairly weak opponent
on the web
Should be a bunch of places which will let you play on the web, both against a computer, and against other players. Need to find a couple and list them here.
xboard runs on linux, it has not been sugarized, so everything is from the Terminal
Open the terminal
su -l yum install xboard wget -P/usr/bin http://freechess.org/Download/timeseal_x86 chmod +x /usr/bin/timeseal_x86 exit
(The first time I installed xboard it, xboard itself failed, but the dependencies succeeded. I re-ran it, and it got xboard. Was this just a blip, or do other people have to do this too?)
- xboard tries by default to use the Helvetica font, which is not installed on the OLPC. So we need to override the font.
- when playing on fics, the timeseal makes it so that the time taken for your computer to talk to the server ("lag") doesn't count against your thinking time.
To play a game of chess against the computer: xboard -font 6x13 -coordFont 6x13 -clockFont 6x13
To play against other people online, at FICS: xboard -font 6x13 -coordFont 6x13 -clockFont cs -icshost 188.8.131.52 -icshelper timeseal_x86
You first need to go to their website and register for an account (It's free.)
when playing on fics, the console is in your shell window, another window comes up with the board. This shows up as a gray circle on the home screen
I'm DanTilkin on FICS, drop me a line if you're on there. I'd love to play you a game.
alias fics="xboard -font 6x13 -coordFont 6x13 -clockFont cs -icshost 184.108.40.206 -icshelper timeseal_x86" alias gnuchess="xboard -font 6x13 -coordFont 6x13 -clockFont 6x13"
You can then just run "fics" to play on the server, or "gnuchess" to play the computer.
When xboard connects to a server, it runs the commands in the file "~/.icsrc". The first two lines should be your username and password, this will log you in automatically.
With one computer, run like you're going to play the computer, then switch to "Edit game" under the mode menu.
With two computers, and internet access, you can both log on to FICS, and play each other using the "match" command.
I was able to get Pychess installed and run, although not without problems. Pychess is less developed than xboard. It's also slower, which is a problem when playing blitz chess on a server. It does have a 2-player mode. It's also in python, and being actively developed, which probably make it a better candidate for OLPC development.
Read this whole section first. If it seems too complicated for you, it probably is. It's not your fault, it needs to be made easier.
- yum has version 0.6, but the current is 0.8 beta4, that's what I installed.
- This has a declared dependency on python version 2.4, but version 2.5 is installed, that's why the --nodeps argument to rpm is needed.
wget http://pychess.googlecode.com/files/pychess-0.8beta4.noarch.rpm rpm --nodeps -i pychess-0.8beta4.noarch.rpm
run as "PYTHONPATH=/usr/lib/python2.4/site-packages pychess"
It needs icons in "usr/share/icons/gnome/" subdirectories, but it doesn't find them. Not sure how to tell it where they are.
I wound up editing code in /usr/lib/python2.4/site-packages/pychess/widgets/ to add calls to icons.append_search_path, this isn't the right answer, but it worked.
I added the following lines, right after the object is created.
[olpc@xo-10-C4-41 widgets]$ grep append_search_path *.py
1. Install a bigger, easier to read font for use with xboard. (How?) 2. put font choices in .Xdefaults, rather than an alias. 3. install timeseal 4. Want to see the console and the board at the same time. 5. try other downloaded interfaces to fics. 6. try java interface to fics.
Ceibal-Chess is a brand new Chess project that aims to produce a chess Activity for the Sugar and the XO.
Project features include:
- Free as in Freedom (GPLv2)
- Designed from the ground up to work on the XO.
- Distributed as an Activity Bundle (.xo)
- Completely developed in Python + PyGame.
- Integration with GNU Chess.
- Player vs Player mode (in one Laptop, using DBus planned).
- Valid movements highlighting.
- Enemy movements highlighting.
- Portable: known to work on various Linux distros and Mac OS X.
- Easy to learn and use, without complex menus or options.
The project is still in its early stages, with some known bugs open, but it's reaching an stage where heavy testing for bug-fixing would be extremely beneficial.
The source code is stored in google code, at: http://code.google.com/p/ceibal-chess. Anonymous checkout using Subversion is enabled, and the code includes an script for automatically creating the Activity Bundle which can be used to deploy the Activity on XO laptops.
You can contact the project administrator at asegovi AT gmail DOT com. There is also a google group, called ceibal-chess.
If you have Subversion installed, get the latest version by using the following command:
svn checkout http://ceibal-chess.googlecode.com/svn/trunk/ ceibal-chess
Running on Linux and Mac OS X
Just get the latest source code version using Subversion and run the main.py python script. There are several flags that control window size and whether the IA should be disabled (for playing among people or testing).
Installing on the XO
First get the latest source code version for Linux or Mac OS X, then run the createbundle.sh BASH script. The created .xo bundle will be stored in the bundle/ directory. Copy this file to the XO and open it using Firefox or running the sugar-bundle-install application from the Terminal Activity.
Once installed, restart Sugar by pressing Control + Alt + Erase. The Ceibal-Chess icon should appear among the other activities.
It is also possible to run Ceibal-Chess from the Terminal Activity in the same way that it's run on Linux, provided you first unset the SUGAR_BUNDLE_PATH environment variable.
I'd love to see a chess activity for the OLPC. I did a search, didn't find anything. For the extensibility side, give kids an easy way to program their own chess engines.
xboard and gnuchess are under the GPL, can possibly use those as a base.