iPhone 3G Earbuds’ inline mic, controls not working

January 27th, 2010

I’ve just solved a rather curious problem with my iPhone 3G S and since previous posts on this site with troubleshooting information have gotten some hits and seem to be of periodic use to people, I though I’d post my solution for posterity.

I used this method on an iPhone 3G S, but I’m confident it also applies to the iPhone 3G, and perhaps even the original iPhone.  The problem was that the earbuds that came with my phone stopped working as they should: I could still hear everything through them—calls, music, games, etc., but the inline microphone and clickable controls (volume, play/pause, next/prev track) stopped responding.  No one could hear me on calls through the buds, and I could no longer control music or get the phone to answer calls.

At first I wondered whether the earbuds had gone bad.  It’s certainly conceivable that the inline module could fail without taking the headphones with it.  I also tried resetting the iPhone in various ways to no avail.  By far the most curious feature of this issue, though, is that when pairing the iPhone with a Bluetooth stereo headset (Jabra HALO), the play/pause button on the headset wouldn’t work either.

What tipped me off to the problem was that the 3.5mm stereo connector for the earbuds no longer seated properly in its jack on the top of the iPhone: there was about half a mm gap between the connecter base and the tallest extent of the iPhone case.  When seated properly it should be flush.  Now, seeing the bottom of the jack is no easy thing, even with some bright lights overhead, but when I looked I was pretty sure that there was some lint crammed into the bottom of the jack.  That’s right, pocket lint was the culprit. How pocket lint could stop a Bluetooth headset from operating correctly is interesting, and probably says interesting things about the design of the iPhone: high-level functions like play/pause being tied to their low-level inputs (headset jack, Bluetooth radio) in some non-trivial way, but I digress.  Removing the lint not only fixed the plug-in earbuds, but also fixed the Bluetooth headset.

Now, a word of caution: sticking things inside electronic connectors is generally not a good idea, and could void your warranty.  But, if you’re like me and the idea of relying on your own fine motor control and senses sounds better than taking a walk (or drive or subway journey) to your nearest Apple Store, then read on.  You need something small and rigid enough to get inside pick out the lint.  My feeling is that those little interdental brushes would be ideal, but I’m a floss man myself and a paperclip was what I had on hand.  It will take a bit of doing, since it’s been compacted against the bottom of the jack by your earbud connector.  A little scraping and blowing out with compressed air and I was in business again.

Now, if only Apple would allow Bluetooth headsets to do next/prev track functions by implementing the full AVRCP profile.


Google’s new approach to China

January 13th, 2010

Big news today for free speech on the internet!

Google has announced that they will no longer censor search results on google.cn.  Here’s Google’s official announcement on their blog, and a NY Times story covering it.  While Google is not the most popular search engine in China, it certainly is the leader among American providers.  We’ll have wait to see in detail what their new approach is, but it’s good news when companies stand up to China and say they won’t cooperate with the Great Firewall.


Selfish WiFi Sharing

December 24th, 2009

I’d like to share my internet connection over WiFi, but there are a couple reasons I don’t.

  1. I don’t want it to impact the bandwidth I have when I’m using my connection.
  2. I don’t want them to use it in such a way that it triggers my ISP to throttle my connection.
  3. I don’t want to be held responsible for what people do on my connection.

Basically, what I’m saying is that I’d like to be able to share without it negatively impacting me.  I feel like a lot of people would also share their own connections if it were easy to do and didn’t have negative consequences.  I also feel that it should be entirely possible to do this!

In (1), what I really mean is that my use of the connection should get priority over whatever random strangers I’m sharing with.  Maybe it’s my neighbors, who don’t have a connection of their own, or maybe it’s just someone passing through, looking for a few minutes of WiFi to check their email.  There’s plenty of time during the day when I’m not using my connection at all, and plenty of time when I’m just doing some light surfing.

What I want is a WiFi router that supports this kind of prioritizing.  Set up and broadcast two different SSIDs: one for priority traffic, one which just gets whatever bandwidth is left over.  The priority channel gets normal encryption and access control, the shared channel is unencrypted.  Maybe I’d call the shared channel “Spike’s Free WiFi.”  The quality of that connection would fluctuate wildly, depending on whether or not I’m filling up the priority channel, but hey, it’d be free.

