Kira IR Receiver and Transmitter Plugins

Does an event get fired for every time a code is received or only when a new code is seen?
It uses standard Vera event handling so an event only fires when the code changes. It is possible to change that by a tweak to one of the files but I have not tested this for side effects. Let me know if you want to be the test-pilot.

Perfect! Thanks for confirming. Before going down the path of code changes, I’m going to try a different approach. I’m going to teach the plugin a no-op code, then on my Harmony remote, I’ll program FF as a sequence of no-op+FF. I’m pretty confident that approach will work for anything where subsequent discrete button presses are meaningful.

@manfaiho, @SM2k may have divined your problem. It is possible that your TV needs the code to be sent more than once. I’ve added that facility to KiraTx. See the first post to download the latest version. The new version includes the fix for Pronto codes with dummy repeats. I also uploaded a new KiraRx with the Pronto import fix.

The action SendIRCode now has two optional parameters. Count=X will cause the code to be sent X times. If not specified, it defaults to 1. Delay=Y puts a delay of Y milliseconds between each send. If not specified, it defaults to 50.

You can test whether this helps by running the following code in APPS → Develop Apps → Test Luup code (Lua). Try changing the Count and Delay parameters.

local dID=123 -- Set to device ID of KiraTx luup.call_action("urn:dcineco-com:serviceId:KiraTx1","SendIRCode",{IRCodeName="nameofcode",Count=3,Delay=50},dID)

Thanks all of your help. I already used scene to repeat LG command in 5 times in 1-2 seconds internval but no luck to get it work at the end. And I found the same problem to capture using thier Java App then test the learn code directly. Nothing help. I sent the help to Keene and they reply below: I will try it again to test if the first code capture issue later then get back you all. I really want to make it works to make Kira success with Vera for IR automation :slight_smile:

-----Original Message-----
From: Mark Fibiger [mailto:mark@keene.co.uk]
Sent: Wednesday, February 19, 2014 4:43 AM
To: Ho Man Fai
Cc: sales@keene.co.uk
Subject: Re: Fwd: RE: Question from www.keene.co.uk

Hi Fai

It is possible that the LG code sends the command just the once the first instant that the button is pressed after that sending a “repeat this” command.

This happens so quickly that usually the code captured is the repeat bit but there is no command to repeat.

On the options on the java Kira utility there is an option to display first code only. Try capturing codes with that checked

Regards

Mark

It’s worth a try but I think you said the code KiraRx learned was the same as the published Pronto one. That looks like a real code.

If the TV requires a repeated code it may need to be faster than you would get running it from a scene. Try the Count parameter in SendIRCode because it will send it as fast as the KIRA can respond.

I had a similar problem device some while back with an actual Pronto remote. The solution was to hand-create the Pronto code by copying the sequence three times and adjusting the header. This is easier than it sounds. KiraTX should be able to import the custom code.

My (Samsung) TV requires 3 bursts only milliseconds apart. Bursts 1 second apart would definitely time out (after all, it doesn’t take 5 seconds for your TV to respond to the “on” button does it?) ;D

It’s definitely worth trying the Count parameter as Rex suggested.

