4th March 2009

Innovative TV Remote

Innovative new TV remote control featured on CNET.

posted in Technology | 1 Comment

4th March 2009

Kindle for iPhone

Various blogs are all in an uproar over the Kindle iPhone app and whether this is a good idea or not. I’m going to come down on the “very good idea” side and say that this makes me more likely to get a Kindle (and more importantly invest in the Kindle eco-system by buying some content).

The big issue for me is the profusion of devices. I don’t want to carry around a phone, a music player, a book reader and a laptop. One of the things I really like about my iPhone is that it acts as a good music player so I can just carry one device.

Having said that the form factor of a given device isn’t perfect for every situation. I downloaded the Kindle app to my phone and tried it out and it was very well done (I got the sample first chapter of the new Neil Stephenson book), but it seemed like it would be a painful way to read a whole book. The key thing is that the iPhone app and device both sync the same books and can share the place you left off reading + bookmarks. So if I were to buy a Kindle device I’d end up of course getting content for it, but if I left it behind I could still do a little light reading from anywhere which is a really cool scenario.

The other angle behind giving away the software of course is that Amazon is presumably more motivated by getting people to invest in their content than in selling the actual devices. Apple has done an amazing job getting their device COGS down so that they make a profit off $199 iPhones, but Amazon is much newer to the hardware space and were at least implying that they can’t sell for much more than the $359 without losing money. But it doesn’t take that many $10 digital books to turn into real money and if their free iPhone app gets you to spend a bunch of money and locks you into your Amazon digital library, they win too. From that perspective it would make sense for them to make a PC version too- if I could read real books on a normal Windows tablet that would probably push me over the edge for sure.

posted in Business, Technology | 0 Comments

26th February 2009

New Printer- Canon Pixma MX7600

I keep meaning to post more about what is going on at work, but that always seems like so much effort to get it right. In any case I got a new printer, which is fun. I’m a fan of the multifunction printers, by which I mean ones that can scan and print in the same unit- fax I don’t really care about and I suppose in theory I could “copy” but I never do.

My old printer was a Dell All In One 962. Dell was practically giving these away free a few years ago and frankly it has done a decent job. But as with most cheap mechanical devices it has started being more and more flaky, plus the software never really worked right with Vista and so the older scan to PDF (with OCR) function hasn’t been working right which has sucked.

Looking at reviews of other printers I noticed that Canon overall seems to get good marks and I was pretty excited to see a couple of models that support duplex printing and scanning. The worst part is that it was very very difficult to tell what the difference was between models, but I ended up getting the slightly more expensive one at just less than $300. In today’s printer market where the printers are almost free and they gouge you on ink, that is a fortune.

My first impression was that the footprint of this thing was huge- much bigger than I expected. It fits in the spot where my old printer was, but only by bulging out onto my desk an extra 6″ and getting a little in the way. I suspect this might have to do with various protrusions that are used to flip the paper for the duplex stuff. Setting it up I noticed a cool feature that old printers didn’t have- the print head unit is replaceable- one of the big problems with my old Dell is that over time the print head has gotten gross so being able to replace it is a nice thing (even if at close to $50 it costs as much as many printers).

The ink is also in individual reservoirs for each color. Again, this gives you potential savings since you don’t have to replace the whole thing the first time one runs out, but it also means there are 6 different things to replace at $15 each. It also has this “clear ink” which frankly I don’t get. This review of the MX7600 explains that clear ink is used to coat normal pages so they work as well as special inkjet paper so we will see.

The setup was both of a bit of a pain and kind of cool. It does a self-calibration step that takes 10 minutes and failed the first time, but basically prints some stuff and uses some optics to make sure it worked right automatically. Still, it did work on the second try and I was off to software setup. The software setup took forever and a half and installed 300mb+ of crap on my machine and required a reboot, none of which are cool. I’m using the printer connected to the network but it doesn’t just work as a normal Windows network printer- you have to hook it up the first time on USB + Ethernet and then you can ditch the USB. Still it requires their software install on every computer that wants to print (unless you use a computer as a server which isn’t really the point of a network printer in the first place).

