Closed ufulu closed 6 years ago
Not ask to update? You mean your python-egardia package? I don't know... I have an hassbian-installation...I still update only home-assistant. This is 0.55.1 and python-egardia is 1.0.22.
Hmm, is the test.py necessary? I hadn't it configured... I thought it was an test file. By the way, it's configured now and if I run it the output was correct: 'DISARM'! It's also correct if my status is 'unknown' in homeassistant.
Hmm, OK, thanks for testing. At least there is no bug in the code in the python-egardia package. I will investigate a little further.
@fabaff do you know what might be going on here?
If the state is shown as UNKNOWN
in the frontend then the state in Home Assistant was set as None
. Often this means that HA was not able to retrieve the state.
@fabaff thanks - in what cases might HA not be able to retrieve the state?
@Daehnie you should have an info entry in the HA log (you will need to set the logging level of HA to include info) showing the status. Could you have a look and post the lines that say 'Egardia alarm status: X'? This will help us troubleshoot. Thanks.
@jeroenterheerdt This one? 2017-11-12 13:11:10 INFO (MainThread) [homeassistant.core] Bus:Handling <Event state_changed[L]: entity_id=sensor.egardia, old_state=<state sensor.egardia=unknown; friendly_name=Egardia Alarmanlage @ 2017-11-12T13:11:07.315511+01:00>, new_state=<state sensor.egardia=; icon=, friendly_name=Egardia Alarmanlage @ 2017-11-12T13:11:10.699689+01:00>>
No, you should see exactly the text above if you set logging to info.
2017-11-12 13:11:08 INFO (Thread-5) [pythonegardia.egardiadevice] Egardia alarm status: Disarm
This does not add up to the status shown as unknown in HA. Are you sure you saw this in the log when the alarm was shown as status unknown?
Yes, I'm sure... I'll send you a logfile after a fresh restart of HA.
@jeroenterheerdt Any news here?
Sorry really busy. Will try to have a look tomorrow.
I tried but I cannot reproduce the issue with the status set to unknown. The log seems identical to what I have in my development environment and the status of the Egardia alarm is shown as disarm directly after restarting. I cannot help here, there seems to be something off in your config.
Thats weird... Even an fresh installed Hassbian with only Egardia in the configuration doesn‘t work!
If you call the device status directly using postman what do you get then?
puh...I've installed postman now. Next I've to try to get the status of my Panel with postman. It's the first time that I use postman.
Ok. If I get the status of http://192.168.178.35/action/panelCondGet I became an unexpected error (JSON). My Raw-Values are: /-secure- { updates : { mode_a1 : "Disarm", mode_a2 : "Disarm", battery : "Normal", tamper : "Close", interference : "Normal", ac_activation : "Normal", rssi : "16", sig_gsm : "N/A" }, forms : { pcondform1 : { mode : "4", f_arm : "0" }, pcondform2 : { mode : "4", f_arm : "0" } } } /
Hmm...After reading the status with Postman I restarted my Egardia Panel. In Home Assistant my Device switched from 'Disarm' to 'unknown'... weird
Unfortunately I am not able to check it right now as I am working remotely. I will get back to you end of this week or during this weekend. Can you tell me the firmware version of your alarm panel?
FW: CTC-1718 1.1.8 1718D0EG04J
@Daehnie working through the support of the sensors I found a situation where I can reproduce you error, I might have found something. Will keep you posted.
Great news!!!
@Daehnie the new release of ha includes the fix. Please test it and let me know.
Yes, its fixed! Now I‘ve a status after restart!
@ufulu @Daehnie @MartinHjelmare and I have made changes to the egardia component so we do not need a separate egardiaserver any longer. Stay tuned for the new version of the component to make it your way through a HA update. Let me know if you run into any issues.
That is great news! Good job! Looking forward to it! Thank you.
Wow! Nice Job!!
@Daehnie @ufulu the new version is out - please stop and disable the egardiaserver using systemctl before updating home assistant.
@jeroenterheerdt Works out of the box with Gate-01!
I am making some progress with the support for sensors as you requested - problem is that also I have been getting rid of the separate egardiaserver
and adding GATE-03
support.... a little too much at once. Anyway, I am getting closer to adding sensor support :)
Hi @jeroenterheerdt, in the mean time this is my workaround to get the sensor info into HA: I use the following jsonrest custom component: and then this sensor Setup:
- platform: jsonrest
resource: http://192.168.39.37/action/deviceListGet
name: egardia_json
username: Redacted
password: !secret egardia
authentication: basic
verify_ssl: false
- platform: template
sensors:
fenster_bad_mitte:
value_template: '{{ states.sensor.egardia_json.attributes.senrows[2]["status"].title() }}'
friendly_name: 'Badfenster Mitte'
fenster_terrassentuer_mitte:
value_template: '{{ states.sensor.egardia_json.attributes.senrows[0]["status"].title() }}'
friendly_name: 'Terrassentür Mitte'
fenster_terrassentuer_rechts:
value_template: '{{ states.sensor.egardia_json.attributes.senrows[3]["status"].title() }}'
friendly_name: 'Terrassentür Rechts'
fenster_terrassentuer_rechts_seite:
value_template: '{{ states.sensor.egardia_json.attributes.senrows[1]["status"].title() }}'
friendly_name: 'Terrassentür Seite Rechts'
@ufulu thanks - I am curious to understand: does this reflect changes in real-time? So let's say you opened the Badfenster, does it show in HASS as Open?
Yes it does!
All, the PR for the changes have been approved, we should see the support for door contacts show up in HASS soon. Note that there will be a breaking change for this, so please re-read the docs carefully!
Yes! 0.65 is out! Can‘t wait to test it! Thanks everybody and especially you @jeroenterheerdt for all the work you put into this!
Enjoy and thanks
Hi, is it possible to read and the state of the egardia devices, linke if a given window or door is currently open or closed, see screenshot and send this information to home assistant?