Cpppo is a Communication Protocol Python Parser and Originator
Cpppo is used to create event-driven state machines which consume a stream of input and generate a series of state changes, or an indication that no progress is possible due to (for example) exhaustion of input symbols.
This is useful for creating parsers for complex grammars describing languages, including binary computer protocols.
An example included with cpppo is an implementation of a subset of the EtherNet/IP CIP language used by some industrial control equipment, such as Rockwell’s Logix Controllers. The cpppo.server.enip package can be used to create Python programs which can parse requests in this protocol (eg. as a server, to implement something like a simulated Controller) or originate requests in this protocol (eg. as a client, sending commands to a Controller).
In addition, the ability to read, write and poll remote PLCs of various types including Modbus/TCP is provided.