Files
qitech-control/docs/developer-docs/Xtrem_protocol.md
T
2025-12-18 11:15:00 +01:00

5.4 KiB
Raw Blame History

XTREM Communication Protocol

Version: 3.007 Device: XTREM / XTREM-S Weighing Module Standard: OIML R76:2006 / EN45501:2015 compliant


Overview

The XTREM communication protocol allows a terminal or host controller to exchange data and commands with the XTREM weighing module. The device transmits and receives ASCII-coded frames over a serial interface (RS232, RS485, Wi-Fi, or Ethernet, depending on configuration).

Since we are using the Ethernet interface we need to provide some kind of DHCP to assign an IP - Address to each XTREM Device. They then may be addressed via a broadcast IP (e.g.: 192.168.4.255/24). A Unicast communication is applied through the device ID inside the XTREM Frame.


Frame Structure

Each message—both query and response—has the same format:

STX ID_O ID_D F D_ADDRESS D_L DATA LRC ETX
Field Description Length (bytes)
STX Start of message (ASCII 02h) 1
ID_O Sender address (2 ASCII hex chars) 2
ID_D Destination address (2 ASCII hex chars) 2
F Function code (R, W, E, etc.) 1
D_ADDRESS Data address (register, 4 ASCII hex chars) 4
D_L Data length (2 ASCII hex chars) 2
DATA Optional data field Variable
LRC Longitudinal Redundancy Check (2 ASCII hex chars) 2
ETX End of message (ASCII 03h) 1

In the default configuration the Frame also requires a CRLF at the end.

Example:

STX ‘1’ ‘7’ ‘0’ ‘1’ ‘R’ ‘0’ ‘1’ ‘0’ ‘1’ ‘0’ ‘0’ LRC ETX CR LF

Function Codes

Function ASCII Hex Description