Chatting to Sugar from a PC

July 11, 2008

(By PC I mean any OS including Linux, Windows, Mac and mobile devices, that has a Jabber client. And since Sugar can run on non-XOs, with XO I include any device primarily running Sugar…)

One of the strengths of the Sugar platform on the OLPC XO is that collaboration is built in. Many Activities are collaborative. However, one of the criticisms has been that it’s been a bit of a walled garden: not easy to collaborate with other computers unless they have the whole Sugar platform installed.

A feature I worked on for the upcoming Sugar 0.82 release is interoperability with XMPP (Jabber) instant messaging software. Collaboration is already based on XMPP, through the use of Telepathy in the Sugar stack - using a chat room for each shared activity - so much of the infrastructure was already in place.

This feature is planned to be included in the OLPC 8.2.0 release, later this year.

Requirements:

  • XO (or other device running Sugar) connected to a Sugar-customised Jabber server
  • PC (regular desktop on any OS) - or mobile device (my Nokia N810 tablet works great) - with a Jabber client

Here’s a walkthrough of the result:

Step 1: (PC) Register on the Jabber server

At the moment, only a very particular server setup works for Sugar collaboration - so you need to use a Jabber server on a school server, or a community jabber server - or set one up yourself. Assuming you have XOs connected to a server, register your Jabber client with that server:

Register Jabber account

Register Jabber account

(At this stage there is no federation of servers, so you must register on that particular server.)

Step 2: See the XO(s) on your buddy list

Currently everyone sees everyone else on the server, in a special group, usually called Online. In this example there is only one XO connected to the server but there may be many.

See XOs in Buddy List

See XOs in Buddy List

Step 3: Start a chat with an XO buddy

Start a chat with the XO. Type a message and send it to start the connection:

Start a chat

Start a chat

Step 4: Sugar displays a notification

On the XO, Sugar will display a notification in the toolbar of the current view or activity, showing an invitation to Chat.

Sugar notification

Sugar notification

You can click on it directly to start Chat, or on the frame invitation:

Step 5: Invitation in the frame

If you view the frame you will see the invitation to Chat. Click on the icon, or hover to get the rollover menu with Join and Decline options.

Frame invitation

Frame invitation

Join, or click the icon.

Step 6: Chat starts

The Chat activity is launched. Note that the “Share with” option is gone, since you cannot share this chat connection with other XOs.

Chat starts

Chat starts

The message(s) sent from the Jabber client are displayed.

Step 7: Chat in progress

Continue the conversation, and it will be displayed as usual in Chat:

Chat in progress

Chat in progress - Sugar

and in the Jabber client:

Chat in progress - PC

Chat in progress - PC

Thanks to Guillaume Desmottes and the other Collaborans for assistance.


OLPC Pilot in Nigeria: No XOs!

June 10, 2008

Computer painted on wallYesterday, Andy Rabagliati (a.k.a. wizzy) visited School Galadima in Nigeria which was an OLPC pilot. (The project there was breaking news at the time I first touched an XO.)

Unfortunately, the state of things today:

There are no longer OLPC laptops at the school. One of the consequences of being a pilot school for OLPC was that they were issued with beta hardware, and there were many problems with the unit, from cables coming unplugged, the wireless network disconnecting, and hardware failure. In preparation for its replacement, the hardware was withdrawn in December 2007. However, at that point, there was a lawsuit filed against OLPC by a Nigerian keyboard maker, claiming infringement of layout and something about keyboard scancodes. As a consequence - the children are still waiting for their replacements.

On my way out of Galadima I visited the chief of the area - Chief Habakkuk of the Gbagyi. He was gracious, and explained that his elder brother, who had been chief, had died 5 years ago, and the mantle of chief had passed to him. As a father of a child at the school, he expressed his thanks for the efforts of OLPC for bringing the laptops, and consequent attention, to his community. I explained that some friends in Cape Town, South Africa, worked on the software inside those laptops, and was visiting the school on their behalf as well to carry the message back. I hope that those children eventually get their laptops, and expressed this wish to the chief.

Read more of Andy’s post

So it seems that this girl, literally “poster child” for G1G1, from Galadima has no XO any more… and neither do these children

Update: I spoke to Darah Tappitake during a recent trip to OLPC HQ and she said the XOs were withdrawn because of the litigation against OLPC in Nigeria - and that once that is settled, OLPC will be back with bigger deployments than before. So the XOs will be redeployed in Galadima - the real thing this time, not just prototypes.


Internet Disservice Provision

May 26, 2008

Joe, you said:

