|
OpENer - Open Source EtherNet/IP(TM) I/O Target Stack
2.1
|
#include <string.h>#include "cipethernetlink.h"#include "cipcommon.h"#include "cipmessagerouter.h"#include "ciperror.h"#include "endianconv.h"#include "opener_api.h"#include "trace.h"Go to the source code of this file.
Data Structures | |
| struct | CipEthernetLinkInterfaceCapability |
| struct | CipEthernetLinkInterfaceControl |
| struct | speed_duplex_array_entry |
| struct | speed_duplex_options |
Typedefs | |
| typedef struct speed_duplex_array_entry | CipEthernetLinkSpeedDuplexArrayEntry |
| typedef struct speed_duplex_options | CipEthernetLinkSpeedDuplexOptions |
Functions | |
| EipStatus | CipEthernetLinkInit () |
| Initialize the Ethernet Link Objects data. More... | |
| int | EncodeInterfaceCapability (EipUint8 **pa_acMsg) |
| int | EncodeInterfaceControl (EipUint8 **pa_acMsg) |
| int | EncodeInterfaceCounters (EipUint8 **pa_acMsg) |
| int | EncodeMediaCounters (EipUint8 **pa_acMsg) |
| EipStatus | GetAttributeSingleEthernetLink (CipInstance *RESTRICT const instance, CipMessageRouterRequest *const message_router_request, CipMessageRouterResponse *const message_router_response, struct sockaddr *originator_address, const int encapsulation_session) |
Variables | |
| CipUdint | dummy_attribute_udint = 0 |
| CipUsint | dummy_attribute_usint = 0 |
| Configures the MAC address of the Ethernet Link object*. More... | |
| CipEthernetLinkInterfaceCapability | interface_capability |
| CipEthernetLinkInterfaceControl | interface_control |
| CipShortString | interface_label = { .length = 0, .string = NULL } |
| CipEthernetLinkSpeedDuplexArrayEntry | speed_duplex_object |
| typedef struct speed_duplex_array_entry CipEthernetLinkSpeedDuplexArrayEntry |
| typedef struct speed_duplex_options CipEthernetLinkSpeedDuplexOptions |
| EipStatus CipEthernetLinkInit | ( | void | ) |
Initialize the Ethernet Link Objects data.
Definition at line 68 of file cipethernetlink.c.
References CIP_ETHERNETLINK_CLASS_CODE, CreateCipClass(), dummy_attribute_udint, dummy_attribute_usint, g_ethernet_link, GetAttributeAll(), GetAttributeSingleEthernetLink(), GetCipInstance(), InsertAttribute(), InsertService(), CipEthernetLinkObject::interface_flags, CipEthernetLinkObject::interface_speed, kCip6Usint, kCipAny, kCipDword, kCipShortString, kCipUdint, kCipUsint, kEipStatusError, kEipStatusOk, kGetableAll, kGetableSingleAndAll, kGetAttributeAll, kGetAttributeSingle, and CipEthernetLinkObject::physical_address.
Referenced by CipStackInit().
| int EncodeInterfaceCapability | ( | EipUint8 ** | pa_acMsg | ) |
Definition at line 150 of file cipethernetlink.c.
References CipEthernetLinkInterfaceCapability::capability_bits, EncodeData(), speed_duplex_array_entry::interface_duplex_mode, speed_duplex_array_entry::interface_speed, kCipDword, kCipUint, kCipUsint, speed_duplex_options::speed_duplex_array, speed_duplex_options::speed_duplex_array_count, and CipEthernetLinkInterfaceCapability::speed_duplex_options.
Referenced by GetAttributeSingleEthernetLink().
| int EncodeInterfaceControl | ( | EipUint8 ** | pa_acMsg | ) |
Definition at line 139 of file cipethernetlink.c.
References CipEthernetLinkInterfaceControl::control_bits, EncodeData(), CipEthernetLinkInterfaceControl::forced_interface_speed, kCipUint, and kCipWord.
Referenced by GetAttributeSingleEthernetLink().
| int EncodeInterfaceCounters | ( | EipUint8 ** | pa_acMsg | ) |
Definition at line 121 of file cipethernetlink.c.
References dummy_attribute_udint, EncodeData(), and kCipUdint.
Referenced by GetAttributeSingleEthernetLink().
| int EncodeMediaCounters | ( | EipUint8 ** | pa_acMsg | ) |
Definition at line 130 of file cipethernetlink.c.
References dummy_attribute_udint, EncodeData(), and kCipUdint.
Referenced by GetAttributeSingleEthernetLink().
| EipStatus GetAttributeSingleEthernetLink | ( | CipInstance *RESTRICT const | instance, |
| CipMessageRouterRequest *const | message_router_request, | ||
| CipMessageRouterResponse *const | message_router_response, | ||
| struct sockaddr * | originator_address, | ||
| const int | encapsulation_session | ||
| ) |
Definition at line 176 of file cipethernetlink.c.
References CipEpath::attribute_number, CalculateIndex(), CipMessageRouterResponse::data, CipAttributeStruct::data, CipMessageRouterResponse::data_length, EncodeInterfaceCapability(), EncodeInterfaceControl(), EncodeInterfaceCounters(), EncodeMediaCounters(), CipMessageRouterResponse::general_status, GetAttributeSingle(), GetCipAttribute(), kCipErrorAttributeNotSupported, kCipErrorSuccess, kEipStatusOkSend, kGetAttributeAll, OPENER_TRACE_INFO, CipMessageRouterResponse::reply_service, CipMessageRouterRequest::request_path, CipMessageRouterRequest::service, and CipMessageRouterResponse::size_of_additional_status.
Referenced by CipEthernetLinkInit().
| CipUdint dummy_attribute_udint = 0 |
Definition at line 50 of file cipethernetlink.c.
Referenced by CipEthernetLinkInit(), EncodeInterfaceCounters(), and EncodeMediaCounters().
| CipUsint dummy_attribute_usint = 0 |
Configures the MAC address of the Ethernet Link object*.
| mac_address | The MAC address of the Ethernet Link |
Definition at line 49 of file cipethernetlink.c.
Referenced by CipEthernetLinkInit().
| CipEthernetLinkInterfaceCapability interface_capability |
Definition at line 61 of file cipethernetlink.c.
| CipEthernetLinkInterfaceControl interface_control |
Definition at line 53 of file cipethernetlink.c.
| CipShortString interface_label = { .length = 0, .string = NULL } |
Definition at line 52 of file cipethernetlink.c.
| CipEthernetLinkSpeedDuplexArrayEntry speed_duplex_object |
Definition at line 57 of file cipethernetlink.c.