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 stringRust type
%uu32
%ii32
%huu16
%hii16
%cu8
%.*s&[u8]
%*s&str