Register
Login

Growing Pains (nginx)
28.11.2009

I finally made the decision to switch over to nginx from lighttpd. The decision came from the increased momentum of the nginx community and my innate desire to tinker with everything. I have also read from multiple sources that lighttpd has some sever memory leak issues, and that nginx is just generally more well-written. Needless to say - some bugs will probably crop up due to the switch. I've already nailed down a few, but I'm sure several remain.

Thus far, I've really enjoyed the logical syntax of nginx over lighttpd, and lack of lighttpd's server.network-backend ...

no comments
SFW/NSFW URL Shortener
17.8.2009

I have thrown together the beginnings of a new URL shortener this afternoon. You can check it out at SFW.im and N.SFW.im. The URLs are pretty self explanatory, so I will leave them at that.

Please not that the N/SFW site is not production ready, and I still have to create a UI and API. However, do feel free to try it out.

5 comments
Documents Should Be Open
13.8.2009

Have you ever encountered a secured PDF? I just did. Basically, it is designed to prevent you from almost anything other than printing the PDF in question. Although I'm not sure about the exact restrictions, I do know that it prohibits me from uploading it to Google Docs. I use multiple computers, and Docs is what I've adopted to keep basic documents synchronized among them.

I see this as the emergence of DRM for the document industry. I paid for the document. I should be able to use it within my legal limitations on all of my computers ...

no comments
DIY DARPA
6.8.2009

I have been working on software for a large (~50+ kg) terrestrial rover for a little over a year, and the mechanical portion is almost complete. This means that I am finally able to field test some of the code that I have written for remote/autonomous operations.

I started a project over at Google Code in case anyone is interested. There is not much to look at as of now, but I hope to create an all inclusive package that will allow people to accel in future DIY projects such as this and avoid the problems that I have ...

no comments
The Puppy
6.8.2009

Without further adieu, I give you the new puppy (Bailey)! She is around 2 years old, and is probably a Border Collie / Jack Russell mix. I don't have any pictures on hand, so the video will have to suffice. However, I think that the video is able to capture more of her personality than a photo ever could. Border Collies are said to be powered by a miniature nuclear reactor, and she is no exception. I speculate that her peak output is somewhere around 1.21 GW. I have her running up to 7 miles as of now, and ...

no comments
Python Comprehensions
19.6.2009

I haven't posted in a while, so here's a fun fact for the day: Although they probably aren't the best way to do most problems, they sure are cool - Python Comprehensions. When you combine a list comprehension with the reduce() function, the one-liner possibilities are endless. For example, if you need a quick and dirty way to calculate the XOR checksum of something (eg. NMEA 0183 GPS output), create a function such as:

import operator
def checksum(s):
    return reduce(operator.xor, [ord(c) for c in s])

It may not be as universally accepted as unrolling ...

1 comments
Django HTML Admin Widget
3.5.2009

I was a bit annoyed at the lack of WYSIWYG fields for Django's admin interface. I was originally planning to use FCKEditor but couldn't find a polished Django implementation (although I'm sure there is one out there). Instead I opted to use TinyMCE due to this nice Django widget implementation. After running setup.py, installation is a cinch - I just added from tinymce import models as tinymce_models, and replaced instances of models.TextField() with tinymce_models.HTMLField(). To customize the options available to TinyMCE, I was able to add this to my settings.py:

 

TINYMCE_DEFAULT_CONFIG = {
    'theme': "advanced",
    'theme_advanced_toolbar_location ...
1 comments
Django Caching
29.4.2009

The site just got mildly reddited, so I've decided to implement some caching in order to deal with possibly higher loads in the future (when I unveil a large-scale autonomous project that I've been working on). On my ongoing quest of Django awesomness, I have recently stumbled upon generic views, which somewhat clouded the idea of caching.

First, the Django docs provide an example that lists something like (r'^foo/(\d{1,2})/$', cache_page(my_view, 60 * 15)), to be put in urls.py in order to cache a view. However, this is quite contradictory to their other references ...

no comments
Simple Python ctypes Example
25.4.2009

I have been working with the massive data tables generated by my balloon flight and have run into a bit of trouble with Python. Everyone knows that Python isn't the fastest kid on the block. However, there are several ways you can speed it up. First off, Python 2.6 and 3.0 provide a new multiprocessing library that makes it much easier to divide a problem amongst concurrent workers. However, this is still not ideal for high throughput data requirements. I have previously worked with Python's C API, but found it's syntax quite undesirable. This new ...

22 comments
SVGs, Microcontrollers, and Xbees
16.4.2009

I brought back and old project this afternoon. I had previously constructed a temperature regulated refrigerator using an Arduino and 5A Omron SSR to toggle the compressor, but had no good way of plotting the results to make sure my refrigeration algorithms were working correctly. The refrigerator was not near a PC, so uploading the live results to a database was out of the question.

However, I recently purchased some XBee modules to play with wireless serial communication, and decided to give them a try with a datalogging application. I picked up an XBee shield for the Arduino and a ...

2 comments
1 >