In Which I Write Software

August 15th, 2013

Snap! It

So I’ve been doing stuff.

You wouldn’t know that to look at this site for the past – oh, five years or so – but one of the reasons that I haven’t been blogging is that I haven’t been doing things that I think would be of interest to the people who’ve historically been the audience here. I almost never knit anymore, but I am still close to the knitting world, mostly thanks to my partner Jennifer. She knits like a fiend and is always exploring interesting nooks and crannies of the fiber universe, so I’ve been getting my knitting fix vicariously through her. (It’s really not the same though.)

Jennifer was putting together some instructional materials a few months ago and got to the point where she needed to take pictures of the knitting techniques that she was executing. Now, Jennifer and I both know our way around cameras. She’s Canon and I’m Nikon, so there’s a wee bit of friction there, but hey, variety is the spice of life. But we found that neither one of our fancy-schmancy camera rigs was really right for the job. It’s not that it was impossible to take close-up pictures of both of her hands knitting; it’s just that it was . . . I don’t know, is there a word that is the antonym of ergonomic? It was clumsy and frustrating. Either she could try and set up her Canon between herself and her hands and angle the camera correctly and set the timer and get her hands in position and and and . . . Or, I could over next to her and try and shoot over her shoulder. Which kind of worked, but I’m a limited resource. Most of the time that she’s working on her knitting projects, I’m at work doing worky things.

One day, fed up with the kludgyness of the process, she looked over at me and said “What I need is a voice-activated camera app for my iPhone, dammit.”

Pointed staring at me.

Eventually it penetrated my skull that she was saying that I should do the writing of this app. And so, many months later, I got my first app posted on the Apple app store. May I present Snap! It. It’s billed as a voice-activated camera, but make no mistake – I really did make this specifically for knitters. Anyone who meets the following criteria should try it out:

  • Is a knitter/crocheter/fiber artist
  • Has an iPhone/iPod/iPad
  • Wants to share pictures of WIPs or techniques with other sighted individuals

It will be significantly more useful if you have a tripod and a mounting bracket for your iOS device. There is no way to stabilize a device just through software at the moment, sorry. But once you get the phone/pod/pad positioned the way you want, just say “snap” or “capture” and the app will happily take pictures for you and save them to your camera roll.

I’m actively developing Snap! It and plan to add more features in the near future, including video recording and focus/exposure controls. Right now the app is free, but when I feel that it has become sufficiently feature-rich, it is going to be reasonably priced. Please check it out if you are so inclined. And please send feedback. I want this app to be a helpful tool.

Now it’s a trend

November 11th, 2012

Last year for my 40th birthday, I took my bike to Vashon island and did a 40-mile loop of the island.

This year, my girlfriend took me to Friday Harbor for my birthday. I just got back from a double loop of the island that took 44.11 miles according to my bike computer.

Once is a statement; twice is a trend. Soon it’ll be a tradition.

CocoaConf Portland

October 26th, 2012

I’m at CocoaConf in Portland today and tomorrow, trying to cram as much OS X and iOS knowledge into my brain as I can. Bloggy goodness to follow.

Derp.

September 29th, 2012

I recently had to move the sweaterproject.org site from one server to another because my old hosting service was being shut down. (Farewell, Slicehost – we barely knew ye.) I got my blog and a couple of others that I host moved to the new server with no issues last weekend. Then, last night at dinner, I was thinking about knitting and software and I remembered Visiknit. I completely forgot to test it after the move.

So, naturally, when I checked it on my smartphone, it was broken. I could go in to a long description of the heroic efforts involved in trying to bring it back up, but I think most readers will realize that the entire process consisted of me sitting in front of a laptop sipping soda and periodically muttering obscenities. So I’ll just cut to the chase and say it’s back up and happily cranking out graphs again. Sorry for the down time.

Painting with light

September 28th, 2012

I ran across an article on PetaPixel.com about an artist named Eric Staller the other day. There is a technique called “painting with light” that has been popular in the last few years where you take long exposures and move a bright light source around to create light trails – it’s fun and easy to do with modern digital cameras. But Eric was doing it in the 1970s on film, which is a lot more challenging.

With modern digital cameras, you can take your shot and see the results immediately. When you’re shooting on film, you have to know exactly what you’re doing because you don’t see your results until you get the film developed. Digital cameras speed up the learning process this way; you get very quick feedback about your settings. I wonder if this is a good thing. I know I’m not as smart as earlier film photographers because I can rely on my camera to give me instant results, so I can noodle with my settings to get just the effect I want, rather than knowing exactly what settings I need before I ever take the shot.

I tried replicating Eric’s technique on our deck last night and got the exposure below. It’s not quite what I wanted but it is a start. I plan to try some more light painting shots in the near future.