When we say 2Mbps, it’s 2Mbps.

Except that your upstream is Verizon who seem to have major routing problems, and have done so for months now. Connecting to SA sites who are on Internet Solutions has always been slow at best, with timeouts at worst. Traffic via Verizon to TENET’s Cape Town servers is routed via Joburg and back.

Amobia’s service is very good in all ways except one: The actual Internet service.

Please Joe, do more than “prod” Verizon. Vote with your wallet before I do.

I am an Amobia client, and I have a story to tell. Don’t make me tell it.


Multipointer X for “Minority Report” XO-2

May 21, 2008

Yesterday the XOXO or XO-2, the next generation OLPC “laptop”, was announced. Gizmodo called it “straight out of the future, like a kid’s book in Minority Report”. More coverage at olpcnews, laptopmag, xconomy, infoSync and PCWorld.Touch typing

In order to support typing on the touch screens, and collaboration by more than one child per laptop, the XO-2 will have a multi-touch interface using Multi-Pointer X (MPX).

Here are a couple of demos of MPX:

Bonus points if you recognised the distro powering the first video…


The future of Sugar

May 16, 2008

The news is out that OLPC and Microsoft have announced an agreement to “make a dual boot, Linux/Windows, version of the XO laptop”. Nicholas Negroponte’s announcement on community mailing lists (unfortunately HTML only but plain text on the wiki) states:

To enable the Sugar environment to reach as many children as possible, particularly in the poorest areas of the world, OLPC must be able to bid on educational technology contracts, some of which require that Microsoft Windows be able to run on our hardware. The increased volumes will lower the XO-1’s price, already lowest in the industry with capabilities no other laptop shares.

The press release and other news coverage states that trials of XP on the XO will begin in June in some countries.

Engadget’s coverage ends with:

As for Sugar? You’ll still be able to get it, but we have a sinking feeling about its future.

Let’s address that right now.

The future of Sugar

First, some quotes from Negroponte’s announcement:

OLPC is substantially increasing its engineering resources and all software development continues entirely on GNU/Linux. We will continue to work to make Sugar on Linux the best possible platform for education and to invest in our expanding Linux deployments in Peru, Uruguay, Mexico and elsewhere.

No OLPC resources are going to porting Sugar to Microsoft Windows, although as a free software project, we encourage others to do so. The Sugar user interface is already available for Fedora, Debian and Ubuntu Linux distributions, greatly broadening Sugar’s reach to the millions of existing Linux systems. We continue to solicit help from the free software community in these efforts. Additionally, the Fedora, Debian and Ubuntu software environments run on the XO-1, adding support for tens of thousands of free software applications.

Sugar as an upstream project

OLPC wants to “enable the Sugar environment to reach as many children as possible” and part of that goal is to have Sugar running on as many platforms as possible. That requires some degree of decoupling from OLPC’s XO builds.

There is now a Sugar roadmap, inspired by GNOME’s release process. It is still aligned with OLPC’s needs for the XO build release process.

Here is the announcement of the Sugar Labs Foundation, Walter Bender’s approach to Sugar development as an upstream project.

Folks, Sugar isn’t going away. We already know that Sugar on Linux can use the innovative features of the XO-1 that XP cannot. Let’s show the world what we can do, standing on the shoulders of thousands of regular people.

[ Coming soon: Ways to get involved in Sugar and collaborative Activity development ]

(Disclaimer: I work for OLPC. The above opinions are mine.)


Ubuntu-ZA: Month of Education - March 2008

March 6, 2008

I proposed monthly themes for participation in Ubuntu South Africa, a couple of weeks ago - now written up at http://www.ubuntu-za.org/Wiki/MonthlyThemes.

Let’s kick off with Education.

If you are at all involved with education, please go back and read that mail, and then:

  • Introduce yourself to the list and tell us what you do or how you are interested in education
  • Think about what the needs are, relating to IT and education
  • Think about what we can do as a community to meet some of those needs

Please put [Education] in the subject line of mails about this topic so people can see at a glance that this is related to the current theme.

We’ll track the output of discussions at http://www.ubuntu-za.org/Wiki/MonthOfEducation.


OLPC community Jabber servers: ejabberd 2.0.0 from source

February 27, 2008

 Update: Added these instructions to the OLPC wiki: http://wiki.laptop.org/go/Installing_ejabberd

Here’s a walkthrough of installing ejabberd 2.0.0 (freshly released) from source, with the OLPC patches, on Ubuntu 7.10. It’s based on the wikipage [[Ejabberd Configuration]] with more detail.

