Lutron Radio RA2?

I’ve not seen a binding for this. I’m very interested in one. If one does not exist and one is not under development, can anybody point me (I’d consider myself a power user but not a dev. Took a java class in college… 20 years ago).

RA2 is controlled via an IP-based “repeater”. You can download the config in XML via HTTP. Commands are sent and status retrieved via a telnet connection to the repeater. Commands are issued as strings preceded by #. So #DeviceNumber,Command,Intensity – like #3,1,80 would turn device 3 on at 80%. Could be a dimmer, a binary switch, window blinds, electrical sockets etc. They have a decent doc that outlines their protocols.

If a plugin does not exist, based on my very simplified explanation above, what other device bindings should I look at to try to get started here?

Thank you

Hi,
I kind of have a similar setup with a rooted Wink Hub, that I’m using as a bridge to zigbee and zwave devices. I’m simply using the execute command to run scripts. So I have one shell script for turning lights on and one for turning lights off. Pushing buttons on the interface runs the execute command via rules.

Edit: here’s a post to what I did. Seems like a similar method would work for you too.

Edit2: Opps, still too new to forum to post links. Just google for “wink hub local control openhab”

If you manually turn a light on from the wall switch,how does OpenHab know?

It’s possible to tell a repeater to monitor only certain devices. Otherwise you could be getting a lot of data as things are happening. But the repeaters do track the status of anything registered to them. So you could poll it. So it would depend on how much data you’re prepared to get from the repeater(s). It’s possible for a RA2 installation to have up to 2 repeaters, not just one. I have two as I’m over 100 devices (motion sensors, keypads, etc, it adds up fast).

I’d be glad to help debug/test a driver.

i know it can be done. Just wanted to know if/how it was done via a script that sent discreet commands.

I telnetted to my lutron repeater and then adjusted some lights and dimmers via my phone. The commands trigger status changes and these are echoed to the telnet window. So not sure if it would be “polling” vs just monitoring, with OpenHAB holding a connection constantly open. looks like this:

login: lutron
password: integration

GNET> ~OUTPUT,32,1,0.00
~OUTPUT,32,29,6
~OUTPUT,32,30,1,0.00
~OUTPUT,32,1,100.00
~OUTPUT,32,29,6
~OUTPUT,32,30,1,100.00
~OUTPUT,12,1,1.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,1.00
~DEVICE,1,102,9,0
~DEVICE,25,81,9,1
~OUTPUT,12,1,2.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,2.00
~OUTPUT,12,1,3.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,3.00
~OUTPUT,12,1,10.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,10.00
~OUTPUT,12,1,21.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,26.00
~OUTPUT,12,1,33.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,33.00
~OUTPUT,12,1,40.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,48.00
~OUTPUT,12,1,54.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,54.00
~OUTPUT,12,1,58.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,58.00
~OUTPUT,12,1,59.00
~OUTPUT,12,29,6
~OUTPUT,12,30,1,59.00

For anyone interested, I’ve an alternative - but very hacky - method for controlling RadioRA2 devices from OpenHAB (but not reading states).

It’s a simple expect script (apt-get install expect) to call two successive lutron commands:

#!/usr/bin/expect
set timeout 20
set command1 [lindex $argv 0]
set command2 [lindex $argv 1]

spawn telnet "lutron"

expect "login: "
send "lutron\r"
expect "password: "
send "integration\r";
expect "QNET> "
send "#device,$command1\r";
expect "QNET> "
sleep 1
send "#device,$command2\r";
expect "QNET> "
send "\x1d";
expect "telnet> "
send "quit\r";

So if I save the script as lutron.exp in my configurations directory and I want to select the scene that’s button 6 on my keypad (device 13) then I would put the following in my rule:

executeCommandLine("/etc/openhab/configurations/lutron.exp 13,10,3 13,6,3")

The reason for sending two commands is that if the keypad was already on that scene then pressing button 6 would turn the scene off. So I first press one other button and then immediately press button 6. I said this was hacky!

Disadvantages: stupid, ugly, not properly integrated, write-only
Advantages: fast, achievable given my limited programming skills - and it works

Incidentally, isn’t it terrifying that all RadioRA2 systems seem to come with telnet access and well known but unchangeable default passwords?

Dan

[edited to include 1 second delay between commands]

I am using zwave for all my swtches, but I really like the lutron wall keypads more than any of the zwave options. Has anyone gotten the lutron wall keypads working with openhab. Can anyone give me any idea of how difficult that would be to accomplish?

Here is a link to the keypad I would like to use

You would need either a rooted wink hub, or more likely the radiora2 central controller to make it work. If you go the radiora2 central controller route you would need access to Lutron’s proprietary software to program it.

The software can be gotten from Lutron for free. Or you can set up the devices manually (which is ridiculously tedious, so get the software).

You can also make an RS-232 connection to the repeater. That has the advantage of not having to login for each command. You’re straight into the command shell. So you wouldn’t need to add delays.