iTunes starts up whenever I connect my bluetooth headset

I am using bluetooth headset to communicate on Skype. Whenever somebody's calling me, I turn my headset on and it will automatically connect to my MacBook. Every time, however, it will also automatically start iTunes and begins to play. I don't want this behavior, since instead of listening to music I would actually want to talk on Skype. How can I change this?

Possible explanation to this could be that headphones may send "Play" button message to the computer once connected, since this is same button that is used to turn them on/off. I am not sure however, if they actually do send this button. But in case they do, how can I disable iTunes startup on Play button? Is there are an official way to do it or should I really go with something like this: http://superuser.com/questions/31925/stop-play-pause-button-opening-itunes-in-sn ow-leopard/39390#39390.

MacBook Pro 6.2, Mac OS X (10.6.4)

Posted on Sep 6, 2010 2:04 AM

Reply
Question marked as Top-ranking reply

Posted on Sep 15, 2014 11:11 AM

I've got this figured out.


On OSX, the "RCD" (remote control daemon) is responsible for the naughtiness. It has hard-coded list of actions to do when it detects certain "events" - one of them being connecting to a bluetooth headset.


To disable this behaviour (minimal loss of functionality, possibly your apple remote won't work):


1. Open Terminal

2. Enter (these are two separate commands)

launchctl stop com.apple.rcd

launchctl unload /System/Library/LaunchAgents/com.apple.rcd.plist


This should stop rcd from being launched by OSX. No rcd - no auto-magic multimedia. Your volume keys should continue working, but things like play key (or bluetooth) auto-starting iTunes should stop.


PS: The following is the nuclear option. In Terminal, enter:

sudo chmod 000 /System/Library/CoreServices/rcd.app/Contents/MacOS/rcd

sudo pkill -9 rcd


To stop rcd from even being started by any app. To restore your rcd, use:

sudo chmod 755 /System/Library/CoreServices/rcd.app/Contents/MacOS/rcd

launchctl start com.apple.rcd

139 replies

Aug 11, 2015 8:09 AM in response to ibisiki

I have a new bluetooth headset that pauses and resumes each time I take them off or put them on. Today is the first time trying them to stream music from a web site and found the issue that many others have described.


A quick scan of this thread showed a few solutions, but I did not quickly find a solution like the one that I threw together this morning. Here it is:


Using your favorite editor, create a file called iTunesSniper.sh with the following contents. I put it in a bin directory that I have off my home directory.


while [[ 1 -eq 1 ]]; do


d=`date`

killpid=`ps -A | grep iTunes$ | tr -s ' ' | cut -d'?' -f1`

rc=$?

if [[ ${rc} -eq 0 && ! -z ${killpid} ]]; then

kill ${killpid}

echo "${d} killed"

fi


sleep 1


done


make sure that the file is executable.


chmod +x iTunesSniper.sh


Run the script from the terminal window. Every second it will check for the iTunes process and when it finds it, it will kill it. It will print the date and time each time it kills the pid. When you don't need it's help anymore, ctl-c will exit the script and iTunes will run without having to rename anything or change any permissions.


bin$ ./iTunesSniper.sh

Tue Aug 11 10:05:45 CDT 2015 killed

Tue Aug 11 10:05:46 CDT 2015 killed

Tue Aug 11 10:05:47 CDT 2015 killed

Tue Aug 11 10:05:48 CDT 2015 killed

Tue Aug 11 10:05:55 CDT 2015 killed


I hope that this helps.

Apr 26, 2013 4:01 PM in response to rryk

Copy this into a plain text file called "killitunes".

Right before you connect headphones, go to terminal. Go "perl killitunes".

If anything launches iTunes (including you), this program force-quits it.

This program auto-quits, or you can quit it with ctrl-C.


#!/usr/bin/perl


my $endtime = time + 300; # will quit in 300 seconds. Change at will.


while (time < $endtime) {

foreach (`ps -aef`) { # read each line into special variable $_

next if (not m=/iTunes.app/=); # skip if not part of iTunes app

next if (not m=/iTunes =); # skip if not the main iTunes program

my $pid = substr ($_, 6, 5); # parse out 5-digit process ID

system "kill $pid"; # force quit that process ID

print "Killed $pid $_\n"; # tell user. \n is return

} # end foreach

sleep (2); # wait 2 seconds to avoid overload

} # end while time


Jun 23, 2014 7:34 PM in response to SteveHyg

This problem still persists. iTunes is annoying af because it provides no way to disable, uninstall, or generally stop from auto-playing whenever I connect my bluetooth speakers. From reading forums, you used to be able to turn this off -- but they've removed that feature. I like OS X, but the force-feeding of software is overbearing and unnecessary. As a customer, it's a negative experience.


I've done a combination of suggestions here and it's seemed to worked on OS X Mavericks 10.9.3.

  1. Renamed iTunes.app and create psuedo.app that does nothing and replaces iTunes auto-play launch

    Outlined in a post HERE

  2. Removed execution permissions from renamed iTunes.app (in my case renamed to noItunes.app)

    In terminal.app: sudo chmod -x /Applications/noTunes.app/


My only concern is an Apple admin is reading this all will patch iTunes, I'll be forced to d/l the update, and this will no longer work. 😮

Dec 4, 2013 1:18 PM in response to PiotrBox

OK,

I managed to rename the app in terminal by:


cd ~/Applications/

sudo mv iTunes.app iTuneF.app

password...


now when i connect my TDK the renamed iTuneF.app starts anyway, but doesn't play music. GREAT.


.... not really. When i connect second time (with iTuneF.app ON) the stupid starts to play again.


I even created fake iTunes.app with automator. the only think it has to do is to quit the iTuneF.app and it does when clicked in dock. but on bluetooth connect nothink.


So this fix only works it you keep renamed itunes app OFF.


AND i have no idea what will happen now when there will be itunes update of some sort. will the system panic and go under bad?

will see


still i really dont like what is happening with apple. wee lose all controll of our own machines.


PS. sorry ofr posting reply. i tried to edit, but it crached after one and now i have no edit button in my post.

Feb 6, 2014 11:38 AM in response to rryk

Somewhat simple workaround with no negative side effects that I'm aware of:


Open Terminal and (If you aren't already logged in as an admin) su to your admin user:

-su myadminaccount

-[enter password]


Still in Terminal; Go to your applications directory and rename iTunes.app:

-cd /Applications

-mv ./iTunes.app MyiTunes.app


Do not connect a bluetooth device just yet. This prevents iTunes from opening but allows you to still put MyiTunes.app on your dock so you can open it yourself. When you connect a bluetooth device, you'll still get a message that asks "Where's iTunes". To get past this, do the following:


Open Spotlight and search for "AppleScript Editor". This shows a blank area for entering your script. Simply go to File>Save, Enter the file name as something like "DoNothing", select the directory you want this file to reside and change the File Format to "Application".


Lastly, connect a bluetooth device which should bring up the dialog mentioned above. Click browse and select the "DoNothing.app" that you saved in the previous step. That's it!



Works for me, good luck.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

iTunes starts up whenever I connect my bluetooth headset

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.