This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Read fire panel sensors current state
#4
Try running this script and see if you get anything in the Logs tab. Check that the panel is configured to send events to RS232.
Code:
if not port then   port = require('serial').open('/dev/RS232', {     baudrate = 19200,   })   buf = {}   function logbuf()     local txt = table.concat(buf)     log(txt)     buf = {}   end end char, err = port:read(1, 1) if char then   if char == '\r' or char == '\n' then     if #buf > 0 then       logbuf()     end   else     buf[ #buf + 1 ] = char     if #buf == 100 then       logbuf()     end   end end
Reply


Messages In This Thread
RE: Read fire panel sensors current state - by admin - 25.01.2023, 07:38

Forum Jump: