Qolsys IQ Panel 2 and 3rd party integration

Sorry, been busy and just got the system set up officially. I’m worried that the panel crashing will alert the monitoring station. Anyone aware of if that is an alarm type state? Even if the panel is not armed? Will try to get some logs soon from AppDaemon.

It worked wonderfully. No issues receiving the triggered state. Node Red is set up to call a few cell phones and post to slack. Thanks for all your help!

@lando1577 I would imagine it would not call out if it crashes. I’ve also not had any crashing issues with the 9 panels we have.

I mentioned this earlier in the thread, but I’m continuing to have an issue lately where the info events just stop for no apparent reason. Then, hours later, when a command is sent to the panel, the following handled error shows up in the AppDaemon main log:

2021-06-21 06:44:27.296723 ERROR qolsys_panel: listen failed/stopped: (, OSError(22, 'Invalid argument'), )

Then, if a subsequent command is sent to the panel, the following unhandled exceptions occur in the python Error log:

2021-06-21 07:42:42.649831 WARNING qolsys_panel: ------------------------------------------------------------

NameError: name 'socket' is not defined
    except socket.error:
  File "/conf/apps/ad-qolsys/qolsys_requests.py", line 290, in __qolsys_arm__
    self.__qolsys_arm__(qolsys=self.qolsys, token=token, arming_type="disarm", partition_id=partition_id, usercode=usercode)
  File "/conf/apps/ad-qolsys/qolsys_requests.py", line 248, in mqtt_request_received
    funcref(args["event"], data, self.AD.events.sanitize_event_kwargs(app, args["kwargs"]))
  File "/usr/local/lib/python3.8/site-packages/appdaemon/threading.py", line 936, in worker
Traceback (most recent call last):

During handling of the above exception, another exception occurred:

BrokenPipeError: [Errno 32] Broken pipe
    return self._sslobj.write(data)
  File "/usr/local/lib/python3.8/ssl.py", line 1173, in send
    self._wrappedSocket.send(b'\n')
  File "/conf/apps/ad-qolsys/qolsys_socket.py", line 92, in send_to_socket
    qolsys.send_to_socket(armString)
  File "/conf/apps/ad-qolsys/qolsys_requests.py", line 289, in __qolsys_arm__
2021-06-21 07:42:42.649354 WARNING qolsys_panel: Traceback (most recent call last):
2021-06-21 07:42:42.627823 WARNING qolsys_panel: ------------------------------------------------------------

Restarting AppDaemon usually restores the panel connectivity immediately.

Since it doesn’t seem others are having this problem, it could be something unique about my setup, but I pretty much just run everything off of my Synology NAS via Docker (HA, AppDaemon, MQTT). This is the only portion of my setup that is unstable, but it’s also the only thing that uses AppDaemon and MQTT.

I think I will try various ways to reset the panel connection in the qolsys_panel app when it detects any of the issues above.

1 Like

@SuperMega I just made a few tweaks. Try 1.8.0.1 (it’s a beta release)… see if that works for you.

Thanks for taking a crack at this! I tried to load the code and it failed immediately with:

2021-06-22 15:53:48.983348 WARNING Error: ------------------------------------------------------------

SyntaxError: invalid syntax
    ^
    self._reset_socket()
  File "/conf/apps/ad-qolsys/qolsys_socket.py", line 130
    import qolsys_socket
  File "/conf/apps/ad-qolsys/qolsys_client.py", line 3, in 
  File "", line 219, in _call_with_frames_removed
  File "", line 848, in exec_module
  File "", line 671, in _load_unlocked
  File "", line 975, in _find_and_load_unlocked
  File "", line 991, in _find_and_load
  File "", line 1014, in _gcd_import
    return _bootstrap._gcd_import(name[level:], package, level)
  File "/usr/local/lib/python3.8/importlib/__init__.py", line 127, in import_module
    self.modules[module_name] = importlib.import_module(module_name)
  File "/usr/local/lib/python3.8/site-packages/appdaemon/app_management.py", line 755, in read_app
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    response = future.result()
  File "/usr/local/lib/python3.8/site-packages/appdaemon/utils.py", line 299, in run_in_executor
    await utils.run_in_executor(self, self.read_app, mod["name"], mod["reload"])
  File "/usr/local/lib/python3.8/site-packages/appdaemon/app_management.py", line 963, in check_app_updates