light painting 1

Edit:

Here’s a slightly better-exposed version.
light painting 2

In which I am a squeeing fan boy.

September 23rd, 2012

I just heard that there is a new film of Les Miserables in production, to be released this summer Christmas. It’s going to star Russel Crowe, Hugh Jackman, and Anne Hathaway. And it’s going to be a production of the musical.

I am squeeing so hard the dog is hiding right now. I love the musical. I got to see the final performance of the original London cast when I was in high school. I can’t wait for this to hit the theaters.

My only beef is that Crowe is playing Javert and Jackman is playing Valjean. When I first heard about them both being in it, I kind of assumed that the casting would be the opposite of that. Jackman strikes me as more of a Javert and Crowe just has that half-badass, half-puppy dog look calls Valjean to mind.

Anyway – there’s at least one movie I’m looking forward to this Christmas season.

Happy Independence Day!

July 5th, 2012

Happy 4th of July from Seattle, everyone!

DSC_3508

Yesterday was a mass of happy for me – I did some code work, I cooked, I knit, and I took pictures. I don’t get to hit all my hobbies in one day like that often.

More photography.

June 26th, 2012

More coding too. And more sheep.

Coding: I FINALLY got past the hang-up which had me at a coding standstill for a fucking month. In my defense, I am the type of coder who needs a fairly long block of uninterrupted time to concentrate and get a problem fixed in memory in order to work on it. I very rarely have that kind of time, ever. But this weekend at Black Sheep Gathering in Eugene, OR, I took some time with my laptop and cranked on the app that I’m working on, and I finally got past the roadblock. Go me.

Sheep: Black Sheep Gathering was last weekend. It was great. We got to catch up with fiber friends from all over and act goofy and pet sheep and fondle really good tools and sigh. . . It was just wonderful. I want more weekends like that.

Which brings us to the pictures. A couple of pics of the lovely animals, followed by some pictures that I’m just kind of happy with.

Please don’t be scared by the moth. It’s not a wool moth. I promise.

DSC_3193

DSC_3187

DSC_3103

moon

Palouse House

Getting closer

May 28th, 2012

Ugh. Wow. The Memorial Day holiday weekend is almost over and I have spent the lion’s share of it in front of my computer, trying to accomplish a single task. I’ve been trying to create a database using a desktop application on my Mac and move it over to an application that I’m writing on my iPad. In very simple terms, I’ve been trying to move a file from point A to point B.

I feel kind of thick for taking so long to get this accomplished. But I just succeeded. I can now edit my database on my desktop (where having a proper mouse and a full keyboard makes data entry a heck of a lot simpler than on the iPad) and with a couple of clicks and drags, get the database onto my iPad for viewing. Ah, sweet victory. Now I just need to make the application on the iPad do something interesting with it.

I want a cookie.

Slowly crawling up the learning curve

May 20th, 2012

Man, XCode development is hard. And fun.

XCode is the suite of development tools that Apple gives away for its OSX and iOS operating systems. It lets you write programs for OSX or iPhones/iPads/iPod Touch, in other words. It’s free, but it’s a serious bunch of software. Writing code with it is not like writing a Visual Basic application (well, except for when it is). The language behind it is Objective-C, which is a variant of the old C programming language. I’ve got some familiarity with C, but most of my software writing experience is using languages like PHP and Python and Perl (love them P languages) that handle a lot of things for you automatically, like pointers.

A pointer is a concept in programming languages that helps make programs more memory efficient. In C, you can say the following:

int x = 10;

That means you’re declaring a new integer value named ‘x’ which starts with the value of 10. Integer values can hold whole numbers.

All well and good. But most of the time in iOS, you’re not dealing with simple little things like integers. You spend a lot more time dealing with very complex objects that consist of lots of simple numbers as well as other objects – like UIView. UIView is an object that’s responsible for displaying stuff on your iPhone or iPad. It takes up a lot more memory than an int, so when you declare one in Objective-C, you create a pointer to it, like so:

UIView *myView;
myView = [[UIView alloc] init];

The “*” on the first line means that you’re not creating a variable that is a UIView; it means you’re creating a variable that points to a different memory location where the UIView is actually being created – a pointer. A pointer doesn’t contain a value that you can use; it contains a memory address where the value that you want to use actually lives.

PHP, Python, and Perl don’t (typically) make you use pointers. Any variable that you create in them is just a variable that you can play with directly. The problem with pointers is that they can potentially allow you to accidentally reference a chunk of memory somewhere else that may or may not still be the variable that you want to be working with. The old adage is that C gives you enough rope to shoot yourself in the foot – pointers are a great way to do that.

Anyway, all this is really saying is that I’m still coding and still learning. Hopefully something useful comes of all this. I need coffee and chocolate.