Run a script when bluetooth device is connected

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I'm trying to run a script automatically right after a certain bluetooth device is connected. To do so, I tried to create a new UDEV rule. The problem I encounter is that my rule doesn't execute upon establishing the connection.



As of now, my rule contains only the MAC address of the device.



ACTION=="add", SUBSYSTEM=="bluetooth", ATTRSaddress=="a0:b1:c2:e3:f4:56", RUN+="/home/myhome/my_script"


How can I find more device details in order to add them to the rule?









share

























    up vote
    0
    down vote

    favorite












    I'm trying to run a script automatically right after a certain bluetooth device is connected. To do so, I tried to create a new UDEV rule. The problem I encounter is that my rule doesn't execute upon establishing the connection.



    As of now, my rule contains only the MAC address of the device.



    ACTION=="add", SUBSYSTEM=="bluetooth", ATTRSaddress=="a0:b1:c2:e3:f4:56", RUN+="/home/myhome/my_script"


    How can I find more device details in order to add them to the rule?









    share























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I'm trying to run a script automatically right after a certain bluetooth device is connected. To do so, I tried to create a new UDEV rule. The problem I encounter is that my rule doesn't execute upon establishing the connection.



      As of now, my rule contains only the MAC address of the device.



      ACTION=="add", SUBSYSTEM=="bluetooth", ATTRSaddress=="a0:b1:c2:e3:f4:56", RUN+="/home/myhome/my_script"


      How can I find more device details in order to add them to the rule?









      share













      I'm trying to run a script automatically right after a certain bluetooth device is connected. To do so, I tried to create a new UDEV rule. The problem I encounter is that my rule doesn't execute upon establishing the connection.



      As of now, my rule contains only the MAC address of the device.



      ACTION=="add", SUBSYSTEM=="bluetooth", ATTRSaddress=="a0:b1:c2:e3:f4:56", RUN+="/home/myhome/my_script"


      How can I find more device details in order to add them to the rule?







      linux-mint udev bluetooth





      share












      share










      share



      share










      asked 2 mins ago









      slybloty

      5763733




      5763733

























          active

          oldest

          votes











          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f476094%2frun-a-script-when-bluetooth-device-is-connected%23new-answer', 'question_page');

          );

          Post as a guest



































          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f476094%2frun-a-script-when-bluetooth-device-is-connected%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          Peggy Mitchell

          The Forum (Inglewood, California)

          Palaiologos