Nokia N900 and iPhone headsets?
For a geek like me, the Nokia N900 is paradise on earth: It's full Debian Linux in your bag. It has the best IM integration I have ever seen on any mobile device. It has the best VoIP (Skype, SIP) integration I have ever seen on any mobile device and it has one of the coolest multitasking implementations I've seen on any mobile device (the card-based task/application switching is fantastic).
Unfortunately, there's one thing that prevents me from using it (or many other phones) to replace my iPhone: While the whole world agreed on one way to wire a microphone/headphone combination, Apple thought it wise to do it another way, which leads to Apple compatible headsets not working with the N900.
By not working I don't just mean "no microphone" or even "no sound". No. I mean "deafening buzzing on both the left and right channel and headset still not being recognized in the software".
The problem is that I already own iPhone compatible headsets and that it's way easier to get good iPhone compatible ones around here. I'm constantly listening to audio on my phone (Podcast, Audiobooks). Having to grab the phone out of my bag and unplugging the headphones whenever it rings is inacceptable to me, so I need to have a microphone with my headphones.
Just now though, I found a small adapter which promises to solve that problem, proving once again, that there's nothing that's not being sold on the internet.
I ordered one (thankfully one of the international shipping options was less than the adapter itself - something I'm not used to with the smaller stores), so we'll see how that goes. If it means that I can use a N900 as my one and only device, I'll be a very happy person indeed.
Sticking to the iPhone
Recently, I got a chance to play around with a Nexus One phone and I was using it as my main phone with the intent to use it as my new main phone. I had enough of the lack of background apps and the closedness of the iPhone, so I thought, I should really go through with this.
Unfortunately though, this didn't work out so well.
People who haven't tried both devices would probably never understand this, but the Nexus One touch screen is really, really bad. The bit of squigglyness you see on the picture in the linked article seems like no big deal, but after one week of Nexus One and then going back to the iPhone, you can't imagine how smooth it feels to use the iPhone again.
It's like being in a very noisy environment and then stepping back into a quiet one.
Why did I try the iPhone again?
While I got Podcast listening to work correctly on the Android phone, I noticed that a lot of my commuting time is not just spent by listening to podcasts, but that some games (currently Doodle Jump and Plants vs. Zombies) play a huge role too and the supply of games on the Android plattform is really, really bad.
And don't get me started on the keyboard: Neither the built-in one nor the one I had switched to even comes close to what the iPhone provides. I'm about 5 times as fast on the iPhone than on the Android. Worse: After switching to the Nexus One, I again began dreading having to write SMSes which usually spells death to any phone for me.
Speaking of keyboard: The built-in one is completely unusable for multilingual people: The text I write on a phone is about 50% english and 50% german. The Android keyboard doesn't allow switching the language on the fly (while the english and german keyboards are quite alike, the keyboard language also determines the auto correction language), and it couples the keyboard language to the phone UI language.
This is really bad, as over the years I bacame so accustomed to english UIs that I frankly cannot work with german UIs any more - also because of the usually really bad translations. Eek.
So, let's tally.
| iPhone | Android Device | |
| Advantages |
|
|
|---|---|---|
| Disadvantages |
|
|
While I thought I could live with the touch screen, the moment I turned on the iPhone again to play a round of "Plants vs. Zombies" that just came out for the i-Devices, I've seen how a touch screen is supposed to work and I could not bring myself around to going back, but I still wanted some of the one big iPhone disadvantage, which is lack of non-SMS-based messaging fixed for me, so here's what I've done:
- WhatsApp on the iPhone works really well as an SMS replacement (something I was after for a very long time)
- meebo so far never disconnected me on the iPhone which is something all other iPhone IM clients have done for me - and even on the android, meebo tended to disconnect and not reconnect.
For me, that's it. No more experiments. What ever I tried to get away from Apple's dictate, it always failed. The N900 is a geeks heaven but doesn't support my expensive in-ear iPhone headset and doesn't provide any halfway interesting games. Android has a bad touchscreen, next to no battery life, is slow and crashy.
It's really hard to admit for me as a geek and strong believer in freedom to use something I bought for whatever purpose I want to use it for, but Apple, even after two years, still rules the phone market in usability and hardware build quality.
Can't wait to see what the next iteration of the iPhone will be, though they don't have to change anything as long as their competition still thinks it's ok to save $2 on each phone by using a crappy touchscreen and a crappy battery.
Things I can’t do with an iPhone/iPad
- have a VoIP call going on when a mobile call/SMS arrives
- read Kindle ebooks (I can now, but knowing Apple's stance on "competing functionality", with the advent of iBook, how long do you think this will last?)
- give it to our customers as another device to use with PopScan (It's not down-lockable and there's no way for centralized app deployment that doesn't go over apple)
- plug any peripheral that isn't apple sanctioned
- plug a peripheral and use it system-wide
- play a SNES ROM (or any other console rom)
- install Adblock (which especially hurts on the iPad)
- consistenly use IM (background notifications don't work consistently)
The iPhone provides me with many advantages and thus I can live with its inherent restrictions (which are completely arbitrary - there's no technical reason for them), but I see no point to buy yet another locked-down device that does half of the stuff I'd want it to do and does it half-assed at that.
Also it's a shame that Apple obviously doesn't need any corporate customers (at least for a small company, I see no possibility).
I just hope, the open and usable Mac computer remains. I would not know what to go back to? Windows? Never. Linux? Sure. But on what hardware?
iPhone works for me
A year ago, I was comparing mobile phones, I bought a Touch Diamond and regretted it and then I bought an iPhone 3G which I used for a year and now I even upgraded to the 3GS. Now that I just got yet another comment to my post about the Touch Diamond, I thought I should recycle that comparison table from a year ago, but this time I'll compare my assumptions about the iPhone back then with how it actually turned out.
So, here's the table:
| assumed | actually | ||
|---|---|---|---|
| Phone usage | |||
| Quick dialing of arbitrary numbers | actually, using the favorites list, and even using the touch keypad with its very large buttons, I never had a problem dialing a number. | ||
| Acceptable battery life (more than two days) | ? | meh - two to three days, but as I'm syncing podcasts every day, I get to charge the phone every day as well, so this doesn't matter as much | |
| usable as modem | probably not | it is now (using a little help for my Swisscom contract). As I was bound to my old contract with sunrise until may, I would have been able to use my old phone in an emergency, but that thankfully didn't happen. | |
| usable while not looking at the device | I got really dependent upon the small button on my headset plus the volume hardware buttons on the side of the device, both allowing me to do 90% of the stuff I was able to do on the old phone without looking at it. | ||
| quick writing of SMS messages | actually, I'm nearly as fast as with the T9 - having all keys at my disposal eliminates the need to select the right word in the menus, but not having the physical keys lets me wrestle with typos or auto correction which removes a bit of the advantage. It's not nearly as bad as I have imagined though. | ||
| Sending and receiving of MMS messages | works now. I missed the feature about once or twice in the 2.0 days, but usually sending a picture via email worked just as well (and was cheaper). | ||
| PIM usage | |||
| synchronizes with google calendar/contacts | maybe | yes. Since the beginning of the year, this works really well because Google just pretends to be Exchange | |
| synchronizes with Outlook | maybe | yes, directly via ActiveSync - but since February, our company went the Google Apps route, so this has become irrelevant. | |
| usable calendar | yes | yes | |
| usable todo list | |||
| media player usage | |||
| integrates into current iTunes based podcast workflow | yes | yes | |
| straight forward audio playing interface | yes | yes (see my note about the button on the headset above) | |
| straight forward video playing interface | actually, the interface is perfectly fine | ||
| acceptable video player | limited | kinda yes. Using my 8 core Mac Pro, it's quick and easy to convert a video, but lately I'm using my home cinema equipment for the real movies/tv series and the iPhone for video podcasts which already come in the native format. Still, it's no generic video player capable of playing video in the most common formats and it doesn't really support playing from any server in my home network. | |
| hackability | |||
| ssh client | maybe | yes. TouchTerm works very well - much better than any of the mobile Putty variants (Symbian an Winmob) | |
| skype client | maybe | note quite. Actually usable with the speakerphone or headset, but not as useful in general use due to the inability to run in the background | |
| OperaMini (browser usable on GSM) | not needed any more due to UMTS and near-flat rates. | ||
| WLAN-Browser | yes | yes | |
Nearly all my gripes about the iPhone have either become irrelevant or turned out not to be a problem after all.
Combine the very acceptable performance as a phone with the perfect performance as a podcast player, music player, acceptable gaming platform and perfect mobile internet device, then it becomes clear that the iPhone has become the perfect phone for me.
I upgraded to the 3GS mainly because of the larger capacity, but now that I have it, the speed improvement actually matters much more than the capacity increase as 32 GB still is not enough to fit all my audio books, so I'm still limited to all my music, all unlistened podcasts and a selection of audio books.
But the speed improvement from the 3G to the 3GS is so incredible, that I'm still very happy I made the purchase. All the other features are either not quite ready for prime time (voice control) or not really interesting to me (video recording, compass).
Still. After looking for the perfect phone for 8 years now, I finally found the hardware in the iPhone.
802.11n, Powerline and Sonos
I decided to have a look into the networking setup for my bedroom as lately, I was getting really bad bandwidth.
Earlier, while unable to stream 1080p into my bedrom, I was able to watch 720p, but lately even that has become choppy at best.
In my bedroom, I was using a Sonos Zone Player 100 connected via Ethernet to a Devolo A/V 200MBit power line adapter.
I have been using the switch integrated into the zone player to connect the bedrom MacMini media center and the PS3 to the network. The idea was that powerline will provide better bandwidth than WiFi, which it initially seemed to do, but as I said, lately, this system became really painful to use.
Naturally I had enough and wanted to look into other options.
Here's a quick list of my findings:
- The Sonos ZonePlayer actually acts as a bridge. If one player is connected via Ethernet, it'll use its mesh network to wirelessly bridge that Ethernet connection to the switch inside the Sonos. I'm actually deeply astonished that I even got working networking with my configuration.
- Either my Devolo adaptor is defective or something strange is going on in my power line network - a test using FTP never yielded more than 1 MB/s throughput which explains why 720p didn't work.
- While still not a ratified standard, 802.11n, at least as implemented by Apple works really well and delivers constant 4 MB/s throughput in my configuration.
- Not wanting to risk cross-vendor incompatibilities (802.11n is not ratified after all), I went the Apple Airport route, even though there probably would have been cheaper solutions.
- Knowing that bandwidth rapidly decreases with range, I bought one AirPort Extreme Base Station and three AirPort Expresses which I'm using to do nothing but extend the 5Ghz n network.
- All the AirPort products have a nasty constantly lit LED which I had to cover up - this is my bedroom after all, but I still wanted line of sight to optimize bandwidth. There is a configuration option for the LED, but it only provides two options: Constantly on (annoying) and blinking on traffic (very annoying).
- While the large AirPort Extreme can create both a 2.4 GHz and a 5 GHz network, the Express ones can only extend either one of them!
This involved a lot of trying out, changing around configurations and a bit of research, but going from 0.7 MB/s to 4 MB/s in throughput certainly was worth the time spent.
Also, yes, these numbers are in Megabytes unless I'm writing MBits in which case it's Megabits.
No more hard drives for me!
Last week I noticed that the hardware store of my choice had these fancy new (and fast) Intel SSDs in stock - reason enough for me to go ahead and buy two to try them out in my two MacPro desktop machines. Kos-Mos, my home mac was the first to be converted.
But before that, there was this hardware problem to overcome. See: The SSDs are 2.5 inch drives whereas the MacPro has 3.5 inch slots. While the connectors (SATA) are compatible, the smaller form factor of the Intel drives prevents the usual drive sliders of the MacPro from working.
The solution was to buy one of these adapters for the SSDs. Before doing that, I read about other solutions, some of them involving duct tape, but this felt like it was the cleanest way and it was: The kits fit perfectly, so installing the drive was a real piece of cake.
The next problem was about logistics:
pilif@kosmos /Volumes/Macintosh HD % df -h | grep Macintosh /dev/disk2s2 365Gi 319Gi 46Gi 88% /Volumes/Macintosh HD |
Whereas the largest Intel SSD available to date has just 160GB of capacity (149 "really usable"), so at least some kind of reorganization had to be done.
Seeing that the installation running on the traditional drive was ages old anyways (dating back to the last quarter of 2006), I decided that the sanest way to proceed was to just install another copy of Leopard to the new drive and use that as the boot device, coping over the applications and parts of the user profile I really needed.
Been there, done that.
I didn't do any real benchmark, but boot-time is now sub 10 seconds. Eclipse starts up in sub 5 seconds. The installation of all the updates since the pristine 10.5.1 that was on the DVDs that came with the machine took less than three minutes - including the reboots (I've installed the 10.5.7 update this morning and it took around 10 minutes on the same machine).
And to make things even better: The machine is significantly quieter than before - at least once the old hard drive powers down.
I will never, ever, again use non-SSD drives in any machine I'm working at from now on.
The perceived speedup was as significant as going from 8MB or RAM to 32MB back in the days. The machine basically feels like a new computer.
Of course I ran into one really bad issue:
The idea was to symlink ~/Music to my old drive because my iTunes Library (mostly due to Podcasts and audio books) was too large to conveniently copy to the SSD. I renamed ~/Music to ~/Music.old, created the symlink and started iTunes for the first time, only to get screwed with an empty library.
According to the preferences though, iTunes did correctly follow the symlink and was pointing to the right path (WTF?). I tried to manually re-add the library folder which did kind of work, but screwed over all my podcasts - completely.
This is where I noticed that somehow iTunes still found ~/Music.old and used that one. A quick ps turned out my best friend, the iTunes helper was running, so I shut that one down and moved ~/Music.old away to /, just to be sure.
Restarted iTunes just to run into the very same problems again (now, this is a serious WTF).
The only way to get this to work was to quit iTunes (that includes killing the helper) and to completely remove all traces of that Music folder.
Now iTunes is finally using the Music folder on my traditional hard drive. This kind of work should not be needed and I seriously wonder what kind of magic was going on behind the scenes there - after killing the helper and renaming the folder, it should not have used it any more.
Still: SSDs are fun. And I would never again want to miss the kind of speed I'm now enjoying.
celes in the office is next
This month’s find: jna and applet-launcher
Way way back, I was talking about java applets and native libraries and the things you need to consider when writing applets that need access to native libraries (mostly for hardware access). And let's be honest - considering how far HTML and JavaScript have come, native hardware access is probably the only thing you still needs applets for.
Java is slow and bloated and users generally don't seem to like it very much, but the moment you need access to specific hardware - or even just to specific files on the users filesystem, Java becomes an interesting option as it is the only technology readily available on multiple platforms and browsers.
Flash only works for hardware Adobe has put an API in (cameras and microphones) and doesn't allow access to arbitrary files. .NET doesn't work on browsers (it works on IE, but the solution at hand should work on browsers too) and ActiveX is generally horrible, doesn't work in browsers and additionally only works under windows (.NET works in theory on Unixes and Macs as well).
Which leaves us with Java.
Because applets are scriptable, you get away with hiding the awful user interface that is Swing (or, god forbid, AWT) and writing a nice integrated GUI using web technologies.
But there's still the issue with native libraries.
First, your applet needs to be signed - no way around that. Then, you need to manually transfer all the native libraries and extension libraries. Also, you'll need to put them in certain predefined places - some of which require administration privileges to be written into.
And don't get me started about JNI. Contrary to .NET, you can't just call into native libraries. You'll have to write your own glue layer between the native OS and the JRE. That glue layer is platform specific of course, so you better have your C compiler ready - and the plattforms you intend to run on, of course.
So even if Java is the only way, it still sucks.
Complex deployment, administrative privileges and antiquated glue layers. Is this what you would want to work with?
Fortunately, I've just discovered two real pearls completely solving the two problems leaving me with the hassle that is Java itself, but it's always nice to keep some practice in multiple programming languages, as long as it doesn't involve C *shudder*.
The first component I'm going to talk about is JNA (Java Native Access) which is for Java what P/Invoke is for .NET: A way for directly calling into the native API from your Java code. No JNI and thus no custom glue code and C compiler needed. Translating the native calls and structures into what JNA wants still isn't as convenient as P/Invoke, but it sure as hell beats JNI.
In my case, I needed to get find the directory corresponding to CSIDL_LOCAL_APPDATA when running under Windows. While I could have hacked something together, the only really reliable way of getting the correct path is to query the Windows API, for which JNA proved to be the perfect fit.
JNA of course comes with its own glue layer (available in precompiled form for more plattforms than I would ever want to support in the first place), so this leads us directly to the second issue: Native libraries and applets don't go very well together.
This is where applet-launcher comes into play. Actually, applet-launcher's functionality is even built into the JRE itself - provided you target JRE 1.6 Update 10 and later, which isn't realistic in most cases (just today I was handling a case where an applet had to work with JRE 1.3 which was superseded in 2002), so for now, applet-launcher which works with JRE 1.4.2 and later is probably the way to go.
The idea is that you embed the applet-launcher applet instead of the applet you want to embed in the first place. The launcher will download a JNLP file from the server, download and extract external JNI glue libraries and finally load your applet.
When compared with the native 1.6 method, this has the problem that the library which uses the JNI glue has to have some special hooks in place, but it works like a charm and fixes all the issues I've previously had with native libraries in applets.
These two components renewed my interest in Java as a glue layer between the webbrowser where your application logic resides and the hardware the user is depending upon. While earlier methods kind of worked but were either hacky or a real pain to implement, this is as clean as it gets and works like a charm.
And next time we'll learn about scripting Java applets.
New MacMini (early 09) and Linux
The new MacMinis that were announced this week come with a Firewire 800 port which was reason enough for me to update shion yet again (keeping the host name of course).
All my media she's serving to my various systems is stored on a second generation Drobo which is currently connected via USB2, but has a lingering FW800 port.
Of course the upgrade to FW800 will not double the transfer rate to and from the drobo, but it should increase it significantly, so I went ahead and got one of the new Minis.
As usual, I entered the Ubuntu (Intrepid) CD, hold c while turning the device on and completed the installation.
This left the Mini in an unbootable state.
It seems that this newest generation of Mac Hardware isn't capable of booting from an MBR partitioned harddrive. Earlier Macs complained a bit if the harddrive wasn't correctly partitioned, but then went ahead and booted the other OS anyways.
Not so much with the new boxes it seems.
To finally achieve what I wanted I had to do the following complicated procedure:
- Install rEFIt (just download the package and install the .mpkg file)
- Use the Bootcamp assistant to repartition the drive.
- Reboot with the Ubuntu Desktop CD and run parted (the partitioning could probably be accomplished using the console installer, but I didn't manage to do it correctly).
- Resize the FAT32-partition which was created by the Bootcamp partitioner to make room at the end for the swap partition.
- Create the swap partition.
- Format the FAT32-partition with something useful (ext3)
- Restart and enter the rEFIt partitioner tool (it's in the boot menu)
- Allow it to resync the MBR
- Insert the Ubuntu Server CD, reboot holding the C key
- Install Ubuntu normally, but don't change the partition layout - just use the existing partitions.
- Reboot and repeat steps 7 and 8
- Start Linux.
Additionally, you will have to keep using rEFIt as the boot device control panel item does not recognize the linux partitions any more, so can't boot from them.
Now to find out whether that stupid resistor is still needed to make the new mini boot headless.
Managed switch
Yesterday I've talked about configuring a VLAN in my home network.
VLAN is a technology using some bits in Ethernet frames to create virtual network segments on the same physical network, but just go ahead and read the linked Wikipedia article as it's more detailed than what I would want to go into.
To really make use of VLANs, you are going to need at least one managed switch (two in my case). I knew this and I was looking around for something useful.
In the end, I ended up with two HP ProCurve 1800-8G's: I wanted something that has at least 8 ports and was Gigabit capable as I was feeling the bandwidth cap on the previous 100M connection between shion and my media center when streaming 1080p content.
That's something I hope to solve with the 1G connection, though the drobo may still be the limiting factor here, but theoretical 480Mbit is better (where are the MacMinis with the Firewire800 interface?) than the 100MBit I was constrained to with the old setup.
The ProCurves are fanless, provide 8 ports and have a really nice web interface which is very easy to use and works on all browsers (as opposed to some linksys things which only work with IE6 (not even IE7 does the trick)). Also, the interface is very responsive and it even comes with an excellent online help.
With only 10 minutes of thought going into the setup and another 5 minutes to configure the two switches I was ready to hook them up and got instant satisfaction: In my server-room I plugged a test machine to any of the ports 2-7 and got onto VLAN1 (the internal network). Then I plugged it into port 8 and promptly was on VLAN2 (as evidenced by the public IP I got).
I have only three minor issues with the configuration of the two switches so far:
- They come with an empty administration password by default and don't force you to change it. Now granted, on a switch you cannot do as many mischief as on a router or worse, a NAS or access point, but it's still not a good thing.
- They come preconfigured with the address 192.168.2.10 and DHCP disabled, practically forcing you to configure them locally before plugging them. I would have hoped for either DHCP enabled or, even better, the possibility of configuring them using RARP. Or they could provide a serial interface which they do not.
- To reset them, you have to unplug them, connect port 1 with port 2 and restart them. While this prevents you from accidentally resetting them, the procedure is a pain to do and when the time comes that I will have to do this, I'll probably have forgotten the procedure.
But these are minor issues. The quick web interface, the excellent online help and the small fanless design make this the optimal switch once you have advanced requirements to fulfill despite not needing more than 8 ports.
There's a larger 24 port cousin of the 1800-8G, but that one has a fan, so it was no option in my case - especially not in the sideboard where I'm now at the end of the 8 port capacity.