For (2), I’ll start off by saying that net connections in the UK have advantages and disadvantages over those in the US.  I think they typically come out slightly cheaper per MBit of connection speed, but most ISPs have annoying “network management policies.”  These include throttling connections if you use push or pull too much data during peak hours, and, I suspect, if you use particular protocols, like those that run P2P services (I’ve noticed severe slowdowns when I put up a bittorrent client or the BBC iPlayer Desktop application, even before I’ve moved enough data to trigger the limits detailed below).  For the most part, ISPs are relatively transparent about their traffic management with respect to peak hour use (see for example Virgin Media’s), but I would like more detail.  Like, the kind of detail that would allow configuration of a router to keep strangers using the connection from getting my connection throttled.  In particular, a clear statement about how different protocols trigger throttling, if any.  If UK ISPs are going to go down the road of advertising “Unlimited” plans, but actually enforcing limits by throttling connections, then they should publish enough detail to allow customers to configure tools to avoid those limits.

(3) is one which needs a legal solution, rather than a technical one.  Basically, what is needed is either legislation or legal precedent that establishes that simply providing internet access doesn’t make a person liable (in both criminal and civil senses) for what is done by others over that connection.  ISPs enjoy this legal protection, as do other providers of communication services—you can’t sue the postal service if they deliver a harassing letter sent to you by someone else.  I know of no cases where a person operating an unencrypted access point has been successfully sued or prosecuted for what others have done on the connection, but there are particularly worrying measures being considered.   At the top of the list are the so called “3 strikes” proposals where being accused of sharing of copyrighted works over a network connection 3 times can get your connection terminated.  I think this is a bad idea for a number of reasons, but it would effectively kill the idea of sharing your network connection with strangers—which would be a real shame.

If you walk down a city block or residential suburb with a WiFi sniffer these days you’ll find dozens of operating access points.  Imagine how much coverage could be achieved if everyone got into sharing the bandwidth they had going spare.  Coverage would be patchy, and speed unreliable, but it would be free and leverage a piece of tech most people will be upgrading over the next few years anyway.  Crowd-sourced municipal WiFi!


iTunes 9 + Win 7 Play Nicely

September 14th, 2009

I’m running the Windows 7 Release Candidate, and pulled down Apple’s new iTunes 9, which debuted on last Wednesday.  I noticed a little added feature:

windows-taskbar-itunes

It seems iTunes 9 takes advantage of the Windows 7 taskbar enhancements and adds a back, play/pause, and forward button below the live preview.  It also adds a balloon above with current track info.  Nice!

This is the first non-Microsoft app that I’ve seen take advantage of the new taskbar.  Who says that Apple & Microsoft can’t play nicely?


Ending Email Distraction

August 16th, 2009

In terms of our interaction, email used to be essentially snail mail that you could send and receive instantly.  But our interaction with email has moved far beyond this simple analogue of open mailbox, get messages.  The postman comes to my house once a day; whatever letters come, that’s all there is until tomorrow.  The mail is a daily ritual, a one-off thing.  Email is more like a constant trickle (or a constant stream or even a firehose).  I can check for messages as often as I like, and modern email programs have all kinds of features to allow incoming messages to announce themselves: some subtle, some not.  Mail messages are passive, but email messages have become active agents!  They flash notifications, make noise, or increase little red counters while vying for your (limited) attention.

 outlook notification

The pull of email is very strong.  For me, when I know there are messages in my inbox, I’m incredibly tempted to deal with them, or at least read them, even if I’m working on something important.  A passive inbox creates more than enough temptation for me; email which asks for my attention is too much.

The daily ritual is effective for regular mail because delivery times are measured in days, and not too distracting because you take care of everything in one go.  Dealing with email as it comes in might be very effective, but because of the myth of multitasking, it torpedoes productivity on anything that requires careful thought.  Every time we change from one task to another, it takes a while to regain focus.  Some studies have suggested this is upwards of 15 minutes!  Even if the total time you spend on email is the same, the more you break it up throughout your day, the less other things you’ll get done.

Many popular email programs have these distracting message notifications turned on by default.  Here’s how to turn them off:

Microsoft Outlook 2003/2007
Tools > Options from the main menu, click Email Options on the Preferences tab.  Then click Advanced Email Options.  In this dialog box you can untick any (or all) of the options under When new items arrive in my Inbox

