DeterministicESPAsyncWebServer v6.27.1
Zero-allocation, bounded-execution async HTTP server for ESP32
Loading...
Searching...
No Matches
cip.h File Reference

CIP (Common Industrial Protocol) message codec (DETWS_ENABLE_CIP) - zero-heap request builder + response parser for the message that rides inside an EtherNet/IP Unconnected Data item (services/enip). Together they form a working CIP read path. More...

#include "ServerConfig.h"

Go to the source code of this file.

Detailed Description

CIP (Common Industrial Protocol) message codec (DETWS_ENABLE_CIP) - zero-heap request builder + response parser for the message that rides inside an EtherNet/IP Unconnected Data item (services/enip). Together they form a working CIP read path.

A CIP message request is:

Service(1) RequestPathSize(1, in 16-bit words) RequestPath(EPATH) ServiceData

The EPATH addresses an object with logical segments. A logical segment byte is 0x20 | logical-type | format, where logical-type is class (0x00), instance (0x04), or attribute (0x10), and format is 8-bit (0x00, then a 1-octet id) or 16-bit (0x01, then a pad octet and a little-endian 2-octet id). A response is Service|0x80 reserved(0) GeneralStatus(1) AdditionalStatusSize(1, words) [additional status] ServiceData.

Service codes + the logical-segment encoding are verified against the Wireshark CIP dissector. This codec is the CIP message; wrap it with eip_build_send_rr_data.

Author
Douglas Quigg (dstroy0)
Date
2026

Definition in file cip.h.