qolsys-controller 0.0.12__py3-none-any.whl → 0.0.14__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- qolsys_controller/database/table_sensor.py +5 -3
- qolsys_controller/partition.py +9 -0
- qolsys_controller/plugin_remote.py +14 -13
- {qolsys_controller-0.0.12.dist-info → qolsys_controller-0.0.14.dist-info}/METADATA +1 -1
- {qolsys_controller-0.0.12.dist-info → qolsys_controller-0.0.14.dist-info}/RECORD +7 -7
- {qolsys_controller-0.0.12.dist-info → qolsys_controller-0.0.14.dist-info}/WHEEL +0 -0
- {qolsys_controller-0.0.12.dist-info → qolsys_controller-0.0.14.dist-info}/licenses/LICENSE +0 -0
@@ -59,6 +59,7 @@ class QolsysTableSensor(QolsysTable):
|
|
59
59
|
"averagedBm",
|
60
60
|
"serial_number",
|
61
61
|
"extras",
|
62
|
+
"allowspeaker",
|
62
63
|
]
|
63
64
|
|
64
65
|
self._create_table()
|
@@ -70,9 +71,9 @@ class QolsysTableSensor(QolsysTable):
|
|
70
71
|
zone_two_way_voice_enabled, zone_reporting_enabled, battery_status,created_date,created_by,
|
71
72
|
updated_date,updated_by,frame_count,frame_type,current_capability,shortID,diag_24hr,
|
72
73
|
allowdisarming,device_capability,sub_type, signal_source, powerg_manufacture_id,parent_node,
|
73
|
-
latestdBm,averagedBm,serial_number,extras,ac_status)
|
74
|
+
latestdBm,averagedBm,serial_number,extras,ac_status,allowspeaker)
|
74
75
|
VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,
|
75
|
-
|
76
|
+
?,?,?,?,?,?,?,?,?,?,?,?)""", (
|
76
77
|
data.get("_id"),
|
77
78
|
data.get("version", ""),
|
78
79
|
data.get("opr", ""),
|
@@ -116,6 +117,7 @@ class QolsysTableSensor(QolsysTable):
|
|
116
117
|
data.get("averagedBm", ""),
|
117
118
|
data.get("serial_number", ""),
|
118
119
|
data.get("extras", ""),
|
119
|
-
data.get("ac_status", "")
|
120
|
+
data.get("ac_status", ""),
|
121
|
+
data.get("allowspeaker", "")))
|
120
122
|
|
121
123
|
self._db.commit()
|
qolsys_controller/partition.py
CHANGED
@@ -39,6 +39,7 @@ class QolsysPartition(QolsysObservable):
|
|
39
39
|
|
40
40
|
# Other
|
41
41
|
self._command_exit_sounds = True
|
42
|
+
self._command_silent_disarming = False
|
42
43
|
self._command_arm_stay_instant = True
|
43
44
|
|
44
45
|
@property
|
@@ -81,6 +82,14 @@ class QolsysPartition(QolsysObservable):
|
|
81
82
|
def command_arm_stay_instant(self) -> bool:
|
82
83
|
return self._command_arm_stay_instant
|
83
84
|
|
85
|
+
@property
|
86
|
+
def command_silent_disarming(self) -> bool:
|
87
|
+
return self._command_silent_disarming
|
88
|
+
|
89
|
+
@command_silent_disarming.setter
|
90
|
+
def command_silent_disarming(self, value: bool) -> None:
|
91
|
+
self._command_silent_disarming = value
|
92
|
+
|
84
93
|
@system_status.setter
|
85
94
|
def system_status(self, new_value: PartitionSystemStatus) -> None:
|
86
95
|
if self._system_status != new_value:
|
@@ -188,15 +188,15 @@ class QolsysPluginRemote(QolsysPlugin):
|
|
188
188
|
await self.aiomqtt.subscribe("iq2meid")
|
189
189
|
|
190
190
|
# Subscribte to MQTT commands response
|
191
|
-
await self.aiomqtt.subscribe("response_" + self.settings.random_mac, qos=
|
191
|
+
await self.aiomqtt.subscribe("response_" + self.settings.random_mac, qos=0)
|
192
192
|
|
193
193
|
# Only log mastermeid traffic for debug purposes
|
194
194
|
if self.log_mqtt_mesages:
|
195
195
|
# Subscribe to MQTT commands send to panel by other devices
|
196
|
-
await self.aiomqtt.subscribe("mastermeid", qos=
|
196
|
+
await self.aiomqtt.subscribe("mastermeid", qos=0)
|
197
197
|
|
198
198
|
# Subscribe to all topics
|
199
|
-
await self.aiomqtt.subscribe("#", qos=
|
199
|
+
#await self.aiomqtt.subscribe("#", qos=0)
|
200
200
|
|
201
201
|
# Start mqtt_listent_task and mqtt_ping_task
|
202
202
|
self._task_manager.cancel(self._mqtt_task_listen_label)
|
@@ -446,7 +446,7 @@ class QolsysPluginRemote(QolsysPlugin):
|
|
446
446
|
LOGGER.error("MQTT Client not configured")
|
447
447
|
raise QolsysMqttError
|
448
448
|
|
449
|
-
await self.aiomqtt.publish(topic=topic, payload=json.dumps(json_payload), qos=
|
449
|
+
await self.aiomqtt.publish(topic=topic, payload=json.dumps(json_payload), qos=0)
|
450
450
|
return await self._mqtt_command_queue.wait_for_response(request_id)
|
451
451
|
|
452
452
|
async def command_connect(self) -> dict:
|
@@ -733,7 +733,7 @@ class QolsysPluginRemote(QolsysPlugin):
|
|
733
733
|
LOGGER.debug("MQTT: Receiving pairing_request command")
|
734
734
|
return response
|
735
735
|
|
736
|
-
async def command_ui_delay(self, partition_id: str) -> None:
|
736
|
+
async def command_ui_delay(self, partition_id: str,silent_disarming:bool = False) -> None:
|
737
737
|
LOGGER.debug("MQTT: Sending ui_delay command")
|
738
738
|
|
739
739
|
# partition state needs to be sent for ui_delay to work
|
@@ -744,6 +744,7 @@ class QolsysPluginRemote(QolsysPlugin):
|
|
744
744
|
"panel_status": partition.system_status,
|
745
745
|
"userID": 0,
|
746
746
|
"partitionID": partition_id, # STR EXPECTED
|
747
|
+
"silentDisarming":silent_disarming,
|
747
748
|
"operation_source": 1,
|
748
749
|
"macAddress": self.settings.random_mac,
|
749
750
|
}
|
@@ -774,23 +775,21 @@ class QolsysPluginRemote(QolsysPlugin):
|
|
774
775
|
await self.send_command(topic, payload, requestID)
|
775
776
|
LOGGER.debug("MQTT: Receiving ui_delay command")
|
776
777
|
|
777
|
-
async def command_disarm(self, partition_id: str, user_code: str = "",
|
778
|
-
LOGGER.debug("MQTT: Sending disarm command - check_user_code:%s", self.check_user_code_on_disarm)
|
779
|
-
|
778
|
+
async def command_disarm(self, partition_id: str, user_code: str = "", silent_disarming: bool = False) -> bool:
|
780
779
|
partition = self.state.partition(partition_id)
|
781
780
|
if not partition:
|
782
781
|
LOGGER.debug("MQTT: disarm command error - Unknow Partition")
|
783
782
|
return False
|
784
783
|
|
785
784
|
# Do local user code verification
|
786
|
-
user_id =
|
785
|
+
user_id = 1
|
787
786
|
if self.check_user_code_on_disarm:
|
788
787
|
user_id = self.panel.check_user(user_code)
|
789
788
|
if user_id == -1:
|
790
789
|
LOGGER.debug("MQTT: disarm command error - user_code error")
|
791
790
|
return False
|
792
791
|
|
793
|
-
async def get_mqtt_disarm_command() -> str:
|
792
|
+
async def get_mqtt_disarm_command(silent_disarming:bool) -> str:
|
794
793
|
if partition.alarm_state == PartitionAlarmState.ALARM:
|
795
794
|
return "disarm_from_emergency"
|
796
795
|
if partition.system_status in {PartitionSystemStatus.ARM_AWAY_EXIT_DELAY,
|
@@ -800,18 +799,20 @@ class QolsysPluginRemote(QolsysPlugin):
|
|
800
799
|
if partition.system_status in {PartitionSystemStatus.ARM_AWAY,
|
801
800
|
PartitionSystemStatus.ARM_STAY,
|
802
801
|
PartitionSystemStatus.ARM_NIGHT}:
|
803
|
-
await self.command_ui_delay(partition_id)
|
802
|
+
await self.command_ui_delay(partition_id,silent_disarming)
|
804
803
|
return "disarm_the_panel_from_entry_delay"
|
804
|
+
|
805
805
|
return "disarm_from_openlearn_sensor"
|
806
806
|
|
807
|
-
mqtt_disarm_command = await get_mqtt_disarm_command()
|
807
|
+
mqtt_disarm_command = await get_mqtt_disarm_command(silent_disarming)
|
808
|
+
LOGGER.debug("MQTT: Sending disarm command - check_user_code:%s", self.check_user_code_on_disarm)
|
809
|
+
|
808
810
|
|
809
811
|
disarm_command = {
|
810
812
|
"operation_name": mqtt_disarm_command,
|
811
813
|
"userID": user_id,
|
812
814
|
"partitionID": int(partition_id), # INT EXPECTED
|
813
815
|
"operation_source": 1,
|
814
|
-
"disarm_exit_sounds": exit_sounds,
|
815
816
|
"macAddress": self.settings.random_mac,
|
816
817
|
}
|
817
818
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: qolsys-controller
|
3
|
-
Version: 0.0.
|
3
|
+
Version: 0.0.14
|
4
4
|
Summary: A Python module that emulates a virtual IQ Remote device, enabling full local control of a Qolsys IQ Panel
|
5
5
|
Project-URL: Homepage, https://github.com/EHylands/QolsysController
|
6
6
|
Project-URL: Issues, https://github.com/EHylands/QolsysController/issues
|
@@ -6,11 +6,11 @@ qolsys_controller/mdns.py,sha256=3_d-_K5Fyxc-2s0Fo1advTSpD72P369Hou1Ko0z__Ag,606
|
|
6
6
|
qolsys_controller/mqtt_command_queue.py,sha256=FjSbjK3_3SXV5eQPfQ-k8HOI5Tbu2aWzAxe4uXymK64,937
|
7
7
|
qolsys_controller/observable.py,sha256=X7uMnBHGpklPTa-RHKldXA0Rq38Cs1yOIuxl8ODeKV4,1049
|
8
8
|
qolsys_controller/panel.py,sha256=2EZtnA9c_yVSL3Vtszq9SLae9ykSuKrzIxssa6LoAvk,39370
|
9
|
-
qolsys_controller/partition.py,sha256
|
9
|
+
qolsys_controller/partition.py,sha256=k5aEAvF0r94DlZlDlcQnW7-lPWgIqJPA42fl3R2KoS4,8347
|
10
10
|
qolsys_controller/pki.py,sha256=_e0tiNF8Hypb37cHr7x8yqUZDaqbzRzP45AitTtmzk4,8663
|
11
11
|
qolsys_controller/plugin.py,sha256=Qh0irFbuw9R2QF3jOFTJw70ceVxK1ld5_sW7VnpOrA8,819
|
12
12
|
qolsys_controller/plugin_c4.py,sha256=71o5Y7Y13GO0vWCPIsCtpqXxrplryyqt8ua5L8F4StQ,382
|
13
|
-
qolsys_controller/plugin_remote.py,sha256=
|
13
|
+
qolsys_controller/plugin_remote.py,sha256=7si3gmUSRyFzombLcKFvC42uW6oASY3NNk9-qEAUPVY,37982
|
14
14
|
qolsys_controller/settings.py,sha256=2c8QLaEylpH2Wuol8EypYBIJhfniZXewb_54w8na2ts,5314
|
15
15
|
qolsys_controller/state.py,sha256=eWn4KiWN75K83CVW224zekDUeIpgjh9tDfnpaOJWV3I,14360
|
16
16
|
qolsys_controller/task_manager.py,sha256=IBFi1l9aId950wvRpvP6d4PHZhr3v1hnnt8NVulM3BI,1139
|
@@ -45,7 +45,7 @@ qolsys_controller/database/table_pgm_outputs.py,sha256=R-bvCLj5Kcl88ySFyDE4vfzI9
|
|
45
45
|
qolsys_controller/database/table_powerg_device.py,sha256=WEuFuak-OKnT7IbjvaZTP3fMZ67uD_W10tyo9nA7oGA,749
|
46
46
|
qolsys_controller/database/table_qolsyssettings.py,sha256=GqMOmhZP5JBOQhzKWJnlQK2f2zMsganIG119D6DpCao,1054
|
47
47
|
qolsys_controller/database/table_scene.py,sha256=zfiNXDJAxOwGAOmU6w5OvyflnP9bZhMc0eWVo2dZLJ4,1668
|
48
|
-
qolsys_controller/database/table_sensor.py,sha256=
|
48
|
+
qolsys_controller/database/table_sensor.py,sha256=KKsNu1zFVNvyLF-2Y-2Dkwks-8EVbnYmtwFi2Xx1_rs,4637
|
49
49
|
qolsys_controller/database/table_shades.py,sha256=p7wH5p6hYlDWag0hQwM7VcwbcoaB1x9KjEWBrhkboqc,723
|
50
50
|
qolsys_controller/database/table_smartsocket.py,sha256=J1jrAEHboasuedyJB8te9TO1zggNAZsq0VgnnyEdU8I,744
|
51
51
|
qolsys_controller/database/table_state.py,sha256=AIV5JiOp5pqc55WnaWdLrsmRtTSppMSSnc5v4W2nA3k,1141
|
@@ -60,7 +60,7 @@ qolsys_controller/database/table_zwave_association_group.py,sha256=S_tWpfzzD44rJ
|
|
60
60
|
qolsys_controller/database/table_zwave_history.py,sha256=4RiCzA_XFdXXVA9X48Z4eoxA_4DFKwdjkP2N6IHHOqQ,1897
|
61
61
|
qolsys_controller/database/table_zwave_node.py,sha256=csESJCkcg8qAPn3KSL4jO9b1oymZ5wrQiXcmWR9vSc0,7302
|
62
62
|
qolsys_controller/database/table_zwave_other.py,sha256=HJzLd4MUfNynE9jHiCzN7j1PFDncwQHeDkP5_8_s0YE,747
|
63
|
-
qolsys_controller-0.0.
|
64
|
-
qolsys_controller-0.0.
|
65
|
-
qolsys_controller-0.0.
|
66
|
-
qolsys_controller-0.0.
|
63
|
+
qolsys_controller-0.0.14.dist-info/METADATA,sha256=OaW7R-qhkfJwEGSNwKOEjgNrA-_qIftbmZv_meorZSs,4175
|
64
|
+
qolsys_controller-0.0.14.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
65
|
+
qolsys_controller-0.0.14.dist-info/licenses/LICENSE,sha256=GBHv9eggdA5ablDMW1xiLzGDZ2gCIhcKGW__c2aVIOc,1069
|
66
|
+
qolsys_controller-0.0.14.dist-info/RECORD,,
|
File without changes
|
File without changes
|