Mozilla Thunderbird
In Windows this is under Tools > Options > General > When a new message arrives.  For Linux, it’s under Edit > Preferences…,  on Mac OS X, it’s Thunderbird > Preferences…

Entourage
Entourage > Preferences > Notifications and untick all the unwanted notifications.

I also like getting my email on the iPhone.  It’s great to be able to read and sort messages while on the bus or waiting in line, but I’d go nuts with it constantly alerting me of incoming email.  You can disable these under Settings > Sounds…


Entropy is the opposite of knowledge

January 17th, 2009

Jeff Atwood, over at Coding Horror posed an interesting little puzzle about probability:

Let’s say, hypothetically speaking, you met someone who told you they had two children, and one of them is a girl. What are the odds that person has a boy and a girl?

To put it in more precise language so we can concentrate on probability and not nuance of word choice, the person means that at least one child is a girl.  At first I was tempted to say what a lot of people came up with in the comments: 50%.  If one is a girl, my thought process goes, then we’re just looking at the probabilities for the other child, and surely those are not affected by the child we know about.

This is, of course, wrong.  In that argument we fail to take into account that having two children are distinguishable events, and we don’t know which child they were talking about when they said one was a girl.  When I actually wrote it down, then the solution became more clear.  Having two children gives 4 possibilities in terms of their gender (B for boy, G for girl):

BB, BG, GB, and GG

In learning that at least one is a girl, we can eliminate BB.  We cannot eliminate BG or GB because we’re not told which child was being referred to when we were told one is a girl.  Of the 3 remaining, 2 have one boy and one girl, so the solution is 2/3 or about 67%.

But wait!  Why should order matter?  As expressed by one commenter:

All the children learned probability theory and forgot how to think normally! Why would you care if the first one is a boy or a girl..they didn’t tell that their first child was a Girl, now did they? So, you have three choices: [BB, GB, GG]

To a certain extent, one is entirely justified in formulating the solution in terms that don’t include the ordering.  It wasn’t asked for in the solution or mentioned it in the problem.  However, if you formulate the problem in this way you are forced to abandon an implicit assumption we made in the previous reasoning: that all possibilities are equally likely.  If we leave out order, we can simplify our notation and just count the number of boys, and know that the rest are girls (leaving aside the relatively rare occurrence of gender ambiguity).  So our possible cases are [2, 1, 0].  However, the respective probabilities for these cases are [25%, 50%, 25%].  That is to say, having one boy and one girl is twice as likely as having two girls.  With this in mind, it’s easy to see that the solution should be 2/3.

But why are the probabilities equal when you include order, and not equal when you don’t?  Maybe you don’t even believe me.  The answer has a very deep connection to physics, and so my advice to any doubter is to try it out with a pair of coins!  Get two coins, flip them, and record the number of heads.  Repeat this 20 or 30 times and you’ll handily see that exactly 1 head comes up roughly twice as often as either 2 heads or 0 heads.  It doesn’t even matter whether you flip them at the same time or whether the coins are easily distinguishable!  Even seemingly identical coins are distinguishable in principle.  No two coins are exactly alike at the molecular level, and even if they were, it would be possible to track them individually through the air during a flip.  By only recording the number of heads we are throwing out some information which is, in principle, available to us.

Any time we don’t include information which, in principle, exists, then we don’t get equal probabilities.  However, we can still work out the probabilities of our incomplete description.  In thermodynamics, our incomplete description (in this case, the number of heads) is called the macrostate, and a complete description that uses all the information available in principle is called a microstate.  To find the probabilities of the macrostates, we have to weight them by the number of different microstates that give that macrostate.  In the case of exactly 1 head, this has two microstates (HT and TH).  The other macrostates each have only one microstate, thus exactly 1 head is twice as likely as either 2 or 0.

The number of different microstates that correspond to a particular macrostate is a measure of our lack of information.  When we get a macrostate of 2 heads, we know exactly which microstate we’re in—we have complete knowledge.  But imagine that we had 100 coins instead of 2.  There is only one microstate that has 0 heads, but there are 100,891,344,545,564,193,334,812,497,256 different microstates for 50 heads.  50 heads is astronomically more likely than 0 heads.  But just knowing that there are 50 heads leaves us without much knowledge of the microstate: there are over 100 thousand trillion trillion of them to choose from!  The measure of this is called entropy (technically, the logarithm of the number of microstates).  In our boy-girl example, having one boy and one girl has a higher entropy because we don’t know the order.  Entropy is sometimes called a measure of disorder.

