Skip to content

Commit

Permalink
Merge branch 'master' into test
Browse files Browse the repository at this point in the history
  • Loading branch information
maragelis authored Jan 14, 2019
2 parents db81bfd + b7f95ed commit b121e2d
Show file tree
Hide file tree
Showing 6 changed files with 38 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .vscode/arduino.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{

"board": "esp8266:esp8266:huzzah",
"configuration": "CpuFrequency=80,VTable=flash,FlashSize=4M1M,LwIPVariant=v2mss536,Debug=Disabled,DebugLevel=None____,FlashErase=none,UploadSpeed=115200",
"sketch": "ParadoxAlarmSystem/ParadoxAlarmSystemOTA/ParadoxAlarmSystemOTA.ino",
"port": "COM5",
"output": "../ArduinoOutput"

}
2 changes: 2 additions & 0 deletions .vscode/c_cpp_properties.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"compilerPath": "/usr/bin/clang",
"cStandard": "c11",
"cppStandard": "c++17"

},
{
"name": "Win32",
Expand All @@ -35,6 +36,7 @@
"C:\\Users\\marag\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.4.2\\**"
],
"forcedInclude": []

}
],
"version": 4
Expand Down
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"files.associations": {

"array": "cpp",
"iterator": "cpp",
"string": "cpp",
Expand Down
10 changes: 10 additions & 0 deletions ParadoxAlarmSystem/ParadoxAlarmSystemOTA/ParadoxAlarmSystemOTA.ino
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@

#define mqtt_server "192.168.4.225"
#define mqtt_port "1883"

#define Hostname "paradoxdCTL" //not more than 15


#define paradoxRX 13
#define paradoxTX 15

Expand Down Expand Up @@ -435,31 +437,38 @@ void callback(char* topic, byte* payload, unsigned int length) {

byte getPanelCommand(String data){
byte retval=0x00;

data.toLowerCase();
if (data == "stay" || data=="0")
{

retval = Stay_Arm;

}

else if (data == "arm" || data=="1")
{
retval= Full_Arm;
}
else if (data == "sleep" || data=="2")

{

retval= Sleep_Arm;

}

else if (data == "disarm" || data == "3")

{

retval=Disarm;

}


else if (data == "bypass" || data == "10")

{

retval=Bypass;
Expand Down Expand Up @@ -488,6 +497,7 @@ byte getPanelCommand(String data){
retval=0x92;

}

else if (data == "disconnect" || data == "99")
{
retval=0x00;
Expand Down
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# ParadoxRs232toMqtt
First stable test version of v2 is ready https://github.com/maragelis/ParadoxRs232toMqtt/tree/test

Feel free to test the test branch, and contribute to dev branch.



This project uses a wemos esp8266 to read events of the serial bus of any Paradox alarm system and send it to Mqtt


Alarm system serial on wemos
paradoxTX gpio15 wemos d8
paradoxRX gpio13 wemos d7
Expand All @@ -9,6 +16,7 @@ This project uses a wemos esp8266 to read events of the serial bus of any Parado


Set Hassio flag to 1 for Home assistant see wiki (Home Assistant in V2)

The 37 byte message is broken down into a json message with "Event Group" and "Sub-group"
Expand Down Expand Up @@ -48,6 +56,7 @@ password is user 4 digit password

Command can be one of the following


arm,
disarm,
sleep,
Expand All @@ -68,3 +77,17 @@ Command can be one of the following
subcomand 1 panel voltage and battery data
all others send 0



20190104 Added wiki Node-red v2 flow

20190103 Added v2 test branch (stable working)

20180804 Wiki added Home Assistant Config (works with node-red)

20180721 Changed to user based password, use the same 4 digit code used on panel for control.



Continue reading wiki ....

Binary file added sp4000.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit b121e2d

Please sign in to comment.