Printing seemed slow but the quality was fine, and what do you expect for an inkjet. Scanning seemed much faster and the software is much nicer than the old stuff from Dell. Duplex scanning from the paper-feeder rocks, and they have a great mode where it shows the scanned pages and lets you easily rearrange / collect them before combining them in a PDF.

Overall looks pretty good so far..

posted in Hardware, Technology | 1 Comment

24th January 2009

White House Blog

The White House has a blog now which is pretty cool. My only complain would be that their RSS feed only has summaries so you have to click through to read the whole thing. I can understand some for-profit blogs that do that so they can get the click count & ads, but for this kind of thing its really annoying.

posted in Technology | 0 Comments

13th January 2009

What Happened to the Rumored Apple Products?

Leading up to MacWorld there were a ton of rumors about a new MacMini, an iPhone Nano, and updates to Snow Leopard. Then the announcements during the actual show were a bit underwhelming(for most people- Chris was really excited about the new MacBook Pro).

My theory is this is all related to the reason that Apple is pulling out of MacWorld in the first place. It is a show they don’t control, IDC presumably wouldn’t let them webcast the keynote so they would rather introduce important things at their own events where they can get more focused press (on a schedule they control, not the middle of the CES mess and where they can time them so the products are ready), with a webcast and broadcast into all the Apple stores.

So they had already signed up for MacWorld and needed to announce something, but they kept it to the fairly tame iLife, iWork updates and the new MacBook Pro which is certainly a product for the enthusiast segment. The theory is that on good PR grounds they are holding the bigger more general audience announcements for events where they can control them better and make a bigger splash.

I’m assuming in a few weeks we are going to hear about invitations heading out for some other Apple event where they will start rolling out the next stuff (I’m hoping for an update to the MacMini myself, and betting that we won’t hear about iPhone updates until around June which appears to be when they refresh that product line).

posted in Apple, Business, PR, Technology | 0 Comments

7th January 2009

Calling a SOAP Service from PowerShell

Ever had that experience where you go do some work and then stop yourself and think “There has got to be an easier way to do this”?

I’ve been building some stuff that is mostly exposed as a web-service. I wanted to call it from PowerShell so I made a nifty set of Cmdlets that call it. But really each of them is just marshaling pretty much directly into the underlying SOAP service with no logic at all. I’ve got to assume someone already came up with a generic solution for this?

posted in Developers, Software, Technology | 0 Comments

6th January 2009

Database Design

So here is a classic database design quandary. Lets say you are developing a service with accounts and each account has a set of parameters associated with it- have they bought the service, how much storage do they have, how many user licenses, etc.

Now, the set of things you want to store is going change over time for sure. So option 1 is to design a completely flexible system for storing key-value pairs-
CREATE TABLE [AcctParams1] (
[AcctId] [int] NOT NULL PRIMARY KEY,
[Key] [nvarchar] (16) NOT NULL,
[Value] [int] NOT NULL
)
CREATE UNIQUE CLUSTERED INDEX [AcctParamsIdx] ON [AcctParams1] ([AcctId], [Key])

A couple of notes before I move on. First of all its very important to create the clustered index on AcctId. You want to make sure that all the rows for the given account are grouped together on disk. If not, when the database goes to load just one account it might have to do IOs all over the place just to get the scattered AcctParam values.

As I said above, this approach is completely flexible, ideally involving no database schema changes ever. But the storage is somewhat less efficient and you are going to have to do multiple queries to retrieve everything you need about an account (one for the account itself, another for params).

The other way to do it is to just build out a table of the explicit columns for these parameters in classic database way-

