Skip to main content

Module mbus

Module mbus 

Source
Expand description

Import an authenticated wireless M-Bus (OMS) gas meter telegram into a TAF 15 history.

Open the radio telegram with the upstream crate, for example [protocol::wireless::open] with the meter’s key. Then pass its application layer to capture_telegram. Only telegrams whose MAC or tag verified (OMS mode 7 with an AFL CMAC, or mode 10) are accepted. Mode 5 and the ELL hide a reading, but anyone in radio range can alter it without the key, so they are rejected as unauthenticated.

Gas meters push readings without a gateway request. The host times them with its own clock (Slot) and keeps the last accepted message counter. It stores Accepted::counter in the same transaction as the history and passes it back as last_counter on the next call. A counter that does not rise is a replay.

Re-exports§

pub use mbus_kit as protocol;

Structs§

Accepted
An accepted reading and the message counter the host must store with it.
Source
The meter and register commissioned for one gas channel.

Enums§

ReadError
Why a telegram was not imported. The destination is unchanged in every case.

Functions§

capture_telegram
Record the volume register of one authenticated telegram at slot.