UPDATE: finished the PTVL changing channels by names group http://voxcommando.com/forum/index.php?topic=1959.msg16925#msg16925 (http://voxcommando.com/forum/index.php?topic=1959.msg16925#msg16925)
looking for some help
I'm trying to redo the current way that i change to a specific channel in PseudoTV Live with VC.
right now i have a separate command for each channel
this one is for channel 301
(http://i1296.photobucket.com/albums/ag18/peglegtv/Public/HGTV301_zps155c3d11.jpg)
what I'm trying to do is use a payload xml with the channel names and channel numbers so i can cut down on the amount of commands i need to change the channel,
I'm wondering if there would be another way to send 2 or 3 digits at the same time so i can carry them in a payload, instead of having to make a command for each channel?
any help would be great, thanks
EDIT: looks like I might be able to use SendKeys to change the channel with 2 and 3 digit numbers
Do you really need to send text instead of actual digits when using xjson.btn.kb. ?
Quote from: jitterjames on January 12, 2015, 08:01:44 AM
Do you really need to send text instead of actual digits when using xjson.btn.kb. ?
yep,
I've tried remote.xml ,keyboard.xml and no keymap at all and they all gave me the same results with the numbers,
i need to send the numbers individually with text ::confused
when I get done with my PTVL setup I'll make sure I upload it, ;D
Try this test.
I can't get PseudoTV Live to work in Helix and I don't have anything else that seems to respond to pressing number keys.
<?xml version="1.0" encoding="utf-16"?>
<!--VoxCommando 2.1.3.4-->
<command id="459" name="number keys" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
<action>
<cmdType>Results.RegEx</cmdType>
<params>
<param>(\d)</param>
<param />
<param>{1}</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>XJson.Raw</cmdType>
<params>
<param>Input.ExecuteAction</param>
<param>"action":"number{Match.{i}}"</param>
</params>
<cmdRepeat>{#M}</cmdRepeat>
</action>
<action>
<cmdType>XJson.Raw</cmdType>
<params>
<param>Input.ExecuteAction</param>
<param>"action":"enter"</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<phrase>sudo channel</phrase>
<payloadList>123, 154</payloadList>
</command>
works great for the numbers, i had to change the enter action to xjson.btn.kb enter
the other enter action didn't work for me i also tried to switch enter to return but no luck
<?xml version="1.0" encoding="utf-16"?>
<!--VoxCommando 2.0.1.0-->
<command id="459" name="number keys" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
<action>
<cmdType>Results.RegEx</cmdType>
<params>
<param>(\d)</param>
<param />
<param>{1}</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>XJson.Raw</cmdType>
<params>
<param>Input.ExecuteAction</param>
<param>"action":"number{Match.{i}}"</param>
</params>
<cmdRepeat>{#M}</cmdRepeat>
</action>
<action>
<cmdType>XJson.Raw</cmdType>
<params>
<param>Input.ExecuteAction</param>
<param>"action":"enter"</param>
</params>
<cmdRepeat>0</cmdRepeat>
</action>
<action>
<cmdType>XJson.Btn.KB</cmdType>
<params>
<param>enter</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<phrase>sudo channel</phrase>
<payloadList>100, 154</payloadList>
</command>
8) thanks for the command
it might work with
"action":"select"
actually you can look in keyboard.xml to see what valid actions are, but also on the kodi json rpc v6 docs.
...and if so, it is probably better to keep them all using the same method.
http://kodi.wiki/view/JSON-RPC_API/v6#Input.Action
follow link and then click "show" just below the title that says "6.9.1 Input.Action"
thanks for the link, ;D switching it to select worked
I'm setting up a command that will scrape settings2.xml for PTVL to add channel names and numbers to payload.xml
so far I have found that I will have to use "set channel name" for rule 1 on every channel that is created, (only a pain the first time around) now im working on eliminating the channels that are marked as "do not play"
will update when finished
Changing channels by channel name in Pseudo TV LIVE,
this group of commands is used to change channels based on channel names
the first command will use the settings2.xml from PTVL add-on to create a map table "PTVL" and a PTVL.xml payload in your xbmc payloads folder
YOU NEED TO RENAME ALL CHANNELS WITH THE 1ST RULE IN THE PTVL CHANNEL CONFIGURATION
this will remove channels marked as "do not play" and channels that have been removed from your channel configuration but are still in your settings2.xml from the payload xml
the second command is used for changing the channels
PTVL by channel name:
<?xml version="1.0" encoding="utf-16"?>
<!--VoxCommando 2.0.1.0-->
<commandGroup open="True" name="PTVL by channel name" enabled="True" prefix="" priority="0" requiredProcess="" description="">
<command id="201" name="UPDATE PTVL " enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description=""5" = channels that are marked as do not play 

"9999" = channels that have been removed ">
<action>
<cmdType>Map.DropTable</cmdType>
<params>
<param>PTVL</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>Map.CreateTable</cmdType>
<params>
<param>PTVL</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>File.Read</cmdType>
<params>
<param>{Path.Appdata}\XBMC\userdata\addon_data\script.pseudotv.live\settings2.xml</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>Results.RegEx</cmdType>
<params>
<param>Channel_(.*?)_rule_1_opt_1"\Wvalue="(.*?)"</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>Map.Set</cmdType>
<params>
<param>PTVL</param>
<param>{Match.{i}.1}</param>
<param>{Match.{i}.2}</param>
</params>
<cmdRepeat>{#M}</cmdRepeat>
</action>
<if ifBlockDisabled="False" ifNot="False">
<ifType>(A)Contains(B)</ifType>
<ifParams>{LastResult}&&"5"</ifParams>
<then>
<action>
<cmdType>Results.RegEx</cmdType>
<params>
<param>Channel_(.*?)_rule_\d_id"\Wvalue="5"</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>Map.Query</cmdType>
<params>
<param>delete from PTVL where fromKey="{Match.{i}.1}"</param>
</params>
<cmdRepeat>{#M}</cmdRepeat>
</action>
</then>
<else />
</if>
<if ifBlockDisabled="False" ifNot="False">
<ifType>(A)Contains(B)</ifType>
<ifParams>{LastResult}&&"9999"</ifParams>
<then>
<action>
<cmdType>Results.RegEx</cmdType>
<params>
<param>Channel_(.*?)_type"\Wvalue="9999"</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>Map.Query</cmdType>
<params>
<param>delete from PTVL where fromKey="{Match.{i}.1}"</param>
</params>
<cmdRepeat>{#M}</cmdRepeat>
</action>
</then>
<else />
</if>
<action>
<cmdType>Map.ExportPayloadXML</cmdType>
<params>
<param>{Path.VC}\XbmcPayloads\PTVL.xml</param>
<param>PTVL</param>
<param>True</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<phrase>Update sudo TV live</phrase>
</command>
<command id="507" name="PTVL channels" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
<action>
<cmdType>TTS.Speak</cmdType>
<params>
<param>changing to {PF.1} channel</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>Results.RegEx</cmdType>
<params>
<param>(\d)</param>
<param />
<param>{1}</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<action>
<cmdType>XJson.Raw</cmdType>
<params>
<param>Input.ExecuteAction</param>
<param>"action":"number{Match.{i}}"</param>
</params>
<cmdRepeat>{#M}</cmdRepeat>
</action>
<action>
<cmdType>XJson.Raw</cmdType>
<params>
<param>Input.ExecuteAction</param>
<param>"action":"select"</param>
</params>
<cmdRepeat>1</cmdRepeat>
</action>
<phrase>Watch </phrase>
<phrase optional="true">The</phrase>
<payloadFromXML phraseOnly="False" use2partPhrase="False" phraseConnector="by" Phrase2wildcard="anyone" optional="False">XbmcPayloads\PTVL.xml</payloadFromXML>
<phrase optional="true">Channel, Network</phrase>
</command>
</commandGroup>
NOTE: If you use eventghost, PTVL has eventghost triggers that you could use to have your PTVL payload update every time you start or stop PTVL
thanks for the help with the numbers input jitterjames ;D