mei_message — MEI Modbus Messages

API Documentation

Encapsulated Interface (MEI) Transport Messages

class pymodbus.mei_message.ReadDeviceInformationRequest(read_code=None, object_id=0, **kwargs)[source]

This function code allows reading the identification and additional information relative to the physical and functional description of a remote device, only.

The Read Device Identification interface is modeled as an address space composed of a set of addressable data elements. The data elements are called objects and an object Id identifies them.

__init__(read_code=None, object_id=0, **kwargs)[source]

Initializes a new instance

Parameters:
  • read_code – The device information read code
  • object_id – The object to read from
encode()[source]

Encodes the request packet

Returns:The byte encoded packet
decode(data)[source]

Decodes data part of the message.

Parameters:data – The incoming data
execute(context)[source]

Run a read exeception status request against the store

Parameters:context – The datastore to request from
Returns:The populated response
__str__()[source]

Builds a representation of the request

Returns:The string representation of the request
class pymodbus.mei_message.ReadDeviceInformationResponse(read_code=None, information=None, **kwargs)[source]
classmethod calculateRtuFrameSize(buffer)[source]

Calculates the size of the message

Parameters:buffer – A buffer containing the data that have been received.
Returns:The number of bytes in the response.
__init__(read_code=None, information=None, **kwargs)[source]

Initializes a new instance

Parameters:
  • read_code – The device information read code
  • information – The requested information request
encode()[source]

Encodes the response

Returns:The byte encoded message
decode(data)[source]

Decodes a the response

Parameters:data – The packet data to decode
__str__()[source]

Builds a representation of the response

Returns:The string representation of the response