網(wǎng)站推廣方式措施/寧波網(wǎng)絡推廣優(yōu)化公司
目錄
- Segment
- PATH
- 舉例
最近在學習EtherNET/IP,PATH不太明白,翻了翻規(guī)范,在這里記個筆記。下面的敘述可能是中英混合,有一些是規(guī)范中的原文我直接搬過來的。我翻譯的不準確。
Segment
PATH是CIP Segment中的一個分類。要了解PATH先要了解Segment
參考規(guī)范卷1,附錄C-1
A CIP segment is a stream of encoded items used to reference, describe, and/or configure a specific CIP entity。
CIP Segment 分類如下
? Port segment – used for routing from one subnet to another
? Logical segment - logical reference information (such as class/instance/attribute IDs)
? Network segment - specifies network parameters needed to transmit on some networks
? Symbolic segment - symbolic name
? Data segment - embedded data (such as configuration data)
Segment使用一個字節(jié)編碼,包含Segment類型和格式。格式根據(jù)Segment類型不同而不同
PATH
PATH屬于其中的Logical segment.
一個PATH包含多個Logical segment,在一個object中引用其他object的類,實例,屬性。
PATH用途如下
? In Connection and Connection Manager Objects, paths indicate the object(s) to/from which
I/O data is moved.
? In Assembly Objects, paths indicate the attributes in other objects which are used to form
the assembled I/O data.
? In Parameter Objects, paths indicate the actual attribute in another object which is being
described by the Parameter Object.
PATH結構如下,需要注意的是,這里的PATH只有一個段屬性,PATH可以包含多個段屬性,訪問到更深入的數(shù)據(jù)。后面會給例子。
logical segment 編碼如下
舉例
舉三個例子
- 8-Bit Service ID Segment (0x38)
- Electronic Key Segment (0x34)(The Electronic Key segment shall be used to verify/identify a device)