2021-06-22 15:53:48.982705 WARNING Error: Traceback (most recent call last):
2021-06-22 15:53:48.956736 WARNING Error: ------------------------------------------------------------
2021-06-22 15:53:48.955897 WARNING Error: Unexpected error loading module: /conf/apps/ad-qolsys/qolsys_client.py:
2021-06-22 15:53:48.954871 WARNING Error: ------------------------------------------------------------

My bad @SuperMega . Try 1.8.0.2.

Cool, working - thank you! I’ll let you know how it goes.

@crazeeeyez An update after having everything running for a bit. Currently I have four panels linked up to AppDaemon. After it ran for a few days three of my panels stopped connecting. AppDaemon log shows panel 2 connecting to socket:

2021-06-24 16:15:12.205922 INFO qolsys_panel_2: connecting to socket

but doesn’t report any more info for panel 2 or the others past that. Panel 1 is working good. Panel 1 is the panel that is physically on the same network as Home Assistant/AppDaemon. The others are on Site-To-Site networks which could be a part of the issue.
Panels 2 and 3 were working at one time though, which is the strange part.
I’m also wondering if it’s the panels that are refusing a connection, and if the panels would need to be rebooted. That would be slightly problematic as there isn’t a way that I’ve found so far to reboot the panel remotely.
I may also just try port forwarding the panels to see if AppDaemon will connect to them that way, I’m not fully confidant that will work however.
If needed I can likely run AppDaemon at each site and have each site publish to the MQTT server on the main network.

Yeah i get into that connecting to socket loop sometimes, too. I haven’t found a way around it… will dig in next week.

1 Like

Here’s my latest log info: QolsysLog - Pastebin.com
It has some errors in it, not sure if it might help you or not.

Ran for over 3 days without issue, then today I had to restart AppDaemon to restore functionality.

What is interesting is that we left the house twice for multiple hours yesterday, and on the first outing the log continued to be filled up with INFO events the entire time we were gone. However, on the second outing, the INFO log entries stopped very soon after the arming event at timestamp 17:11:40 and the socket appeared to be idle or not broadcasting while we were gone.

We returned at timestamp 21:36:00 and the disarm command to the alarm was successful, however, no response was received. This resulted in the alarm still appearing as “armed” in Home Assistant.

I later tried to disarm it via Home Assistant at timestamp 22:25:44 and got no response. This time, the alarm system did not respond to the command (but this could be because it was already disarmed).

