Integration

Introduction

Note

This section only describes device-specific information and is meant to be used with the “Elvaco NB-IoT MCM Integrator’s guide” which contains common information.

For device management, the module will act as a LwM2M client connecting to a LwM2M server. The Device Management system enables configuration and monitoring of the module remotely. This includes setting configuration parameters, update the firmware and trigger momentaneous/historical readouts of the module. For meter data transport, the module uses either the MQTT-SN protocol or LwM2M send.

Upon activation, the device will attempt to connect to its configured bootstrap server via the mobile (NB-IoT) network. When successful, the module will receive connection credentials, i.e. IP addresses to the DM server and the meter data server.

The module will thereafter connect to the DM server and perform a DTLS handshake to generate the session key used to encrypt the data that is transmitted between DM server and module. Note that using DTLS is optional, and the product also support unencrypted communication.

If using MQTT-SN as for meter data delivery, the module will after connection to the DM server try toconnect to the MQTT-SN gateway. If succesful, a DTLS handshake will be performed to generate the sessions keys used to encrypt the session key used to encrypt the meter data transport if configured to do so.

Each module has a security chip where a device-unique set of keys are stored. These are provisioned to the module during production. The UDP transport of both DM and MDM can be secured using DTLS 1.2. Either the pre-provisioned keys can be used, or new keys can be provisioned during the bootstrap phase.

Status and configuration parameters

Standard LwM2M status and configuration parameters

Table 5. All standard LwM2M status and configuration parameters

Op.

LwM2M object

LwM2M resource

ID

Type

Range or Enumeration

Comment

R

LwM2M Security

LWM2M Server URI

0/0/0

String

Bootstrap URI

R

LwM2M Security

Bootstrap server

0/0/1

Bool

TRUE

R

LwM2M Security

Security Mode

0/0/2

Integer

0..4

BS Security mode

0 = PSK mode

3 = No security

R

LwM2M Security

PSK Identity

0/0/3

Opaque

DevEUI

-

LwM2M Security

Secret Key

0/0/4

Opaque

Bootstrap PSK

R

LwM2M Security

Short Server ID

0/0/10

Integer

1..65534

R

LwM2M Server

Short Server ID

1/0/0

Integer

1..65534

R

LwM2M Server

Lifetime

1/0/1

Integer

E

LwM2M Server

Bootstrap Request Trigger

1/0/9

R(W)

LwM2M Security

LWM2M Server URI

0/1/0

String

DM ServerURI

Writable by

Bootstrap server

R

LwM2M Security

Bootstrap server

0/1/1

Bool

FALSE

R(W)

LwM2M Security

Security Mode

0/1/2

Int

0..4

DM Security mode

Writable by

Bootstrap server

R

LwM2M Security

PSK Identity

0/1/3

Opaque

DM PSK identity (DevEUI)

(W)

LwM2M Security

Secret Key

0/1/4

Opaque

DM PSK

Writable by

Bootstrap server

R

LwM2M Security

Short Server ID

0/1/10

Integer

1..65534

R

LwM2M Server

Short Server ID

1/1/0

Integer

1..65534

R

LwM2M Server

Lifetime

1/1/1

Integer

DM lifetime

E

LwM2M Server

Registration Update Trigger

1/1/8

R

Device

Manufacturer

3/0/0

String

Manufacturer

("Elvaco")

R

Device

Model Number

3/0/1

String

Product model

("CMi6110")

R

Device

Serial Number

3/0/2

String

DevEUI

R

Device

Firmware Version

3/0/3

String

Firmware version

E

Device

Reboot

3/0/4

Reboot

R

Device

Available Power Sources

3/0/6/0

Integer

0..7

Power source

1: Internal battery

2: External battery

6: AC (Mains) power

R

Device

Power Source Voltage

3/0/7/0

Integer

Power source voltage (Millivolt)

R

Device

Battery level

3/0/9

0..100

Battery level (in %)

R

Device

Error Code

3/0/11/0

0..8

Error codes, according to LwM2M 1

RW

Device

Current Time

3/0/13

Time

Current time

RW

Device

UTC Offset

3/0/14

String

UTC Offset

UTC+X (ISO 8601)

R

Device

Hardware version

3/0/18

String

Hardware version

R

Connectivity Monitoring

Network Bearer

4/0/0

Integer

0..50

7 = NB-IoT

R

Connectivity Monitoring

Available Network Bearer

4/0/1/0

Integer

0..50

7 = NB-IoT

