Kira IR Receiver and Transmitter Plugins

Thanks for the reply!
I have an IP assigned to both the KiraRx and KiraTx in the Living room. I have a different IP assigned to both the KiraRx and Kira Tx in the bedroom. It’s not a problem. I just use different code names. Just thought you might want to know.

If you don’t mind I would like to know if the following code is an efficient way to use one scene to receive multiple IR codes.

Thanks again, Mark

local dID = 123 – Device ID of KiraRx living
local dID2 = 124 – Device ID of Living light outlet
local dID3 = 125 – Device ID of Porch light
local dID5 = 127 – Device ID of Shade virtual switch
local dID6 = 128 – Device ID of Alarm control
local dID7 = 129 – Device ID of KiraRx bedroom

local IrCode = luup.variable_get(“urn:dcineco-com:serviceId:KiraRx1”, “RxCode”, dID)
local IrCode2 = luup.variable_get(“urn:dcineco-com:serviceId:KiraRx1”, “RxCode”, dID7)

luup.variable_set(“urn:dcineco-com:serviceId:KiraRx1”,“RxCode”,“”,dID) – Clears Kira code
luup.variable_set(“urn:dcineco-com:serviceId:KiraRx1”,“RxCode”,“”,dID7) – Clears Kira code

if IrCode == “LivLight” then – Living light outlet toggle
local L_light = luup.variable_get(“urn:upnp-org:serviceId:SwitchPower1”, “Status”, dID2)
if L_light == “0” then luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”,“SetTarget”,{newTargetValue = “1”}, dID2)
else
luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”,“SetTarget”,{newTargetValue = “0”}, dID2) end
end

if IrCode == “PorLight” then – Porch light toggle
local P_light = luup.variable_get(“urn:upnp-org:serviceId:SwitchPower1”, “Status”, dID3)
if P_light == “0” then luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”,“SetTarget”,{newTargetValue = “1”}, dID3)
else
luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”,“SetTarget”,{newTargetValue = “0”}, dID3) end
end

if IrCode == “ShadesOff” then – Shades auto-off
luup.call_action(“urn:upnp-org:serviceId:VSwitch1”, “SetTarget”, {newTargetValue = “0”}, dID5) end

if IrCode == “ShadesOn” then – Shades auto-on
luup.call_action(“urn:upnp-org:serviceId:VSwitch1”, “SetTarget”, {newTargetValue = “1”}, dID5) end

if ((IrCode == “Chime”) or (IrCode2 == “BedChime”)) then – Chime toggle
luup.call_action(“urn:micasaverde-com:serviceId:DSCAlarmPanel1”,
“SendCommand”,
{Command = “071”, Data=“1*4”}, dID6) end

Just thought you might want to know.

Thank you. It appears not to work as I had intended so I’ll check it out. You could fix it by using different port numbers if you needed to to. That is how the new combined plugin will handle it.

If you don't mind I would like to know if the following code is an efficient way to use one scene to receive multiple IR codes.

Your code should work, Mark. Presumably you have created a trigger for each of the code names? You could just put the relevant Lua actions in each trigger’s Luup event and then you wouldn’t need the if statements. You could leave the code to clear RxCode in the main LUUP so it happens after any trigger.

BTW: You could use this for toggling a switch:

local P_light = luup.variable_get("urn:upnp-org:serviceId:SwitchPower1", "Status", dID3) luup.call_action("urn:upnp-org:serviceId:SwitchPower1","SetTarget",{newTargetValue = (tonumber(P_light)+1) % 2}, dID3)

[quote=“RexBeckett, post:153, topic:175170”]

Do you think that the long IR codes will include passthrough of received codes too ?

I don’t know but I have PM’d you the details of a man who will.[/quote]

Unfortunately, I got no answer from him ::slight_smile:

[quote=“lolodomo, post:163, topic:175170”][quote=“RexBeckett, post:153, topic:175170”]

Do you think that the long IR codes will include passthrough of received codes too ?

I don’t know but I have PM’d you the details of a man who will.[/quote]

Unfortunately, I got no answer from him ::)[/quote]

You could also try posting your question on the Keene forum.

Thanks again for the quick reply! I will change the toggle to your code. Much cleaner! This is a new language for me. A lot to learn! ;D

I am using two different IPport numbers with each of the two Kiras. I used an “*” for the trigger code. This could be this is causing the operation I have described above. Please see attached JPG.

You could just put the relevant Lua actions in each trigger's Luup event
I like your suggestion to add code to each of the triggers. I hadn't seen that option before. Would this be a better/more efficent way?

Thank you, Mark

Hi guys,

I’m using the KIRAM with the RX plugin an all is working fine.
However I have major trouble to get the TX plugin to work (or the KIRAM with the Java SW in send mode).
I can learn codes in the TX plugin fine but sending them does not work.

Here is what happens:

  1. learn the code in the TX module, it shows up fine
  2. test the code
    2.1. once in a while the device reacts to the FIRST test. subsequent pressing of test and no further reaction from the device.
    2.2. most of the time test does not work = code sent but device does not react
  3. saving and loading the learned code followed by test never worked = code sent but device does not react