2021-06-26 17:10:03.673466 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-06-26 17:10:03.777840 INFO qolsys_panel: Publishing to: mqtt-states/binary_sensor/guest_room_door/state, Payload: Closed
2021-06-26 17:11:40.156037 INFO qolsys_panel: event: ARM
2021-06-26 17:11:40.157454 INFO qolsys_panel: event: ARM, usercode: None, partition_id: 0, arm_type: away, instant: False
2021-06-26 17:11:40.158973 INFO qolsys_panel: armString: {'partition_id': '0', 'action': 'ARMING', 'arming_type': 'ARM_AWAY', 'version': 0, 'nonce': 'qolsys', 'source': 'C4', 'version_key': 1, 'source_key': 'C4', 'token': 'frnqwe'}
2021-06-26 17:11:40.666876 INFO qolsys_panel: publishing ARMING event to: qolsys/panel/alarming
2021-06-26 17:11:40.824979 INFO qolsys_panel: Got arming event: {'topic': 'qolsys/panel/alarming', 'wildcard': '#', 'payload': '{"event":"ARMING","arming_type":"EXIT_DELAY","delay":45,"partition_id":0,"version":1,"requestID":"97e7f148-0a81-4de6-9f4d-759680419daa"}\n'}
2021-06-26 17:11:40.827088 INFO qolsys_panel: event_name: MQTT_MESSAGE
2021-06-26 17:11:40.828708 INFO qolsys_panel: data: {'topic': 'qolsys/panel/alarming', 'wildcard': '#', 'payload': '{"event":"ARMING","arming_type":"EXIT_DELAY","delay":45,"partition_id":0,"version":1,"requestID":"97e7f148-0a81-4de6-9f4d-759680419daa"}\n'}
2021-06-26 17:11:40.830255 INFO qolsys_panel: kwargs: {'topic': 'qolsys/panel/alarming', '__thread_id': 'thread-0'}
2021-06-26 17:11:40.859460 INFO qolsys_panel: Partitions: {0: {"id": 0,"name": partition1,"status": arming,"entity_id": partition1,"code": 2408,"zones": {2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23}}
2021-06-26 17:11:40.860953 INFO qolsys_panel: Publishing to: mqtt-states/alarm_control_panel/qolsys/partition1/state, Payload: arming
2021-06-26 17:12:26.140363 INFO qolsys_panel: publishing ARMING event to: qolsys/panel/alarming
2021-06-26 17:12:26.854712 INFO qolsys_panel: Got arming event: {'topic': 'qolsys/panel/alarming', 'wildcard': '#', 'payload': '{"event":"ARMING","arming_type":"ARM_AWAY","partition_id":0,"version":1,"requestID":"4f685540-ee94-4475-935e-4dc3e34e49bb"}\n'}
2021-06-26 17:12:26.856128 INFO qolsys_panel: event_name: MQTT_MESSAGE
2021-06-26 17:12:26.857543 INFO qolsys_panel: data: {'topic': 'qolsys/panel/alarming', 'wildcard': '#', 'payload': '{"event":"ARMING","arming_type":"ARM_AWAY","partition_id":0,"version":1,"requestID":"4f685540-ee94-4475-935e-4dc3e34e49bb"}\n'}
2021-06-26 17:12:26.859174 INFO qolsys_panel: kwargs: {'topic': 'qolsys/panel/alarming', '__thread_id': 'thread-0'}
2021-06-26 17:12:26.863183 INFO qolsys_panel: Partitions: {0: {"id": 0,"name": partition1,"status": armed_away,"entity_id": partition1,"code": 2408,"zones": {2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23}}
2021-06-26 17:12:26.865045 INFO qolsys_panel: Publishing to: mqtt-states/alarm_control_panel/qolsys/partition1/state, Payload: armed_away
2021-06-26 17:19:20.536224 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-06-26 17:19:20.777586 INFO qolsys_panel: Publishing to: mqtt-states/binary_sensor/door_window_9/state, Payload: Closed
2021-06-26 17:19:40.118790 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-06-26 17:19:40.136878 INFO qolsys_panel: Publishing to: mqtt-states/binary_sensor/door_window_9/state, Payload: Closed
2021-06-26 17:20:15.655188 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-06-26 17:20:15.833914 INFO qolsys_panel: Publishing to: mqtt-states/binary_sensor/family_room_side/state, Payload: Closed
2021-06-26 17:20:28.778784 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-06-26 17:20:28.901880 INFO qolsys_panel: Publishing to: mqtt-states/binary_sensor/living_room_door/state, Payload: Closed
2021-06-26 17:20:36.321457 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-06-26 17:20:36.917932 INFO qolsys_panel: Publishing to: mqtt-states/binary_sensor/family_room_side/state, Payload: Closed
2021-06-26 17:20:44.242853 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-06-26 17:20:44.263893 INFO qolsys_panel: Publishing to: mqtt-states/binary_sensor/family_room_back/state, Payload: Closed
2021-06-26 21:36:00.483752 INFO qolsys_panel: event: DISARM
2021-06-26 21:36:00.510361 INFO qolsys_panel: event: DISARM, usercode: ****, partition_id: 0, arm_type: None, instant: False
2021-06-26 21:36:00.512042 INFO qolsys_panel: armString: {'partition_id': '0', 'action': 'ARMING', 'arming_type': 'DISARM', 'version': 0, 'nonce': 'qolsys', 'source': 'C4', 'version_key': 1, 'source_key': 'C4', 'token': 'frnqwe', 'usercode': '****'}
2021-06-26 22:25:44.439821 INFO qolsys_panel: event: DISARM
2021-06-26 22:25:44.447710 INFO qolsys_panel: event: DISARM, usercode: ****, partition_id: 0, arm_type: None, instant: False
2021-06-26 22:25:44.449478 INFO qolsys_panel: armString: {'partition_id': '0', 'action': 'ARMING', 'arming_type': 'DISARM', 'version': 0, 'nonce': 'qolsys', 'source': 'C4', 'version_key': 1, 'source_key': 'C4', 'token': 'frnqwe', 'usercode': '****'}
2021-06-26 22:28:13.423245 INFO AppDaemon: SIGTERM Received
2021-06-26 22:28:13.423830 INFO AppDaemon: AppDaemon is shutting down

All very strange, but I have noticed on a few occasions that the alarm panel “performs” a final request like this without a response before everything stops working and further inspection reveals that INFO events were no longer showing up in the log. I no longer got errors when sending commands to the non-responsive panel, but I still need to restart AppDaemon container entirely to get everything working again.

Hey folks,

After installing ad-qolsys via HACS, I did the ACL and other config changes noted above and can see mqtt publish events for sensors as they change, but there are no entities for these sensors in Home Assistant. Should entities be automatically created my sensors or do I need to create them myself somehow?

It should just work. What does the log tell you? If you subscribe to mqtt do you see the messages? Is auto discover turned on in HA MQTT?

I added mosquitto add-on and enabled the HA integration connecting to it. That integration has discovery on. When listening to topic “#” in the same integration, no messages appear when opening and closing doors.

Below is my current config and logs. It seems like ad-qolsys is recognizing the events, but not sending them via mqtt? Is that right?

mqtt config:
EDIT: The “Broker options” image below has incorrect configuration. See my reply below for what worked.
image
image

appdaemon.yaml

appdaemon:
  latitude: 52.379189
  longitude: 4.899431
  elevation: 2
  time_zone: Europe/Amsterdam
  plugins:
    HASS:
      type: hass
    MQTT:
      type: mqtt
      namespace: mqtt
      client_host: 192.168.X.Z
      client_port: 1883

ACL Setup info found here → addons/DOCS.md at e933cba5a457a492fec458dcb2629e9dbadeb569 · home-assistant/addons · GitHub
accesscontrollist:

topic readwrite #

apps.yaml

qolsys_panel:
  module: qolsys_client
  class: QolsysClient
  mqtt_namespace: mqtt
  qolsys_host: 192.168.X.Y2
  qolsys_token: ******
  request_topic: qolsys/requests # Optional
  qolsys_info_topic: qolsys/panel/info # Optional
  qolsys_zone_update_topic: qolsys/panel/zone_update # Optional
  qolsys_zone_event_topic: qolsys/panel/zone_event # Optional
  qolsys_alarming_event_topic: qolsys/panel/alarming # Optional
  qolsys_disarming_event_topic: qolsys/panel/disarm # Optional
  qolsys_disarm_code: ******
  qolsys_confirm_arm_code: False # Optional
  qolsys_confirm_disarm_code: False # Optional
  qolsys_arm_away_always_instant: False # Optional
  log_level: "DEBUG"

LOGS:

2021-07-08 02:48:53.875902 INFO AppDaemon: Python version is 3.8.10
2021-07-08 02:48:53.876227 INFO AppDaemon: Configuration read from: /config/appdaemon/appdaemon.yaml
2021-07-08 02:48:53.876575 INFO AppDaemon: Added log: AppDaemon
2021-07-08 02:48:53.876947 INFO AppDaemon: Added log: Error
2021-07-08 02:48:53.877308 INFO AppDaemon: Added log: Access
2021-07-08 02:48:53.877655 INFO AppDaemon: Added log: Diag
2021-07-08 02:48:57.427513 INFO AppDaemon: Loading Plugin HASS using class HassPlugin from module hassplugin
2021-07-08 02:49:08.853989 INFO HASS: HASS Plugin Initializing
2021-07-08 02:49:08.854330 INFO HASS: HASS Plugin initialization complete
2021-07-08 02:49:08.854743 INFO AppDaemon: Loading Plugin MQTT using class MqttPlugin from module mqttplugin
2021-07-08 02:49:11.864006 INFO MQTT: MQTT Plugin Initializing
2021-07-08 02:49:11.864278 INFO MQTT: Using 'mqtt-client/status' as Will Topic
2021-07-08 02:49:11.864543 INFO MQTT: Using 'mqtt-client/status' as Birth Topic
2021-07-08 02:49:11.864847 INFO MQTT: Using appdaemon_mqtt_client as Client ID
2021-07-08 02:49:11.865856 INFO AppDaemon: Initializing HTTP
2021-07-08 02:49:11.866286 INFO AppDaemon: Using 'ws' for event stream
2021-07-08 02:49:11.870120 INFO AppDaemon: Starting API
2021-07-08 02:49:11.872947 INFO AppDaemon: Starting Admin Interface
2021-07-08 02:49:11.873279 INFO AppDaemon: Starting Dashboards
2021-07-08 02:49:13.416126 INFO HASS: Connected to Home Assistant 2021.6.6
2021-07-08 02:49:13.420555 INFO MQTT: Connected to Broker at URL 192.168.X.Y:1883
2021-07-08 02:49:13.430181 INFO AppDaemon: Got initial state from namespace mqtt
2021-07-08 02:49:13.430537 INFO MQTT: MQTT Plugin initialization complete
2021-07-08 02:49:14.240013 INFO HASS: Evaluating startup conditions
2021-07-08 02:49:14.251134 INFO HASS: Startup condition met: hass state=RUNNING
2021-07-08 02:49:14.251477 INFO HASS: All startup conditions met
2021-07-08 02:49:14.268816 INFO AppDaemon: Got initial state from namespace default
2021-07-08 02:49:15.494985 INFO AppDaemon: App 'hello_world' added
2021-07-08 02:49:15.496088 INFO AppDaemon: App 'qolsys_panel' added
2021-07-08 02:49:15.496893 INFO AppDaemon: Found 2 total apps
2021-07-08 02:49:15.497350 INFO AppDaemon: Starting Apps with 2 workers and 2 pins
2021-07-08 02:49:15.498475 INFO AppDaemon: Running on port 5050
2021-07-08 02:49:16.504978 INFO AppDaemon: Scheduler running in realtime
2021-07-08 02:49:16.508678 INFO AppDaemon: Adding /config/appdaemon/apps to module import path
2021-07-08 02:49:16.509073 INFO AppDaemon: Adding /config/appdaemon/apps/ad-qolsys to module import path
2021-07-08 02:49:16.515264 INFO AppDaemon: Loading App Module: /config/appdaemon/apps/hello.py
2021-07-08 02:49:20.098407 WARNING AppDaemon: No app description found for: /config/appdaemon/apps/ad-qolsys/partition.py - ignoring
2021-07-08 02:49:20.100099 INFO AppDaemon: Loading App Module: /config/appdaemon/apps/ad-qolsys/qolsys_client.py
2021-07-08 02:49:24.335702 WARNING AppDaemon: No app description found for: /config/appdaemon/apps/ad-qolsys/qolsys_socket.py - ignoring
2021-07-08 02:49:24.337240 WARNING AppDaemon: No app description found for: /config/appdaemon/apps/ad-qolsys/door_window.py - ignoring
2021-07-08 02:49:24.338798 WARNING AppDaemon: No app description found for: /config/appdaemon/apps/ad-qolsys/qolsys_requests.py - ignoring
2021-07-08 02:49:24.340017 INFO AppDaemon: Initializing app hello_world using class HelloWorld from module hello
2021-07-08 02:49:24.343051 INFO AppDaemon: Initializing app qolsys_panel using class QolsysClient from module qolsys_client
2021-07-08 02:49:27.061948 INFO hello_world: Hello from AppDaemon
2021-07-08 02:49:27.063362 INFO hello_world: You are now ready to run Apps!
2021-07-08 02:49:27.162778 DEBUG qolsys_panel: qolsys_host: 192.168.X.Y2, qolsys_port: 12345, qolsys_token: ******, qolsys_timeout: 86400, request_topic: qolsys/requests
2021-07-08 02:49:27.164361 INFO qolsys_panel: Creating qolsys_socket
2021-07-08 02:49:27.166690 INFO qolsys_panel: wrapping socket
2021-07-08 02:49:28.728504 INFO qolsys_panel: connecting to socket
2021-07-08 02:49:37.572245 INFO qolsys_panel: Connected wrappedSocket: <ssl.SSLSocket fd=12, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=0, laddr=('172.30.33.1', 50052), raddr=('192.168.X.Y2', 12345)>
2021-07-08 02:49:37.574090 INFO qolsys_panel: Starting listener thread
2021-07-08 02:49:37.578404 INFO qolsys_panel: Previous message repeated 1 times
2021-07-08 02:49:37.578844 INFO qolsys_panel: starting listen
2021-07-08 02:49:37.579601 INFO qolsys_panel: started listener thread
2021-07-08 02:49:37.580566 INFO qolsys_panel: started listener
2021-07-08 02:49:37.581421 INFO qolsys_panel: QolSys Socket Created
2021-07-08 02:49:37.582266 INFO qolsys_panel: listener for requests topic: qolsys/requests
2021-07-08 02:49:37.584119 DEBUG qolsys_panel: call_service: mqtt/subscribe, {'namespace': 'mqtt', 'topic': 'qolsys/requests'}
2021-07-08 02:49:37.586278 DEBUG qolsys_panel: Calling listen_event for qolsys_panel
2021-07-08 02:49:37.588846 INFO qolsys_panel: listener for info topic: qolsys/panel/info
2021-07-08 02:49:37.589819 DEBUG qolsys_panel: call_service: mqtt/subscribe, {'namespace': 'mqtt', 'topic': 'qolsys/panel/info'}
2021-07-08 02:49:37.592137 DEBUG qolsys_panel: Calling listen_event for qolsys_panel
2021-07-08 02:49:37.593928 INFO qolsys_panel: listener for zone event topic: qolsys/panel/zone_event
2021-07-08 02:49:37.594722 DEBUG qolsys_panel: call_service: mqtt/subscribe, {'namespace': 'mqtt', 'topic': 'qolsys/panel/zone_event'}
2021-07-08 02:49:37.596340 DEBUG qolsys_panel: Calling listen_event for qolsys_panel
2021-07-08 02:49:37.597875 INFO qolsys_panel: listener for zone update topic: qolsys/panel/zone_update
2021-07-08 02:49:37.598619 DEBUG qolsys_panel: call_service: mqtt/subscribe, {'namespace': 'mqtt', 'topic': 'qolsys/panel/zone_update'}
2021-07-08 02:49:37.600577 DEBUG qolsys_panel: Calling listen_event for qolsys_panel
2021-07-08 02:49:37.602065 INFO qolsys_panel: listener for arming topic: qolsys/panel/alarming
2021-07-08 02:49:37.602746 DEBUG qolsys_panel: call_service: mqtt/subscribe, {'namespace': 'mqtt', 'topic': 'qolsys/panel/alarming'}
2021-07-08 02:49:37.604602 DEBUG qolsys_panel: Calling listen_event for qolsys_panel
2021-07-08 02:49:37.606767 INFO qolsys_panel: listner for triggered (ALARM) topic: qolsys/alarm/triggered
2021-07-08 02:49:37.607585 DEBUG qolsys_panel: call_service: mqtt/subscribe, {'namespace': 'mqtt', 'topic': 'qolsys/alarm/triggered'}
2021-07-08 02:49:37.609357 DEBUG qolsys_panel: Calling listen_event for qolsys_panel
2021-07-08 02:49:37.610249 DEBUG qolsys_panel: call_service: mqtt/publish, {'namespace': 'mqtt', 'topic': 'qolsys/requests', 'payload': '{"event": "INFO", "token": "******"}'}
2021-07-08 02:49:37.612220 INFO AppDaemon: App initialization complete
2021-07-08 02:51:01.959979 DEBUG qolsys_panel: data received from qolsys panel: {"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Closed","zone_id":1},"requestID":"f95aa09c-4796-44cc-8e90-a14ebd1ca8d8"}
 len(data): 157
2021-07-08 02:51:01.961434 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-07-08 02:51:01.962847 DEBUG qolsys_panel: data being published: {"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Closed","zone_id":1},"requestID":"f95aa09c-4796-44cc-8e90-a14ebd1ca8d8"}
2021-07-08 02:51:01.964196 DEBUG qolsys_panel: call_service: mqtt/publish, {'namespace': 'mqtt', 'topic': 'qolsys/panel/zone_event', 'payload': '{"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Closed","zone_id":1},"requestID":"f95aa09c-4796-44cc-8e90-a14ebd1ca8d8"}\n'}
2021-07-08 02:51:22.627500 DEBUG qolsys_panel: data received from qolsys panel: {"event":"ZONE_EVENT","zone_event_type":"ZONE_UPDATE","zone":{"id":"AD43AD","type":"Door_Window","name":"Front Door","group":"entryexitdelay","status":"Closed","state":"0","zone_id":1,"zone_physical_type":1,"zone_alarm_type":3,"zone_type":1,"partition_id":0},"version":1,"requestID":"0dd3eee7-908f-4103-bb7a-b06518c39d39"}
 len(data): 323