In thermodynamics the macrostate of a system is given by things like overall temperature, volume and pressure, whereas microstates would have to be given in terms of the positions and velocities of each molecule.  That information is present, in principle (at least up to a quantum-mechanical limit), so it has a real effect on the probability.  Just like in coin-tossing the probabilities of the macrostates are weighted by the number of microstates that correspond.  The more likely macrostates must have higher entropy.  This is the origin of the famous 2nd Law of Thermodynamics.  Since macrostates of high entropy are so much more likely, random processes always end up there; the more elements in the system, the more this probability becomes like a simple fact.


Windows Live Writer

January 12th, 2009

The Wordpress web-interface for writing blog posts is OK, but I do miss some of my favorite word-processing features. The blog-posting facility in Word 2007 didn’t impress me, but I’m on a Microsoft kick this week while trying Windows 7, so I thought I’d take Windows Live Writer for a spin.

Although it presents you the option to start a blog on Windows Live, it claims to play nicely with Wordpress’s publishing API. I was skeptical, since I host my own blog (powered by Wordpress), rather than having it on Wordpress.com, but I’ve so far been impressed. Setup was very easy and totally automated: I just gave it my login credentials and the URL to the main site. It quickly discovered that I hadn’t enabled the publishing API, but helpfully gave me the URL of the options page to enable it. It also detected and downloaded my theme so it can give a full preview of what my post will look like on the site.

The botton of the window has three tabs: “Edit,” “Preview,” and “Source.” “Edit” is a WYSIWYG text editor, which helpfully defaults to the appropriate fonts for my blog, but doesn’t include the sidebar or other elements from my theme. “Preview” shows the post as it will look on the page—complete with sidebar and the previous post sitting underneath it. “Source” gives the HTML underneath the post, and unlike previous Microsoft forays into web publishing, it gives clean, sensibly formatted HTML.

pancake bunny

Inserting images is also painless, as illustrated by this bunny with a pancake on its head.  The one thing it is missing in terms of the Wordpress system is a way to set the tags for the post.  There’s a tool for inserting tags, but all that does is insert some HTML into the post for tagging to external sites like Technorati or del.ico.us.  All in all, it’s a welcome and viable alternative to using the Web-based tool.

UPDATE (13 Jan): As helpfully pointed out in comments, there is a way to set the tags for the post.  It’s in the post Properties, accessible with <F2>.  Win!


Windows 7 Beta

January 11th, 2009

Downloading the Windows 7 Beta was a little more difficult than it should have been, but I was admittedly jumping the gun a little bit.  The public beta was briefly posted, only to be withdrawn because the servers couldn’t keep up with demand.  (It’s now back up.)  Being the impatient man that I am, I managed to find a BitTorrent link to the DVD iso.  It surprises me, just a little, that more companies don’t include a .torrent whenever you have the option to download large files.  I’m not sure if MS thinks that it isn’t secure, or looks amateurish, but I have to say that posting a link and then taking it down doesn’t look so good either.  BitTorrent, or peer-to-peer technology in general just makes so much sense for this kind of application: that is to say, getting a large chunk of data downloaded to a large number of people quickly.  (If you’re unfamiliar with peer-to-peer, it does this by breaking the file into pieces and passing the pieces around from person to person rather than everyone trying to get it from a single server.)

Windows 7, like in previous versions, allows you to install without a Product Key and enter it later, so I loaded it up right away, confident that I’d be able to get one when Microsoft reinstated the public download site.  Upgrading from XP, there was no option to try to migrate my programs and settings, only a clean install was available.  This didn’t bother me, but might turn off some people who’ve skipped Vista when it comes time to upgrade to Win7.  Vista users, apparently, can upgrade with their programs and settings more-or-less intact.  The install was very smooth, and took a little over half an hour.  It had no problems setting up my hardware.  In fact, the only drivers I’ve downloaded myself so far are the Dell drivers for the “advanced” features on my touchpad (aside: advanced is in scarequotes because I liked the Synaptics touchpad on my old Dell much better than the Alps one on my current D630).

