OpENer - Open Source EtherNet/IP(TM) I/O Target Stack  2.1
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
typedefs.h File Reference
#include <inttypes.h>
#include <stddef.h>
#include <stdbool.h>
Include dependency graph for typedefs.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef uint8_t CipBool
 
typedef uint8_t CipByte
 
typedef int32_t CipDint
 
typedef uint32_t CipDword
 
typedef int16_t CipInt
 
typedef double CipLreal
 
typedef uint8_t CipOctet
 Data types as defined in the CIP Specification Vol 1 Appendix C. More...
 
typedef float CipReal
 
typedef int8_t CipSint
 
typedef uint32_t CipUdint
 
typedef uint16_t CipUint
 
typedef uint8_t CipUsint
 
typedef uint16_t CipWord
 
typedef uint8_t EipBool8
 
typedef uint8_t EipByte
 EIP Data type definitions. More...
 
typedef double EipDfloat
 
typedef float EipFloat
 
typedef int16_t EipInt16
 
typedef int32_t EipInt32
 
typedef int8_t EipInt8
 
typedef uint16_t EipUint16
 
typedef uint32_t EipUint32
 
typedef uint8_t EipUint8
 
typedef unsigned long long MicroSeconds
 
typedef unsigned long MilliSeconds
 

Enumerations

enum  EipStatus { kEipStatusOk = 0, kEipStatusOkSend = 1, kEipStatusError = -1 }
 EIP stack status enum. More...
 
enum  UdpCommuncationDirection { kUdpCommuncationDirectionConsuming = 0, kUdpCommuncationDirectionProducing = 1 }
 Communication direction of an UDP socket; consuming is receiver, producing is sender. More...
 

Detailed Description

Do not use interface types for internal variables, such as "int i;", which is commonly used for loop counters or counting things.

Do not over-constrain data types. Prefer the use of the native "int" and "unsigned" types.

Use char for native character strings.

Do not use "char" for data buffers - use "unsigned char" instead. Using char for data buffers can occasionally blow up in your face rather nastily.

Definition in file typedefs.h.

Typedef Documentation

typedef uint8_t CipBool

Boolean data type

Definition at line 42 of file typedefs.h.

typedef uint8_t CipByte

8-bit bit string

Definition at line 43 of file typedefs.h.

typedef int32_t CipDint

32-bit signed integer

Definition at line 51 of file typedefs.h.

typedef uint32_t CipDword

32-bit bit string

Definition at line 45 of file typedefs.h.

typedef int16_t CipInt

16-bit signed integer

Definition at line 50 of file typedefs.h.

typedef double CipLreal

64-bit IEEE 754 floating point

Definition at line 53 of file typedefs.h.

typedef uint8_t CipOctet

Data types as defined in the CIP Specification Vol 1 Appendix C.

8 bit value that indicates particular data type

Definition at line 41 of file typedefs.h.

typedef float CipReal

32-bit IEEE 754 floating point

Definition at line 52 of file typedefs.h.

typedef int8_t CipSint

8-bit signed integer

Definition at line 49 of file typedefs.h.

typedef uint32_t CipUdint

CipUdint 32-bit unsigned integer

Definition at line 48 of file typedefs.h.

typedef uint16_t CipUint

CipUint 16-bit unsigned integer

Definition at line 47 of file typedefs.h.

typedef uint8_t CipUsint

8-bit unsigned integer

Definition at line 46 of file typedefs.h.

typedef uint16_t CipWord

16-bit bit string

Definition at line 44 of file typedefs.h.

typedef uint8_t EipBool8

bool data types

Definition at line 37 of file typedefs.h.

typedef uint8_t EipByte

EIP Data type definitions.

8-bit bit string

Definition at line 28 of file typedefs.h.

typedef double EipDfloat

IEEE 754 64-bit floating point number

Definition at line 36 of file typedefs.h.

typedef float EipFloat

IEEE 754 32-bit floating point number

Definition at line 35 of file typedefs.h.

typedef int16_t EipInt16

16-bit signed number

Definition at line 30 of file typedefs.h.

typedef int32_t EipInt32

32-bit signed number

Definition at line 31 of file typedefs.h.

typedef int8_t EipInt8

8-bit signed number

Definition at line 29 of file typedefs.h.

typedef uint16_t EipUint16

16-bit unsigned number

Definition at line 33 of file typedefs.h.

typedef uint32_t EipUint32

32-bit unsigned number

Definition at line 34 of file typedefs.h.

typedef uint8_t EipUint8

8-bit unsigned number

Definition at line 32 of file typedefs.h.

typedef unsigned long long MicroSeconds

Definition at line 69 of file typedefs.h.

typedef unsigned long MilliSeconds

Definition at line 68 of file typedefs.h.

Enumeration Type Documentation

enum EipStatus

EIP stack status enum.

The following are generally true regarding return status: -1 ... an error occurred 0 ... success

Occasionally there is a variation on this: -1 ... an error occurred 0 .. success and there is no reply to send 1 ... success and there is a reply to send

For both of these cases EIP_STATUS is the return type.

Other return type are: – return pointer to thing, 0 if error (return type is "pointer to thing") – return count of something, -1 if error, (return type is int)

Enumerator
kEipStatusOk 

Stack is ok

kEipStatusOkSend 

Stack is ok, after send

kEipStatusError 

Stack is in error

Definition at line 93 of file typedefs.h.

Communication direction of an UDP socket; consuming is receiver, producing is sender.

These are used as array indexes, watch out if changing these values

Enumerator
kUdpCommuncationDirectionConsuming 

Consuming direction; receiver

kUdpCommuncationDirectionProducing 

Producing direction; sender

Definition at line 104 of file typedefs.h.