2021-07-08 02:51:22.629193 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-07-08 02:51:22.631089 DEBUG qolsys_panel: data being published: {"event":"ZONE_EVENT","zone_event_type":"ZONE_UPDATE","zone":{"id":"AD43AD","type":"Door_Window","name":"Front Door","group":"entryexitdelay","status":"Closed","state":"0","zone_id":1,"zone_physical_type":1,"zone_alarm_type":3,"zone_type":1,"partition_id":0},"version":1,"requestID":"0dd3eee7-908f-4103-bb7a-b06518c39d39"}
2021-07-08 02:51:22.632314 DEBUG qolsys_panel: call_service: mqtt/publish, {'namespace': 'mqtt', 'topic': 'qolsys/panel/zone_event', 'payload': '{"event":"ZONE_EVENT","zone_event_type":"ZONE_UPDATE","zone":{"id":"AD43AD","type":"Door_Window","name":"Front Door","group":"entryexitdelay","status":"Closed","state":"0","zone_id":1,"zone_physical_type":1,"zone_alarm_type":3,"zone_type":1,"partition_id":0},"version":1,"requestID":"0dd3eee7-908f-4103-bb7a-b06518c39d39"}\n'}
2021-07-08 02:51:57.144876 DEBUG qolsys_panel: data received from qolsys panel: {"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Open","zone_id":1},"requestID":"c8a42f5d-bedd-4055-a5c4-089d3e6c2e07"}
 len(data): 155
