Skip to main content

Posts

Showing posts from August, 2007

Beer condition met.

I can ssh into the OLPC and drive the Roomba around with a simple command line interface built on PyRobot. I also have a bash script running on the OLPC that grabs a snapshot from the webcam every 5 seconds and uploads it to my web server. The entire thing is held together with duct tape.

Now I just need one laptop per Roomba.

From Fido
Read more

Presenting PyRobot

I've been working on a re-write of iRobot's openinterface.py that is, hopefully, cleaner and more compatible with older Roombas in addition to the Create. I call it PyRobot. And now, it has a home.

Currently, PyRobot is not nearly as feature complete as openinterface.py. But I expect that will change as I start playing more with my robot army maids.
Read more

Need to generate emails for something shady?

import urllib
import urllib2
import hashlib
import random
import re

TRASHMAIL_URL = 'https://www.trashmail.net/'
FIND_NEW_EMAIL = \
re.compile(r'Your new email redirection address is: (.*?)')

def GetTrashMailAddress(redirect_to):
values = dict(
form_source=hashlib.md5(str(random.random())).hexdigest()[:8],
form_dest=redirect_to,
form_nb_redirections='30',
form_expire_days='30',
form_whitelisting='0',
delete_msg_chk='1',
lang='en',
create_submit='Create disposable email address')

data = urllib.urlencode(values)
req = urllib2.Request(TRASHMAIL_URL, data)
response = urllib2.urlopen(req)
return FIND_NEW_EMAIL.search(response.read()).group(1)
Read more