In the near future I’ll post about prebuilt packages - they are currently out of date.

A bit about my setup: I’m installing ejabberd on my laptop running Ubuntu. I have two XOs connected to my wireless access point. My dhcp and dns doesn’t give a fully qualified domain name to my laptop, so I’m putting its IP address and “your.host.name” into /etc/hosts on all the machines.

To run ejabberd as a public server, you will need to run it on a public server where you have root privileges - like a Xen hosted virtual server. Replace “your.host.name” in my examples with the appropriate hostname.

Let’s dive into the installation… Some of the commands displayed below might be chopped off. You can still copy and paste them to see the full command.

1. Don’t have ejabberd installed from the Ubuntu archives - we will build it from source.

2. Install dependencies:

sudo apt-get install erlang-base erlang-nox erlang-dev build-essential libssl-dev

3. Get the ejabberd source:

mkdir ejabberd
cd ejabberd
wget http://www.process-one.net/downloads/ejabberd/2.0.0/ejabberd-2.0.0.tar.gz
tar xfz ejabberd-2.0.0.tar.gz

4. Get and apply the OLPC-specific patches and configuration:

wget http://people.collabora.co.uk/~robot101/olpc-ejabberd/shared_roster_push2.diff
wget http://people.collabora.co.uk/~robot101/olpc-ejabberd/shared_roster_recent.diff
wget http://people.collabora.co.uk/~robot101/olpc-ejabberd/shared_roster_online.diff
wget http://people.collabora.co.uk/~robot101/olpc-ejabberd/mod_ctlextra.diff
wget http://people.collabora.co.uk/~robot101/olpc-ejabberd/ejabberd.cfg
cd ejabberd-2.0.0/
patch -p1 < ../shared_roster_push2.diff
patch -p1 < ../shared_roster_recent.diff
patch -p1 < ../shared_roster_online.diff
patch -p1 < ../mod_ctlextra.diff

5. Build ejabberd:

cd src
./configure
make

(Although I saw “warning: pointer targets in assignment differ in signedness” at this point, the build did succeed.)

6. Install:

sudo make install

7. Apply configuration:

cd ../..
sudo cp ejabberd.cfg /etc/ejabberd/
sudo gedit /etc/ejabberd/ejabberd.cfg

(or use your preferred editor.)

Change the hostname: find the line that says

{hosts, ["jabber.laptop.org"]}.

and set it to the FQDN of your server:

{hosts, ["your.server.name"]}.

Do the same for the admin login: find the line that says

{acl, admin, {user, "jtest", "jabber.laptop.org"}}.

and set the FQDN to your server:

{acl, admin, {user, "jtest", "your.server.name"}}.

(The username “jtest” is for admin rights accessing the web interface. You can change it to something else, but keep it consistent.)

8. Start the server. You should be able to use sudo /etc/init.d/ejabberd start, but that didn’t work for me (yet). This will do it, but won’t start automatically on boot:

sudo ejabberdctl start

9. To set up the shared roster we need a user who can log in through the web interface. Use a jabber client to register the user jtest on your.server.name - you need to do this to have an admin user in the web interface.

10. Go to http://your.server.name:5280/admin/ and login as “jtest@your.server.name” with the password you set when registering.

11. Click on “Virtual Hosts”, then your hostname, then “Shared Roster Groups”. Type “everybody” and click Add New.