2021-07-08 02:51:57.145789 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-07-08 02:51:57.146776 DEBUG qolsys_panel: data being published: {"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Open","zone_id":1},"requestID":"c8a42f5d-bedd-4055-a5c4-089d3e6c2e07"}
2021-07-08 02:51:57.147559 DEBUG qolsys_panel: call_service: mqtt/publish, {'namespace': 'mqtt', 'topic': 'qolsys/panel/zone_event', 'payload': '{"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Open","zone_id":1},"requestID":"c8a42f5d-bedd-4055-a5c4-089d3e6c2e07"}\n'}
2021-07-08 02:51:59.479868 DEBUG qolsys_panel: data received from qolsys panel: {"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Closed","zone_id":1},"requestID":"de97b407-dee7-4c9d-af09-41b5434c87df"}
 len(data): 157
2021-07-08 02:51:59.480933 INFO qolsys_panel: publishing ZONE_EVENT event to: qolsys/panel/zone_event
2021-07-08 02:51:59.481972 DEBUG qolsys_panel: data being published: {"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Closed","zone_id":1},"requestID":"de97b407-dee7-4c9d-af09-41b5434c87df"}
2021-07-08 02:51:59.482955 DEBUG qolsys_panel: call_service: mqtt/publish, {'namespace': 'mqtt', 'topic': 'qolsys/panel/zone_event', 'payload': '{"event":"ZONE_EVENT","zone_event_type":"ZONE_ACTIVE","version":1,"zone":{"status":"Closed","zone_id":1},"requestID":"de97b407-dee7-4c9d-af09-41b5434c87df"}\n'}

