kk7ds / pynx584

Python library and server for talking to NX584/NX8E interfaces
GNU General Public License v3.0
29 stars 26 forks source link

CS375 (also 275 ad 575) serial port #54

Open choeflake opened 3 years ago

choeflake commented 3 years ago

The CS375/CS275 and CS375 have a serial port onboard. I tried to communicate using the pynx584 library.

First I started having trouble reading the serial port. After going to 2400 baud I can read the data. After buying a new serial-usb converter I could go to 4800.

It seems to to me that transmitting commands to the CSx75 does not work. But I do not understand why. When connected, I get only these output:

2021-04-09 19:43:50,551 controller DEBUG Parsing raw ASCII line '0B81352E33371200FA1FFFFC8397'
2021-04-09 19:43:50,551 controller DEBUG Received: 1 Interface Configuration (data [53, 46, 51, 55, 18, 0, 250, 31, 255, 252])
2021-04-09 19:43:53,062 controller DEBUG Parsing raw ASCII line '0B81352E33371200FA1FFFFC8397'
2021-04-09 19:43:53,062 controller DEBUG Received: 1 Interface Configuration (data [53, 46, 51, 55, 18, 0, 250, 31, 255, 252])
2021-04-09 19:43:55,557 controller DEBUG Parsing raw ASCII line 'B81352E33371200FA1FFFFC8397'
2021-04-09 19:43:55,558 controller DEBUG Received: 19 Reserved (data [82, 227, 51, 113, 32, 15, 161, 255, 255, 200])
2021-04-09 19:43:58,053 controller DEBUG Parsing raw ASCII line '0B81352E33371200FA1FFFFC8397'
2021-04-09 19:43:58,053 controller DEBUG Received: 1 Interface Configuration (data [53, 46, 51, 55, 18, 0, 250, 31, 255, 252])

The log starts with:

2021-04-09 19:41:54,043 controller DEBUG Sending queued [59, 21, 4, 9, 19, 41, 6]
2021-04-09 19:41:55,186 controller DEBUG Sending queued [35, 7]
2021-04-09 19:41:55,468 controller DEBUG Parsing raw ASCII line '0B81352E33371200FA1FFFFC8397'
2021-04-09 19:41:55,468 controller DEBUG Received: 1 Interface Configuration (data [53, 46, 51, 55, 18, 0, 250, 31, 255, 252])
2021-04-09 19:41:57,963 controller DEBUG Parsing raw ASCII line '0B81352E33371200FA1FFFFC8397'
2021-04-09 19:41:57,964 controller DEBUG Received: 1 Interface Configuration (data [53, 46, 51, 55, 18, 0, 250, 31, 255, 252])

Needless to say that arm/disarm does nothing. The log shows a 'sending queued', but no reponse.

gabeale commented 1 year ago

Hi, I'm having CS575 panel too with onboard RS232 port as well. I tested pynx584 program that has been successfully installed on Raspberry pi Zero that is connected to the panel through a USB to serial converter (see below reference)

https://www.amazon.it/gp/product/B01LY97ZM5/ref=ppx_yo_dt_b_asin_title_o08_s00?ie=UTF8&psc=1

Serial converter is working properly when Panel RS232 is set to "Printer" mode. See the following snapshot:

image

The other two options are: "Serial" and "Serial STU". The last one should be the proprietary PHAST protocol for which it is required additional hardware to get communicating.

I guess I have tried any combination to get pynx584 working, without success (see images below):

image

Zone status is always empty!

image

@choeflake How did you get the outputs you mentioned?