OpENer - Open Source EtherNet/IP(TM) I/O Target Stack
2.1
|
Go to the source code of this file.
Data Structures | |
struct | connection_path_epath |
Functions | |
size_t | CipEpathEncodeConnectionEpath (const CipConnectionPathEpath *const connection_epath, CipOctet **encoded_path) |
bool | CipEpathEqual (const CipOctet *const path1, const CipUint path1_length, const CipOctet *const path2, const CipUint path2_length) |
const CipDword | CipEpathGetLogicalValue (const EipUint8 **message) |
size_t | CipEpathSetLogicalValue (const CipDword logical_value, const LogicalSegmentLogicalFormat logical_format, CipOctet **message) |
void | GetElectronicKeyFormat4FromMessage (const CipOctet **const cip_path, ElectronicKeyFormat4 *key) |
Gets the data for an Electronic Key of format 4 from the EPath message. More... | |
CipUsint | GetPathDataSegmentSimpleDataWordLength (const unsigned char *const cip_path) |
Gets the data word length of a Simple Data segment. More... | |
DataSegmentSubtype | GetPathDataSegmentSubtype (const unsigned char *const cip_path) |
Gets the Data Segment subtype of a Data Segment EPath message. More... | |
ElectronicKeySegmentFormat | GetPathLogicalSegmentElectronicKeyFormat (const unsigned char *const cip_path) |
Gets the Electronic Key format of a Logical Segment Special Type EPath message. More... | |
LogicalSegmentExtendedLogicalType | GetPathLogicalSegmentExtendedLogicalType (const unsigned char *const cip_path) |
Gets the Extended Logical Type of a Logical Segment EPath message. More... | |
LogicalSegmentLogicalFormat | GetPathLogicalSegmentLogicalFormat (const unsigned char *const cip_path) |
Gets the Logical Format of a Logical Segment EPath message. More... | |
LogicalSegmentLogicalType | GetPathLogicalSegmentLogicalType (const unsigned char *const cip_path) |
Gets the Logical Type of an EPath Logical Segment message. More... | |
LogicalSegmentSpecialTypeLogicalFormat | GetPathLogicalSegmentSpecialTypeLogicalType (const unsigned char *const cip_path) |
Gets the Special Type Logical Type of a Logical Segment EPath message. More... | |
CipUdint | GetPathNetworkSegmentProductionInhibitTimeInMicroseconds (const unsigned char *const cip_path) |
Gets the Production Inhibit Time in Microseconds. More... | |
CipUsint | GetPathNetworkSegmentProductionInhibitTimeInMilliseconds (const unsigned char *const cip_path) |
Gets the Production Inhibit Time in Milliseconds. More... | |
NetworkSegmentSubtype | GetPathNetworkSegmentSubtype (const unsigned char *const cip_path) |
Gets the Network Segment Subtype of a EPatch Network Segement EPath message. More... | |
bool | GetPathPortSegmentExtendedLinkAddressSizeBit (const unsigned char *const cip_path) |
Only to be used on Port Segments. Returns if the Port Segment has the extended link address size bit set. More... | |
unsigned int | GetPathPortSegmentExtendedPortNumber (const unsigned char *const cip_path) |
Only to be used on Port Segments with Extended Port Number. Gets the Extended Port Number. More... | |
unsigned int | GetPathPortSegmentLinkAddressSize (const unsigned char *const cip_path) |
Only to be used on Port Segments. Gets the Link Address Size. More... | |
unsigned int | GetPathPortSegmentPortIdentifier (const unsigned char *const cip_path) |
Only to be used on Port Segments. Returns the Port Identifier. More... | |
SegmentType | GetPathSegmentType (const CipOctet *const cip_path) |
Gets the basic segment type of a CIP EPath. More... | |
SymbolicSegmentExtendedFormat | GetPathSymbolicSegmentExtendedFormat (const unsigned char *const cip_path) |
Gets the Extended Format subtype of a Symbolic Segment EPath message. More... | |
SymbolicSegmentFormat | GetPathSymbolicSegmentFormat (const unsigned char *const cip_path) |
Gets the Symbolic Segment Format of the Symbolic Segment EPath message. More... | |
SymbolicSegmentExtendedFormat | GetPathSymbolicSegmentNumericType (const unsigned char *const cip_path) |
Gets the Numeric subtype of a Symbolic Segment Extended Format EPath message. More... | |
void | SetPathLogicalSegmentLogicalFormat (LogicalSegmentLogicalFormat format, CipOctet *const cip_path) |
void | SetPathLogicalSegmentLogicalType (LogicalSegmentLogicalType logical_type, CipOctet *const cip_path) |
void | SetPathPortSegmentExtendedPortIdentifier (const unsigned int extended_port_identifier, CipOctet *const cip_path) |
Sets the Extended Port Identifier in a EPath Port Segment message. More... | |
void | SetPathPortSegmentPortIdentifier (const unsigned int port_identifier, unsigned char *const cip_path) |
Sets the Port Identifier form an Port Segment EPath to be sent. More... | |
void | SetPathSegmentType (SegmentType segment_type, unsigned char *const cip_path) |
Sets the basic segment type of an CIP EPath to be sent. More... | |
#define LOGICAL_SEGMENT_EXTENDED_TYPE_ARRAY_INDEX 0x01 |
Message value indicating the Array Index Extended Logical Segment type
Definition at line 38 of file cipepath.h.
#define LOGICAL_SEGMENT_EXTENDED_TYPE_BIT_INDEX 0x03 |
Message value indicating the Bit Index Extended Logical Segment type
Definition at line 40 of file cipepath.h.
#define LOGICAL_SEGMENT_EXTENDED_TYPE_INDIRECT_ARRAY_INDEX 0x02 |
Message value indicating the Indirect Array Index Extended Logical Segment type
Definition at line 39 of file cipepath.h.
#define LOGICAL_SEGMENT_EXTENDED_TYPE_INDIRECT_BIT_INDEX 0x04 |
Message value indicating the Indirect Bit Index Extended Logical Segment type
Definition at line 41 of file cipepath.h.
#define LOGICAL_SEGMENT_EXTENDED_TYPE_RESERVED 0x00 |
Message value indicating an reserved/unused Extended Logical Segment type
Definition at line 37 of file cipepath.h.
#define LOGICAL_SEGMENT_EXTENDED_TYPE_STRUCTURE_MEMBER_HANDLE 0x06 |
Message value indicating the Structured Member Handler Extended Logical Segment type
Definition at line 43 of file cipepath.h.
#define LOGICAL_SEGMENT_EXTENDED_TYPE_STRUCTURE_MEMBER_NUMBER 0x05 |
Message value indicating the Structured Member Number Extended Logical Segment type
Definition at line 42 of file cipepath.h.
#define LOGICAL_SEGMENT_FORMAT_EIGHT_BIT 0x00 |
Message value indicating an 8 bit value
Definition at line 33 of file cipepath.h.
#define LOGICAL_SEGMENT_FORMAT_SIXTEEN_BIT 0x01 |
Message value indicating an 16 bit value
Definition at line 34 of file cipepath.h.
#define LOGICAL_SEGMENT_FORMAT_THIRTY_TWO_BIT 0x02 |
Message value indicating an 32 bit value
Definition at line 35 of file cipepath.h.
#define LOGICAL_SEGMENT_SPECIAL_TYPE_FORMAT_ELECTRONIC_KEY 0x00 |
Message value indicating an electronic key
Definition at line 45 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_ATTRIBUTE_ID 0x10 |
Message value of the logical segment/logical type Attribute ID
Definition at line 28 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_CLASS_ID 0x00 |
Message value of the logical segment/logical type Class ID
Definition at line 24 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_CONNECTION_POINT 0x0C |
Message value of the logical segment/logical type Connection Point
Definition at line 27 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_EXTENDED_LOGICAL 0x1C |
Message value of the logical segment/logical type Extended Logical
Definition at line 31 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_INSTANCE_ID 0x04 |
Message value of the logical segment/logical type Instance ID
Definition at line 25 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_MEMBER_ID 0x08 |
Message value of the logical segment/logical type Member ID
Definition at line 26 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_SERVICE_ID 0x18 |
Message value of the logical segment/logical type Service ID
Definition at line 30 of file cipepath.h.
#define LOGICAL_SEGMENT_TYPE_SPECIAL 0x14 |
Message value of the logical segment/logical type Special
Definition at line 29 of file cipepath.h.
#define NETWORK_SEGMENT_SUBTYPE_EXTENDED_NETWORK 0x1F |
Message indicating a network message extended network message
Definition at line 52 of file cipepath.h.
#define NETWORK_SEGMENT_SUBTYPE_FIXED_TAG 0x02 |
Message value indicating a network segment fixed tag message
Definition at line 48 of file cipepath.h.
#define NETWORK_SEGMENT_SUBTYPE_PRODUCTION_INHIBIT_TIME_IN_MICROSECONDS 0x10 |
Message value indicating a network segment PIT in microseconds message
Definition at line 51 of file cipepath.h.
#define NETWORK_SEGMENT_SUBTYPE_PRODUCTION_INHIBIT_TIME_IN_MILLISECONDS 0x03 |
Message value indicating a network segment PIT in milliseconds message
Definition at line 49 of file cipepath.h.
#define NETWORK_SEGMENT_SUBTYPE_SAFETY 0x04 |
Message value indicating a network segment safety message
Definition at line 50 of file cipepath.h.
#define NETWORK_SEGMENT_SUBTYPE_SCHEDULE 0x01 |
Message value indicating a network segment schedule message
Definition at line 47 of file cipepath.h.
#define SEGMENT_TYPE_DATA_SEGMENT 0x80 |
Message value of the Data segment
Definition at line 19 of file cipepath.h.
#define SEGMENT_TYPE_DATA_TYPE_CONSTRUCTED 0xA0 |
Message value of the Data type constructed
Definition at line 20 of file cipepath.h.
#define SEGMENT_TYPE_DATA_TYPE_ELEMENTARTY 0xC0 |
Message value of the Data type elementary
Definition at line 21 of file cipepath.h.
#define SEGMENT_TYPE_LOGICAL_SEGMENT 0x20 |
Message value of the Logical segment
Definition at line 16 of file cipepath.h.
#define SEGMENT_TYPE_NETWORK_SEGMENT 0x40 |
Message value of the Network segment
Definition at line 17 of file cipepath.h.
#define SEGMENT_TYPE_PORT_SEGMENT 0x00 |
Message value of the Port segment
Definition at line 15 of file cipepath.h.
#define SEGMENT_TYPE_SEGMENT_RESERVED 0xE0 |
Reserved value
Definition at line 22 of file cipepath.h.
#define SEGMENT_TYPE_SYMBOLIC_SEGMENT 0x60 |
Message value of the Symbolic segment
Definition at line 18 of file cipepath.h.
typedef struct connection_path_epath CipConnectionPathEpath |
typedef enum data_segment_subtype DataSegmentSubtype |
Data segment sub types.
typedef enum electronic_key_segment_format ElectronicKeySegmentFormat |
Electronic key formats.
Enum containing values how long the encoded value will be (8, 16, or 32 bit)
typedef enum logical_segment_type LogicalSegmentLogicalType |
Enum containing values which kind of logical segment is encoded.
typedef enum network_segment_subtype NetworkSegmentSubtype |
All types of network segment types for the use in all code.
Enum constants for the different network segment subtypes to decouple code from the actual needed message values
typedef enum port_segment_type PortSegmentFlag |
Port Segment flags.
typedef enum segment_type SegmentType |
Segment type Enum.
Bits 7-5 in the Segment Type/Format byte
Extended symbolic symbol formats.
typedef enum symbolic_segment_format SymbolicSegmentFormat |
Symbolic segment formats.
enum data_segment_subtype |
Data segment sub types.
Enumerator | |
---|---|
kDataSegmentSubtypeReserved |
Reserved |
kDataSegmentSubtypeSimpleData |
Simple Data segment |
kDataSegmentSubtypeANSIExtendedSymbol |
ANSI extended symbol segment |
Definition at line 136 of file cipepath.h.
Electronic key formats.
Enumerator | |
---|---|
kElectronicKeySegmentFormatReserved |
Reserved |
kElectronicKeySegmentFormatKeyFormat4 |
Electronic key format 4 key |
Definition at line 114 of file cipepath.h.
Definition at line 88 of file cipepath.h.
Enum containing values how long the encoded value will be (8, 16, or 32 bit)
Enumerator | |
---|---|
kLogicalSegmentLogicalFormatEightBit | |
kLogicalSegmentLogicalFormatSixteenBit | |
kLogicalSegmentLogicalFormatThirtyTwoBit |
Definition at line 100 of file cipepath.h.
Enumerator | |
---|---|
kLogicalSegmentSpecialTypeLogicalFormatReserved | |
kLogicalSegmentSpecialTypeLogicalFormatElectronicKey |
Definition at line 106 of file cipepath.h.
enum logical_segment_type |
Enum containing values which kind of logical segment is encoded.
Definition at line 77 of file cipepath.h.
All types of network segment types for the use in all code.
Enum constants for the different network segment subtypes to decouple code from the actual needed message values
Definition at line 123 of file cipepath.h.
enum port_segment_type |
Port Segment flags.
Enumerator | |
---|---|
kPortSegmentFlagExtendedLinkAddressSize |
Extended Link Address Size flag, Port segment |
Definition at line 72 of file cipepath.h.
enum segment_type |
Segment type Enum.
Bits 7-5 in the Segment Type/Format byte
Definition at line 59 of file cipepath.h.
Extended symbolic symbol formats.
Definition at line 153 of file cipepath.h.
Symbolic segment formats.
Enumerator | |
---|---|
kSymbolicSegmentFormatASCII |
ASCII format |
kSymbolicSegmentFormatExtendedString |
Extended String format |
Definition at line 145 of file cipepath.h.
size_t CipEpathEncodeConnectionEpath | ( | const CipConnectionPathEpath *const | connection_epath, |
CipOctet ** | encoded_path | ||
) |
Definition at line 645 of file cipepath.c.
References connection_path_epath::attribute_id_or_connection_point, CipEpathGetNeededLogicalFormatForValue(), CipEpathSetLogicalValue(), connection_path_epath::class_id, connection_path_epath::instance_id, kLogicalSegmentLogicalTypeClassId, kSegmentTypeLogicalSegment, MoveMessageNOctets(), SetPathLogicalSegmentLogicalFormat(), SetPathLogicalSegmentLogicalType(), and SetPathSegmentType().
bool CipEpathEqual | ( | const CipOctet *const | path1, |
const CipUint | path1_length, | ||
const CipOctet *const | path2, | ||
const CipUint | path2_length | ||
) |
Definition at line 697 of file cipepath.c.
Definition at line 332 of file cipepath.c.
References GetDintFromMessage(), GetIntFromMessage(), GetPathLogicalSegmentLogicalFormat(), GetSintFromMessage(), kLogicalSegmentLogicalFormatEightBit, kLogicalSegmentLogicalFormatSixteenBit, kLogicalSegmentLogicalFormatThirtyTwoBit, MoveMessageNOctets(), and OPENER_ASSERT.
Referenced by ParseConnectionPath().
size_t CipEpathSetLogicalValue | ( | const CipDword | logical_value, |
const LogicalSegmentLogicalFormat | logical_format, | ||
CipOctet ** | message | ||
) |
Definition at line 356 of file cipepath.c.
References AddDintToMessage(), AddIntToMessage(), AddSintToMessage(), kLogicalSegmentLogicalFormatEightBit, kLogicalSegmentLogicalFormatSixteenBit, kLogicalSegmentLogicalFormatThirtyTwoBit, MoveMessageNOctets(), and OPENER_ASSERT.
Referenced by CipEpathEncodeConnectionEpath().
void GetElectronicKeyFormat4FromMessage | ( | const CipOctet **const | cip_path, |
ElectronicKeyFormat4 * | key | ||
) |
Gets the data for an Electronic Key of format 4 from the EPath message.
cip_path | The start of the EPath message |
key | Writes the data on the user provided data electronic key struct |
Definition at line 441 of file cipepath.c.
References ElectronicKeyFormat4SetDeviceType(), ElectronicKeyFormat4SetMajorRevisionCompatibility(), ElectronicKeyFormat4SetMinorRevision(), ElectronicKeyFormat4SetProductCode(), ElectronicKeyFormat4SetVendorId(), GetIntFromMessage(), GetPathLogicalSegmentElectronicKeyFormat(), GetSintFromMessage(), kElectronicKeySegmentFormatKeyFormat4, MoveMessageNOctets(), and OPENER_ASSERT.
Referenced by ParseConnectionPath().
CipUsint GetPathDataSegmentSimpleDataWordLength | ( | const unsigned char *const | cip_path | ) |
Gets the data word length of a Simple Data segment.
cip_path | The start of the EPath message |
Gets the data word length of a Simple Data segment.
cip_path | Pointer to the start of the EPath message |
Definition at line 616 of file cipepath.c.
References GetPathDataSegmentSubtype(), GetPathSegmentType(), GetSintFromMessage(), kDataSegmentSubtypeSimpleData, kSegmentTypeDataSegment, and OPENER_ASSERT.
DataSegmentSubtype GetPathDataSegmentSubtype | ( | const unsigned char *const | cip_path | ) |
Gets the Data Segment subtype of a Data Segment EPath message.
cip_path | The start of the EPath message |
Definition at line 595 of file cipepath.c.
References DATA_SEGMENT_SUBTYPE_ANSI_EXTENDED_SYMBOL, DATA_SEGMENT_SUBTYPE_SIMPLE_DATA, kDataSegmentSubtypeANSIExtendedSymbol, kDataSegmentSubtypeReserved, and kDataSegmentSubtypeSimpleData.
Referenced by GetPathDataSegmentSimpleDataWordLength(), and ParseConnectionPath().
ElectronicKeySegmentFormat GetPathLogicalSegmentElectronicKeyFormat | ( | const unsigned char *const | cip_path | ) |
Gets the Electronic Key format of a Logical Segment Special Type EPath message.
cip_path | The start of the EPath message |
Definition at line 426 of file cipepath.c.
References ELECTRONIC_KEY_SEGMENT_KEY_FORMAT_4, GetPathLogicalSegmentSpecialTypeLogicalType(), kElectronicKeySegmentFormatKeyFormat4, kElectronicKeySegmentFormatReserved, kLogicalSegmentSpecialTypeLogicalFormatElectronicKey, and OPENER_ASSERT.
Referenced by GetElectronicKeyFormat4FromMessage(), and ParseConnectionPath().
LogicalSegmentExtendedLogicalType GetPathLogicalSegmentExtendedLogicalType | ( | const unsigned char *const | cip_path | ) |
Gets the Extended Logical Type of a Logical Segment EPath message.
cip_path | The start of the EPath message |
Definition at line 379 of file cipepath.c.
References GetPathLogicalSegmentLogicalType(), kLogicalSegmentExtendedLogicalTypeArrayIndex, kLogicalSegmentExtendedLogicalTypeBitIndex, kLogicalSegmentExtendedLogicalTypeIndirectArrayIndex, kLogicalSegmentExtendedLogicalTypeIndirectBitIndex, kLogicalSegmentExtendedLogicalTypeReserved, kLogicalSegmentExtendedLogicalTypeStructureMemberHandle, kLogicalSegmentExtendedLogicalTypeStructureMemberNumber, kLogicalSegmentLogicalTypeExtendedLogical, LOGICAL_SEGMENT_EXTENDED_TYPE_ARRAY_INDEX, LOGICAL_SEGMENT_EXTENDED_TYPE_BIT_INDEX, LOGICAL_SEGMENT_EXTENDED_TYPE_INDIRECT_ARRAY_INDEX, LOGICAL_SEGMENT_EXTENDED_TYPE_INDIRECT_BIT_INDEX, LOGICAL_SEGMENT_EXTENDED_TYPE_STRUCTURE_MEMBER_HANDLE, LOGICAL_SEGMENT_EXTENDED_TYPE_STRUCTURE_MEMBER_NUMBER, and OPENER_ASSERT.
LogicalSegmentLogicalFormat GetPathLogicalSegmentLogicalFormat | ( | const unsigned char *const | cip_path | ) |
Gets the Logical Format of a Logical Segment EPath message.
cip_path | The start of the EPath message |
Definition at line 287 of file cipepath.c.
References GetPathSegmentType(), kLogicalSegmentLogicalFormatEightBit, kLogicalSegmentLogicalFormatSixteenBit, kLogicalSegmentLogicalFormatThirtyTwoBit, kSegmentTypeLogicalSegment, LOGICAL_SEGMENT_FORMAT_EIGHT_BIT, LOGICAL_SEGMENT_FORMAT_SIXTEEN_BIT, LOGICAL_SEGMENT_FORMAT_THIRTY_TWO_BIT, and OPENER_ASSERT.
Referenced by CipEpathGetLogicalValue().
LogicalSegmentLogicalType GetPathLogicalSegmentLogicalType | ( | const unsigned char *const | cip_path | ) |
Gets the Logical Type of an EPath Logical Segment message.
cip_path | The start of the EPath message |
Definition at line 213 of file cipepath.c.
References GetPathSegmentType(), kLogicalSegmentLogicalTypeAttributeId, kLogicalSegmentLogicalTypeClassId, kLogicalSegmentLogicalTypeConnectionPoint, kLogicalSegmentLogicalTypeExtendedLogical, kLogicalSegmentLogicalTypeInstanceId, kLogicalSegmentLogicalTypeMemberId, kLogicalSegmentLogicalTypeServiceId, kLogicalSegmentLogicalTypeSpecial, kSegmentTypeLogicalSegment, LOGICAL_SEGMENT_TYPE_ATTRIBUTE_ID, LOGICAL_SEGMENT_TYPE_CLASS_ID, LOGICAL_SEGMENT_TYPE_CONNECTION_POINT, LOGICAL_SEGMENT_TYPE_EXTENDED_LOGICAL, LOGICAL_SEGMENT_TYPE_INSTANCE_ID, LOGICAL_SEGMENT_TYPE_MEMBER_ID, LOGICAL_SEGMENT_TYPE_SERVICE_ID, LOGICAL_SEGMENT_TYPE_SPECIAL, and OPENER_ASSERT.
Referenced by GetPathLogicalSegmentExtendedLogicalType(), GetPathLogicalSegmentSpecialTypeLogicalType(), and ParseConnectionPath().
LogicalSegmentSpecialTypeLogicalFormat GetPathLogicalSegmentSpecialTypeLogicalType | ( | const unsigned char *const | cip_path | ) |
Gets the Special Type Logical Type of a Logical Segment EPath message.
cip_path | The start of the EPath message |
Definition at line 407 of file cipepath.c.
References GetPathLogicalSegmentLogicalType(), GetPathSegmentType(), kLogicalSegmentLogicalTypeSpecial, kLogicalSegmentSpecialTypeLogicalFormatElectronicKey, kLogicalSegmentSpecialTypeLogicalFormatReserved, kSegmentTypeLogicalSegment, LOGICAL_SEGMENT_SPECIAL_TYPE_FORMAT_ELECTRONIC_KEY, and OPENER_ASSERT.
Referenced by GetPathLogicalSegmentElectronicKeyFormat(), and ParseConnectionPath().
CipUdint GetPathNetworkSegmentProductionInhibitTimeInMicroseconds | ( | const unsigned char *const | cip_path | ) |
Gets the Production Inhibit Time in Microseconds.
cip_path | The start of the EPath message |
Gets the Production Inhibit Time in Microseconds.
cip_path | Pointer to the start of the EPath message |
Definition at line 514 of file cipepath.c.
References GetDintFromMessage(), GetPathNetworkSegmentSubtype(), GetPathSegmentType(), kNetworkSegmentSubtypeProductionInhibitTimeInMicroseconds, kSegmentTypeNetworkSegment, and OPENER_ASSERT.
CipUsint GetPathNetworkSegmentProductionInhibitTimeInMilliseconds | ( | const unsigned char *const | cip_path | ) |
Gets the Production Inhibit Time in Milliseconds.
cip_path | The start of the EPath message |
Gets the Production Inhibit Time in Milliseconds.
cip_path | Pointer to the start of the EPath message |
Definition at line 497 of file cipepath.c.
References GetPathNetworkSegmentSubtype(), GetPathSegmentType(), kNetworkSegmentSubtypeProductionInhibitTimeInMilliseconds, kSegmentTypeNetworkSegment, and OPENER_ASSERT.
NetworkSegmentSubtype GetPathNetworkSegmentSubtype | ( | const unsigned char *const | cip_path | ) |
Gets the Network Segment Subtype of a EPatch Network Segement EPath message.
cip_path | The start of the EPath message |
Gets the Network Segment Subtype of a EPatch Network Segement EPath message.
cip_path | Pointer to the start of the EPath message |
Definition at line 466 of file cipepath.c.
References GetPathSegmentType(), kNetworkSegmentSubtypeExtendedNetworkSegment, kNetworkSegmentSubtypeFixedTagSegment, kNetworkSegmentSubtypeProductionInhibitTimeInMicroseconds, kNetworkSegmentSubtypeProductionInhibitTimeInMilliseconds, kNetworkSegmentSubtypeReserved, kNetworkSegmentSubtypeSafetySegment, kNetworkSegmentSubtypeScheduleSegment, kSegmentTypeNetworkSegment, NETWORK_SEGMENT_EXTENDED_NETWORK, NETWORK_SEGMENT_FIXED_TAG, NETWORK_SEGMENT_PRODUCTION_INHIBIT_TIME_IN_MICROSECONDS, NETWORK_SEGMENT_PRODUCTION_INHIBIT_TIME_IN_MILLISECONDS, NETWORK_SEGMENT_SAFETY, NETWORK_SEGMENT_SCHEDULE, and OPENER_ASSERT.
Referenced by GetPathNetworkSegmentProductionInhibitTimeInMicroseconds(), GetPathNetworkSegmentProductionInhibitTimeInMilliseconds(), and ParseConnectionPath().
bool GetPathPortSegmentExtendedLinkAddressSizeBit | ( | const unsigned char *const | cip_path | ) |
Only to be used on Port Segments. Returns if the Port Segment has the extended link address size bit set.
cip_path | The start of the EPath message |
Definition at line 148 of file cipepath.c.
Referenced by GetPathPortSegmentExtendedPortNumber(), GetPathPortSegmentLinkAddressSize(), and SetPathPortSegmentExtendedPortIdentifier().
unsigned int GetPathPortSegmentExtendedPortNumber | ( | const unsigned char *const | cip_path | ) |
Only to be used on Port Segments with Extended Port Number. Gets the Extended Port Number.
cip_path | The start of the EPath message |
Definition at line 186 of file cipepath.c.
References GetPathPortSegmentExtendedLinkAddressSizeBit(), GetPathPortSegmentPortIdentifier(), kPortSegmentExtendedPort, and OPENER_ASSERT.
unsigned int GetPathPortSegmentLinkAddressSize | ( | const unsigned char *const | cip_path | ) |
Only to be used on Port Segments. Gets the Link Address Size.
cip_path | The start of the EPath message |
Definition at line 177 of file cipepath.c.
References GetPathPortSegmentExtendedLinkAddressSizeBit(), and OPENER_ASSERT.
unsigned int GetPathPortSegmentPortIdentifier | ( | const unsigned char *const | cip_path | ) |
Only to be used on Port Segments. Returns the Port Identifier.
cip_path | The start of the EPath message |
Definition at line 158 of file cipepath.c.
References GetPathSegmentType(), kSegmentTypePortSegment, and OPENER_ASSERT.
Referenced by GetPathPortSegmentExtendedPortNumber().
SegmentType GetPathSegmentType | ( | const CipOctet *const | cip_path | ) |
Gets the basic segment type of a CIP EPath.
cip_path | The start of the EPath message |
Definition at line 76 of file cipepath.c.
References kSegmentTypeDataSegment, kSegmentTypeDataTypeConstructed, kSegmentTypeDataTypeElementary, kSegmentTypeLogicalSegment, kSegmentTypeNetworkSegment, kSegmentTypePortSegment, kSegmentTypeReserved, kSegmentTypeSymbolicSegment, OPENER_ASSERT, SEGMENT_TYPE_DATA_SEGMENT, SEGMENT_TYPE_DATA_TYPE_CONSTRUCTED, SEGMENT_TYPE_DATA_TYPE_ELEMENTARTY, SEGMENT_TYPE_LOGICAL_SEGMENT, SEGMENT_TYPE_NETWORK_SEGMENT, SEGMENT_TYPE_PORT_SEGMENT, SEGMENT_TYPE_SEGMENT_RESERVED, and SEGMENT_TYPE_SYMBOLIC_SEGMENT.
Referenced by GetPathDataSegmentSimpleDataWordLength(), GetPathLogicalSegmentLogicalFormat(), GetPathLogicalSegmentLogicalType(), GetPathLogicalSegmentSpecialTypeLogicalType(), GetPathNetworkSegmentProductionInhibitTimeInMicroseconds(), GetPathNetworkSegmentProductionInhibitTimeInMilliseconds(), GetPathNetworkSegmentSubtype(), GetPathPortSegmentPortIdentifier(), GetPathSymbolicSegmentExtendedFormat(), ParseConnectionPath(), SetPathLogicalSegmentLogicalFormat(), and SetPathLogicalSegmentLogicalType().
SymbolicSegmentExtendedFormat GetPathSymbolicSegmentExtendedFormat | ( | const unsigned char *const | cip_path | ) |
Gets the Extended Format subtype of a Symbolic Segment EPath message.
cip_path | The start of the EPath message |
Definition at line 570 of file cipepath.c.
References GetPathSegmentType(), GetPathSymbolicSegmentFormat(), GetPathSymbolicSegmentNumericType(), kSegmentTypeSymbolicSegment, kSymbolicSegmentExtendedFormatDoubleByteChars, kSymbolicSegmentExtendedFormatReserved, kSymbolicSegmentExtendedFormatTripleByteChars, kSymbolicSegmentFormatExtendedString, OPENER_ASSERT, SYMBOLIC_SEGMENT_EXTENDED_FORMAT_DOUBLE_CHAR, SYMBOLIC_SEGMENT_EXTENDED_FORMAT_NUMERIC, and SYMBOLIC_SEGMENT_EXTENDED_FORMAT_TRIPLE_CHAR.
SymbolicSegmentFormat GetPathSymbolicSegmentFormat | ( | const unsigned char *const | cip_path | ) |
Gets the Symbolic Segment Format of the Symbolic Segment EPath message.
cip_path | The start of the EPath message |
Definition at line 534 of file cipepath.c.
References kSymbolicSegmentFormatASCII, kSymbolicSegmentFormatExtendedString, and SYMBOLIC_SEGMENT_FORMAT_EXTENDED_STRING.
Referenced by GetPathSymbolicSegmentExtendedFormat().
SymbolicSegmentExtendedFormat GetPathSymbolicSegmentNumericType | ( | const unsigned char *const | cip_path | ) |
Gets the Numeric subtype of a Symbolic Segment Extended Format EPath message.
cip_path | The start of the EPath message |
Definition at line 552 of file cipepath.c.
References kSymbolicSegmentExtendedFormatNumericSymbolUDINT, kSymbolicSegmentExtendedFormatNumericSymbolUINT, kSymbolicSegmentExtendedFormatNumericSymbolUSINT, kSymbolicSegmentExtendedFormatReserved, SYMBOLIC_SEGMENT_EXTENDED_FORMAT_NUMERIC_UDINT_TYPE, SYMBOLIC_SEGMENT_EXTENDED_FORMAT_NUMERIC_UINT_TYPE, and SYMBOLIC_SEGMENT_EXTENDED_FORMAT_NUMERIC_USINT_TYPE.
Referenced by GetPathSymbolicSegmentExtendedFormat().
void SetPathLogicalSegmentLogicalFormat | ( | LogicalSegmentLogicalFormat | format, |
CipOctet *const | cip_path | ||
) |
Definition at line 311 of file cipepath.c.
References GetPathSegmentType(), kLogicalSegmentLogicalFormatEightBit, kLogicalSegmentLogicalFormatSixteenBit, kLogicalSegmentLogicalFormatThirtyTwoBit, kSegmentTypeLogicalSegment, LOGICAL_SEGMENT_FORMAT_EIGHT_BIT, LOGICAL_SEGMENT_FORMAT_SIXTEEN_BIT, LOGICAL_SEGMENT_FORMAT_THIRTY_TWO_BIT, and OPENER_ASSERT.
Referenced by CipEpathEncodeConnectionEpath().
void SetPathLogicalSegmentLogicalType | ( | LogicalSegmentLogicalType | logical_type, |
CipOctet *const | cip_path | ||
) |
Definition at line 252 of file cipepath.c.
References GetPathSegmentType(), kLogicalSegmentLogicalTypeAttributeId, kLogicalSegmentLogicalTypeClassId, kLogicalSegmentLogicalTypeConnectionPoint, kLogicalSegmentLogicalTypeExtendedLogical, kLogicalSegmentLogicalTypeInstanceId, kLogicalSegmentLogicalTypeMemberId, kLogicalSegmentLogicalTypeServiceId, kLogicalSegmentLogicalTypeSpecial, kSegmentTypeLogicalSegment, LOGICAL_SEGMENT_TYPE_ATTRIBUTE_ID, LOGICAL_SEGMENT_TYPE_CLASS_ID, LOGICAL_SEGMENT_TYPE_CONNECTION_POINT, LOGICAL_SEGMENT_TYPE_EXTENDED_LOGICAL, LOGICAL_SEGMENT_TYPE_INSTANCE_ID, LOGICAL_SEGMENT_TYPE_MEMBER_ID, LOGICAL_SEGMENT_TYPE_SERVICE_ID, LOGICAL_SEGMENT_TYPE_SPECIAL, and OPENER_ASSERT.
Referenced by CipEpathEncodeConnectionEpath().
void SetPathPortSegmentExtendedPortIdentifier | ( | const unsigned int | extended_port_identifier, |
CipOctet *const | cip_path | ||
) |
Sets the Extended Port Identifier in a EPath Port Segment message.
extended_port_identifier | The extended port identifier to be encoded into the message |
cip_path | The start for the EPatch message |
Definition at line 198 of file cipepath.c.
References GetPathPortSegmentExtendedLinkAddressSizeBit(), kPortSegmentExtendedPort, and SetPathPortSegmentPortIdentifier().
void SetPathPortSegmentPortIdentifier | ( | const unsigned int | port_identifier, |
unsigned char *const | cip_path | ||
) |
Sets the Port Identifier form an Port Segment EPath to be sent.
port_identifier | The port identifier |
cip_path | A message buffer - Will be written on! |
Definition at line 168 of file cipepath.c.
References OPENER_ASSERT.
Referenced by SetPathPortSegmentExtendedPortIdentifier().
void SetPathSegmentType | ( | SegmentType | segment_type, |
unsigned char *const | cip_path | ||
) |
Sets the basic segment type of an CIP EPath to be sent.
segment_type | The segment type |
cip_path | A message buffer - Will be written on! |
Definition at line 113 of file cipepath.c.
References kSegmentTypeDataSegment, kSegmentTypeDataTypeConstructed, kSegmentTypeDataTypeElementary, kSegmentTypeLogicalSegment, kSegmentTypeNetworkSegment, kSegmentTypePortSegment, kSegmentTypeReserved, kSegmentTypeSymbolicSegment, OPENER_ASSERT, SEGMENT_TYPE_DATA_SEGMENT, SEGMENT_TYPE_DATA_TYPE_CONSTRUCTED, SEGMENT_TYPE_DATA_TYPE_ELEMENTARTY, SEGMENT_TYPE_LOGICAL_SEGMENT, SEGMENT_TYPE_NETWORK_SEGMENT, SEGMENT_TYPE_PORT_SEGMENT, SEGMENT_TYPE_SEGMENT_RESERVED, and SEGMENT_TYPE_SYMBOLIC_SEGMENT.
Referenced by CipEpathEncodeConnectionEpath().