Coder Social home page Coder Social logo

max-christian / homebridge-texecom Goto Github PK

View Code? Open in Web Editor NEW
27.0 10.0 8.0 278 KB

A plugin for homebridge (https://github.com/nfarina/homebridge) to integrate Texecom Premier Elite zones into HomeKit

License: MIT License

JavaScript 100.00%
homebridge-plugin homebridge homekit intruder-alarm alarm serial

homebridge-texecom's Introduction

homebridge-texecom

A plugin for Homebridge that creates HomeKit motion, contact, smoke, or carbon monoxide sensors for alarm zones from a Texecom Premier intruder alarm via a serial connection or COM-IP module. homebridge-texecom was originated by Kieran Jones.

See the armdisarm branch for arm/disarm via HomeKit (in progress as of August 2024).

You can receive notifications, which can be set to work only when you're away from home:

example of notifications

Another great use is to use the alarm's motion sensors to switch lights on automatically:

example of automation

You can also set automations to happen when you arm the alarm and when the alarm goes off.

IMPORTANT - To use this plugin you will require a Texecom alarm system and a PC-COM, COM-IP or USB-COM serial interface. If using the PC-COM or USB-COM, you must also have nothing already utilising COM1 on the alarm panel, or be able to move existing modules connected to COM1 to a different COM port on the alarm panel. The support for IP is new and is intended for use with the COM-IP -- we don't know if it works with the SmartCom, so let us know if you get it working.

Configuration

Texecom zones must be configured individually in the Homebridge config.json file with the appropriate zone number from Texecom. Configuring areas is optional, but is required if you want to see if the alarm if set or have automations or notifications when the alarm is armed, disarmed or triggered. You probably have many zones and only one area.

Example:

"platforms": [
    {
        "platform": "Texecom",
        "serial_device": "/dev/ttyUSB0",
        "baud_rate": 19200,
        "zones": [
            {
                "name": "Living Room",
                "zone_number": "7",
                "zone_type": "motion",
                "dwell": 1000
            },
            {
                "name": "Front Door",
                "zone_number": "15",
                "zone_type": "contact",
                "dwell": 1000
            }
        ],
        "areas": [
            {
                "name": "Texecom Alarm",
                "area_number": "1",
                "area_type": "securitysystem",
                "dwell": 0
            }
        ]
    }
]

Global Configuration

For serial connections:

Key Default Description
serial_device N/A The serial device on which to connect to Texecom
baud_rate N/A The baud rate configured in Texecom (Usually 19200)
zones N/A The individual configuration for each zone in Texecom

For IP connections:

Key Default Description
ip_address N/A The IP address of the COM-IP Texecom module
ip_port N/A The TCP port of the COM-IP Texecom module

Per-zone Configuration

This plugin is a platform plugin so you must configure each zone from your Texecom intruder alarm into your config individually.

Key Default Description
name N/A The name of the area as it will appear in HomeKit, e.g. 'Texecom Alarm'.
zone_number N/A The zone number from Texecom
zone_type "motion" The type of zone; motion, contact, smoke, or carbonmonoxide
dwell 0 The amount of time in ms that a zone stays active after zone activation is cleared by Texecom

Per-area Configuration

Key Default Description
name N/A The name of the sensor as it will appear in HomeKit.
area_number N/A The area number from Texecom, usually 1.
area_type "securitysystem" The type of area; only securitysystem is supported.
dwell 0

Configuring Texecom

Ensure your intruder alarm is fully configured and operational, connect a USB-Com or PC-Com cable to COM1 on the panel PCB and then connect to the computer running Homebridge.

To configure your COM1 port for the Crestron protocol:

  1. Enter your engineer code
  2. Scroll until you find "UDL/Digi Options"
  3. Press 8 to jump to "Com Port Setup"
  4. Scroll to "Com Port 1"
  5. Press "No" to edit the port
  6. Press 8 to jump to "Crestron System"
  7. Press "Yes" to confirm and save.

Press "Menu" repeatedly to exit the engineer menu.

If connecting to a COM-IP, set up the COM-IP as usual and ensure it is working. Then change the configuration for the port the COM-IP is connected to to Crestron as detailed above. This allows the panel to configure the IP address into the module, then changing to Crestron will allow the panel to input/output the correct commands.

Future features

Alarm systems are complicated and have a lot of features, not all them are suitable for integrating to HomeKit but many of them can be integrated.

  • Panic buttons - Investigate the possibility of integrating the medical, panic, and fire buttons into HomeKit as buttons/switches to manually trigger those alerts.

homebridge-texecom's People

Contributors

garethflowers avatar kieranmjones avatar max-christian avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

homebridge-texecom's Issues

Support Crestron over IP via ComIP

I'm implementing support for the ComIP in homebridge-texecom now. As with serial connections, the only protocol supported will initially be Crestron.

Texecom have provided the following instructions for enabling Crestron over ComIP. Presumably this prevents anything else working via the ComIP, but I've not tried it yet:

Crestron can be sent over IP providing the IP module is set up first as normal then the COM port on the panel is changed to Crestron.

This allows the panel to Configure the IP address into the module, then changing to Crestron will allow the panel to input/output the correct commands

New owner?

I'm afraid to announce that I will no longer be able to develop this plugin, I am moving home and my new home at least for now does not include a Texecom alarm nor do I think I am necessarily going to install one.

This is a great plugin though and I know people are getting some good use of it so I am hoping someone might be interested in taking it over. I am informed that I can transfer a repository to another user so if there are any volunteers then please let me know.

@max-christian might you be interested?

Show temperature of sensors

Hi I know it might not be possible but I was looking at the texecom connect app and it shows the temperature of each sensor it would be nice to be able to get that temperature in homebridge so the temperature of the room can be monitored.

Im having problem to make it work

Hi

Im having problem to make it work

Im running Homebridge v1.1.6 on Raspberry PI4,
texecom ELite24, v4

I Have installed the plugin, set all the zones as they are programmed in the panel, connected Raspberry PI to Elite24 via Com - Usb cable on the COM1 port of the panel.

PS should the com-usb cable be connected to the elite24 panel all time??????

I can see the Area and zones created in Homebridge, but i can not see the Pir or Doors
Contacts changing their states or status of the alarm state

Any ideas where im doing something wrong???????

Advise really appreciated

cheers Erick

Arm disarm via Homekit

I'm just wondering whether it is possible to arm and disarm the alarm via homebridge?

Not working with SmartCom

Hello, thanks for the update @max-christian I have upgraded from the COM IP to the SmartCom but this doesn't let me connect entering the IP.
If you're able to get this working with the SmartCom that would be amazing, if you need me to test anything that is not an issue.
It doesn't have to be IP with SmartCom and can use a Username/Password if that helps.

Raspberry Pi4 install

I'm not sure if this project has a new owner yet, but I'm having difficulty trying to install homebridge-texecom on a Raspberry Pi. I've tried several rebuilds and several version of the Raspberry Pi and it always fails when trying to install (through the Homebridge UI). The reason it fails appears to not being able to build SerialPort, I've tried installing SerialPort independently before trying to install homebridge-texecom but it continues to fail. Is it possible to install this on a Raspberry Pi?

I hoping to investigate getting this working with SmartCom.

Alarm system services - show intruder alarm status.

Hi,

Just wondered if you were making any progress on showing the alarm status (armed / disarmed).
That's the feature that I'm keen to get.
Would love to be able to use the "alarm set" as a way of knowing that we were all leaving the house.
Lights should turn off etc.

I can have a go at hacking it into your script myself, but I'd be winging it.
I considered faking it as a zone 101 or something and then capturing it with the "A" instead of the "Z" and adjusting it to an area number, but it seems a bit of a fudge !

So if you are already working on it, would rather wait for it to be done properly.

If I can offer any support / testing etc. please let me know.

I'm using your script through the Com-USB to a raspberry pi and it does work really well !

Thanks,
Bruce.

SIGTERM after IP connection closed

When using an IP address that fails to connect an unhandled error is sometimes raised which causes a SIGTERM (and restart) in Homebridge.

[6/30/2020, 12:24:06 AM] [Texecom] IP connection ended
[6/30/2020, 12:24:06 AM] [Texecom] IP connection closed
[6/30/2020, 12:24:06 AM] Error: connect EADDRNOTAVAIL 127.0.0.1 - Local (0.0.0.0:57855)
    at internalConnect (net.js:923:16)
    at defaultTriggerAsyncIdScope (internal/async_hooks.js:313:12)
    at GetAddrInfoReqWrap.emitLookup [as callback] (net.js:1063:9)
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:68:8)

