This is an open source project originally intended for use with the now legacy Android 1.6 (donut) release and 3.5mm headphone jack HTC multi adapters on the G1 due to android issue 2534. It was originally based on an abandoned project at code.google.com called toggleheadset.
Since initial release, lots of people have downloaded and used this application to fix hardware problems with their phones - specifically cases where the headphones connector detection doesn't work and your audio doesn't automatically switch to the correct output automatically. This has been a surprisingly common occurrence.
To install you need to place on your homescreen to use it by holding your finger down on the homescreen, selecting widgets and selecting togglheadset2. See http://code.google.com/p/toggleheadset2/wiki/InstallAndUse
Thanks to Adam King for changes to support 2.1+
Headset Indicator makes status bar notification when a headset or headphones are connected.
If supported by device, notification shows if microphone is available.
This app is especially useful for some custom ROMs, devices doesn't have default notifier like some Xperia, Nexus devices.
Be sure to ENABLE notification, open app then click "Enable Notification"