I have similar issues with the Kira Java SW on the PC. I can learn codes fine from both internal and external IR receiver.
Test always only works the first time directly after a learn. Subsequent tests result in no recognition from the target device (IR is transmitted, LED on the dual emitters I have blinks).

Any ideas?

Thanks !

Does this problem affect all your IR-controlled devices?

If so, it may be that the learned codes are not correct. Try increasing the distance between the remote and KIRA when learning the code. Also press the remote button just briefly - when held, the code is sometimes different.

If the problem is with one device, what is it and what is the code?

I checked with Keene and they helped me fix the codes. Turns out the on function required repeats :frowning:

Sent from my Nexus 10 using Tapatalk

I’m struggling to get the receiver plugin working reliably with a Harmony Ultimate. I can learn the codes no problem, but they are only recognised intermittently. Despite trying different remotes at different distances, the learned code seems to alternate between several different values. Do I need to learn every combination of each, or have I missed something obvious?
Also, despite downloading the files from the link on the first page of this thread, I cant get the delete code function to work. If I click Delete on a code, I get “Name cannot contain spaces or a punctuation!” and the code is still there. I have gotten around this by editing the saved xml file and then restoring it.

Thanks.

I am NO expert here! With that said, learning IR codes can be a challenge! Rex has some suggestions a few threads back. Another option is finding your IR controlled device at:
RC: Device Command Library File Area Index or searching the internet for Pronto codes for your IR device.

If you find a code for your device, you could enter the Pronto code into Kira(Rx or Tx) and use the Pronto button. When you want to delete a code don’t forget to enter the name that you entered when you created the code into the “Name” box. Next, hit “Delete” and a second time to confirm.

Mark

Thanks Mark, I had missed that I needed to enter the name again. I was just clicking Next until I got to the code and then hitting delete.
As I 'm trying to control lights via my Vera Lite, I’m just using an old remote to trigger scenes and then transferring this to my Harmony Remote, so there is no existing device as such.
I just spotted a post by spearofjustice on this thread that desribes the problem I’m having, and he suggests using a Magnavox Model # VRU662AT21 VCR control which I will try.

I am using a Xantech remote programer RC-68+. I can make a lot of codes that aren’t in use by my system. I have about 20 in use now. I put a few in a text file. Have a try and see if any help.

Mark

Hi Mark,

Thanks for that. I’ll try it out at the weekend.

Pat

Mark, I couldn’t get the Xantech codes to work as Logitech don’t seem to have that device in their database. I tried other Xantech devices, but no joy. I ended up using an NEC E422 TV as the device template, which works fine with this plugin.

A question for everyone on this group that uses a remote to control their lighting - particlularily the Logitech Harmony: How do you set up your remotes for each room? For example, I have created an Activity on my remote for each room, and then assigned buttons for each lighting scenario (eg Reading Lights, Dinner, etc) which turns on various combinations of lights for that room. What I would like to be able to do is then use the volume control on the remote to brighten or dim those particular lights, but I cant figure out how to achieve this.

Has anyone tried this or is there a better way of implementing what I’m trying to achieve?

Thanks.

I learned the Xantech codes with Kira (Rx and Tx). Then I learned the same codes with my Pronto. For you to use them, you would need to paste the codes into the KiraTx “Import” box and push the Kira button. Next you would need to send the code with KiraTx while learning the code with your Harmony. Kind of a pain but, the codes work well. Sound like you got some good codes anyway. :slight_smile:

I don’t have a Harmony remote so I can’t help much there.

Mark

That’s what I tried, but the Harmony didn’t recognise the codes when I transmitted them from the Kira, so I gave up at the stage and nearly threw the remote out the window! I had to try several different TV models before I found one that Kira would respond consistently to.

Pat

Though not entirely the same solution the other workaround that I was able to do is to use a Leviton Wall switch 4 button scene controller whch has an IR input. Their remote control for this scene controller sends the IR command for any of the 4 buttons specifically, which can be learned to a universal remote.

Then just program any of the 4 buttons with a scene created in vera (example watch tv, watch movie, lights on or off etc) and then point the universal remote to the controller, it’s also possible to put the controller somewhere else and attach an IR blaster to that if the confirguration permits.

Not fully elegant but simple and doable.

Thanks for that, but I think Leviton is a US system and I live in Ireland. I have the remote working well now with Kira triggering various scenes, but I’m looking to add a few bells & whistles to it. Currently PLEG looks like my best bet so I’m trying to get to grips with that.

Pat

Hi RexBeckett. I am hoping you could lend me some suggestions. In the past I had two KiraRx set up to receive codes independently from two different rooms. Each had their own ip number. I have made some changes and I now want to use one of the two KiraRx to receive all codes from the two locations. One is dID48 and the other is dID50. dID48 is set with an id port 65432. dID50 with id port65433. The codes are not seen at all by the dID48 KiraRx that I was hoping would receive the codes. I have removed the IP address from both of the KiraRx and KiraTX locations.

Thank you, Mark

Hi Mark,

A single KiraRx should receive codes from multiple KIRA modules provided they are all set to the same port specified in IPport and IPaddr is blank. Your KIRAs are using different ports so you need to change one of them. Either delete the second KiraRx or set it to an unused port so it doesn’t intercept the datagrams.