[Deprecated] Lutron Caseta Connect V1.5

Hmm. The ipaddress module is part of the standard library and typically comes with the base python installation. You may just have a lean install. Try “pip install ipaddress” and then rerun the script

This is what I get when pushing the physical button:

f9d43c5f-9186-40b7-a914-300240e9d0b6 9:44:07 PM: info Status: 200
b749da79-b89c-4b99-b38d-d88ab25c30ed 9:44:07 PM: debug description is on/off: 0
b749da79-b89c-4b99-b38d-d88ab25c30ed 9:44:07 PM: debug description is read attr - raw: 58D1010B040A0B05290000, dni: 58D1, endpoint: 01, cluster: 0B04, size: 0A, attrId: 050b, encoding: 29, value: 0000
c3c4a39d-6bd1-4c6e-8aec-d1ec267e3de1 9:44:06 PM: debug Values received: [Body:[Button:2, Action:4
, Device:5]]
70bf152a-b25f-47d9-a9a6-6bc23f74c22e 9:44:06 PM: debug Telnet data with action: 4
70bf152a-b25f-47d9-a9a6-6bc23f74c22e 9:44:06 PM: debug getChildDevices(true), children=5
c3c4a39d-6bd1-4c6e-8aec-d1ec267e3de1 9:44:06 PM: debug [Body:[Button:2, Action:4
, Device:5]]
c3c4a39d-6bd1-4c6e-8aec-d1ec267e3de1 9:44:06 PM: debug [index:07, mac:B827EBB7D24F, headers:[content-length:59, connection:close, host:20.10.10.101:39500, content-type:application/json, post / http/1.1:null], body:{“Body”: {“Device”: “5”, “Action”: “4\r\n”, “Button”: “2”}}, header:POST / HTTP/1.1
Connection: close
Content-Length: 59
Content-Length: 59
Content-Type: application/json
Host: 20.10.10.101:39500, data:[Body:[Button:2, Action:4
, Device:5]], json:[Body:[Button:2, Action:4
, Device:5]]]
c3c4a39d-6bd1-4c6e-8aec-d1ec267e3de1 9:44:06 PM: debug Values received: [Body:[Button:2, Action:3
, Device:5]]
70bf152a-b25f-47d9-a9a6-6bc23f74c22e 9:44:06 PM: debug Telnet data with action: 3
70bf152a-b25f-47d9-a9a6-6bc23f74c22e 9:44:06 PM: debug getChildDevices(true), children=5
c3c4a39d-6bd1-4c6e-8aec-d1ec267e3de1 9:44:06 PM: debug [Body:[Button:2, Action:3
, Device:5]]
c3c4a39d-6bd1-4c6e-8aec-d1ec267e3de1 9:44:06 PM: debug [index:06, mac:B827EBB7D24F, headers:[content-length:59, connection:close, host:20.10.10.101:39500, content-type:application/json, post / http/1.1:null], body:{“Body”: {“Device”: “5”, “Action”: “3\r\n”, “Button”: “2”}}, header:POST / HTTP/1.1
Connection: close
Content-Length: 59
Content-Length: 59
Content-Type: application/json
Host: 20.10.10.101:39500, data:[Body:[Button:2, Action:3
, Device:5]], json:[Body:[Button:2, Action:3
, Device:5]]]

Here’s what I get when I push the button in the app:

gs
1ad753b7-f416-4dfd-9125-9993f238a727 9:46:05 PM: debug description is on/off: 0
b749da79-b89c-4b99-b38d-d88ab25c30ed 9:45:51 PM: debug description is read attr - raw: 58D1010B040A0B05295804, dni: 58D1, endpoint: 01, cluster: 0B04, size: 0A, attrId: 050b, encoding: 29, value: 0458
b749da79-b89c-4b99-b38d-d88ab25c30ed 9:45:50 PM: debug description is read attr - raw: 58D1010B040A0B0529BD03, dni: 58D1, endpoint: 01, cluster: 0B04, size: 0A, attrId: 050b, encoding: 29, value: 03bd
b749da79-b89c-4b99-b38d-d88ab25c30ed 9:45:48 PM: debug description is read attr - raw: 58D1010B040A0B05292200, dni: 58D1, endpoint: 01, cluster: 0B04, size: 0A, attrId: 050b, encoding: 29, value: 0022
c2b12c35-5fd6-4c6d-ba3e-179b753bf5d1 9:45:47 PM: debug updating TS
c2b12c35-5fd6-4c6d-ba3e-179b753bf5d1 9:45:47 PM: debug event from: Mini Shelf, value: on, source: DEVICE, description:
b749da79-b89c-4b99-b38d-d88ab25c30ed 9:45:47 PM: debug description is on/off: 1
b749da79-b89c-4b99-b38d-d88ab25c30ed 9:45:47 PM: debug description is catchall: 0104 0006 01 01 0140 00 58D1 00 00 0000 0B 01 0100
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: debug Found: false for notifications_2_pushed
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: debug toggle: [Mini Shelf] = [off]
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: debug Found: [Mini Shelf] for lights_2_pushed
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: debug executeHandlers: 2 - pushed
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: debug Found 1 events in past 3 seconds
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: debug button: {“buttonNumber”:2}, value: pushed
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: debug buttonEvent: button = pushed ({“buttonNumber”:2})
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: trace timeOk = true
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: trace daysOk = true
2ea13c93-dcf2-452e-8048-de4b7b4bbad8 9:45:47 PM: trace modeOk = true
5c2b52a6-f8fb-4df8-9d18-060a31b53a4d 9:45:47 PM: debug Living Room Remote button 2 was pushed
e4ee58dc-2349-4218-9280-d6974e5b8fbf 9:45:42 PM: debug Parse returned {{ linkText }} has left
7c3c7e84-4e38-435d-a10e-a9553a53bcd3 9:45:42 PM: debug Parse returned {{ linkText }} has arrived
ce373499-61a5-4bbb-a37c-e528592cf610 9:45:42 PM: debug Parse returned {{ linkText }} has arrived

