Category Archives: computers

Python and PHP

Python is my go to language for most programming. To each their own, but I like it. There’s a slick as heck library for python, SQLAlchemy, which just makes dealing with SQL commands easier and safer by default.

Lately there have been pressures to take up PHP again. I was wondering what helpful SQL libraries there are for PHP, so I used a well-known web search engine:

It seems that SQL Injection is fairly popular.

Spending the Afternoon Taking Apart My Stereo (and Not Doing School Work)

A “project,” for me, is taking a broken thing and fixing it. Or, conversely, taking a working thing and breaking it. Far more likely, and a great way to learn simple lessons through hours (or weeks) of frustration. Yesterday I needed a project.

Part of it was I went to the MIT swapfest, which fed my inspiration to find something to tinker with. Also, part of my inspiration to fine a project was seeing this guy while biking back to Boston:

This guy was willing to wobble crosstown with a poorly secured computer, scanner, keyboard, and mouse. I ought to be willing to take apart something in my apartment.

Onto the project! I’ve got this stupid stereo system:

I got it off Craigslist years ago when I first moved to Brooklyn. After a super sketchy transaction, I figured out Craigslist is just an easy way sell stolen merch in Brooklyn. Anyways, I only use Aux in, which is good because by now the radio is broken, the CD player is broken, and the tape deck is (I assume) broken. And they’re broken in a way so that motors will spontaneously spin and click in the middle of the night at a volume that makes me hide under covers with a crucifix. They need to go. Also, that LCD screen is bright and flashes nonesense. When you turn the stereo off, the screen goes in “Demo Mode,” which is brighter and flashier. That also needs to go. First, check the exterior:

Get the screwdrivers! Unscrew, unscrew, yank, snip, fuck you Tape Deck!

You’ll never be cool like vinyl.

And fuck you, 3-disk changer!

You were a stopgap between 1-disk and iPod. I’d show more mercy if you didn’t loudly cycle through three empty slots at random times, hoping today would be your day. No one likes you-get out of my face.

Maybe in taking it apart, I found my first use for that CD player. There’s a heavy magnet that holds CDs firmly to the spindle platter, so – yank, snap, bend, unscrew, BAM – Free refrigerator magnet:

Well, the flashing lights are more difficult than I thought they would be. I spent some time staring at logic boards and reading about embedded systems. Unplugging some wires stops all audio. Unplugging other wires bricks the thing. It looks like the control system (volume, inputs, mixing) are too closely integrated with the display. I bet I could bypass the current display and replace it with a simple serial LCD and a pile of aligator clips, but that will have to be another project. So, I put all the useful components back together. In a very small victory, all the mechanical parts are now removed and I was able to watch a whole movie without any whirring and clicking. Jesus, Paccino does a great Shylock, but I forgot how weird that play is….

There’s something especially rewarding about hacking Apple products…

I don’t know what it is. I think it’s just that all there stuff is such a black box. You can’t easily open any of their products, you never see their guts, you never think about the software on it. Stuff goes in, stuff comes out, but they very purposefully design things so you don’t know what’s going on inside. The way Apple explains their kit is that it is “Magical.”

But fuck “magic.” I quit believing in magic when I was seven and found out the Force isn’t real. What’s actually inside my iPod  is a lithium-ion battery, a 74GB HDD, and a motherboard with integrated 64MB of RAM, a 1MB flash chip with a bootloader on it, and another dedicated to the operating system. And to prove it, I wiped and replaced the bootloader, then pointed it to my newly installed iPod operating system. Check it out:

So I did this in the first place because I don’t use iTunes anymore, and that’s what’s needed to update an iPod. But that’s lame, right? I mean, when iTunes adds music to an iPod, all that’s happening is it’s copying mp3 files to a USB attached harddrive. Why do I need iTunes to copy mp3s to a USB attached harddrive? My computer can copy mp3 files to a USB attached harddrive. So I decided to install a different operating system on my iPod, and now I can copy mp3s to my iPod however I want. Simple.

But then once it was done, it was pretty gorgeous. You know, maybe not the Rockbox UI, but the process and the results are gorgeous. I got to, step by step, crush any illusions I had about my iPod, and finally the curtain is drawn back. It’s a fuckin computer that plays mp3s. And that’s it. Worth remembering.

PS — Awesome operating system from Rockbox, and working bootloader from emCORE.

My Printer is Spying On Me

Shit, heavy topic for first time back.

Well, the Electronic Frontier Foundation has done some great work compiling data on how many business sized laser printers add almost invisible yellow dots to every printed page. Those yellow dots are a coded way of stamping the paper with the make, model, and serial number of the printer; and the time, date, and file name of the print job. Also, that data is put there at the request of the Secret Service. FOIA is a great fucking program that oughta be strengthened:

None of the printers I use are on the list of printers put together by the EFF. So it was time to check test pages myself — especially the printer I know is used to make agendas for Occupy Berkshires meetings. Can the Secret Service track papers printed for political rallies I attend? Fuck yeah!

Here are the yellow dots, raw but magnified:

Here is a much larger section, altered in GIMP to boost contrast. Also a rectangle is added so you can more clearly see that this is a repeated pattern, not just random dots:

So if you have access to a laser printer you should really help the EFF figure out the encoded messages by printing test pages and sending them in.

I’ve gotten into the ideas of software freedom, and have been struggling to find where exactly I stand. I think this, for me, crystallizes why people fight for free software. Printers wouldn’t print tracking data for too long if they came with source code. Say — where can I get some libre firmware for a Konica printer? Preferably ones that print invisible smiley faces that mean nothing :)


Restarting the blog

Got shit off off of blogger, running my own WordPress installation, and once a month I’ll have something to say about film making, free software, politics, activism, radio, internet. Anything. This’ll be great!