{}

Our Brands

Impact-Company-Logo-English Black-01-177x54

Welcome to the Schneider Electric Website

Welcome to our website.
How can we help you today?
How can I receive Data from Hyper Terminal to a Magelis HMI using Script Driver?

Here is a sample script to receive Data from Hyper Terminal to a Magelis HMI using Script Driver:

// 1. Create script variables

// For reading messages from hyperterminal

int result;

byte readArray[]= new byte[20];

// 2. Read data from serial port

result = HyperTerminal.read(0, 20, readArray);

if (result <= 0)              // Check for error

ReadText.write("ERROR"); // Write to variable

else

{

// Convert byte array to String

String temp = new String( readArray );

ReadText.write(temp);

}

Schneider Electric India

Explore more
Range:
Articles that might be helpful Users group

Discuss this topic with experts

Visit our Community for first-hand insights from experts and peers on this topic and more.
Explore more
Range: