Output From Channel As Array


Azurulddin

Recommended Posts

Posted

which array should i use to perform channel output as array and how to recall the array??

 

example: channel is MyOut

 

should i use:

 

Rand (MyOut) or Fill(MyOut,10)

 

 

Posted

There are examples in the user's guide, section 4.5 and 4.6 as well as elsewhere.  I'd really need a little more detail on what you want to do or see to give a specific example.

Posted

i got 2 temperature sensor and every 5 second the data from sensor will store at OPc server.what i would like to do is take the data from OPC server and put inside a array for other execution.

 

example:

temp. sensor 1 = {20,30,50,80.100,50,30}

temp. sensor 2 = {50,10,70,30.90,20,110}

 

what i want:

 

temp.sensor 1

at array 1

temp.sensor 2

at array 2

                                                                              

 

Every 5 second, put data inside the array

20

50

30

10

50

70

80

30

100

90

50

20

30

110

 

 

 

 

 

 

 

 

 

 

 

 

then i would like to read the 80 at array 1 and display the data via display-variable value.

 

which type of array should i use and can you give some example??

Posted

If you create a Channel to read the OPC server, it will automatically put the data into an array as new readings appear.  Channels act like arrays that grow over time as new data appears, with the most recent data being inserted at the top of the array.  The maximum size of the channel array is determined by the History parameter.

Archived

This topic is now archived and is closed to further replies.