Kodi Community Forum

Full Version: How to launch an Applescript from my Harmony Remote
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

As I said in the title I'd like to run an AppleScript to change my monitor refresh rate.

I'm running Dharma 10.1 and my scripts are working without a glitch from OSX.

I've tried many ways to run them but none is OK (my scripts are in a scripts folder in me/library/application support/XBMC/userdata) :
- XBMC.RunAppleScript("../scripts/24p.applescript")
- XBMC.Runscript("../scripts/24p.applescript")
- Without the XBMC prefix
-...

But it doesn't work, I know I'm ok with keymap.xml since I've changed other settings and they work ok.

Any idea ?
telliouze Wrote:Hi,

As I said in the title I'd like to run an AppleScript to change my monitor refresh rate.

I'm running Dharma 10.1 and my scripts are working without a glitch from OSX.

I've tried many ways to run them but none is OK (my scripts are in a scripts folder in me/library/application support/XBMC/userdata) :
- XBMC.RunAppleScript("../scripts/24p.applescript")
- XBMC.Runscript("../scripts/24p.applescript")
- Without the XBMC prefix
-...

But it doesn't work, I know I'm ok with keymap.xml since I've changed other settings and they work ok.

Any idea ?

I use Remote Buddy..
I'm also trying to run an aplescript, but am doing this from the Harmony keymap. I get exactly the same result. Nothing.

I've modified the keymap to do various other things, but for some reason the applescript fails to be launched.

<button id="82">XBMC.RunAppleScript(run script "Users/[username]/Library/Application Support/XBMC/scripts/volumeDown.applescript")</button>

..RunScript("Users/[username]/Library/App...
All sorts of combos, but none are successful.

Suggestions?
Korey Wrote:I use Remote Buddy..

Shit costs money bro Sad
Korey Wrote:I use Remote Buddy..

I'm curious - what Mac unit are you using with your Harmony and what IR remote is the Harmony set up to use (device type)?

I'm using Logitech's PS3 BT->IR adaptor with my Harmony and also use the Remote Buddy software on my Mac Mini running OSX. It works but there is a slight lag then translating from BT to IR, and the adaptor automaticly drops the BT connection after a few minutes which also takes extra seconds to reestablish.
So I'm basicly looking for a better solution and IR codes which my Harmony and Mac Mini/OSX can both use - I want to avoid using the BT->IR adaptor. The standard Apple remote does not have enough buttons for my use.
Beano Wrote:I'm curious - what Mac unit are you using with your Harmony and what IR remote is the Harmony set up to use (device type)?

I'm using Logitech's PS3 BT->IR adaptor with my Harmony and also use the Remote Buddy software on my Mac Mini running OSX. It works but there is a slight lag then translating from BT to IR, and the adaptor automaticly drops the BT connection after a few minutes which also takes extra seconds to reestablish.
So I'm basicly looking for a better solution and IR codes which my Harmony and Mac Mini/OSX can both use - I want to avoid using the BT->IR adaptor. The standard Apple remote does not have enough buttons for my use.

I don't have a Harmony, I have a Nevo Q50. Wink
I have a Mac Mini OSX 10.6.7. I have created custom mappings via Remote Buddy. Really quite easy to do anything you want with it..
Did you guys get this work?

I´m exactly in the same situation: managed to get them work on osx, but not in XBMC with harmony.

Is there coder-master-ninja or somebody who knows how the keymap.xml file has to coded exactly to get applescript work? I read the wiki, but didn´t find any solutions to this issue.

Do I need to configure XBMC or is it just configuring the keymap.mxl file?

Couldn´t find a guide saying: "this is how you run your applescript in xbmc with harmony". Is there any?

Remote buddy wasn´t for me... tried it already.

Thanks in advance.
perkins Wrote:Did you guys get this work?

I´m exactly in the same situation: managed to get them work on osx, but not in XBMC with harmony.

Is there coder-master-ninja or somebody who knows how the keymap.xml file has to coded exactly to get applescript work? I read the wiki, but didn´t find any solutions to this issue.

Do I need to configure XBMC or is it just configuring the keymap.mxl file?

Couldn´t find a guide saying: "this is how you run your applescript in xbmc with harmony". Is there any?

Remote buddy wasn´t for me... tried it already.

Thanks in advance.

Solved:

At the moment I wanted to use default Harmony keys to control XBMC. So I went to applications in my finder and clicked "XBMC" with right click and choose to see inside of the package.

There I looked for the keymaps (Resources,XBMC,System,Keymaps). Those are the defauld keymaps (I guess?)

Then opened up the joystick.Harmony.xml -file with xml editor. There I looked for the F1, F2, F3 functions of the remote and replaced the original line with: XBMC.RunScript(Refresh24.applescript)

The apple scripts are in /library/application support/XBMC/scrits folder.

Did the same for 50Hz and 60Hz scripts.

For some reason I had to disable remote from my XBMC settings and enable it again to get it work.

Now I have 3 buttons to change the refresh rate Big Grin

Hope this is going to be done soon automaticly, since it´s bit odd that it´s not done yet.

I´m not a fan of stuttering image... I think when we use media player, smooth image is the basic function and everything else should be build on that.