APIs, concepts, guides, and more
GcodeCallbackData

Holds data for the G-code M-code callback mechanism. More...

Attributes

int32_t LineNumber
 The line number in the G-code file where the M-code is encountered.
 
const char * LineText
 The actual line content from the G-code file.
 
RsiErrorUserError
 Allows the user to set give error details to the G-Code execution thread what occurred during the execution of the M-code callback.
 

Description

This structure encapsulates the data that is used when an M-code is encountered in the G-code file.
The G-code execution thread fills in the LineNumber and Line fields, representing the line number and the actual line content.
If the user callback code fails and needs to notify the G-code execution thread, the user is expected to populate the UserError->number field to indicate the failure of the M-code handling logic and UserError will be logged to Robot.

Visit our Concept Page for more information.

Note
Fields prefixed with User are meant to be populated by the user implementing the callback.
See also
GcodeCallback
Examples
GcodeMotion.cs.

Definition at line 895 of file cartesianrobot.h.