-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding device integrations #16
Comments
@Xorso I am currently working on an integration for alarm_control_panel and binary_sensor (for alarm system zones like doors, windows, motion). Please let me know what Control4 devices you have and are willing to work on. |
I also have an alarm system with some door and window sensors and a motion sensor (if you want any help testing or otherwise). Oh, and a door lock. Additionally I have some thermostats (Sensibo ones that have a direct HA integration but also some zigbee/control4 line voltage ones that control some small baseboard heaters). |
While I'm not a coder, I have a Control4 system that I can help with testing on. The main feature I'm looking for is the relays built into the EA3 that are used to switch garage doors, or sense reed switch states, etc. |
Hi everyone! The HACS integration https://github.com/lawtancool/hass-control4 has just been updated with alarm_control_panel and binary_sensor support. Please update and let me know how it goes. |
My alarm system showed up but I can’t seem to control it at all and it doesn’t seem to detect the armed state properly (stays disarmed even when I tried arming it from control4). I don’t see any of the door/window reed switch sensors or the motion sensor at all. Let me know if there is anything in particular that would be helpful. I probably won’t have time to dig into myself until at least the weekend. |
Are the binary sensors the relays in the EA? As far as I can tell nothing has changed after the update for me. |
@mellis Please try updating to HACS integration 1.1.1, then follow the new instructions in the README: https://github.com/lawtancool/hass-control4#additional-configuration-required-for-alarm-control-panel I'm not sure what's going on with the binary sensors on your system - was there anything in the logs? If not, I'll make an update so that the logs print out some useful info for debugging this. @Xesyliad The binary sensors are for contact/motion sensors from an alarm system. Relays aren't supported yet. |
@lawtancool so I attempted to configure it but it doesn’t seem to be detecting the state properly still and can’t seem to arm it. I’m guessing I used the wrong state names, do you know how I can get the correct ones? This information isn’t available through the C4 API? I can disarm the system now though which is progress :). I can probably fine some time to dig into it myself as well in the next few days I think. |
@mellis You can get the state names by trying to arm your system through the Control4 app. Type them into the config flow exactly as they appear in the app (case-sensitive, don't include an extra space on the end). The Control4 API does have a way to get a list of the state names, but doesn't tell us how they correspond to the Home Assistant states (ex. Stay in Control4 = Armed Home in HA). I'll see if I can make it so that there's a drop-down in the config flow so the user can choose from the list that Control4 gives us. |
Hmm okay, I tried updating the different state names again. I wasn't sure which to use for the last one, I also tried leaving it blank. After I did this I can "Arm Night" from the HA dashboard and it does correctly change the alarm systems state, however that isn't reflected in HA. Similarly if I change the state from Control4 it also doesn't see the state change. I did try reloading the integration and it then changed to an "unknown" armed state. I was then able to disarm it from HA, which did work but again the armed/disarmed state in HA did not update. I didn't notice anything in the log from the C4 integration. |
@mellis Can you send a screenshot of Home Assistant -> Developer Tools -> States so I can see the extra state attributes of your alarm control panel? |
@lawtancool here's what it looks like both disarmed and in night mode. |
@mellis Thanks for the screenshots! Please update to HACS integration version 1.1.5, which should solve those issues. After you update, please delete the Control4 integration and set it up again if you encounter any errors. It also adds a config flow field for "arm vacation mode name", so you can have all five of your alarm arming modes in HA. Also, I noticed that your system has |
@lawtancool Yeah, my system can be armed without the code. |
Seeing some errors in the log now from the integration after updating.
One about a binary sensor too.
|
@mellis I made a small mistake, please update to version 1.1.6. That should fix the alarm control panel. If you continue to have issues, please delete the Control4 configuration entry and set it up again. I'm not really sure what's going on with your binary sensors, as I've never seen that before on my system. I'll look into it and maybe push a version with more debug output so I can fix that. |
@mellis Please update to version 1.1.7. |
@lawtancool updated, this seems better. I have noticed it still shows the stated as "unknown" (but armed) when I switch it to the night mode. I haven't tested any of the other modes yet. |
@mellis You might need to delete the Control4 config entry and set it up again - all the updates might have messed up the configuration data. I'm not sure what you mean by "unknown" (but armed)? |
@lawtancool I tried deleting it and re-adding but it doesn't seem to have helped. Here's what I mean by armed but having a state "unknown" |
@mellis The integration detects the arm state by comparing the Can you send a screenshot of the drop down options you see in the config flow dialog? It would also be nice to know what the value of Also, are you able to arm the alarm from Home Assistant, or are you making the state changes through the Control4 app? If this issue persists, I might need to revert the drop down UI to a text entry field, so that the user can manually arm their system in each mode to figure out what |
Yeah, that was what I thought after peaking around the code a bit.
I dropped one earlier in this comment. I'll try and record the state of the entity for each arming type in control4 when I get a chance. Will have to be when no one else is home for some of them so I don't accidentally trigger it 😅.
Yup, after I set the config to the menu names I was able to arm the system from home assistant. It does display the away state correctly as well I happened to notice, so that one likely aligns with the menu option. I think it's mostly the night/stay modes that are different but I'll go through them all to check. I wonder if this is something specific to my setup or if this is something that is controllable with the dealer software 🤔. |
@lawtancool Okay I got a chance to try every alarm state. I captured the alarm panels state from the developer section of HA in each state as well as the exit delay states. I was asked for the code before entering some of the states (I noted which). Beginning in the "Disarmed" state
Began "Stay with no entry delay" (asked for code). Began exit delay of 120s
After exit delay countdown, Control4 state read "Armed Night".
Instant Stay
No entry delay (asked for code before arming). Began 120s countdown.
After exit delay countdown, Control4 state read "Armed Night"
Away. Began 60s countdown.
After 60s countdown, Control4 state read "Armed Away"
Stay, began 120s countdown
After 120s countdown, Control4 state read "Armed Night"
|
Hi, will there be any ongoing feature development on pyControl4 at all? There hasn't been any activity for quite a while. |
Hi, just to add another vote for extra C4 functionality. The light power usage data (whilst extensive) would be great for me. I have around 50 lighting circuits! Some of my lighting circuits are used to turn other devices on/off using a C4 non dimming lighting module as these can run devices up to 16A per pair of outputs. As such, I have 2 external garden heaters and a pool pump setup on these outputs. In C4 they have been configured to something other than a light so that they appear as a heater icon and pump icon, but they are in effect exactly the same as the lighting circuits in the same module. Im using the official C4 integration currently and these "other" switched devices are not shown, but all the lights from the same modules are. Is there a way that they can still be imported? Lastly, being able to trigger the relays for things like gates / garage doors would be a real bonus too. |
This issue is for discussion of efforts to add more device integrations to pyControl4/Home Assistant.
The text was updated successfully, but these errors were encountered: