This post is quite old. CherryMusic has improved a lot since then. For the latest version and information on CherryMusic, please visit http://fomori.org/cherrymusic
I recently wrote a Music Streaming Server in python, that allows you to listen to your music inside a browser, no matter where you are. It is called CherryMusic and features a standalone webserver based on cherryPy as well as JPlayer, a HTML5/Flash music player. It indexes your data for fast search using a sqlite database, so there is nothing to setup for you, just download the sources and off it goes!
In my tests it works perfectly with many thousand indexed files: searches are returned immediately, even on my little home server.
After the break you can find some screenshots of it in action.
I recently saw a video of an implementation of Conway’s game of life written in APL which was done in just one line. And because I couldn’t sleep last night, I implemented it in python as short as I possibly could.
So here it is:
for j,i,nb in map(lambda j:(j,j+s+1,bin(life&((7|5<<s|7<<s*2)<<j))[2:].count('1')),map(lambda x:x+int(x/(s-2))*2,range(0,(1<<s-2)+1))):
next = next|(1<<i)^(1^(((('23'.count(str(nb))<<1)+'3'.count(str(nb)))>>((life>>i)&1))&1))<<i
There’s a little write-up and the source after the break.
I recently needed to get some data out of a large tar file, about 5gb in size, that I didn’t want to extract, as it contained many thousands of small files. Unfortunately the tar format was not designed to be indexed, since it was meant for backups on magnetic tapes (tar stands for tape archive). The gnu tar has a command for retrieving single files, but it needs to go through the whole tar each time, which was just too slow.
So I decided to write a little tool, that would index all files inside the archive and write that index to another file. Now I can access each file within the tar in just a second, instead of 15 minutes. Introducing the tarindexer!
UPDATE: The project is now up on github under GPL v3
I’m running a Thin-Client as a home server and sometimes I need access to some files at home. Since those no-ip services didn’t prove that reliable in the past, I decided to implement a DynDNS substitute in PHP.
The concept is quite simple: Let the little server at home call a PHP script somewhere on a “big” Server that has a static IP. The big server then writes the IP to a file, so it can be read from anywhere. There are two scripts that have to reside on the big server: an index.php, which reads and echoes the IP, that was recorded, and another script in a .htaccess protected folder, which is able to write the IP of the home server to a file.
Today I had no WiFi. And no USB cable. So I figured out a way to use ADB over bluetooth, because no one can stop me from developing an App. It is a rather simple hack, which should work on any rooted phone (or tablet).
All you need is a terminal emulator for android, and a bluetooth capable linux computer, of course.
The Archos 101 has a crappy touch screen, as all the owners of this device already know. Most of the other problems could be fixed using a custom rom like urukdroid. But the touchscreen has been bugging me for the past year now: the touchscreen sometimes just acts weird (wild and random clicks, or almost no reaction), until it is “recalibrated”. No wonder, since it is a cheap USB touch screen “UNITEC USB Touch (Win7)”, probably made for windows 7 netbooks. Since the recalibration is hidden deep in the android settings, but needs regular access, I wrote a simple app as a “shortcut” to it. You can find the app download link at the end of the article.
Some years ago I built a projector, using a overhead prjector and a TFT, as most of you readers know them already. But I never did overcome the problem of keystoning. I know that you can tilt one of the lenses, but with most DIY builds this can be a quite frustrating procedure.
So after many years of looking for a solution thats easy to use, especially because I don’t want that ugly projector to keep standing in the middle of my living room and I always move it to one corner after using it. That means that i have to do the keystone calibration each and everytime I want to use it.
The solution: mplayer already has a perspective correction video filter feature included
A little while ago I finally made the decision that I would like to have a server at home and I was at first fascinated by the SheevaPlug, but many people complained that the powersupply of it would die within weeks, so I needed an alternative but I still didn’t want to use a regular computer because of several disadvantages;
- It would be to loud
- It would consume too much energy
- It would be overkill for my purposes
- The hardware is relatively expensive
But when I had a look on Ebay, I stumbled upon a Thin-Client, which is essentially a small, low power computer, that is used in companies as something like a next-generation terminal. Since it did only cost 50€ I thought I would just give it a try.
I recently build a little USB-SNES-Gamepad for my Android Tablet, because I didn’t like using the on screen controls of the emulators. It just wasn’t fun playing the games of my childhood without the original controller in my hands. Luckily my Tablet has a standard USB port with host capability and supports thumbdrives, keyboards and mice out-of-the-box. So I figuered I could easily put the controllerboard of a usb keyboard inside the spare original SNES gamepad i had liying around.