Netris2

Description of the device
The model NETRIS®2 IIoT-capable WIKA radio unit is used wherever centralised, web-based, remote monitoring of measuring instrument data is required. The Ex radio unit receives the data via the two intrinsically safe, analogue 4 ... 20 mA input signals. The fully encapsulated instrument with IP55 ingress protection transmits the received data continuously to a cloud via configurable data packets with LoRaWAN® (Long Range Wide Area Network). Battery-operated wireless transmission via LoRaWAN® is based on LPWAN technology to enable high transmission ranges and long battery life. The radio unit is connected to a suitable measuring instrument via cable. The simple web configuration via the cloud and the LoRaWAN® network enables the complete end-to-end encryption with bidirectional communication for safe IIoT applications. The WIKA radio unit NETRIS®2 is part of the WIKA IIoT solution. With this, WIKA offers a holistic solution for your digitalization strategy.
For more information see product site.
NETRIS2 Parser Quick Start
Parser API
All functions are pure. NETRIS2 does not support changing measuring ranges because both channels are fixed to 4-20 mA.
Types:
Input types:
interface UplinkInput {
fPort: number // LoRaWAN FPort
bytes: number[] // Raw payload as array of unsigned bytes (0-255)
recvTime?: string // Optional ISO timestamp (if your LNS provides it)
}
interface HexUplinkInput {
fPort: number // LoRaWAN FPort
bytes: string // Raw payload as hex-encoded string (case-insensitive, even length)
recvTime?: string // Optional ISO timestamp (if your LNS provides it)
}Return type (shared by all decode helpers):
type Result = {
data: Record<string, any> // Parsed key/value pairs
warnings?: string[] // Non-fatal anomalies
} | {
errors: string[] // Fatal or structural issues only
}To understand the data field, take a look at the examples and the schema definition.
Supported channels to identify different sensors by:
// Is used in the returned data
type ChannelName = 'Electrical current1' | 'Electrical current2'Channels that support adjusting the measurement range:
type AdjustableChannelName = never // No adjustable channels in NETRIS2Channel Configuration:
| Channel Name | Default Min | Default Max | Unit | Configurable |
|---|---|---|---|---|
Electrical current1 | 4 | 20 | mA | No |
Electrical current2 | 4 | 20 | mA | No |
Both channels have fixed 4-20 mA ranges that cannot be adjusted.
decodeUplink(input)
function decodeUplink(input: UplinkInput): ResultdecodeHexUplink(hexInput)
function decodeHexUplink(hexInput: HexUplinkInput): Resultbytes must have even length; case-insensitive.
adjustMeasuringRange(channel, range)
// Will always throw for NETRIS2 because no channel supports range updates
function adjustMeasuringRange(
channelName: AdjustableChannelName,
range: {
start: number
end: number
}
): voidNETRIS2 exposes the common parser API, but both current channels are fixed by the device and protocol. No range adjustment is required or supported.
adjustRoundingDecimals(decimals)
// Smartly adjust number of decimals for rounded values
// Impacts all numeric values in all outputs
// Default is 4
function adjustRoundingDecimals(decimals: number): voidApplies to future decodes only.
encodeDownlink(input)
type DownlinkInput = {
protocol: 'TULIP2'
input: {
deviceAction: 'configuration'
// Configuration fields...
} | {
deviceAction: 'resetBatteryIndicator'
configurationId?: number
}
} | {
protocol: 'TULIP3'
input: {
action: 'readRegisters'
// Read register fields...
} | {
action: 'writeRegisters'
// Write register fields...
} | {
action: 'forceCloseSession'
} | {
action: 'restoreDefaultConfiguration'
} | {
action: 'newBatteryInserted'
} | {
action: 'getAlarmStatus'
// Alarm status fields...
}
}
// encode a single downlink frame
function encodeDownlink(input: DownlinkInput): {
bytes: number[] // Encoded downlink payload as array of unsigned bytes (0-255)
fPort: number // LoRaWAN FPort to use
warnings?: string[] // Non-fatal anomalies
} | {
errors: string[] // Fatal or structural issues only
}Validates the input and encodes it into a single downlink frame. If the documentation refers to percentage values, use the real-world current values. For NETRIS2, 20% within a 4-20 mA span corresponds to 7.2 mA because 0.2 multiplied by (20 minus 4), plus 4, equals 7.2.
To understand the input structure, refer to the downlink schema definition and downlink examples.
encodeMultipleDownlinks(input)
// Same input type as encodeDownlink()
// encodes the given configuration in one or more downlink frames depending on byte size
function encodeMultipleDownlinks(
input: DownlinkInput
): {
frames: number[][] // Encoded downlink payloads as arrays of unsigned bytes (0-255)
fPort: number // LoRaWAN FPort to use
warnings?: string[] // Non-fatal anomalies
} | {
errors: string[] // Fatal or structural issues only
}To understand the input structure, refer to the downlink schema definition and downlink examples.
About NETRIS2 Channels
Note: NETRIS2 has fixed 4-20 mA measurement ranges for both channels that cannot be adjusted. The device always reads electrical current in the 4-20 mA range. No configuration is required for measurement ranges.
If you need to verify the device configuration, check the identification frames after device activation.
TULIP3 Identification Frames
For devices using TULIP3 protocol, the first uplinks after device activation can include identification messages (message type 20/0x14) that report the actual configured measurands, units, and register-backed metadata for both channels.
- Current channel 1: Check
sensor1/channel1formeasurand,unit, and identification registers. - Current channel 2: Check
sensor1/channel2formeasurand,unit, and identification registers. - Communication module: Product, channel plan, firmware, and serial number are exposed on the communication module level.
Example TULIP3 identification frame:
{
"data": {
"messageType": 20,
"messageSubType": 1,
"identification": {
"sensor1": {
"channel1": {
"measurand": "Current",
"unit": "mA",
"minMeasureRange": 4,
"maxMeasureRange": 20,
"channelName": "Electrical current1"
},
"channel2": {
"measurand": "Current",
"unit": "mA",
"minMeasureRange": 4,
"maxMeasureRange": 20,
"channelName": "Electrical current2"
}
}
}
}
}TULIP2 Identification Frames
Identification messages (message type 6/0x06) confirm the configured channels:
Example TULIP2 identification frame:
{
"data": {
"messageType": 6,
"configurationId": 1,
"productIdName": "NETRIS2",
"channels": [
{
"channelId": 0,
"channelName": "Electrical current1"
},
{
"channelId": 1,
"channelName": "Electrical current2"
}
]
}
}Quick Start
- No measurement range configuration is needed because both channels are fixed to 4-20 mA.
- Add a wrapper function if your network server is non-compliant:
function decode(input) { return decodeUplink(input) } - Use
protocol: 'TULIP2'orprotocol: 'TULIP3'when encoding downlinks. - Refer to the schema and examples for the exact downlink structure.
NPM Module Inclusion
| Device | Included | Factory function |
|---|---|---|
| NETRIS2 | ✔️ | NETRIS2Parser |
