Search the Community
Showing results for tags 'tcp'.
When do I use the following code in lua:? tcpSocket:disconnect(); i some sample code it has been added to the sample in others not. example: -- Volume 40dB -- tcpSocket:write("MV40".."\r") fibaro:sleep(500); result, err = tcpSocket:read(); tcpSocket:disconnect(); if (err == 0) then fibaro:log("transfer OK"); fibaro:debug("transfer OK"); else fibaro:log("transfer failed"); fibaro:debug("transfer failed"); end ------------------------------------ -- HERE its not been used -- tcpSocket:write(string.char(0x53, 0x49, 0x49, 0x52, 0x41, 0x44, 0x49, 0x4f, 0x0d)); fibar
Hi, I`m novice in Fibaro and LUA I have some TCP device in my network transmits a txt data to custom TCP port on HC2 if some event happens (e.g. alarm) How I can always listen that TCP port on HC2 via LUA and start to a custom action in case the txt data appear on the port?
Hi, I tried to get messages from my alarm system Honeywell Vista 10. To connect to the alarm system I use AD2Pi installed on Raspberry Pi. On Raspberry Pi started ser2sock program that redirect messages from serial to tcp. On HC2 I created VD, in which I can arm/disarm alarm system. I just sent the code for disarming I created a scene to get messages from alarm system, but always I see error message: [DEBUG] 11:35:40: line 12: attempt to index global 'Net' (a nil value) --[[ %% properties %% events %% globals --]] loca