12. Click on “everybody” and enter “everybody” for Name, “@online@” for Members, and “everybody” for Displayed Groups. Click Submit. (I tried some variations on these names, per [[Ejabberd Configuration]] and http://www.ejabberd.im/shared-roster-all but these exact strings were the only combination that worked for me.)

It should be working now!

13. In your jabber client, disconnect and reconnect the “jtest@your.host.name” account.

14. On an XO, go to the Terminal and type “sugar-control-panel -s jabber your.host.name”. Restart sugar with ctrl-alt-erase.

15. In your jabber client (with the jtest account) you should see a new group appear called everybody, showing the nickname of the XO.

You can now get multiple XOs, emulated XOs or sugar-jhbuild instances connected and collaborating!


OLPC community Jabber servers: global vs local, alternatives

February 27, 2008

Kevin Mark commented on my post OLPC community Jabber servers:

The only issue is that when xochat.org was running, I was able to connect from my sugar emulator in ny to an xo users in australia. Your idea will not allow that, more or less.

I thought responding to this would benefit a broader audience.

Global servers that anyone can join are simply not feasible at this time as xochat.org showed: the server dies due to being overwhelmed by the number of users.

(Once we’ve got the next generation of server connectivity done, we should be able to run highly scalable servers, and run multiple federated servers that are connected to each other, allowing kids from different schools - or adults anywhere - to collaborate. That’s the promise - we’re still a way off.)

However, people can certainly set up global special interest servers - like say one for PyGame activity developers, or one for library content contributors, and so on. The key is to narrow the focus so you don’t get too many participants.

Alternately, as I mentioned the best way may be servers by city, or region for a particular use. In particular, there should be servers specifically for kids, where the only adult participants are parents helping out - not adult users looking for their own collaboration channels.

If you’d like to chat with OLPC-interested people in strange and foreign lands, then I recommend IRC chat: join #olpc on freenode, and you’ll find people from all over (depending on time zone). There is an XO activity for IRC: XoIRC - so you can chat from your XO.

For serious questions and discussions, please join the appropriate mailing list. Discussions on IRC are immediate and often effective, but transient. There’s little to no record of them, for others to discover and follow up - so questions that may benefit others are best done by old-fashioned mail.


OLPC community Jabber servers

February 26, 2008

OLPC collaboration via a server is currently only working on ejabberd with some special patches. It’s not easy getting a server up and running, and this is hindering the deployment of community servers. This is the first post in a series to assist people in getting a functional jabber server up and running.

We should have dozens of community servers run by, and supporting, G1G1 users, but the only one I’m aware of that was functional was Tom Hoffman’s xochat.org, and it’s been down for a while.

Here’s the issue: At this stage, we cannot handle arbitrary numbers of XOs on a server. (We are working on this, but don’t hold your breath - the fix won’t be ready for Update.1.)

Due to the shared roster, everybody sees everybody else on the server. That won’t scale. The most I’ve seen online on a server was about 170 XOs - so what we need are servers for specific communities, where random strangers are not necessarily welcome. (That sounds harsh, but joining a busy server will only make it unavailable for everybody else!)

So please step up and run a server! Over the next few days I’ll document different approaches to getting up and running, and if you need help, you can find me on IRC: morgs in #olpc on freenode (

I’ve started a wikipage, [[Community Jabber Servers]] to list servers (those that want to be publicly listed, anyway). If you want to publicize a server there, please be as specific as possible about who your community consists of, so that the whole world doesn’t show up at once and kill your server.

Coming up next: Setting up ejabberd 2.0.0 with OLPC patches, from source

Coming in the near future: Up to date ejabberd packages with OLPC patches included


Ubuntu-ZA participation: monthly themes

February 23, 2008

(also posted to the ubuntu-za list - reply there if appropriate)

Ubuntu-ZA Participation

I’d like to propose that we pick an area of participation in Ubuntu South Africa each month for six months, and during that month we put as much as we can into discussing and moving that theme, or topic, forwards.

The topics I have in mind are (in no specific order):

  • Education
  • Small Business
  • Software Development
  • System Administrators
  • Spreading Ubuntu in South Africa
  • [insert your idea here!]

The Goal

By the end of that month, the goal would be to achieve the following:

  • Identify those in our community who are active or interested in this area - by introducing ourselves on the mailing list
  • Identify the relevant needs and issues we face (e.g. skills in administering a school network, or a small business server, etc)
  • Identify people in the community who can meet those needs or offer relevant services for a fee
  • Nominate a person to act as the team leader for that area to continue promoting relevant activities in our community
  • Report back to Ubuntu South Africa and the global Ubuntu community the results of the month’s activities (https://wiki.ubuntu.com/TeamReports)

After six months, we’ll have Software Freedom Day in September, and this year we’ll be prepared in advance and coordinate activities with relevant LUGs and see if we can’t get some rockin’ events happening (with Karl to lead the way at Sandton Convention Centre)!

Your Mission

Please contribute topic/theme ideas, and choose one to start with for March. Here are more details on some of the topics I listed above to show what I mean:

Education

Within our community we have:

  • Educators
  • People running IT infrastructure for education
  • Students and Learners
  • Developers of educational software or content

Issues: Why use Ubuntu instead of Microsoft’s educational pricing? How to run a school network? How to convert to Ubuntu? Who are the experts and service providers in Edubuntu / LTSP / thin client networks? Where does Ubuntu not meet people’s needs?

Small Business

  • Small business owners
  • Small business IT people (often the same people)
  • IT providers servicing small businesses

Issues: How to do X/Y/Z with Ubuntu? Setting up a small business server? Integration with non-free software… Document format compatibility… Who to call on if it breaks…

Software Development

  • Developing desktop software for/on Ubuntu
  • Ubuntu as a development platform for the web