R

Connectivity Monitoring

Radio Signal Strength

4/0/2

Integer

RSRP

(NRSRP)

R

Connectivity Monitoring

APN

4/0/7/0

String

APN

R

Connectivity Monitoring

Cell ID

4/0/8

Integer

Cell ID

R

Connectivity Monitoring

SMNC

4/0/9

Integer

0..999

MNC

PLMN = SMNC + SMCC

R

Connectivity Monitoring

SMCC

4/0/10

Integer

0..999

MCC

PLMN = SMNC + SMCC

W

Firmware Update

Package URI

5/0/1

Firmware Update URI

E

Firmware Update

Update

5/0/2

Firmware

Update Trigger

R

Firmware Update

State

5/0/3

Integer

0..3

Firmware Update Status

0: Idle

1: Downloading

2: Downloaded

3: Updating

R

Firmware Update

Update result

5/0/5

Integer

Firmware Update Result

R

Firmware Update

Firmware Update Protocol Support

5/0/8/0

Integer

0..5

0 = CoAP

R

Firmware Update

Firmware Update Delivery Method

5/0/9

Integer

0..2

0 = Pull only

’R

LwM2M Cellular Connectivity

PSM Timer

10/0/4

Integer

NB-IoT T3412.

.

R

LwM2M Cellular Connectivity

Active Timer

10/0/5

Integer

NB-IoT T3324.

R

LwM2M Cellular Connectivity

eDRX parameters for NB-S1 mode

10/0/9

Opaque

8 bit

NB-IoT eDRX.

R

LwM2M Cellular Connectivity

Activated Profile names

10/0/11

ObjLink

Link to APN Connection Profile object

RW

LwM2M APN Connection Profile

Profile name

11/[0,1]/0

String

RW

LwM2M APN Connection Profile

APN

11/[0,1]/1

String

Manual APN

Writable in object resource

1.

RW

LwM2M APN Profile

Auto select APN by device

11/[0,1]/2

Boolean

Auto APN Mode

Writable in object resource

1.

RW

LwM2M APN Connection Profile

Authentication Type

11/[0,1]/4

Integer

0..3

3 = None, Writing currently not supported


Elvaco product specific LwM2M obje

Table 6. All product specific LwM2M objects

LwM2M object

LwM2M resource

ID

Type

Op.

Range or Enumeration

Comment

Elvaco MCM Config

Meter Readout Interval

33906/./0

Integer

RW

Interval in minutes

Elvaco MCM Config

Report data encoding

33906/./1

Integer

RW

0 = SenML/CBOR

1 = JSON

2 = M-Bus

Elvaco MCM Config

Report frame type

33906/./2

Integer

RW

42 = CMi6110_Standard

43 = CMi6110_Extended

Elvaco MCM Config

Eco mode enabled

33906/./3

Boolean

RW

Elvaco MCM Config

NFC Enabled

33906/./4

Boolean

RW

Elvaco MCM

Config

NFC Configlocked

33906/./5

Boolean

R

Elvaco MCM Config

Adjust time

33906/./6

Integer

W

Adjustment in seconds

Elvaco MCM Config

Instantaneous readout trigger

33906/./10

E

Trigger a meter readout.

Elvaco MCM Config

Historic resend trigger

33906/./13

E

Trigger upload of all historic

Elvaco MCM Config

Historic resend status

33906/./14

Integer

R

Number of messages in uplink queue

Elvaco MCM Config

Apply APN staging profile

33906/./15

E

Apply APN staging profile.

Elvaco MCM Config

Config write status

33906/./16

Boolean

R

Result of last config write to flash

Elvaco MCM Config

Meter Report Interval

33906/./17

Integer

RW

Interval in minutes

Elvaco MCM Config

Meter Transmit Interval

33906/./18

Integer

RW

Interval in minutes

Elvaco MCM Config

Meter Transmit Offset

33906/./19

Integer

RW

Offset in minutes

Elvaco MCM Config

Meter Transmit Delay

33906/./20

Integer

RW

Delay in minutes

Elvaco MCM

Meter Uploads Per Tx

33906/./21

Integer

RW

Max number of messages per tx interval

Elvaco MCM Config

DTLS Min Timeout

33906/./22

Integer

RW

Timeout in seconds

Elvaco MCM Config

DTLS Max Timeout

33906/./23

Integer

RW

Timeout in seconds

Elvaco MCM Config

MQTT-SN Communication Timeout

33906/./24

Integer

RW

