Help to undertsand an Intouch Application Script

a_rishi

Member
Join Date
Jul 2011
Location
Mauritius
Posts
12
Can someone give a clear explanation of the IOSetAccessName for an Intouch Application Script? - Thanking everyone in advance.

The setup is 1 No. PC for SCADA i.e. the Server and 4 Nos. HMI all link through a ring topology Fiber optic network.

I understand that at startup, Intouch reads the PC Name. If the PC name is Server.

What I don't understand is the IOSetAccessName( "PLC1_HF", OP1Name,"", ""). Why redirect to LCP1?

When the node name is not Server i.e. it is an HMI

The Application Script is as follows and set at Startup.

{*****************************************************************************************}

GetNodeName( NodeName, 131 );

ServerName = "Server"; {S majuscule obligatoire}
OP1Name = "LCP1";
OP2Name = "LCP2";
OP3Name = "LCP3";
OP4Name = "Lcp4";


IF NodeName == ServerName THEN
Server = 1;
{Activation access name API}
IOSetAccessName( "PLC1_HF", OP1Name,"", "");
IOSetAccessName( "PLC1_MF", OP1Name,"", "");
IOSetAccessName( "PLC1_LF", OP1Name,"", "");

IOSetAccessName( "PLC2_HF", OP2Name,"", "");
IOSetAccessName( "PLC2_MF", OP2Name,"", "");
IOSetAccessName( "PLC2_LF", OP2Name,"", "");

IOSetAccessName( "PLC3_HF", OP3Name,"", "");
IOSetAccessName( "PLC3_MF", OP3Name,"", "");
IOSetAccessName( "PLC3_LF", OP3Name,"", "");

IOSetAccessName( "PLC4_HF", OP4Name,"", "");
IOSetAccessName( "PLC4_MF", OP4Name,"", "");
IOSetAccessName( "PLC4_LF", OP4Name,"", "");


{Activation access name test OP Applicom card}
IOSetAccessName( "ApplicomOp1", OP1Name,"", "");
IOSetAccessName( "ApplicomOp2", OP2Name,"", "");
IOSetAccessName( "ApplicomOp3", OP3Name,"", "");
IOSetAccessName( "ApplicomOp4", OP4Name,"", "");


{Redirection tags to the server}
IOSetAccessName( "TgSrv", " ","", "");

LogMessage("********************************************This computer is the CONTROL ROOM INTOUCH VIEWER");

ELSE
Server=0;
{Desactivation access name API}

IOSetAccessName( "PLC1_HF", "","", " ");
IOSetAccessName( "PLC1_MF", "","", " ");
IOSetAccessName( "PLC1_LF", "","", " ");

IOSetAccessName( "PLC2_HF", "","", " ");
IOSetAccessName( "PLC2_MF", "","", " ");
IOSetAccessName( "PLC2_LF", "","", " ");

IOSetAccessName( "PLC3_HF", "","", " ");
IOSetAccessName( "PLC3_MF", "","", " ");
IOSetAccessName( "PLC3_LF", "","", " ");

IOSetAccessName( "PLC4_HF", "","", " ");
IOSetAccessName( "PLC4_MF", "","", " ");
IOSetAccessName( "PLC4_LF", "","", " ");



{Desactivation acces name test OP Applicom card}
IOSetAccessName( "ApplicomOp1", OP1Name,"", " ");
IOSetAccessName( "ApplicomOp2", OP2Name,"", " ");
IOSetAccessName( "ApplicomOp3", OP3Name,"", " ");
IOSetAccessName( "ApplicomOp4", OP4Name,"", " ");


{Redirection tags to the server}
IOSetAccessName( "TgSrv", "","", "");

LogMessage("********************************************This computer is a LOCAL INTOUCH VIEWER");

LogMessage("********************************************This LOCAL INTOUCH VIEWER read datas in the CONTROL ROOM INTOUCH VIEWER");

ENDIF;

{Initialisation node name of acces name}
IOSetAccessName( "Intouch", ServerName,"", "");

{*****************************************************************************************}

CONDITION SCRIPT

{ ------------------------ DEGRADE MODE : OP USE BD LOCAL (ITS BD) ---------------------------------}
IF Server == 0 THEN
{Redirection tags to the OP}
IOSetAccessName( "TgSrv", NodeName,"", "");

IF NodeName == OP1Name THEN
{Activation access name API}
IOSetAccessName( "PLC1_HF", " ","", "PLC1_HF");
IOSetAccessName( "PLC1_MF", " ","", "PLC1_MF");
IOSetAccessName( "PLC1_LF", " ","", "PLC1_LF");
ENDIF;

IF NodeName == OP2Name THEN
IOSetAccessName( "PLC2_HF", " ","", "PLC2_HF");
IOSetAccessName( "PLC2_MF", " ","", "PLC2_MF");
IOSetAccessName( "PLC2_LF", " ","", "PLC2_LF");
ENDIF;

IF NodeName == OP3Name THEN
IOSetAccessName( "PLC3_HF", " ","", "PLC3_HF");
IOSetAccessName( "PLC3_MF", " ","", "PLC3_MF");
IOSetAccessName( "PLC3_LF", " ","", "PLC3_LF");
ENDIF;

IF NodeName == OP4Name THEN
IOSetAccessName( "PLC4_HF", " ","", "PLC4_HF");
IOSetAccessName( "PLC4_MF", " ","", "PLC4_MF");
IOSetAccessName( "PLC4_LF", " ","", "PLC4_LF");
-------------------------------------------------------------------------------------

What happen if the HMI PC name example LCP1 is changed to HMI1 but in the script it is not changed?
 
Last edited:

Similar Topics

Hi all, hope you are having a great day, I am in need of your help to create a AOI or program that does this kind of job: I have a IO Link...
Replies
5
Views
94
please help me . I have to make this ladder diagram and I can’t figure it out :(
Replies
12
Views
342
Hi Everyone, i was hoping for a little help with this module. i have data that needs to be read from a different plc through the Modbus plus...
Replies
11
Views
222
Hello, I am trying to replicate a piece of logic on the PLC5 onto an SEL RTAC. I am using ladder on SEL and FBD. I am having issue on the ladder...
Replies
13
Views
228
Back
Top Bottom