Skip to main content

Crate opcua_kit

Crate opcua_kit 

Source
Expand description

§opcua-kit

An early-stage Rust toolkit for OPC Unified Architecture (OPC UA). The initial release provides one small, dependency-free utility for interpreting the severity of a raw OPC UA status code. It supports no_std. Client and server functionality are outside the scope of this release.

use opcua_kit::{Severity, status_severity};

assert_eq!(status_severity(0x80AB_0000), Severity::Bad); // BadInvalidArgument

The severity occupies the two highest bits. The function treats the reserved bit pattern as bad, following the guidance for OPC UA clients. Keep the original code for diagnostics and data-quality flags. OPC UA Part 4, StatusCode

Dual-licensed under MIT or Apache-2.0.

Enums§

Severity
Client interpretation of the severity field of an OPC UA StatusCode.

Functions§

status_severity
Classifies the two severity bits, independently of the subcode and flags.