Amazing! Thanks! I don’t have Home Assistant yet so just needed to be sure I understood this correct
The only thing you have to do it type in the IP address and the port on Ajax HUB of your homeassistant so Ajax connects to HomeAssistant as a control central.
yeah that is perfect, I don’t want my alarm system controlled by HA exactly because of security considerations, just want to read status. And my system should arrive today!
I sorry for my English…I’m trying to setup mu Ajax hub whit home assistant but I receive this error
Setup failed for sia: Invalid config.
23:51 setup.py (ERROR)
Unable to import sia: No module named ‘sseclient’
23:51 config.py (ERROR)
this is my configuration
- name: casa
where the port is the port of my home assistant and it is configured in the surveillance station of Ajax app whit the ha ip and ha port.
can you help me please thank so much
Hi all, I’ve taken @CheaterDev s repo and set it up to work with HACS, so you can add the custom repo with this link: https://github.com/eavanvalkenburg/sia as an Integration, to get the component through the community store. I also plan to further develop the component since I now have an Ajax system, so feel free to put in issues and PRs there!
hi all, I’ve made some major updates to the component, same link as before, watch out because the config is very different as well. It now has the ability to specify zones with specific sensors in each (for instance if you have a zone with and without a smoke detector). But it will also auto-discover sensors once your system sends a message that is mapped to a particular type of sensor. The very least you get is a sensor.hubname_last_heartbeat which shows when the last RP messages came in, and it will put into the attributes YG messages. If there are other message types that should do something let me know of create an issue or PR in the repo. In the repo a doc with all SIA protocal messages is also present. Have fun!
A full config here:
sia: port: port hubs: - name: hubname account: account encryption_key: password zones: - zone: 1 name: zonename sensors: - alarm - moisture - smoke
Amazing stuff! Good work! I will test this out as soon as I can.
Hi, i don’t know where else to ask but i will give it a try here, i don’t have an ajax alarm home but in our office we do and is 100% compatible with a regional monitoring station to receive signals from the AJAX alarm using the SIA protocol. Is it possible from my home assistant by utilising the same protocol to connect to the monitoring station from my HA instance ? i am very happy with HA as alarm since i have every sensor imaginable integrated i just need an alert to the monitoring station if the alarm is triggered. sorry if i am way off topic.
Hi Eduard, this is great.
I got it to work and have the following ‘issues’
Each minute my log says:
“2019-09-26 21:11:56 ERROR (Thread-2) [custom_components.sia] subsection not found”
Any idea where this is coming from? I did at first not have any zones configured in the hub, but when I did and added the ‘zones’ part in the config, the issue persists, so that does not look related. Despite the ‘subsection not found’ it looks like is is working though.
When homebridge restarts it forgets the entity (alarm_control_panel.ajax_1_alarm in my case). The only way to have it available again is to ‘arm’ the system once. However the ‘smoke’ alarm sensor is also not listed. I do not plan to create a fire to get the entity
I did not had this issue with the ‘Cheaterdev/sia-ha’ version.
(encryption is anabled with 16 characters, and ping interval is set to 1 in the hub and ha config)
Hi @mandark, Thanks for trying it, I’ve been working on a major rebuild and that is in the Beta branch on github, that has a fix for the subsection error, but since I haven’t finished testing all the other improvements, no guaranteeL on other errors! I noticed in my own setup the same so I’ll have to look into that, but I’m traveling so want be able to do that until next week, prob Thursday.
Hi Eduard, I have installed the beta version, and added as a quick workaround for the second issue to the end of ‘def init(self, hass, hub_config)’ in the file “init.py” the following:
sensor_id = self._upsert_sensor(1, DEVICE_CLASS_ALARM) self._states[sensor_id].state = STATE_ALARM_DISARMED self._states[sensor_id].assume_available() sensor_id = self._upsert_sensor(1, DEVICE_CLASS_SMOKE) self._states[sensor_id].state = False self._states[sensor_id].assume_available()
(I do not have the flood sensor)
I think a more permanent solution would be to read the zone section from config file and set the default values of the defined sensors to their ‘clear’ states.
Hi @mandark and others, just released a new version, should have many fixes, and I’ve also improved the debug logging to make it a bit easier to track when something goes wrong. v0.2!
Hi everyone! It’s Cheater.dev here.
I’m really glad that someone took my work to improve.
I have not so much time to make this integration with such quality as @eavanvalkenburg did it. Also, this was my first attempt to python
As i’m using my integration from the beginning - i have an issue that i can’t understand how to properly fix: under heavy local network load on same machine(like torrents at 600+mbit/s) - something happens, and Ajax hub stops sending events and doesn’t reconnect. Only HA restart fixes the problem - so there is so strange code in my network acceptor code. Did anyone had same issue?
Also some people were saying to me that there is a opportunity to send back to Ajax hub some codes to change alarm state with ofiicial SIA API. I can’t find anything about that in documentation…
Dear @eavanvalkenburg , I installed your component using HACS: It works!
Ok, maybe I’m stupid or something but after installing this with minimal config I get the sensor.ajax_last_heartbeat. But nothing is added after that, even arming/disarming.
Edit: Ok so I am stupid, had the wrong IP in Ajax app so now it is updating heartbeat entity,
I don’t understand how to set up the full configuration - what is the zones? I don’t have any zones in HA and neither in Ajax. Is it the same as rooms? In Ajax app the Monitoring station reports “Not Connected”.
Edit: Still don’t understand the zones. Tried to randomly add zone 1 as in the example and now my hub and one of the smoke detectors show up.
After reboot home assistant, the alarm_control_panel state is always disarmed.
How to restore the real state ?
In my case I needed to install ‘sseclient’ manually to fix unable to import sia errors:
pip3 install sseclient
I’m using Home Assistant in a virtual environment on a Raspberry Pi.
@eavanvalkenburg kudos for your efforts! I see you are eager to respond and update the implementation, which is wonderful! After 1,5 years I finally have states from my AJAX system. Next to HA I also have a Homey which I can now populate with these states, awesome!
The Ajax alarm system has support for multiple zones. This means that you can split your alarm into different zones such as one for your home and another one for e.g. the garage. You can then control the alarm state independently for each zone so that the garage zone is armed but the home zone is disarmed. Everybody has at least one zone and since you do not know what zones are you probably only have one.
The original sia-ha code did not have support for multiple zones which meant that it didn’t work for everyone with more than one zone. Now we have the possibility to define how many zones we have which is great.
Hey everyone !
I plan to buy an alarm system that would be fully connected to Hass (only one way, I don’t want to be able to deactivate the alam from Hass). Ajax system looks nice, really nice, but I still have one hesitation.
Can you confirm me that currently you can not get access to the status of each individual Ajax sensor from Hass ? You can only have access to the zone status (enable, disable,alarm,… something like this) ?
Sorry to ask here, but does anybody have advice about a professional alarm system that would fit my needs and send immediately to Hass any update of any of its sensors ?
Confirmed. As far as I know there is no possibility to retrieve the individual status of each Ajax sensor. The SIA integration only gives access to the alarm status - armed, disarmed, night mode, fire alarm, leak alarm. However, the SIA integration cannot control the alarm in any way, just read status codes. This is good enough for most automation scenarios but I do miss the possibility to retrieve door sensors status to see if a door is opened or not, temperature data and to be able to use the alarm motion sensors to control lighting in HA etc.
The new OS Malevich 2.8 update that is coming out in the next few weeks will introduce more automation features but only for native Ajax devices such as Socket and Relay. It seems that Ajax do not want to expose the system for home automation using third party systems because of the security risk this imposes. I think that is an unfortunate decision since it could be done in a safe and controlled way. A simple local API or service that sends device status data to a predefined endpoint would be awesome and make Ajax an even greater and fully featured product.