Control4 Keypad Zigbee Driver

Ok, I found the hue example. Unfortunately, I must not be doing something right cause nothing happens…

LOL, I used the Hue Zigbee Bulb devicetype, and that has the following error in it:

groovy.lang.GroovyRuntimeException: Ambiguous method overloading for method java.math.BigInteger#. Cannot resolve which method to invoke for [null, class java.lang.Integer] due to overlapping prototypes between: [class [I, int] [class [B, int] [class java.lang.String, int] @ line 100

I’ll fix that and see what happens.

Let me put together a simple on / off device type for that end point. Give me a few minutes. Hey what is the best way to share code on this site? In the past I have copied code into this text box but their has to be a better way??? Any advice?

EUREKA!!!

“st cmd 0x${device.deviceNetworkId} 1 6 0 {}”

Hard coding the endpointId worked. I turned off and on the lights. Go figure… Just fix the broken code and it worked off the HUE Zigbee example, go figure…

Now where to go from here…

setLevel works as well:

“st cmd 0x${device.deviceNetworkId} 1 8 4 {${level} 0000}”

Good job!!

Okay next thing i would do would be to remove all the non necessary code and make sure your fingerprint is correct.

Here is what I think your fingerprint should look like:

fingerprint endpointId: “01”, profileId: “0104”, deviceId: “0101”, deviceVersion: “00”,
inClusters: “07 0000 0003 0004 0005 0006 0008 000A”, outClusters: “00”

I have to admit the fingerprinting process is bit of an art i haven’t got it completely figured out. It appears they are trying to tie a device to a device driver based on the driver’s fingerprint. They appear to use the configuration of end points to make up the fingerprint. But what I don’t know is if a device has multiple end points like yours which end point should I use in the finger printing. In the above example I used the first end point. If all goes well when this device joins the SmartThings hub your device type will be assigned to it and will appear as such on your smart phone. I have it working with another device and it works very well!!

Ok, THANK YOU @JohnR!!!

Here is the git for the psuedo working dimmer for Control4…

I have parsed out the C4 profile response which is really goofy but I can get the taps of the buttons and parse them.

Also, it can setLevel, turn on/of and poll/refresh it to get the status of the light.

This means, it works. Now to figure out how to send to those other profiles.

https://github.com/pstuart/smartthings/blob/master/Control4%20Zigbee%20HA%20Dimmer.groovy

1 Like

Here’s a quick video of it in action…

https://plus.google.com/109218861040495449466/posts/Dv7VLQsCQ3H

3 Likes

megalike!!

so sweet!!

I’m getting this error with the gethub