Timeout in seconds

Elvaco MCM Config

MQTT-SN Communication Attempts

33906/./25

Integer

RW

Total number of attempts

Elvaco MCM

MQTT-SN Register Timeout

33906/./26

Integer

RW

OBSOLETE!

Timeout in seconds

Elvaco MCM

MQTT-SN Register Attempts

33906/./27

Integer

RW

OBSOLETE!

Total number of attempts

Elvaco MCM Config

MQTT-SN Publish Timeout

33906/./28

Integer

RW

OBSOLETE!

Timeout in seconds

Elvaco MCM Config

MQTT-SN Publish Attempts

33906/./29

Integer

RW

OBSOLETE!

Total number of attempts

Elvaco MCM Config

CoAP ACK Timeout

33906/./30

Integer

RW

Timeout in seconds

Elvaco MCM Config

CoAP Max Retransmit

33906/./31

Integer

RW

Number of retransmissions

Elvaco MCM Config

IOWA DTLS Min Timeout

33906/./32

Integer

RW

Timeout in seconds

Elvaco MCM Config

IOWA DTLS Max Timeout

33906/./33

Integer

RW

Timeout in seconds

Elvaco MCM Config

IOWA Communication Retry Count

33906/./34

Integer

RW

Number of

Elvaco MCM Config

IOWA Communication Retry Delay

33906/./35

Integer

RW

Delay in seconds

Elvaco MCM Config

IOWA Communication Sequence Retry Count

33906/./36

Integer

RW

Number of

Elvaco MCM Config

IOWA Communication Sequence Retry Delay

33906/./37

Integer

RW

Delay in seconds

Elvaco MCM Config

Network Connection Maximum Hold-off

33906/./38

Integer

RW

Delay in seconds

Elvaco MCM Config

Network Search Period

33906/./39

Integer

RW

Period in seconds

Elvaco MCM Config

Modem Restart Back-off Intervals

33906/./40

String

RW

min0max0,min1-max1,... in minutes

Elvaco MCM Config

MDM Re-connect Back-off Intervals

33906/./41

String

RW

min0max0,min1-max1,... in minutes

Elvaco MCM Config

LwM2M Resume Back-off Intervals

33906/./42

String

RW

min0max0,min1-max1,... in minutes

Elvaco MCM Config

Meter Max Retry Count

33906/./43

Integer

RW

Max number of retries when meter communication

Elvaco MCM

Auto Upload Age Limit

33906/./44

Integer

RW

Max age in minutes of unsent

Elvaco MCM Config

Auto Upload Order

33906/./45

Integer

RW

In what order should unsent measurements be uploaded.

0 = FIFO

1 = LIFO.

Elvaco MCM

Time Sync Source

33906/./46

Integer

RW

Which source to use for time synchronization.

0 = Manual

1 = Network.

Elvaco MCM Config

MDM Communication Failures

33906/./47

Integer

RW

Maximum number of failures before connection is considered broken.

Elvaco MCM Config

Upload Protocol

33906/./48

Integer

RW

0..1

Protocol to use for meter data upload

0 = MQTT-SN

1 = LwM2M

Elvaco MCM Config

Use PSM

33906/./49

Integer

RW

0..3

Power saving mode:

0 = Disabled

1 = eDRX

2 = PSM

3 = PSM + eDRX

Elvaco MCM

eDRX Mode

33906/./50

Integer

RW

0..1

eDRX mode:

0 =Automatic

1 = Manual

Elvaco MCM

Enable RAI

33906/./51

Integer

RW

0..1

Enable RAI:

0 = RAI Disabled

1 = RAI=2 for MQTT-SN QoS=1

Elvaco MCM

Power Source

33906/./52

Integer

RW

0..1

Configuration value for power source. Used when hardware unit cannot determine source.

0 = Battery

1 = PSU

Elvaco MCM Config

NB-IoT Radio Bands

33906/./53

String

RW

NB-IoT Radio Bands to use: band0,band1,...

Elvaco MDM Server

URI

33905/./0

String

RW

URI to the meter data server

Elvaco MDM Server

Protocol

33905/./1

Integer

RW

0..

0 = MQTT-SN

Elvaco MDM Server

Transport Security Mode

33905/./2

Integer

RW

0..4

0 = PSK mode

3 = No security

Elvaco MDM Server

Transport Secret Key

33905/./5

Opaque

W

Key to use with the selected security mode

Elvaco MDM Server

Connection config

33905/./10

Integer

