Editing with a side of Raspberry Pi

Let me warn you. This post is less about writing and more about me being a geek. Sure, it starts out writing related, but don’t say I didn’t warn you.

So I sat down last night to start editing the first draft my novel, which I actually finished a couple years ago. I printed out the first two chapters and started marking them up with a red pen. When I got to the top of the third page I realized that editing that page was pointless because that part of the story had no business being there are all. It was pointless and boring. I ended up completely removing the first seven pages (except the first sentence) and replacing them with a single paragraph. After that I had to stop editing for the night. Do you have any idea how draining it is to sit down to edit only to completely remove the first seven pages of your manuscript. I credit that to being a better writer now than I was when I originally wrote it, but it’s still a bit unsettling to remove such a large chunk at the very beginning. Overall I like the story, but getting it presentable is going to take a lot of work. Although if I keep this rate up of hacking bits out, the 76000 words I previously wrote will turn into a short story by the time I’m done, but if it needs to come out it’s going to come out.

After I sacrificed those first seven pages to the gods I was emotionally drained so I had to quit editing for the night. That’s when I turned my attention to one of my non-writing projects.

I call it my Holiday Pi. I call it that because the brain of the thing is a Raspberry Pi (a mini computer, about the size of a computer mouse) and it will be used to augment my holiday decorating, namely Christmas and Halloween.

This is what a Raspberry Pi looks like. I would have taken a photo of mine but I didn't feel like unhooking all of the wires.

This is what a Raspberry Pi looks like. I would have taken a photo of mine but I didn’t feel like unhooking all of the wires.

What is this Holiday Pi, you ask? Well, it’s a box. Oh, you wanted more than that? Ok, allow me to explain.

I built this box. Then I cut a couple holes in it and put a few power receptacles in the side of it. I then hooked the RPi up to an 8 channel solid state relay board that switches the power outlets on/off on an individual basis when the RPi sends the necessary signal. I know I probably lost you already, but stay with me. It’ll make enough sense to understand what it’s for after I finish explaining… I hope.

Okay, so we’ve got a Raspberry Pi, a solid state relay board, and some power receptacles. The programming in the Rpi turns the receptacles on and off. You’re probably asking yourself, “what is the purpose of this whole setup?” I’ll get to that.

The infamous black box that houses all sorts of strange and unusual things. It's twice as big as it needed to be because half of it is for storage of various other unstrange and usual things used in conjunction.

The infamous black box that houses all sorts of strange and unusual things. It’s twice as big as it needed to be because half of it is for storage of various other unstrange and usual things used in conjunction.

Well I then hooked up a mini amplifier and a set of outdoor speakers. This is where the programming of the RPi comes in. When I send a song through the speakers, it also sends that song through a special program (I didn’t write the original program, but I did some modifications on it to suit my needs) that switches the receptacles on and off, effectively synching them to the song. This means that anything plugged in will turn on and off. If you don’t see where I’m going with this, let me spell it out for you: next year’s Christmas lights will be synced to music, thus making me king of the neighborhood.

As for Halloween I have a couple other programs I wrote: Flicker, Lightning, and Howloween.

I know it's not the prettiest thing in the world with all those wires running about, but I assure you it's perfectly safe. Amp is at the top, Relay board is at the bottom. RPi is on the right.

I know it’s not the prettiest thing in the world with all those wires running about, but I assure you it’s perfectly safe. Amp is at the top, Relay board is at the bottom. RPi is on the right.

Flicker just sets one of the receptacles to be always on, but randomly flicker. This will be used to add lighting to my graveyard setup, lighting that flickers (obviously). Specifically, the plan is to use it with a couple colored lights buried in a bed of fog.

Lightning flickers another receptacle, but starts and ends in the off position and sends a thunder sound clip through the speakers. The combination of the two should produce a decent lightning effect. Good enough for the graveyard in my front yard anyway.

Howloween plays a random sound effect at a random interval. It has nothing to do with the receptacles.

I’m still trying to think of uses for the 6 other receptacles available with the current Halloween setup. If you have any ideas, give them to me in the comments below. I have a plan to make “dancing graves”, which in essence is just like the Christmas display except with lighted tombstones synced to the music, but I’d have to build the tombstones for that one and I’m not sure I want to take on that project quite yet. I’ve got a lot of time until Halloween though, so it might happen.

All 8 are used with the Christmas synchronization so I’d have to expand my box to add anything to that one, and I don’t plan on doing that anytime soon.

Now, I just have to finish my testing and find some music worthy of syncing to lights.

If you’re interested in building your own:
Basics of building the box can be found here.
My program files can be found here.

I tried to warn you…

Advertisements

17 responses to “Editing with a side of Raspberry Pi

Comments, criticism or half drunken rants?

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: