HF-TMC51x0 Driver (TMC5130 & TMC5160) 0.1.0-dev
Hardware Agnostic C++ Driver for the TMC51x0 (TMC5130 & TMC5160)
Loading...
Searching...
No Matches
tmc51x0::UartConfig Struct Reference

UART communication configuration structure. More...

#include <tmc51x0_types.hpp>

Public Member Functions

 UartConfig ()=default
 Default constructor.
 

Public Attributes

uint8_t node_address {0}
 UART node address.
 
uint8_t send_delay {0}
 UART send delay.
 

Detailed Description

UART communication configuration structure.

Configuration parameters for UART mode operation (only used when SPI_MODE=0). These parameters configure the device's node address and timing for multi-device UART chains.

Note
These settings are only used in UART mode. For SPI mode, they are ignored.
In UART daisy-chain mode, each device must have a unique node address.

Constructor & Destructor Documentation

◆ UartConfig()

tmc51x0::UartConfig::UartConfig ( )
default

Default constructor.

Initializes with safe defaults:

  • Node address: 0 (first device or single device)
  • Send delay: 0 (no delay)

Member Data Documentation

◆ node_address

uint8_t tmc51x0::UartConfig::node_address {0}

UART node address.

7-bit UART node address for multi-device UART chains (0-127). Same value as node address in NODECONF register.

Range: 0-127 (7-bit address) Default: 0 (first device in chain, or single device)

Note
Only used when communication mode is UART (SPI_MODE=0).
For SPI mode, this value is ignored.
This is automatically configured during Initialize() if set.
In UART daisy-chain mode, each device must have a unique address. UART node address (0-127, default: 0)

◆ send_delay

uint8_t tmc51x0::UartConfig::send_delay {0}

UART send delay.

Number of bit times to wait before replying to a register read in UART mode. Used to ensure proper timing in multi-device UART chains.

Range: 0-15 bit times Default: 0 (no delay)

Note
Only used when communication mode is UART (SPI_MODE=0).
For SPI mode, this value is ignored.
This is automatically configured during Initialize() if node_address is set.
Higher values provide more margin for timing but increase response latency. UART send delay in bit times (0-15, default: 0)

The documentation for this struct was generated from the following file: