Macro anchor::klipper_output
klipper_output!() { /* proc-macro */ }
Expand description
Sends a printf
-style message to the remote end
Dynamic messages can be sent to the remote end using this command. The main use case is for debugging. E.g.
klipper_output!("This the %uth test! %*s?", 10, "A test string");
A printf
-style syntax is used, to match the syntax from Klipper. The format string is parsed
at compile time, including type checking. The supplied argument type must match the format
string.
The format strings available, and their matching types, are:
Format string | Rust type |
---|---|
%u | u32 |
%i | i32 |
%hu | u16 |
%hi | i16 |
%c | u8 |
%.*s | &[u8] |
%*s | &str |