Under review

How to have a feedback in button using TCP/Telnet from the Server.

Tecnico Videosound 5 years ago updated by Vladimir Ovchinnikov (expert) 5 years ago 7 1 duplicate

Good Morning, 

i'm having this issue about Server and Telnet/TCP.

What i'm trying to do is to control a smart power socket with 4 ports (netio 4c) with buttons , all the input commands are ok but i need to receive a feedback (the light is on / the light is off). 

I'm controlling the socket via Telnet (using hex code).

Image 35804

The circled button should receive the feedback.

Image 35805

And this is the Server I/O config.

this is the command to get the port status (n.1 of 4) : 


Thank you, Samuele

Duplicates 1
Under review


Feedback from equipment controlled with the help of AV & Custom Systems, can be received only with the help of JavaScript. it is conditioned by the fact that the program does not know to which equipment it will connect in advance. So it cannot determine the format and type of data which can be received.


Ok, Thank you .

How can i read this kind of data via javascript?

I need to incorporate the script in the server.

I followed the guide but i can't find a solution

Use EVENT_RECEIVE_TEXT or EVENT_RECEIVE_DATA events. to receive data from the device. Then process and write to the desired feedbacks by the SetFeedback method.

This is so simple but the script doesn't work.

I want to set the value of the feedback channel at 1 if the listener receives data , 0 if it doesn't.

I solved the problem.

But another one appeared :

Now the feedback lights work but i can't differentiate the 4 sockets , so when i turn on socket n1 the feed light of n2 ,n3 , n4 also turn on.

I tryied sending from each socket his number (with command "ID") to the server ; 

using GetCommandAtName() for reading the number of the socket;

if() for accepting only the right number.

The problem is that the program seems to ignore the "if" condition.


You have a server project that uses the GetItem() method, which only works in a panel project. So you will never have an ID equal to "1" or "2".