org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
script1411762064186838130924.groovy: 16: unexpected token: + @ line 16, column 1.
+metadata {
^

1 error

Any ideas?

Also does this work with a C4-DIM1-Z this is the switch I have…

Did you install it as a SmartApp or device? Yes it should work with dimmers

I installed it as a device.

Okay i have it paired, but the driver isn’t working. Here’s what I have in the trace logs after playing with it. Is there anything special I need to do in the code for my specific device?

cdccfeef-4d41-4c88-994a-75c18ce416b8 12:25:04 AM: debug on() null
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:25:04 AM: debug Device.endpoint is null
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:25:02 AM: debug off() null
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:25:02 AM: debug Device.endpoint is null
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:43 AM: debug Payload is A(￁ !
!X !X
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:43 AM: trace catchall: C25D 0001 02 02 0440 00 043D 00 00 0000 0A 01 120041020000130028C1000020020100210A000200215802030020000B002158020C002013
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:07 AM: debug Payload is c03 sa c4.dm.t0c 00
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:07 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6330332073612063342E646D2E7430632030300D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:07 AM: debug Payload is c02 sa c4.dm.t0c 0a
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:07 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6330322073612063342E646D2E7430632030610D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:07 AM: debug Payload is c01 sa c4.dm.cc 01 01
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:07 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6330312073612063342E646D2E63632030312030310D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:06 AM: debug Payload is c00 sa c4.dm.t0c 3d
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:06 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6330302073612063342E646D2E7430632033640D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:05 AM: debug Payload is bff sa c4.dm.b1c
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:05 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6266662073612063342E646D2E6231630D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:05 AM: debug Payload is bfe sa c4.dm.t0c 61
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:05 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6266652073612063342E646D2E7430632036310D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:02 AM: debug Parse returned Theater Main Dimmer switch is on
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:02 AM: debug Payload is bfd sa c4.dm.cc 00 01
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:02 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6266642073612063342E646D2E63632030302030310D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:01 AM: debug Payload is bfc sa c4.dm.t0c 64
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:01 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6266632073612063342E646D2E7430632036340D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:00 AM: debug Payload is bfb sa c4.dm.t0c 2f
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:00 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6266622073612063342E646D2E7430632032660D0A
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:00 AM: debug Payload is bfa sa c4.dm.b0c
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:24:00 AM: trace catchall: C25C 0001 C5 C5 0C40 00 043D 00 00 0000 35 00 6266612073612063342E646D2E6230630D
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:41:47 AM: debug Payload is aBc4:light_ip_control4:C4-DIM1-ZB03.06.16 !
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:41:47 AM: trace catchall: C25D 0001 02 02 0440 00 043D 00 00 0000 0A 01 0700421E63343A6C696768745F69705F636F6E74726F6C343A43342D44494D312D5A0400420830332E30362E3136050020050600211E00
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:40:48 AM: debug Payload is A(￁ !
!X !X
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:40:48 AM: trace catchall: C25D 0001 02 02 0440 00 043D 00 00 0000 0A 01 120041020000130028C1000020020100210A000200215802030020000B002158020C002013
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:39:47 AM: debug Payload is aBc4:light_ip_control4:C4-DIM1-ZB03.06.16 !
cdccfeef-4d41-4c88-994a-75c18ce416b8 12:39:47 AM: trace catchall: C25D 0001 02 02 0440 00 043D 00 00 0000 0A 01 0700421E63343A6C696768745F69705F636F6E74726F6C343A43342D44494D312D5A0400420830332E30362E3136050020050600211E00

I will update the github tonight with a new device code

So what is all required to get to the point you are today? A smartthings hub and zigbee controller? Along with some dimmers and keypads and things from Control4? I have access to Composer and ability to install drivers. Would love to help in whatever way possible.

@Chellis_Dodge, I put new code up, but I think the issue is it didn’t register the device endpoint, this might be a pairing issue with SmartThings. Make sure you have the latest zigbee firmware from support. I couldn’t get Control4 to work until I was upgraded to the same version that the GE wink bulbs requires.

@Tucan,

Not sure the question… You need a SmartThings hub which has a zigbee controller in it. Pair it with any device, ie Control4 dimmer or keypad, or switch, etc.

They pair, but then you have to figure out the endpoints, packets, commands, etc.

No need to use Composer or install drivers. Integrating SmartThings with Control4 would either require a driver to be developed for Control4 and/or two way local IP support for the hub to poll and query Control4 to get the project and device status and send changes…

Just an update the hub and zigbee firmware update solved the problem, your code worked for a C4DIM1-Z-WH switch. Thanks Patrick well done.

Thanks for creating this device!

What’s the process to pair the C4 dimmer with SmartThings? Do I need to disconnect the device from C4? What do I do next?

Thanks!

OK, think I got it. Need to disconnect from C4. Then try to add a new device on the app and hit the top of the C4 four times for pairing. then go and update the device in the development tools with name and proper type

Great work …I have been able to get 1 switch and 1 dimmer to connect to ST…my question is how would i get it to poll the switch to see what its state is…as of now when the light is manually turned on or off it is not reflected in the application…

to make sure i did it correct all i did was disconnect from the c4 mesh and connected to ST came up as unkown… thing went into developer modual and labeled it as dimmer or switch and set it as type ge link bulb and then it worked from app but again does not update state…thanks for your work!