Archive for July, 2009

Assembling a Minty Boost

Friday, July 31st, 2009

Before I made an attempt at creating a mutant iPhone, which turned out pretty good, I had a go at assembling a Minty Boost. A Minty Boost is a homemade portable charger, designed by ladyada.net, which works with regular AA batteries and has a USB plug, it’s able to charge almost anything that can be charged with a USB cable. And yes, it charges iPhones, doesn’t that sound like music to your ears?

The website lists all the parts needed, several schematics and a walkthough on how to assemble it. All parts can be bought online or you can search for them at your local hardware/electronics store. I choose to buy 2 sets online, since I had a hard time locating the IC chip in Belgium. A set costs $19.50 and contains all the parts needed, including a custom made PCB board (big plus). I choose the cheapest shipping method ($6) and it took only a week to get to the other side of the big blue ocean. Customs did ask €10 for the parts though.

Minty Boost parts

The actual assembly is pretty straightforward and can be done without any soldering experience. The only thing left to do now, is fitting it all in a little box. I’ll post some pictures of the actual finished product, once I find a suitable metal box.

Assembled Minty Boost

Basic authentication of a .NET REST service

Tuesday, July 28th, 2009

One of the issues one can encounter when building a REST service with the .NET Framework 3.5 SP1 is the fact that when basic authentication is enabled, it defaults to authentication against Windows accounts in IIS. It’s not possible to specify your own handler/provider to authenticate against for instance a proprietary user database, nor is it possible to secure only a certain operation/service and leave the others unsecured.

Luckily there’s a open source project hosted on CodePlex called WCF REST Contrib which, besides adding a whole lot of other improvements, solves the aforementioned issues. The project provides a sample solution showcasing all the features, which might seem a bit overwhelming since it includes quite some configuration. I have attached a sample project with only the bare minimum configuration (using attributes) to enable per operation authentication.

Browse to CancerService.svc/request/skincancer to test the authentication, the browser should display a prompt asking for a username and password. The username is “tony” and password “clifton”. Don’t mind the rather questionable service and operation name, I had no inspiration at the time.

The original documentation failed to mention that the per operation/service authentication depended on the WebErrorHandler, which has been corrected.

Attachment: Authentication Tryout

The mutant iPhone

Sunday, July 26th, 2009

A few months ago I received a first generation iPhone which had been in a car accident. The screen had been cracked and the aluminum case was in a bad shape, despite the horrible external imperfections it was actually working, well kind of. I was unable at the time to restore it to firmware 2.2.1 since it would hang at one specific point during the process. Luckily, with the advent of firmware 3.0, somehow I was able to restore it without the previous hang.

I used the device a few weeks as test device for my Emmer Inc related adventures, until I got my hands on Lemmy Van den Eede’s bricked iPhone which didn’t boot at all. In the end I combined the best parts of both iPhones to create one working mutant iPhone.

Disassembled

The internet is filled with movies and guides on how to disassemble an iPhone, but I thought I’d post a few lessons learned and give my own opinion on the process. Before I attempted the transplantation, I was unsure how doable it would be.

    Antenna cover removed

  • Removing the black antenna cover and the aluminum back casing is difficult. No matter how easy they make it look in the movies, it just isn’t. I used metal tools instead of the advertised plastic case openers, which I doubt will do the trick. I’ve read several comments stating that the plastic tools look good, but are useless at opening the case. Expect scratches and scuff marks on the case and slight bending of the aluminum casing! I highly doubt if anyone can open the casing for the first time without causing external damage.
  • Once the device is open, disassembling it is indeed straightforward, I was a bit scared that I might not be able to assemble it again. But as long as you don’t lose anything it is easier than one would think. Just take your time & you’ll be fine. The only “issue” I had when assembling it, was a latch which had to be connected to the motherboard, I thought it had to click, but you just have to slide it in the connector.
  • Removing the glass plate and the actual LCD from the inner case is rather difficult, removing the glass plate itself from the LCD is in my opinion nearly impossible without breaking your LCD. In the end I took the inner casing with the LCD and glass plate of the bricked iPhone and inserted the motherboard of the other iPhone.
  • Desoldered battery

  • While I was at it, I also desoldered the battery of the bricked iPhone and soldered it back in into the mutant iPhone. The battery is soldered to the motherboard with 3 wires, the wires are covered with glue which is a little tricky to remove. But it is doable, even with little to no experience soldering. Whatever you do, don’t let the red wire tough the white or black one, according to the disasembly guides. Put some tape over the red one.

Finished mutant iPhone

And that was kind of what I wanted to document. Just take your time, watch the disassembly videos a few times and you should be ok. If you came to terms with the fact that your beautiful iPhone will look a little less perfect afterwards, that is.