RW

0..1

0 = Optimized

1 = Compliant

Elvaco MDM Server

Topic

33905/./11

String

RW

MQTT-SN topic

Elvaco Meter Data

Message Type

33911/./0

Integer

R

Elvaco Meter Data

Message Encoding

33911/./1

Integer

R

Elvaco Meter Data

Message Data

33911/./2

Opaque

R

Elvaco Meter Info

Meter Model

33908/./0

String

R

User-friendly string

Elvaco Meter Info

Meter ID

33908/./1

Integer

R

Elvaco Meter Info

Communication status

33908/./2

Integer

R

0..2

0 = OK

1 = No meter detected

2 = Error

Elvaco Meter

Error flags

33908/./3

Opaque

R

Elvaco NB-IoT

IMSI

33909/./0

Integer

R

International mobile subscriber identity

Elvaco NB-IoT

ICCID

33909/./1

String

R

Integrated circuit card identifier

Elvaco NB-IoT

Registrations

33909/./2

Integer

R

Number of network registrations done

Elvaco NB-IoT

Last registration duration

33909/./3

Integer

R

Duration in seconds

Elvaco NB-IoT

Modem model

33909/./4

String

R

Elvaco NB-IoT

Modem firmware

33909/./5

String

R

Elvaco NB-IoT

Registration uptime

33909/./6

Integer

R

Last network registration uptime in seconds

Elvaco NB-IoT status

Uptime

33907/./0

Integer

R

Uptime in seconds

Elvaco NB-IoT status

Average current consumption

33907/./1

Integer

R

Consumption in uA (micro-amps)

Elvaco NB-IoT status

Network classification

33907/./2

Integer

R

0 = Excellent

1 = Good

2 = Fair

3 = Poor

Elvaco NB-IoT status

ECL

33907/./3

Integer

R

0..2

Elvaco NB-IoT status

RSSI

33907/./4

Integer

R

In tenths of dBm

Elvaco NB-IoT status

SNR

33907/./5

Integer

R

In tenths of dB

Elvaco NB-IoT status

MDM connection status

33907/./10

Integer

R

0..5

0 = OK

1 = Connecting

2 = No credentials

3 = DTLS failed

4 = Communication failed

6 = Socket failed

7 = Idle

Elvaco NB-IoT status

Current radio band

33907/./11

Integer

R

0..85

Current radio band id

Elvaco Transaction statistics

Reset statistics

33910/./0

E

Resets statistics for what this object instance is tracking.

Elvaco Transaction statistics

Transactions

33910/./1

Integer

R

Number of transactions.

Elvaco Transaction statistics

Retransmissions

33910/./2

Integer

R

Number of retransmissions.

Elvaco Transaction statistics

Lost transactions

33910/./3

Integer

R

Number of lost transactions.

Elvaco Transaction statistics

Average response time

33910/./4

Integer

R

Elvaco Transaction statistics

Minimum response time

33910/./5

Integer

R

Elvaco Transaction statistics

Maximum

33910/./6

Integer

R


L+G UH50 error codes

Note

Make sure to double check error codes identifier and explanation with latest meter specification.

Table 7. L+G meter specific error codes

Bit-No

Identifier

Explanation

0

F0

Error during flow metering (e.g. Air in measuring pipe)

1

F1

Interruption of flow temperature sensor

2

F2

Interruption of return temperature sensor

3

F3

Electronic for temperature evaluation defective

4

F41

Meter battery empty

5

F5

Short-circuit flow temperature sensor

6

F6

Short-circuit return temperature sensor

7

F7

Fault in the internal memory (CRC)

8

F8

Error F1, F2, F5 or F6 pending for longer than 8h.

9

F9

Error in the electronics

10

F0V

Prewarning for soiling of the measurement tube

11

F7V2

Correctable error in the internal memory EEPROM 2


Changing APN via LwM2M

Since changing APN is a potentially hazardous operation that may render the device disconnected from the mobile network, there is a rollback functionality in place when changing the APN.

To change APN, write the APN to the resource /10/1/1 and set APN mode to manual in /10/1/2. Once done, stage the changes by executing /33906/0/15. When executed, the device will reset and try to use the new APN. If the device manages a successful bootstrapping, the new APN will be saved as the default. If a successful bootstrapping has not happened for some time, the device will roll back to the old APN and reset again.

Was this article helpful?

0 out of 0 found this helpful
Have more questions? Submit a request

Comments (0 comments)

Article is closed for comments.