Trend by Array

Anonymous
2012-05-08
2012-06-04
  • Anonymous - 2012-05-08

    Originally created by: federico.lettieri

    Hi to all
    i'm trying to realize a x-t plot using values contained into an array. This array is filled by the plc that take samples using 1second time frame. The array have 1000elements. I try to reach my goal using an histogram item but there are two problems: the first problem is that handle an histogram with that number of elements is a little bit heavy for visualization, and often is impossible to go online cause there is a max number of watching variables. The second problem is that the histogram is unable to display 1000 vertical lines in a display with the resolution of 800x600 (i'm using a cross control system model ccp-xs 10,4");for this reason if i try to use an histogram associated with an array of 1000 elements the result is a plot with the 500th element displayed near the end instead of displayed in the middle. I think that i can try to use the functions to draw lines in the SysLibTargetVisu.lib but reading the guide is not clear how to act.
    I try to write some code like this:

    retVal:=BeginPaint('a',4,4,256);
    retVal:=DrawButton(100,100,200,200,'a',65535,FALSE,0,TRUE);
    retVal:=EndPaint('a',4);
    

    and execute it by pressing a button but...no result.
    How i can reach my goal?any suggestions?

    Federico

     
  • shooter - 2012-05-08

    histogram is not fast enough for this.
    your array idea is fine.
    do not shift the array but only a pointer where the new data is placed.
    For reading use another pointer and draw a line from previous to now pointon the screen.
    put al points on screen, if a screen of 500 is used the points will overlap automatic.
    your lib can only be used when the screen works with codesys.
    otherwise you will have to make it via a webvisu, or program in your HMI.

     
  • DeltaQ - 2012-06-04

    I downloaded from Wago this Sample for FTP communication.
    Check the trending windows, maybe they can help you.

    FTP Samples.rar [42.56 KiB]

     

Log in to post a comment.