Homebridge config.json

...
"platform": "Texecom",
"ip_address": "192.168.1.2",
"ip_port": 10001,
...

The error appears to be due to a network connection retry that is done on localhost.

Unable to install on Node 14

Running npm install --global homebridge-texecom@latest gives the following error:

> @serialport/[email protected] install /usr/local/lib/node_modules/homebridge-texecom/node_modules/@serialport/bindings
> prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild

prebuild-install WARN install No prebuilt binaries found (target=14.5.0 runtime=node arch=x64 libc= platform=darwin)
  CXX(target) Release/obj.target/bindings/src/serialport.o
../src/serialport.cpp:329:14: error: no matching member function for call to 'Set'
    results->Set(Nan::New<v8::String>("cts").ToLocalChecked(), Nan::New<v8::Boolean>(data->cts));
    ~~~~~~~~~^~~
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3666:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3669:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/serialport.cpp:330:14: error: no matching member function for call to 'Set'
    results->Set(Nan::New<v8::String>("dsr").ToLocalChecked(), Nan::New<v8::Boolean>(data->dsr));
    ~~~~~~~~~^~~
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3666:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3669:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/serialport.cpp:331:14: error: no matching member function for call to 'Set'
    results->Set(Nan::New<v8::String>("dcd").ToLocalChecked(), Nan::New<v8::Boolean>(data->dcd));
    ~~~~~~~~~^~~
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3666:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3669:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/serialport.cpp:378:14: error: no matching member function for call to 'Set'
    results->Set(Nan::New<v8::String>("baudRate").ToLocalChecked(), Nan::New<v8::Integer>(data->baudRate));
    ~~~~~~~~~^~~
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3666:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/testuser/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3669:37: note: candidate function not viable: requires 3 arguments, but 2 were
      provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
