IoTIVP-Binary defines the raw bytes-on-wire format for the IoTIVP ecosystem.
It is engineered for:
- Low-power devices (ESP32, RP2040, STM32)
- LoRa, BLE, UWB, WiFi, Sub-GHz
- Robotics & sensors
- Environments requiring integrity with minimal overhead
+---------+------------+-----------+-----------+--------+--------+
| Header | Timestamp | Device ID | TLV Block | Nonce | Hash |
+---------+------------+-----------+-----------+--------+--------+
1B 2–4B 1–4B variable 0–2B 4–8B
This provides unlimited flexibility for custom sensors.
| Type | Meaning | Value Format |
|---|---|---|
| 0x01 | Temperature | int16 fixed-point |
| 0x02 | Humidity | uint8 |
| 0x03 | Battery | uint8 |
| ... | Extend freely | Custom |
The final bytes are a BLAKE2s or SHA-256 truncated hash:
hash = blake2s(header + timestamp + id + tlv + nonce + secret)
Length: 4–8 bytes depending on profile.
from iotivp_binary import BinaryConfig, encode_packet
cfg = BinaryConfig(
timestamp_len=2,
device_id_len=2,
nonce_len=1,
hash_len=4,
hash_alg="blake2s"
)
packet = encode_packet(
header=0x01,
timestamp=512,
device_id=42,
tlv_fields=[
(0x01, (235).to_bytes(2, "big")), # temperature
],
nonce=7,
cfg=cfg
)
print(packet.hex())from iotivp_binary import decode_packet
decoded = decode_packet(packet_bytes, cfg=cfg)
print(decoded)- ✔ Ultra-low overhead
- ✔ MCU-friendly
- ✔ Cryptographic integrity
- ✔ TLV extensibility
- ✔ Deterministic layout for firmware
- LoRaWAN payloads
- BLE/Bluetooth LE advertisements
- Robotics control sensors
- Satellite IoT links
- Mobile asset tags
IoTIVP-Binary powers the entire IoTIVP integrity pipeline.