|
HF-TMC51x0 Driver (TMC5130 & TMC5160) 0.1.0-dev
Hardware Agnostic C++ Driver for the TMC51x0 (TMC5130 & TMC5160)
|
Motion events / status outputs (X_COMPARE, RAMP_STAT clear) More...
#include <tmc51x0.hpp>
Public Member Functions | |
| Events (TMC51x0 &driver) noexcept | |
| Result< void > | SetXCompare (float position, Unit unit) noexcept |
| Program the X_COMPARE position compare threshold (unit-aware) | |
| Result< float > | GetXCompare (Unit unit) const noexcept |
| Get last programmed X_COMPARE threshold (cached, unit-aware) | |
| Result< void > | ClearRampStatus (uint32_t bits_to_clear) noexcept |
| Clear specific bits in RAMP_STAT. | |
Private Attributes | |
| TMC51x0 & | driver_ |
Motion events / status outputs (X_COMPARE, RAMP_STAT clear)
|
inlineexplicitnoexcept |
|
noexcept |
Clear specific bits in RAMP_STAT.
| bits_to_clear | Bitmask of RAMP_STAT bits to clear (write-1-to-clear) |
|
noexcept |
Get last programmed X_COMPARE threshold (cached, unit-aware)
| unit | Unit to return the cached compare value in |
This does not read hardware (X_COMPARE is write-only); it returns the last value written by SetXCompare() (or other APIs writing X_COMPARE).
|
noexcept |
Program the X_COMPARE position compare threshold (unit-aware)
| position | Compare position |
| unit | Unit of the compare position |
Note: X_COMPARE is a write-only register. The driver caches the last written value; use GetXCompare() to retrieve that cached value.
|
private |