adccommunitymod (AutomationDirect) asked a question.

Historical Trends on the CMore Micro

Created Date: September 26,2008

Created By: jondecker76

**** This post has been imported from our legacy forum. Information in this post may be outdated and links contained in the post may no longer work.****

PLC Used: DL05 It took me a bit of tinkering to find an elegant way of building the table in vMemory that would be used to display historical trends on the CMore micro. In my example, I am using 24 data points to show a historical trend for the last 24 minutes of the value stored in v2000. In my CMore micro, i set the historical trend (Line Graph Object) to use 24 data points, and that the trend data starts at vmemory address V3000. Build a historic trend data table at v3000-v3027 that trends the last 24 minutes of the value in v2000. //C0 will be our 1-minute interval timer - SP3----------------------(PD)C0 - C0-----------------------|LD K17 | //We need to shift the data in the table //to the "left " by 23 locations. This parameter //is in hex, so 17 is hex for 23 |LDA O3001| //Load and convert to hex, octal address V3001 //notice that we are loding the address table_Start + 1 |MOV V3000| //this esentially move those 23 values to the left 1 word in memory |LD V2000 | //now lets grab V2000 current value |OUT V3027| //and place it at the end of the table!


  • adccommunitymod (AutomationDirect)

    Created Date: September 26,2008

    Created by: jondecker76

    PLC Used: DL05

    It took me a bit of tinkering to find an elegant way of building the table in vMemory that would be used to display historical trends on the CMore micro.

    In my example, I am using 24 data points to show a historical trend for the last 24 minutes of the value stored in v2000. In my CMore micro, i set the historical trend (Line Graph Object) to use 24 data points, and that the trend data starts at vmemory address V3000.

    Build a historic trend data table at v3000-v3027 that trends the last 24 minutes of the value in v2000.

    //C0 will be our 1-minute interval timer

    - SP3----------------------(PD)C0

    - C0-----------------------|LD K17 | //We need to shift the data in the table

    //to the "left " by 23 locations. This parameter

    //is in hex, so 17 is hex for 23

    |LDA O3001| //Load and convert to hex, octal address V3001

    //notice that we are loding the address table_Start + 1

    |MOV V3000| //this esentially move those 23 values to the left 1 word in memory

    |LD V2000 | //now lets grab V2000 current value

    |OUT V3027| //and place it at the end of the table!

    Expand Post