Setting Variables Through The Network


Hi Guys,

We are trying to set variables through the network (Telnet) on EZ Builder, but we could not find a way to change the variables values.

Is there a way to alter variables or pass parameters to custom made scripts through the network?

Thanks Guys Grin


EZ-Builder is a Raw TCP Server and will accept and run valid EZ-script sentences:

First activate the server:
User-inserted image

Then i used a windows 10 telnet client:


telnet localhost 6666

User-inserted image
As you can see (EZ-Builder window):

I managed to change/create variables and i executed MyScript1



From EZ-Builder:
User-inserted image

bear in mind although EZ-Builder accepts Telnet clients is not a Telnet Server

Telnet is an old and well documented protocol:

and supports 7 bit clients, so when you make a connection both parties can negotiate the data transfer mode, the server can send you a data byte to negotiate or a client can actively start negotiating.

EZ-Builder is not a Telnet Server so will not start the negotiation neither will accept a client negotiation.

So if you use a full Telnet client like putty:
User-inserted image

and then you start sending ez-script statements:
User-inserted image

you will notice the first statement fails!

The reason is Putty (Telnet Client) engaged the Telnet Protocol negotiating by sending a control byte to the EZ-Builder Tcp Server.

EZ-Builder server waits for the End-Of-Line sequence to execute the EZ-Script statement.

So the first statement has unexpected data (telnet client control byte) and EZ-Builder will report an error.

You have few choices:
1) send some end-of-line sequences e.g. enter (CR/LF) characters before starting the EZ-Script statements. After the first statement all the other statements were successfully executed.

2) Use a passive negotiator Telnet Client e.g. Windows 10 Telnet. The client does not start telnet negotiating but will negotiate if the server starts the negotiation process.

2) use a RAW tcp client application or RAW mode (putty) when connecting to the EZ-Builder TCP Server.


Easiest way is to use http server:


Nothing beats a shell command Smile

Create a command file e.g. morning.txt


ControlCommand("Connection", Connect0)
SayEZBWait("Hey! Sleepy heads time to wake up !")
ControlCommand("Auto Position", AutoPositionAction, "Morning Dance")

and if you have putty with plink installed.


"C:\Program Files (x86)\PuTTY\plink" -batch -raw localhost -P 6666 < c:\scripts\morning.txt

1) because each statement is individually executed you can't use ez-script code structures e.g. If, Repeats, Goto etc.
2) As you can guess you will need to trigger another script to do the disconnect.