The interface improvements are pleasing, and run smoothly and responsively on my laptop (Core2Duo 2GHz, 2GB RAM, Intel 965 Integrated graphics).  Especially nice is the updated taskbar, which gives live thumbnail previews of the windows as you mouse over it, and the new-to-me Window Flip 3D alternative to Alt-Tab.  Annoying is its insistence on changing the theme to a heavy black color every time I open something from the Control Panel.

I also BSoD’ed (the instantly familiar blue screen of death) once while watching a DVD in VLC Player.  It’s nice to know that fail still comes in white text on a blue background.  But other than that, it’s been a nice experience.  Outlook, in particular, loads lightening-fast, and I haven’t had any issues with program or hardware incompatibility.  Looking forward to giving BitLocker whole-disk encryption a go, as well as seeing what the gaming performance is like.


Live Mesh first look

January 10th, 2009

So, I’ve decided to use my Saturday to geek-out and try some new computer stuff.  While Microsoft is making a somewhat lackluster presentation at CES compared to the likes of Sony, Palm, and Dell which have announced slick-looking gadgets, in terms of things to try right now, two Microsoft betas have caught my attention.  The first is Live Mesh, the subject of this post.  I’ll write something a little later about Windows 7.

I noticed that Microsoft’s Live Mesh service won a “Crunchie” from TechCrunch.com, so I decided to give it a try.  At its core, it’s a service for syncing files and folders among multiple computers.  But, in addition to updating your different machines, it includes a “Live Desktop,” which is a 5GB storage area in Microsoft’s cloud to allow you to get access to your most important files on any computer with an internet connection.  It also includes remote-access software, which is nothing new, but is accessible with just a click or two (at least in theory–my desktop crashed the first time I tried it).  It certainly seems much more sensible than the complicated setup one needs to do on both ends which is currently par for the course.  It also has some sharing features, but as far as I can tell, these require others to sign-up and sign-in, which will limit their usefulness severely (especially while the service is still in beta).

Live Mesh Popup Control Panel

I’ve installed it on my home desktop and lappy, and will give it a go on my office computer when I get in on Monday.  I have to say, I’m not particularly impressed with the syncing so far from an interface perspective: the size totals for transfers don’t make a lot of sense, and my lappy started uploading even though I told it to sync a new folder taken from my desktop.  These may just be initial hiccups, so I’m willing to give it the benefit of the doubt.  We’ll see how diligent it is at keeping the files up to date without intervention.

 


Text messaging numbers

December 30th, 2008

The “most emailed” story in the NY Times today is about the prices and costs of sending text messages from a mobile phone.  Mobile phone companies charge an arm and a leg for these–in terms of markup on costs it has to be the single most lucrative service they offer.  US carriers charge 20 cents per text, and UK carriers charge 10p for pay-as-you-go text messaging, which doesn’t seem like much until you consider how little data they’re actually carrying.

Text messages are limited to just 160 characters, which can be encoded into just 140 bytes.  To give you an idea of just how little that is, I compared it to the size of the web-version of the NY Times story linked above.  Just the basic HTML (i.e. no images) is 89,986 bytes (or about 88 KB).  That’s about 642 text messages, which is more than my monthly allowance.  Including images, this figure jumps to 858,333 bytes, or 5,360 text messages, more than I send in several years.  On my iPhone, my monthly plan includes unlimited Internet data, and I can download the NY Times article (over the relatively poky GPRS connection) in about 20 seconds.  Yet my plan only includes 500 text messages: an amount of data that could be transmitted in a second over standard connections.

A space scientist at the University of Leicester calculated that sending text messages cost more per byte than data from the Hubble Space Telescope.  It’s all to create the illusion of scarcity so the carriers can keep charging their exorbitant fees.  I remember seeing signs in India for text messaging at 0.08 Rupees per text, about 2 tenths of a cent.  This means US carriers charge 100 times more for their text messages.

The NY Times article goes into a little more technical detail to explain that text messages are actually packed into what’s called the control channel, used to send instructions back and forth from handset to cell towers.  These channels get used whether there are text messages or not, so an increase in volume adds little to operating costs.  The messages don’t appear on the high-bandwidth channels used to transmit voice, further supporting the conclusion that text message pricing has nothing to do with the actual costs of carrying the data.

Fortunately, as the NY Times article explains, Herb Kohl, the chairman of the Senate antitrust subcommittee has taken the first steps in attempting to get the carriers to account for their behavior, and several lawsuits have been filed accusing the companies of price fixing.  All I have to say is, “about time.”