|
HF-TMC9660 Driver 0.1.0-dev
Hardware Agnostic C++ Driver for the TMC9660
|
Subsystem for TMCL script execution control. More...
#include <tmc9660.hpp>
Public Member Functions | |
| bool | upload (const std::vector< uint32_t > &script_data) noexcept |
| Upload a TMCL script to the TMC9660's internal memory. | |
| bool | start (uint16_t address=0) noexcept |
| Start or restart execution of the stored script. | |
| bool | stop () noexcept |
| Stop execution of the running script. | |
| bool | step () noexcept |
| Execute a single TMCL instruction of the loaded script. | |
| bool | reset () noexcept |
| Reset the TMCL program counter. | |
| bool | getStatus (uint32_t &status) noexcept |
| Query the execution state of the running script. | |
| bool | readMemory (uint16_t address, uint32_t &value) noexcept |
| Read a 32-bit instruction from script memory. | |
| bool | addBreakpoint (uint16_t address) noexcept |
| Add a breakpoint at the given address. | |
| bool | removeBreakpoint (uint16_t address) noexcept |
| Remove a previously set breakpoint. | |
| bool | clearBreakpoints () noexcept |
| Remove all breakpoints from the script. | |
| bool | getMaxBreakpointCount (uint32_t &count) noexcept |
| Query the maximum number of supported breakpoints. | |
Private Member Functions | |
| Script (TMC9660 &parent) noexcept | |
Private Attributes | |
| TMC9660 & | driver |
Friends | |
| class | TMC9660 |
Subsystem for TMCL script execution control.
|
inlineexplicitprivatenoexcept |
|
noexcept |
Add a breakpoint at the given address.
| address | Instruction address where execution should break. |
|
noexcept |
Remove all breakpoints from the script.
|
noexcept |
Query the maximum number of supported breakpoints.
| [out] | count | Maximum breakpoint count reported by the device. |
|
noexcept |
Query the execution state of the running script.
| [out] | status | Raw status value returned by GetStatusScript. |
|
noexcept |
Read a 32-bit instruction from script memory.
| address | Instruction address to read. | |
| [out] | value | Returned 32-bit TMCL instruction word. |
|
noexcept |
Remove a previously set breakpoint.
| address | Address of the breakpoint to remove. |
|
noexcept |
Reset the TMCL program counter.
Sends the ApplReset command which stops execution and resets the script to the beginning.
|
noexcept |
Start or restart execution of the stored script.
| address | The address from which to start execution (usually 0 for beginning of script). |
|
noexcept |
Execute a single TMCL instruction of the loaded script.
Uses the ApplStep opcode which advances the interpreter by one instruction. Useful for debugging scripts in real time.
|
noexcept |
Stop execution of the running script.
|
noexcept |
Upload a TMCL script to the TMC9660's internal memory.
This enters download mode, writes a series of instructions to the device memory, and exits download mode. The script will typically run on device startup or when triggered.
| script_data | Vector of 32-bit instructions representing the TMCL script. |
|
private |