Python-based IP150 interrogator that publishes data and subscribes to control commands to and from an MQTT broker, without using a headless browser.
NB: This is still a very early release and has its bugs
Another version of this script (using the software port & also has access to alarm outputs (PGMs)) is available in my ParadoxIP150v2 repository. Tested only with MG5050 V4, for other variants I hope the community will assist with PRs.
- Tested with Python 2.7.10
- Download the files in this repository and place it in some directory
- Edit the config.ini file to match your setup
- Run the script: Python IP150-MQTT.py
If successfully connected to your IP150 and MQTT broker, the app will start off by publishing all current zone and partition statuses. The following topics are available (and their names are configurable in the config.ini file):
- Zone Statuses:
- Topic: Paradox/ZS/Z1
- (ZS = Zone Statuses; Z = Zone; followed by the number that has changed)
- Payload (example): S:OPEN,P:1,N:"Front PIR"
- (S = Status: OPEN / CLOSE (configurable in the config.ini file); P = Partition number, followed by the zone name)
- Alarm Statuses:
- Topic: Paradox/AS/P1
- (AS = Alarm Status (Arm, Disarm, etc.); P = Partition, followed by the partition number)
- Payload (example): Disarmed
- (Possible states = Disarm, Arm, Sleep, Stay, Unsure)
- Siren status:
- Topic: Paradox/SS
- (SS = Siren Status)
- Payload: ?
- This is still being tested as its a bit problematic with having neighbours. If this message is published there's been some activity with your siren. Deliberately set off the siren to determine what the payload is under different situations.
- Controlling the alarm
- Publish the following topic to control the alarm:
- Paradox/C/P1/Disarm
- (C = Control; P = Partition, followed by number; Then the action = Disarm / Arm / Sleep / Stay)
- The payload is not evaluated
- Publish the following topic to control the alarm:
- Controlling this application
- Publish the following topics to enable/disable polling of the IP module:
- Paradox/C/Polling/Enable
- Paradox/C/Polling/Disable
- The payload is not evaluated.
- Publish the following topics to enable/disable polling of the IP module:
Note: If you modified the subscription topic for controls in the config.ini file ensure it ends with a '/'.
( thanks @Rtaxerxes )
If you want to run this as a daemon on Mac,
- Create a file called local.paradox.plist.
- Copy and paste the below into the file, editing for the location of your files.
- Copy the file to /Library/LaunchDaemons/.
- Run it with: sudo launchctl load /Library/LaunchDaemons/local.paradox.plist
- Stop it with: sudo launchctl unload /Library/LaunchDaemons/local.paradox.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>local.paradox</string>
<key>WorkingDirectory</key>
<string>/(folder where files are)</string>
<key>ProgramArguments</key>
<array>
<string>/usr/bin/python</string>
<string>/(folder where files are)/IP150-MQTT.py</string>
</array>
<key>RunAtLoad</key>
<true/>
</dict>
</plist>