I also had to manually install it. The script ran after I did.

Sorry, it is really had to tell what device is creating each of the logs. Can you show me what the output for just the Service Manager and then just the Pico Device when a button is pressed? Based on what you sent there, the button presses are being sent to ST as expected. It seems like they are somehow not making it to the actual device however and I am not certain why.

What do you mean manually install it?

I was referring to the ipaddress module for the manutal install.

Here are screenshots:

Everything there looks exactly as it should. You are sure you are using the right Pico? It is one you added during the smart app install? Not trying to ask stupid questions but I cannot see any reason why it isn’t working other than that…

Yup. It’s the right remote. I’ll keep poking at it tomorrow. I appreciate your fast responses!

I am very sorry I do not have a better answer. Maybe remove and readd the Pico and then setup the button controller app again?

I must comment that I love how the dimmers remember that the level it was at and next turn on sets it to the same level.
I love how homebridge integrated ST into HomeKit and now love that this bring my HomeKit devices to ST. Almost total integration barring a few door locks

2 Likes

I was able to get it up and running. One thing that i did that was causing problem for me is I was coping and pasting from my old LutronPi.py file and the order is switched in the new one. My bad should have read rather then just blindly cut and paste. It is working great thank you for all your work.

Now just debating on weather the pro is worth it.

2 Likes

good to know I wasn’t going blind when I couldn’t find the combo. :wink: I’ve set up a search on ebay and maybe a pro will pop up cheap soon. I don’t really need the pico support (especially with minimotes so cheap) but it’d sure be nice.

As far as the pro goes, there are really two things it can give you. The first is the ability to use your PICO’s to control ST devices. They can essentially be used just like a Aeon minimote or similar controller. If you have a bunch of them laying around like I do it can be a pretty useful and relatively cheap option compared to buying other minimotes.

The other thing that is possible, although I haven’t added it yet, is the ability to adjust ramp rates. By that I mean the ability to adjust the level of a light over a set amount of time. So for example you could tell your bedroom lights to gradually turn on over 10 minutes maybe. That sort of thing. The capability is there with the Pro hub, I just haven’t completely figured out how to implement it yet. When I say implement it, I mean more on the ST side of things. It will be relatively trivial to add the functionality, but I am not sure how to set it on a case by case basis yet. It is something I plan to look into more over time.

It was a bad remote! We have another one that we actually use in a 3-way setup. I tried setting that one up instead and it totally worked. So we are swapping them since the bad one works just fine controlling Lutron stuff. I really appreciate your help.

1 Like

I’d like to setup a watchdog for this running under Windows. The process has hit an unhandled exception a few times which gets annoying when coupled with motion sensors. Is there an http challenge or something I can use to know the process has failed or is no longer processing correctly?

Hmm…I am not sure exactly. Can you give me more info on the unhandled exception thing? I have not had that problem, but I don’t run it on Windows so I dunno. Maybe there is an exception I can handle that will prevent it from crashing on you?

You could try running it as a service if you are having this problem frequently. Perhaps the service will crash when you hit the exception if that’s the case you can have it auto-restart. If it doesn’t bring down the service (so restart options don’t work) you could have a script that restarts the service - either based on time or more intelligently checking for functionality…

I’m not running it in windows, so these are just off the wall suggestions that I have not tried.

1 Like

@njschwartz have you considered closing out the Beta thread so you aren’t fielding questions in 2 separate threads?

About 2 months ago I purchased a Raspberry Pi, a single Caseta dimmer and a Pico with the plan of using this solution around my house if it worked well. A few days later, the official integration was announced, so I put this aside. In the mean time, I replaced about 5 more dimmers around my house with Caseta dimmers.

Today, I got impatient and got this all up and running - couldn’t wait any longer for SmartThings.

I also ran into the ipaddress module issue when I was installing. I needed to do a ‘sudo pip install ipaddress’ to get it to work, in case that helps anyone else for whom it didn’t work with just the ‘pip install ipaddress’

Initially, I put the IP addresses at the bottom of the code since that’s where they were originally when I first set this up. After that didn’t work, I realized those lines were commented out and I needed to add the IP addresses on lines 32 & 33 near the top. Then, everything worked like a charm!

Thank you to @njschwartz for such a great contribution to the community!

1 Like

Can I do that? lol I have been thinking it is a bit of a pain but didn’t know I could. Let me see,

Glad you got it working. I will add that line about the ipaddress thing to the instructions above since it seems like pretty much everyone is running into that. Let us know if you have any issues and enjoy!