Thanks all of your support. It works now. What I found is, all the learned codes always doesn’t work for LG TV 2012 model remote control ONLY. I used prevous LG Prono documentation to copy its PowerOn/Off into the Kira (didn’t work before because my mistaken: I copied and pasted the code with CR which is incorrect format:-( ) then everything works but sometime. Then I added Count=10 for 10ms then it works consistently. I really need to understand more about IR code format and pattern so that to adjust its code until work for all situation. I don’t know why the big difference between learnt and predinfed IR code…interesting…At least Kira can work for my minimum cases. I will start the rest then update you guys Thank you all of your assitance :slight_smile:

I’m glad to hear that you’re making progress, Fai.

I added Count=10 for 10ms then it works consistently.
Did you also try a lower [b]Count[/b] with a bigger [b]Delay[/b]? The reason I ask is that, when I was testing the new [b]Count[/b] feature, it didn't look to me as if KIRA could handle multiple sends with less than 30ms [b]Delay[/b]. It may be that KIRA is not actually sending all of your commands because of this.

I would try with a Delay of 40 or 50 and see if a smaller Count still works.

I don't know why the big difference between learnt and predinfed IR code....
There is often a difference between the code sent by a remote for a quick press on the key as opposed to holding it on for longer.

Yes, I am fine tuning the count and duration for my IR codes. Let me update you more later.

Btw, did you tes thier beta firmware to send long code for Air Condition control? Did this plugin support long code? I want to use it to control Air Condition as well. Thanks again as always :slight_smile:

Best regards,
Fai

Btw, did you tes thier beta firmware to send long code for Air Condition control?
No and, as it's Winter here, my only AC is decommissioned so I can't test it. I think you should be the test-pilot for that.
Did this plugin support long code?
I don't know. What is required to support long code?

Hi Rex,

I got some problem for long code firmware and am still checking with Reene support.

For count test, I test so many times but LG IR remote is really troublesome. I need to let IR emitter point direct straight to its IR recevier (if not, failure rate is very high, other IR control doesn’t). I also test so many times with the conclusion that count=10 for 10ms is the most safe combination to make it works. Really not easy to control LG TV 2012 Model :frowning:

Anyway, once I have any update for this long code firmware, I will let you guys know :slight_smile:

Best regards,
Fai

Thank you for writing this plugin! I have some of it working well.
I am having two problems. I have a Lutron shade and my Pronto remote operates the shade perfectly. The codes I am using came from a Lutron provided Excel spreadsheet. I copied the two codes (open and close) from the spreadsheet into my Pronto without any trouble. I can?t import the two codes into KiraRx, KiraTx or the Keene Java utility. They all say the code is invalid. When I copy the code from my Pronto into KiraRx or KiraTx the code is accepted but doesn?t work. Here is the Lutron provided code for close:

000000670000009C002000200020002000200020002000100010002000100010001000100010001000100010002000200020001000100010001000200010001000100010002000200020001000100010001000200020001000100020002000100010001000100010001000100010007000200020002000200020002000200010001000200010001000100010001000100010001000200020002000100010001000100020001000100010001000200020002000100010001000100020002000100010002000200010001000100010001000100010001000700020002000200020002000200020001000100020001000100010001000100010001000100020002000200010001000100010002000100010001000100020002000200010001000100010002000200010001000200020001000100010001000100010001000100070002000200020002000200020002000100010002000100010001000100010001000100010002000200020001000100010001000200010001000100010002000200020001000100010001000200020001000100020002000100010001000100010001000100010007000200020002000200020002000200010001000200010001000100010001000100010001000200020002000100010001000100020001000100010001000200020002000100010001000100020002000100010002000200010001000100010001000100010001000700020002000200020002000200020001000100020001000100010001000100010001000100020002000200010001000100010002000100010001000100020002000200010001000100010002000200010001000200020001000100010001000100010001000100070

I have had some success with using:
local dID=47 – Set to device ID of KiraTx
luup.call_action(“urn:dcineco-com:serviceId:KiraTx1”,“SendIRCode”,{IRCodeName=“ShadesClose”,Count=3,Delay=80},dID)

Here is my second problem. I have a zwave switch that toggles with a trigger from an ir relay connected to an Everspring door sensor. This works very well. I have tried to use the same scene with a second trigger (KiraRx) to toggle the same switch. It will work once in a while. Maybe, 1 in 20 times. I have used different codes from different remotes without any improvement.
Any help would be appreciated!

Thank you, Mark

Hi @MarkAgain,

Most software that converts from Pronto code, including my plugins, will not like the code in that form. It needs to have a space after each four digits. e.g. 0000 0067 0000 009C …

I have a zwave switch that toggles with a trigger from an ir relay connected to an Everspring door sensor. This works very well. I have tried to use the same scene with a second trigger (KiraRx) to toggle the same switch. It will work once in a while. Maybe, 1 in 20 times. I have used different codes from different remotes without any improvement.

Does KiraRx show that it recognised the code? It will show the name of the last code on the UI. You will only get a trigger when the code changes. You will not get multiple triggers from the same code unless there is a different code in between.

Thanks for the quick reply! I added spaces to the Excel code. This imported into KiraTx and converted. This code didn’t work at all. Just don’t understand. Here is the converted Excel code:

0000 0067 0000 009C 0020 0020 0020 0020 0020 0020 0020 0010 0010 0020 0010 0010 0010 0010 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0020 0010 0010 0020 0020 0010 0010 0010 0010 0010 0010 0010 0010 0070 0020 0020 0020 0020 0020 0020 0020 0010 0010 0020 0010 0010 0010 0010 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0020 0010 0010 0020 0020 0010 0010 0010 0010 0010 0010 0010 0010 0070 0020 0020 0020 0020 0020 0020 0020 0010 0010 0020 0010 0010 0010 0010 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0020 0010 0010 0020 0020 0010 0010 0010 0010 0010 0010 0010 0010 0070 0020 0020 0020 0020 0020 0020 0020 0010 0010 0020 0010 0010 0010 0010 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0020 0010 0010 0020 0020 0010 0010 0010 0010 0010 0010 0010 0010 0070 0020 0020 0020 0020 0020 0020 0020 0010 0010 0020 0010 0010 0010 0010 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0020 0010 0010 0020 0020 0010 0010 0010 0010 0010 0010 0010 0010 0070 0020 0020 0020 0020 0020 0020 0020 0010 0010 0020 0010 0010 0010 0010 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0010 0010 0010 0010 0020 0020 0020 0010 0010 0010 0010 0020 0020 0010 0010 0020 0020 0010 0010 0010 0010 0010 0010 0010 0010 0070

I learned the two codes with the Keene Java utility and they work about 50% of the time. I have messed with the number and delay. Nothing I have tried works well.

Your response to the second part makes sense. I think it explains some of my trouble. I was in the middle of trying different codes with Kira Tx when KiraTx sopped working completely. The Vera message said something like KiraTX lua startup failed. I had to go back to a previous Vera backup and start over. Now I can’t get any Kira learn functions to work or KiraRx to see anything. Must be missing something. I don’t know how you got figured this out!

Thank you, Mark

I got the learn working. Had the IP wrong. One thing done! :slight_smile:

Mark

When you learn a code with KIRA, position the remote at the normal operating distance - not very close as you normally do with Pronto. If you are too close, the learned code often does not work well.

I cannot explain why the published Pronto code for your Lutron does not work but I can tell you that it is not at all unusual. I have had many failures of published code with Pronto, Marantz and Harmony as well as KIRA. I generally get better results by learning from a working remote.

Thank you for the help!

I have got the two codes working fairly well. I don’t have the original Lutron remote. Just the Pronto. I experimented with the length of time that the Pronto remote sent the codes. I learned and relearned the codes with KiraTx. I also tried different counts and delays entered into the LUUP within the Scene. I very much want to save the codes that I learned with KiraTx. I already used the Backup button within KiraTx. I have two questions. Does the KiraTx backup get saved with the Vera3 Setup/Backup? The second question: how can I save the KiraTxNNN.xml to my computer for future use. I would like to post the Lutron learned codes and the LLUP here as well.

I don’t want to make any changes until I get this backed up. Don’t want to risk loosing these settings/codes.

Thank you, Mark

I have got the two codes working fairly well.
Well done! The most important tool for success with IR control is perseverance. ;D
Does the KiraTx backup get saved with the Vera3 Setup/Backup?
No I don't think it is.
how can I save the KiraTxNNN.xml to my computer for future use.
The full file path will be [b]/etc/KiraTxNNN.xml[/b] and you can copy it to your PC using WinSCP or a similar FTP package that can operate with the [i]SCP[/i] protocol. See attached info for using WinSCP.

Wow! Thank you Rex! Got the file on my desktop! Now I can work on the KiraRx function later tonight. No; tomorrow. Need a break. ;D

Here are the Lutron Serena codes I came up with and the LLUP. The first is Close-All and the second is Open-All:

K 232D 01CE 0148 01A8 0A4B 0329 02E0 0328 02DD 0328 02DD 0328 014B 01A7 02DA 01A8 0149 01A7 014A 01A7 014A 01A6 0147 032A 02DA 032A 014B 01A6 0147 01A8 02D8 01A8 0149 01A7 014A 0329 02DD 0328 014B 01A6 0149 01A7 02DA 032A 014B 01A6 02D8 0329 014B 01A6 0149 01A8 0147 01A8 0147 01A8 0A4B 032A 02DD 032A 02DD 032A 02D9 032A 0149 01AA 02DA 01A8 0149 01A7 014A 01A8 0147 01AA 0147 032A 02DE 032A 0149 01AA 0149 01A7 02DA 01A8 0149 01A7 014A 0329 02DA 0174 2000

K 232C 01CF 0148 01AA 0A64 032A 02DA 032B 02DA 032B 02DA 032B 014A 01AB 02D7 01AA 0147 01AA 0147 01AA 0147 01A8 0147 032B 02DB 032A 014A 01AA 0147 01AA 02D7 01AA 0147 01AA 0147 032B 02DB 032B 014A 01AB 0147 01AA 02D7 01AB 0147 01AA 0147 032B 02DB 032B 014A 01AB 0147 01AA 0147 01AA 0A64 032A 02DA 032B 02DA 032C 02DA 032B 014A 01AB 02D7 01AA 0147 01AA 0147 01AA 0149 01A8 0147 032C 02DB 032A 014A 01AB 0147 01AA 02D7 01AA 0147 01AA 0147 032A 2000

local dID=XX
luup.call_action(“urn:dcineco-com:serviceId:KiraTx1”,“SendIRCode”,{IRCodeName=“ShadesClose”,Count=6,Delay=90},dID)

local dID=XX
luup.call_action(“urn:dcineco-com:serviceId:KiraTx1”,“SendIRCode”,{IRCodeName=“ShadesOpen”,Count=6,Delay=90},dID)

Thank you!!! Mark

Hi Rex,

Sorry for my late reply. I have done my test for Kira 128 Tx and Rx (using Firmware: 1.8J) with your plug-in on Vera Lite that all work perfectly as I expect. Previous problems all were caused by Kira IR Emitter not attached in front of AV devices including LG TV (I used it in 1.5M apart). I have now installed Keene’s IR distributor and put all IR emitter directly attached on LG TV then everything becomes consistence. Thank you very much :slight_smile:

Now I have also tried to update its 1.9 firmware (from http://www.keene.co.uk/forum/viewtopic.php?f=4&t=369&sid=9c494ed7e9a299a8082e6c52ff886812) in order to support its long code for AC control. I learnt the code below for AC PowerOn and Off using thier Java app then test it. Yes it works perfectly.

K 237A 0D03 0657 01BC 016E 01BD 0168 01BC 04AA 019E 0187 01BC 04A4 01BC 0168 019F 018D 019F 0186 01BC 049D 019F 04C7 01BC 0168 019F 0186 019F 018D 01BC 049D 01BC 04A9 019F 0186 019F 0186 019F 018D 01BC 0168 01BD 0167 01A0 018D 019F 0186 019F 0186 01BC 016E 01BD 0168 01BD 0167 01A0 018D 01BC 0168 019F 04C0 01BD 0168 01BD 016E 019F 0186 019F 0186 019F 018D 01BC 0168 01BC 0169 01BC 04A4 01BC 016F 019F 0186 019F 018D 01BC 0168 01BD 0167 01BD 04A4 01BC 04A9 01BD 049D 01BC 04A2 01BD 04A9 01BD 049D 019E 018D 01BC 0168 019F 0186 019F 04C7 01BD 0162 01BD 016E 019F 0186 019F 018D 01BD 0168 019F 018D 01BC 0162 01BD 016E 01A0 04C0 019F 04C0 01BD 016F 01BD 0162 019F 04C7 019F 0186 019F 0186 019F 018D 01BC 0168 01BD 04A4 01BC 0168 019F 04C0 01BD 016F 019F 0186 01BC 0167 01A0 0186 01BC 016E 01A0 0186 019F 018D 01BC 0168 01BD 0167 01BD 016E 01A0 0186 01BC 016E 01BD 0168 019F 018D 01BC 0162 01BD 016E 01BD 0168 019F 018D 019F 0186 019F 018D 019F 0186 019F 0186 019F 0186 01BC 016E 01BD 0168 019F 0186 01BD 016E 01BD 0168 019F 0186 019F 018D 01BC 0168 01BD 016E 019F 0186 019F 0186 01BD 0167 019F 018D 01BC 0168 01A0 018D 01BC 0168 01BC 0169 01BC 04A4 019E 04C0 01BC 04A4 01BC 04A2 01BD 016F 01BD 04A2 01A0 0186 019F 018D 019F 2000

Then I copied this code into your plug-in then clicked Kira button. The code seems not being converted the same exactly.

K 237A 0D03 0657 01BC 016E 01BD 0168 01BC 04AA 019E 0187 01BC

04A4 01BC 0168 019F 018D 019F 0186 01BC 049D 019F 04C7 01BC

0168 019F 0186 019F 018D 01BC 049D 01BC 04A9 019F 0186 019F

0186 019F 018D 01BC 0168 01BD 0167 01A0 018D 019F 0186 019F

0186 01BC 016E 01BD 0168 01BD 0167 01A0 018D 01BC 0168 019F

04C0 01BD 0168 01BD 016E 019F 0186 019F 0186 019F 018D 01BC

0168 01BC 0169 01BC 04A4 01BC 016F 019F 0186 019F 018D 01BC

But anyway, it still works :slight_smile:

However, when I am using 1.9 version, I have found the following issues:

(1) Suppose, Kira128 can normally act as IR repeater (using external IR receiver on 1.8J Firmware) to emit IR code recevied from its IR receiver. Due to its nature, I found teh same with double IR command is triggeres when I used Logitech harmony Ultimate Remote to trigger IR command which supposely emit to all of my AV devices as well as Kira128 external IR receiver at the same time. Most of AV devices have no problem ( for this double IR command within a sec) except my HD media player (especially for the cursor up, down, left and right). The only solution is to put this player behind from the IR sign direction from Harmony hub. However, when I upgraded to 1.9 Firmware, I found it will NOT re-act as IR repeater and NOT re-send the IR command from its IR reciever to its IR emitter. That’s very strange but can resolve my 1.8J Firmware’s problem.

(2) Suppose, when IR command is emitted (controlled by Vera) or recieved (from its IR receiver), I would see the flash on “ACK” and “IR output” LED. I would expect it’s normal. However, I found on firmware 1.9 version, it would sometime lost these IR commands and at that time I would see “Ack” LED hold ON over a few seconds. The worse situation, I would see both “Activity” and “Ack” LED hold ON together more than 5 secs. During that time, when I click any command from Vera to send IR code, it must lose. I think there are some problems on 1.9J firmware that would intermittently block a normal operation during the handshake with Vera.

I don’t know what’s the problem is but I really want to fix it on 1.9 version becasue I enjoy a normal IR Tx and Rx between Vera and Kira as well as AC remote control.

Look forward to receiving your advice. Thanks .

Best regards,
Fai