nVidia Shield help - SendKey and Variables
Posted: 29 Oct 2019 21:50
I am just getting start with Automagic. As many others, I am trying to use it to achieve IP control of a nVidia Shield TV.
The TV is rooted and I was initially successful at achieving IP control utilizing Root Command to send Keycodes. The advantage was that it was easy to program with a single action and a variable sent through the HTTP request to utilize as the Keycode used in the Root Command. Unfortunately, the lag associated with the excessive time to complete each command makes this technique unusable.
I have seen some other users have had success with a faster (and reportedly acceptable) response by changing the default keyboard and using the UI Command sendKey. I have gotten this to work using fixed arguments, but it doesn't appear sendKey will accept a variable as an argument, for example: sendKey({param_action}). This seems to mean programming it will be quite the chore. So a few questions...
1. Am I correct in the assessment that sendKey() will not accept a variable for an argument?
2. If so, is there any workaround to this other than having a separate condition and action for each IP control? For instance, could the entire funtion (i.e. "sendKey(20)" for instance) be sent as a text string in the HTTP request and then executed that way?
3. Has anybody figured out some other fast way to use IP commands to control a rooted nVidia Shield?
Thanks for the help as I try to wrap my head around how to properly use Automagic.
The TV is rooted and I was initially successful at achieving IP control utilizing Root Command to send Keycodes. The advantage was that it was easy to program with a single action and a variable sent through the HTTP request to utilize as the Keycode used in the Root Command. Unfortunately, the lag associated with the excessive time to complete each command makes this technique unusable.
I have seen some other users have had success with a faster (and reportedly acceptable) response by changing the default keyboard and using the UI Command sendKey. I have gotten this to work using fixed arguments, but it doesn't appear sendKey will accept a variable as an argument, for example: sendKey({param_action}). This seems to mean programming it will be quite the chore. So a few questions...
1. Am I correct in the assessment that sendKey() will not accept a variable for an argument?
2. If so, is there any workaround to this other than having a separate condition and action for each IP control? For instance, could the entire funtion (i.e. "sendKey(20)" for instance) be sent as a text string in the HTTP request and then executed that way?
3. Has anybody figured out some other fast way to use IP commands to control a rooted nVidia Shield?
Thanks for the help as I try to wrap my head around how to properly use Automagic.