Open amitfin opened 1 year ago
Not sure why tests were failing (Tox passes locally), but according to the log the failed test case seems unrelated to this change (not even ADM-CID): testSIA.test_parse_and_check[encrypted-altered_key-siadcs]
Regarding the errors in the tests:
This is the output of tox when running locally in the dev-environment (docker):
py38: SKIP (0.35 seconds)
py39: OK (46.80=setup[14.09]+cmd[32.71] seconds)
py310: OK (85.34=setup[52.08]+cmd[33.27] seconds)
py311: SKIP (0.02 seconds)
mypy: OK (36.20=setup[35.30]+cmd[0.91] seconds)
congratulations :) (168.93 seconds)
(devcontainer.json
was changed locally with "VARIANT": "3.10"
, so py310 will be executed. This is the verion which failed in the workflow).
Pima Force 144 alarm uses "ADM-CID" format.
407 Code
The alarm system has a mobile app PIMAlink 3.0 which can be used to arm and disarm the alarm system. When using the mobile app (and not the keypad), the alarm is sending event 407: "Remote arm/disarm":
2023-09-21 01:59:23.136 DEBUG (MainThread) [pysiaalarm.base_server] Incoming line: 7449003F"ADM-CID"0078R1L0#AAAA[#00AAAA|3407 01 001]_01:59:16,09-21-2023
408 Code
When using the keypad's "arm away" button, the alarm sends event 408: "Quick arm"
2023-10-04 13:26:45.185 DEBUG (MainThread) [pysiaalarm.base_server] Incoming line: 9B2F0041"ADM-CID"1285R1L0#AAAAAA[#AAAAAA|3408 01 000]_13:26:16,10-04-2023
(ADM-CID code can be found here).
Adding new mappings for events 407 & 408.
The updated mapping file was tested with our alarm system and it's working as expected. The state of the alarm entity is getting updated correctly.