4 errors generated.
make: *** [Release/obj.target/bindings/src/serialport.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:314:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:276:12)
gyp ERR! System Darwin 17.7.0
gyp ERR! command "/usr/local/Cellar/node/14.5.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/homebridge-texecom/node_modules/@serialport/bindings
gyp ERR! node -v v14.5.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @serialport/[email protected] install: `prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 

Homebridge: v1.1.1
Node: v14.5.0
NPM: v6.14.5

Is there a way to map statuses against Homekit

At the moment when I part arm my system for the night, it's mapped to 'Away' on HomeKit, So I wanted to see if there's a way to map it to 'night' on HomeKit . I have yet to see what happens when the Alarm is on away mode.

Update: when the alarm is fully armed - it also shows as away mode

Crestron on COM Port 3

Hi,

Instructions state to use COM Port 1 for Crestron Protocol.

I have a SmartCOM that utilises COM 1/2 and a COMIP module in COM3

Is there a way to utilise COM3 or is this not possible?

Thanks

Alarm Triggered, but didn't trigger on homebridge...

Looking at the logs, this is what showed up:
[homebridge-texecom] This plugin generated a warning from the characteristic 'Security System Target State': characteristic was supplied illegal value: number 4 exceeded maximum of 3. See https://git.io/JtMGR for more info.

I'm pretty sure it used to work before.

Using home bridge v1.3.8 on node 17.0.1

Upgrade HOOBS to Ver 3.3.3 CONNECT not working

Hi After updating HOOBS to version 3.3.3 the plugin loads but sensor don't detect motion. Here is a copy of the log
3/2/2021, 10:48:21 AM [3/2/2021, 10:48:21 AM] Registering accessory 'homebridge-texecom.Texecom'
3/2/2021, 10:48:21 AM [3/2/2021, 10:48:21 AM] Registering platform 'homebridge-texecom.Texecom'
3/2/2021, 10:48:21 AM Loading 2 platforms...
3/2/2021, 10:48:21 AM [Texecom] Initializing Texecom platform...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Garage Pir'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Living Room Pir'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Dining Room Pir'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Kitchen Pir'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Upstairs Hall Pir'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Shed Pir'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Front Door'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Back Door'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Shed Window'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Garage Door'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Kitchen Window Left'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Kitchen Window Right'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Small Front Bedroom'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Downstairs'...
3/2/2021, 10:48:21 AM Initializing platform accessory 'Shed'...

Tried restarting services, tried rebooting HOOBS
Was making real progress for Example alarm armed turning of lights. Front Door Open and night switch on drive lights. Hopefully you can help

Issue with SerialPort interface

There seems to be an issue with the serialport support in the plugin.
I have tried multiple amends to the code but still get connection errors.
Happy to assist in testing if needed.

No messages on alarm activation

I'm getting the A, D, U and Z codes from my panel with a serial to USB lead hooked up to COM1 configured for crestron but I don't get the L code when the alarm is triggered. All I get is the Z for the zone that is active.

Does anyone know if this is something tat was added in a particular version of panel firmware or a config option? My panel is on v3.00 so very old.

I get the alert of the alarm triggering via SMS from my COM-GSM.

Any help greatfully appreciated.

Texecom ricochet

Hi , great plugin. I have a texecom ricochet alarm which uses the wireless sensors.
I have installed the plugin over ip with smartcom on port 1 and com ip on port 2 and the canines the settings on port 2 to Crestron.
When I open my front door the logs say data received from texecom (or similar) but nothing happens on my device. Is it due to the wireless ?

Cheers
Nath

Error during installation - @serialport/bindings

Install fails with the following error:

USER: xxxxxx
DIR: /usr/local/lib
CMD: npm install homebridge-texecom@latest

> @serialport/[email protected] install /usr/local/lib/node_modules/homebridge-texecom/node_modules/@serialport/bindings
> prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild

prebuild-install WARN install No prebuilt binaries found (target=13.13.0 runtime=node arch=x64 libc= platform=darwin)
  CXX(target) Release/obj.target/bindings/src/serialport.o
../src/serialport.cpp:329:14: error: no matching member function for call to
      'Set'
    results->Set(Nan::New<v8::String>("cts").ToLocalChecked(), Nan::New<...
    ~~~~~~~~~^~~
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3547:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3550:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/serialport.cpp:330:14: error: no matching member function for call to
      'Set'
    results->Set(Nan::New<v8::String>("dsr").ToLocalChecked(), Nan::New<...
    ~~~~~~~~~^~~
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3547:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3550:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/serialport.cpp:331:14: error: no matching member function for call to
      'Set'
    results->Set(Nan::New<v8::String>("dcd").ToLocalChecked(), Nan::New<...
    ~~~~~~~~~^~~
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3547:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3550:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/serialport.cpp:378:14: error: no matching member function for call to
      'Set'
    results->Set(Nan::New<v8::String>("baudRate").ToLocalChecked(), Nan:...
    ~~~~~~~~~^~~
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3547:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/xxxxxx/Library/Caches/node-gyp/13.13.0/include/node/v8.h:3550:37: note: 
      candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
4 errors generated.
make: *** [Release/obj.target/bindings/src/serialport.o] Error 1

Versions:

  • OS: macOS
  • Homebridge: 0.4.53
  • Node: 13.13.0
  • Npm 6.14.4

Send Key press Command #12

I'm using TCP connection to command and monitor Texecom and all works well except the send key press command. i.e. using this command to send 0x14 (Chime Key) receive an ACK to say the command is actioned, but it isn't! Anybody got this to work? Appologies if this seems a bit crypric to those without the API spec to hand.

Install error

When I want to install the plugin I get the following error message, I have Synology nas:

USER: root
DIR: /homebridge
CMD: npm --no-update-notifier install --unsafe-perm --save homebridge-texecom@latest

[email protected] install /homebridge/node_modules/serialport
prebuild-install || node-gyp rebuild

prebuild-install WARN install No prebuilt binaries found (target=10.15.1 runtime=node arch=x64 platform=linux)
make: Entering directory '/homebridge/node_modules/serialport/build'
CXX(target) Release/obj.target/serialport/src/serialport.o
../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Open(Nan::NAN_METHOD_ARGS_TYPE)':
../src/serialport.cpp:41:49: warning: 'v8::String::Utf8Value::Utf8Value(v8::Localv8::Value)' is deprecated: Use Isolate version [-Wdeprecated-declarations]
v8::String::Utf8Value path(info[0]->ToString());
^
In file included from /root/.node-gyp/10.15.1/include/node/v8.h:26:0,
from /root/.node-gyp/10.15.1/include/node/node.h:63,
from ../../nan/nan.h:53,
from ../src/./serialport.h:6,
from ../src/serialport.cpp:1:
/root/.node-gyp/10.15.1/include/node/v8.h:2892:28: note: declared here
explicit Utf8Value(Localv8::Value obj));
^
/root/.node-gyp/10.15.1/include/node/v8config.h:324:3: note: in definition of macro 'V8_DEPRECATED'
declarator attribute((deprecated(message)))
^~~~~~~~~~
../src/serialport.cpp:48:53: warning: 'v8::Localv8::Object v8::Value::ToObject() const' is deprecated: Use maybe version [-Wdeprecated-declarations]
v8::Localv8::Object options = info[1]->ToObject();
^
In file included from /root/.node-gyp/10.15.1/include/node/node.h:63:0,
from ../../nan/nan.h:53,
from ../src/./serialport.h:6,
from ../src/serialport.cpp:1:
/root/.node-gyp/10.15.1/include/node/v8.h:10046:15: note: declared here
Local Value::ToObject() const {
^~~~~
../src/serialport.cpp: In function 'void EIO_AfterOpen(uv_work_t*)':
../src/serialport.cpp:95:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(2, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Update(Nan::NAN_METHOD_ARGS_TYPE)':
../src/serialport.cpp:113:53: warning: 'v8::Localv8::Object v8::Value::ToObject() const' is deprecated: Use maybe version [-Wdeprecated-declarations]
v8::Localv8::Object options = info[1]->ToObject();
^
In file included from /root/.node-gyp/10.15.1/include/node/node.h:63:0,
from ../../nan/nan.h:53,
from ../src/./serialport.h:6,
from ../src/serialport.cpp:1:
/root/.node-gyp/10.15.1/include/node/v8.h:10046:15: note: declared here
Local Value::ToObject() const {
^~~~~
../src/serialport.cpp: In function 'void EIO_AfterUpdate(uv_work_t)':
../src/serialport.cpp:150:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(1, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
../src/serialport.cpp: In function 'void EIO_AfterClose(uv_work_t
)':
../src/serialport.cpp:188:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(1, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
../src/serialport.cpp: In function 'void EIO_AfterFlush(uv_work_t
)':
../src/serialport.cpp:231:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(1, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Set(Nan::NAN_METHOD_ARGS_TYPE)':
../src/serialport.cpp:250:53: warning: 'v8::Localv8::Object v8::Value::ToObject() const' is deprecated: Use maybe version [-Wdeprecated-declarations]
v8::Localv8::Object options = info[1]->ToObject();
^
In file included from /root/.node-gyp/10.15.1/include/node/node.h:63:0,
from ../../nan/nan.h:53,
from ../src/./serialport.h:6,
from ../src/serialport.cpp:1:
/root/.node-gyp/10.15.1/include/node/v8.h:10046:15: note: declared here
Local Value::ToObject() const {
^~~~~
../src/serialport.cpp: In function 'void EIO_AfterSet(uv_work_t)':
../src/serialport.cpp:285:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(1, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
../src/serialport.cpp: In function 'void EIO_AfterGet(uv_work_t
)':
../src/serialport.cpp:336:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(2, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
../src/serialport.cpp: In function 'void EIO_AfterGetBaudRate(uv_work_t
)':
../src/serialport.cpp:383:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(2, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
../src/serialport.cpp: In function 'void EIO_AfterDrain(uv_work_t
)':
../src/serialport.cpp:424:30: warning: 'v8::Localv8::Value Nan::Callback::Call(int, v8::Localv8::Value*) const' is deprecated [-Wdeprecated-declarations]
data->callback.Call(1, argv);
^
In file included from ../src/./serialport.h:6:0,
from ../src/serialport.cpp:1:
../../nan/nan.h:1674:3: note: declared here
Call(int argc, v8::Localv8::Value argv[]) const {
^~~~
CXX(target) Release/obj.target/serialport/src/serialport_unix.o
../src/serialport_unix.cpp:24:26: fatal error: linux/serial.h: No such file or directory

                      ^

compilation terminated.
make: *** [serialport.target.mk:104: Release/obj.target/serialport/src/serialport_unix.o] Error 1
make: Leaving directory '/homebridge/node_modules/serialport/build'
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:262:23)
gyp ERR! stack at ChildProcess.emit (events.js:189:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
gyp ERR! System Linux 4.4.59+
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /homebridge/node_modules/serialport
gyp ERR! node -v v10.15.1
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN homebridge No description
npm WARN homebridge No repository field.
npm WARN homebridge No license field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: prebuild-install || node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2019-03-04T17_56_09_350Z-debug.log

Command failed. Please review log for details

Not working due to corrupted/encoded data being received

After some playing around with Com ports on my Texecom I managed to get a copy of this plugin up and working - and it worked great!

But even since doing a reboot of Homebridge I'm seeing corrupted (or encoded?) data being received - instead of the usual "Z0010 style data. This means that none of my motion/contact sensors are detected anymore.

[7/3/2020, 9:38:41 AM] [Texecom] IP data received: e��b
[7/3/2020, 9:38:41 AM] [Texecom] Unknown string from Texecom: e��b
[7/3/2020, 9:38:43 AM] [Texecom] IP data received: Ȅ�b
[7/3/2020, 9:38:43 AM] [Texecom] Unknown string from Texecom: Ȅ�b
[7/3/2020, 9:40:45 AM] [Texecom] IP data received: 億b
[7/3/2020, 9:40:45 AM] [Texecom] Unknown string from Texecom: 億b
[7/3/2020, 9:40:46 AM] [Texecom] IP data received: ń�b
[7/3/2020, 9:40:46 AM] [Texecom] Unknown string from Texecom: ń�b
[7/3/2020, 9:40:51 AM] [Texecom] IP data received: 億b
[7/3/2020, 9:40:51 AM] [Texecom] Unknown string from Texecom: 億b
[7/3/2020, 9:40:52 AM] [Texecom] IP data received: ń�b
[7/3/2020, 9:40:52 AM] [Texecom] Unknown string from Texecom: ń�b

Any ideas why this dodgy data is being received?

Weird Issue with strings from Texecom

So Sometimes (rarely) i'll get an accepted command which comes through as ZXXX1 or ZXXX0, but most of the time texecom is sending a pre-fix as follows:

[8/1/2020, 6:40:45 PM] [Texecom] IP data received: t4w"Z0061

[8/1/2020, 6:40:45 PM] [Texecom] Unknown string from Texecom: t4w"Z0061

Which results in it not understanding which zone it is, most of the time it begins with a t but the 2nd & 3rd character is variabale. eg. t.2"Z0051.

Any Ideas?

SIGTERM when connected via USB-com

Hi
I thought i had got this working over IP, but it caused issues with the SmartCom. I am going back to USB-COM to see if i can then have both working.
I have connected the USB-COM to COM PORT 3 on the board and changed this to CRESTRON
When i then connect i get this in the log and then it restarts etc..

[Texecom] Initializing Texecom platform...
[10/2/2019, 4:37:26 PM] [Texecom] Computed SN fBK191r5BNet/7VqBhGrMI2GmMQ=
[10/2/2019, 4:37:26 PM] [Texecom] Initializing platform accessory 'Front Door'...
[10/2/2019, 4:37:26 PM] TypeError: serialport.parsers.readline is not a function
at TexecomPlatform.accessories (/usr/local/lib/node_modules/homebridge-texecom/index.js:112:32)
at Server._loadPlatformAccessories (/usr/local/lib/node_modules/homebridge/lib/server.js:403:20)
at Server._loadPlatforms (/usr/local/lib/node_modules/homebridge/lib/server.js:341:16)
at Server.run (/usr/local/lib/node_modules/homebridge/lib/server.js:90:36)
at module.exports (/usr/local/lib/node_modules/homebridge/lib/cli.js:59:10)
at Object. (/usr/local/lib/node_modules/homebridge/bin/homebridge:17:22)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:742:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)
[10/2/2019, 4:37:26 PM] Got SIGTERM, shutting down Homebridge...

Any ideas?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.