検索機能を使用して 500 を上回る Kepware の知識ベース記事の中から閲覧します。結果を絞り込むか、クエリーを下部の検索フィールドに入力します。

解決策が見つからなかった場合には、当社の PTC eSupport Portal で追加資料を確認することもできます。eSupport Portal へのログインを要求された場合、My Kepware の認証情報を使用できます。My Kepware アカウントが必要ですか? こちらで作成

各種検索方法:
View All Solutions

Kepware Knowledge Base: Solution


How Are Arrays Handled in the Allen-Bradley ControlLogix Ethernet Driver?


Last Update: 2018/11/12

Because ControlLogix devices handle arrays differently than other PLCs, Kepware's Allen-Bradley ControlLogix Ethernet Driver handles arrays differently than other drivers.

  1. It supports 3 dimensional arrays, whereas standard drivers only support 2 dimensions.
  2. Individual elements of an array can be addressed directly.
  3. Sub-arrays of data within the array can be addressed using offsets.

When addressing an element in an array or specifying an offset, the indexing/ordering of the data is 0-based. The number of elements to be displayed in an array reference are 1-based. When addressing elements or subsets in an array, the elements are referenced using square brackets and a range or sub-array of data is referenced using braces. There are two types of arrays: single-dimension arrays and multi-dimension arrays.

Single-Dimension Arrays
A 1x16 array example is shown below. The tag name is "IArray".

737884255256257258259910111213141516

Example single-dimension array references are as follows:

  • IArray [5] = 257. This is the fifth element in the array.
  • IArray {5} = [73, 78, 84, 255, 256]. This is the first five elements in the array.
  • IArray [10] {3} = [11, 12, 13]. This is an array of 3 elements starting at the tenth element.

Multi-Dimension Arrays
A 4x4 array example is shown below. The first row is 0 and the first column is 0. The tag name is "IArray".

737884255
256257258259
9101112
13141516

Example multi-dimension array references are as follows:

  • IArray [1,3] = 259. This is the last element in the second row of the array.
  • IArray {4} = [73, 72, 84, 255]. This is an array of four elements with no offset.
  • IArray [2, 0] {2} = [9, 10]. This is an array of two elements starting at an offset of the first element in the third row.