CREATE TABLE [AcctParams2] (
[AcctId] [int] NOT NULL IDENTITY,
[Purchase] [int] NOT NULL,
[UserLimit] [int] NOT NULL,
[StorageLimit] [int] NOT NULL
)
With this approach you need to change the database schema every time you want to add some new param. However I think sometimes people get too freaked out by database schema changes (often because of too painful “upgrades” in the past). For example if you just needed to do this-

ALTER TABLE [AcctParams2] ADD [TransferLimit] [int] NOT NULL DEFAULT 5

On modern databases this kind of thing tends to execute pretty quickly but most importantly if your code is written carefully you can run this on your SQL box while your service is still online without having to simultaneously update the code of the service. I did some examples and create the above table and put a million rows of random data in it (which took 229 seconds on my test box). The above ALTER TABLE took 7 seconds to execute.

Guess what? We can do much better. Try this one-
ALTER TABLE [AcctParams2] ADD [TransferLimit] [int] NULL

By making it a NULL column it took… 0 seconds to execute. And again, if your app is built the right way, existing code will continue to work unchanged. So you can use a database schema that really defines the parameter names and types (in effect, SQL is handling the key-value stuff for you), but still has minimal upgrade impact on the uptime of your service.

A third approach is to have something like-

CREATE TABLE [AcctParams3] (
[AcctId] [int] NOT NULL IDENTITY,
[Params] [text] NOT NULL,
)

And stuff XML in the text column. Again, lots of flexibility, but you need to deal with all the XML parsing and it tends to be difficult to get the database to help you with any queries or analysis of that data. I’ve also seen multiple efforts that went down this path and the XML parsers ended up inflexible enough that they actually introduced tons of inflexibility and upgrade hassle. If you need to touch every row to upgrade the XML on this approach you just made yourself a huge problem.

One last note that applies to either approach 2 or 3- you can combine these params in the base [Account] table. Whether you want to do this or not depends on the access patterns. If 90%+ of the time when you want to access one, you want to access the other (IE, you are always writing SELECT * from [Account] join [AcctParams] on [Account].[AcctId] = [AcctParams].[AcctId] ), you might as well combine them so that its always just one I/O. On the other hand if you often want just one or the other AND they start to get large (lots of values, especially to the point where it gets close to the page size), it can make sense to split them out.

As will all optimization, there are no hard and fast rules- just guidelines and good places to test alternatives.

posted in Developers, Storage, Technology | 0 Comments

3rd January 2009

Holiday Project- Windows Azure

Dare embarked on a holiday project too, building some stuff using Azure. I’ve been meaning to get around to that one too myself. In any case, some great observations there, I’ll have to write up my likes and dislikes about PowerShell myself shortly.

posted in Azure, Developers, Technology | 0 Comments

26th December 2008

Winter Break Work

This year we aren’t going on any special trips over winter break so I’ve been “at work”, although given the weather (and the fact that no one is actually on campus) I’ve been working at home.

This is a pretty slow time of the year and it can be hard to get main work items done with so few other people around to coordinate with and get feedback from. Of course this makes it ideal to ramp up on key technologies and I’ve been spending a lot of time learning about Windows PowerShell. As a counter-example to my earlier comments about this time of year at Microsoft the PowerShell team just released CTP3 of Windows PowerShell version 2.0 last week and have had a flood of posts about cool things to do with it on the PowerShell Team Blog.

PowerShell seems like a pretty key breakthrough in terms of managing computers, especially large networks of them as we need to for the SharePoint Grid project. Having said that I’m still all over the place about the right way to approach it- there are so many different ways to get a given thing done that it can be a bit difficult to decide the right approach. I’ll try to post more about some of the options and trade-offs.

posted in PowerShell, Software, Technology | 0 Comments

25th December 2008

Christmas Chinese Food Riot

We are out picking up take out Chinese food for dinner and it’s quite the scene here. Not really a riot, but close- there has been some actual pushing and people knocked over a large potted plant. Plus lots of people getting in the way of the wait staff. Be safe people!

posted in Technology | 2 Comments