I finally got the entities to show up, but everything is unavailable. Any suggestions? Also, I’m not sure how to add other alarm modes. I’m super new to MQTT stuff. I had to comment out “qolsys_port: 12345 # Optional” to stop seeing errors in the MQTT broker, as suggested earlier in this thread.

Another thing that may be an issue, my panel is running firmware 2.6.0 which I updated to manually, not sure what you guys are running but I hope that isn’t the cause of this problem

@DDragon everything looks right to me. It looks like it’s trying to publish your messages. However, I do see in your Broker options there’s a username and password. Is your MQTT broker setup as anonymous? I don’t see any credentials in your appdaemon config. When you listen to #, are you using any credentials?

Look at that. This is the mistake I made!

For anyone looking at this in the future, I originally tried to set up client_user and client_password in appdaemon.yaml but this didn’t work.

What did work was changing my mqtt integration to connect anonymously without any login info in appdaemon.yaml (the config I posted above).
image

Now the only device missing is my CO Detector. It looks like that doesn’t have a device class in ad-qolsys.

PR for CO Detector: Add co detector mapping by NathanMagnus · Pull Request #16 · roopesh/ad-qolsys · GitHub

I decided to start from scratch again, deleting the broker username and password seemed to work for me, except once again all my devices show as “unavailable” @crazeeeyez any idea what causes this? My config essentially matches DDragon’s above

One thing I forgot when updating my solution, I also noticed that my Mosquitto add-on configuration was missing the active: true flag. Below is what mine looks like:

logins: []
customize:
  active: true
  folder: mosquitto
certfile: fullchain.pem
keyfile: privkey.pem
require_certificate: false