MrPLC Member
  • Content count

  • Joined

  • Last visited

Posts posted by kotermak

  1. On 10/10/2021 at 3:27 PM, Ken Roach said:

    Welcome to the MrPLC forum community !

    The Logix operating system supports array tags of up to 2 megabytes, which would be an INT[1048576] array.   The software will warn you if you try to create a tag bigger than 1.5 MB, but it will be valid up to 2 MB.

    Remember that arrays start with element zero.   If you have an INT[32] type array and the element index number is [32] or bigger the controller will throw a minor recoverable fault.

    I'm in the habit of testing the index value before I execute an instruction with a variable array index, like LEQ(IndexValue,31) in the ladder rung.  

    Some programmers are more thorough and use the SIZE instruction to determine the array size before putting in such a limit, so their limiting logic will still work even if the array size is changed later.

    Thanks for detailed response and explanation.

    Looks like I resolved that issue. Now I have last couple rungs  of my routine where i want to add all values of my  Array[52].  Any idea how to write the short formula for the CMP (Compute) instruction which will give me the SUMM (total decimal value) of all DINs in my Array[52]? I tried these options {Array[value]}; Array{value} and others but all returned with error. I dont want to write formula with summary of 52 values : Array(0)+Array(1)+........Array(52).    I checked all manuals and instruction descripton so far found nothing. Do I missing something there? Thanks.