Fix bricked XOs automatically
I’ve been getting increasing numbers of requests from donors in the first OLPC Give 1 Get 1, many of whom are just getting around to opening their XOs, to have their laptops repaired. As is now widely known, due to a manufacturing glitch the first few batches of OLPC XO-1s that were shipped to consumers had a faulty motherboard battery holder. This alone wouldn’t be a problem, if only two other things hadn’t happened at the same time:
- The XO-1s were shipped with Open Firmware’s security enabled. This caused them to have the same anti-theft protection as laptops deployed in the third world, without any of the benefits of a remote killswitch or tracking
- The XO-1s had a version of OFW which would fail to boot when the clock was below a certain value
The above two issues combined with the manufacturing fault was a recipe for disaster. Owners who discovered this in the first 30 days were able to get a RMA and a working laptop, but OLPC lacked the resources to support those outside of this minimal warranty.
The procedure for repairing the above is straightforward and well documented. However, it can be tedious, especially for those who are unfamiliar with the tools involved. Since I needed the programming practice anyway, I decided to write a rudimentary Python script to automate the process.
Thus enters d6.py. d6.py makes it (hopefully) amazingly simple to unbrick your XO, so that you can get up and running as soon as possible. You can clone the git repo, or download it directly (permalink). To download and run in a single command:
python -c "import urllib2; exec urllib2.urlopen('http://dev.laptop.org/git/activities/olpc-contrib/tree/d6.py').read();
Plug in your OLPC Serial Adapter (or one of the compatible alternatives), and run the script as a user which has access to /dev/ttyUSB0 (or as root, not recommended) or change the path inside the script to something suitable to your system. This script is in the alpha state, is poorly documented, and may not handle all edge cases (read: other people’s systems) well. I’m not responsible if it kills your cat, lights your XO on fire, or makes your wife leave you, but hopefully it’ll be of some use. Expect a GUI shortly.
Limitations:
- Does not handle all error conditions
- No command line params
- Hard-coded path to serial adapter
Therefore, the code does not run on other platforms other than Linux. You might also encounter problems if you’re running it on a system with brltty installed, removing it should fix the conflict.
Feedback is more than welcome in the comments.
December 1st, 2009 at 09:15
Luke,
Love this post – its a great detail of problems G1G1 folks need to be aware of. Can I make it a Guest Post on OLPC News (linking back to here, of course)?
December 1st, 2009 at 09:23
@Wayan,
Totally, feel free. Glad you find it useful!
February 5th, 2010 at 23:21
Pretty interesting. Not exactly my problem though – my bricked OLPC simply won’t take a charge. When AC is plugged in, there’s no LED lights at all. By now the battery has run out of its own juice so there’s simply no way to fire up the laptop at all. Thoughts as to what the cause could be?
February 18th, 2010 at 09:09
Could be a power adapter problem. Send me an email and I might be able to take a look!