5.7 I2C Data Packet
The I2C Data Packet configures an I2C read, write, or combined write and read operation.
| Field | Description | Notes |
|---|---|---|
| Address | A 7-bit I2C device address | Decimal or hexadecimal Error: “Address must be a 7-bit hexadecimal or an unsigned integer.” |
| Operation | The I2C operation type | Write, Read or Write + Read |
| Write Length | The number of bytes to write | Read-only; automatically calculated from the write data Tooltip: “Auto-calculated” |
| Data Source | Where the write data comes from | Enter here (manual entry) or Import file |
| Write Data | Comma-separated byte values (0–255) | Decimal or hexadecimal values Error: “Please enter values separated by commas. Each value must be a decimal or hexadecimal number from 0 to 255.” |
| Read Length | Number of bytes to read | Integer from 1 to 65,535 |
| Read Data | The data received from the device | Read-only; populated after a successful read. After a successful read, a Save to file button appears next to the Read Data field to export the received data. |
All fields with validation(Address, Write Length, Write Data, and Read Length) display a validation icon:
| Icon State | Tooltip | Notes |
|---|---|---|
| Editing | “Click to validate [field].” | Shown while the user is editing the field |
| Error | Field-specific error message (e.g., “Address must be a 7-bit hexadecimal or an unsigned integer.”) | Shown after validation detects errors |
Fastpath:
- Pressing <Enter> in a field or clicking anywhere outside the field triggers validation
- A Reset field button appears on the Write Data input, allowing the user to reset the data source selection and re-enter data if needed
- The Address, Write Data, and Read Data fields each have a HEX/DEC toggle button that switches the display and input format between hexadecimal and decimal. The currently active format is highlighted, and a hint label (HEX or DEC) is shown next to the field when it is not in focus. The format is auto-detected from the first byte entered (values starting with 0x are treated as hexadecimal).
