Skip to main content

Universal Driver

When activated on the OrionMeter LA-IP-MBUS device, the universal driver enables polling of meters using the M-Bus protocol in the selected operating mode.
The driver is easy to configure and can be adapted to a wide range of both standard and non-standard metering devices.

Operating Modes​

The universal driver supports two operating modes, each designed for a specific class of devices and integration scenarios.

Standard Addressed Mode​

Used to poll standard-compliant M-Bus meters that support the typical request–response structure.
In this mode, the driver:

  • accesses the meter using:
    • a network address (1 byte), or
      • M-Bus commands:
        • SND_NKE — initialize communication;
        • REQ_UD2 — request user data;
    • a serial number (4 bytes, BCD);
      • M-Bus commands:
        • SND_NKE — initialize communication;
        • SND_UD — slave select;
        • REQ_UD2 — request user data;
  • expects a typical response in the form of RSP_UD;
  • parses and forwards the response to the LoRaWAN network.

Sequence Diagram​

Configuration​

The command set and response format are fixed. Configuration only includes the device address, scheduling, and error handling.

Available parameters:

  • Address type — network (1 byte) or serial number (4 bytes, BCD);
  • Meter address — defined in one of two formats:
    • Network address — value from 0x01 to 0xFD, used for direct addressing;
    • Serial number — 4 BCD-encoded bytes (least significant byte first), used for selection via SND_UD;
  • Polling interval — defined in 10-minute steps;
  • Start time — hour of the day when polling begins;
  • Retry count — number of attempts in case of no response;
  • Result transmission flag — enables or disables forwarding of the response to LoRaWAN;
  • Group activity — enables or disables this configuration.

The SND_NKE, REQ(Slave select), REQ_UD2 commands are generated automatically.
The received RSP_UD response is transmitted to LoRaWAN without modification.

Each configuration group operates independently.

info

The device supports up to 4 configuration groups, each with its own address and schedule.

Data Transmission to LoRaWAN​

The data received in response to the RSP_UD command is transmitted to the LoRaWAN network without any modifications, using Payload format ID 0x17. During transmission, the current Spread Factor (SF) used by the device is taken into account. If the data does not fit into the transmission queue, it is fragmented into multiple packets for successful delivery.

Custom Mode​

Used for meters that:

  • do not support standard M-Bus commands;
  • require a custom exchange sequence;
  • or return data in a non-standard format.

In this mode:

  • the user defines the command manually as a byte array;
  • a timeout and pre-transmission delay are specified;
  • result transmission to LoRaWAN can be disabled (e.g. for SND_NKE commands).

Sequence Diagram​

Below is an example of sending pre-configured commands:

  • 1040FE3E16
  • 107BFE7916
  • 1040FE3E16

Configuration​

This mode provides flexible control over the communication process.

Available parameters:

  • Command — user-defined byte array to be sent to the meter. Maximum length is 30 bytes;
  • Command length — actual number of bytes to transmit;
  • Pre-delay — delay before command transmission (in milliseconds);
  • Response timeout — maximum wait time for a reply after sending the command;
  • Result transmission flag — determines whether the received response is forwarded to LoRaWAN;
  • Polling interval — defined in 10-minute steps;
  • Start time — hour of the day when polling begins;
  • Retry count — number of retry attempts in case of timeout, CRC errors, etc.;
  • Group activity — enables or disables this configuration group.

If the result transmission flag is enabled, the response is sent to LoRaWAN without modification.

info

Up to 4 configuration groups can be active simultaneously, each with its own exchange parameters.

Data Transmission to LoRaWAN​

The response received to a request that requires transmission is forwarded to the LoRaWAN network without any modifications, using Payload format ID 0x17. During transmission, the current Spread Factor (SF) used by the device is taken into account. If the data does not fit into the transmission queue, it is fragmented into multiple packets for successful delivery.