grblHAL core  20241107
gcode.h File Reference
#include "nuts_bolts.h"
#include "coolant_control.h"
#include "spindle_control.h"
#include "errors.h"

Go to the source code of this file.

Data Structures

struct  output_command
 Data for M62, M63 and M67 commands when executed synchronized with motion. More...
 
union  gc_parser_flags_t
 Parser flags for special cases. More...
 
union  gc_override_flags_t
 Override flags. More...
 
union  coord_data_t
 Coordinate data. More...
 
struct  coord_system_t
 Coordinate data including id. More...
 
union  plane_t
 Axis index to plane assignment. More...
 
struct  gc_values_t
 G- and M-code parameter values. More...
 
union  parameter_words_t
 Parameter words found by parser - do not change order! More...
 
struct  gc_value_ptr_t
 
struct  spindle_t
 
struct  spindle_modal_t
 
struct  gc_modal_t
 
struct  gc_canned_t
 Data for canned cycles. More...
 
struct  gc_thread_data
 
struct  tool_data_t
 Tool data. More...
 
struct  parser_state_t
 Parser state. More...
 
struct  scale_factor_t
 
struct  parser_block_t
 Parser block structure. More...
 

Macros

#define MAX_OFFSET_ENTRIES   4
 
#define gc_sync_position()   system_convert_array_steps_to_mpos (gc_state.position, sys.position)
 
#define sync_position()   plan_sync_position(); system_convert_array_steps_to_mpos (gc_state.position, sys.position)
 

Typedefs

typedef uint32_t tool_id_t
 
typedef uint16_t macro_id_t
 
typedef int8_t offset_id_t
 
typedef struct output_command output_command_t
 Data for M62, M63 and M67 commands when executed synchronized with motion. More...
 

Enumerations

enum  non_modal_t {
  NonModal_NoAction = 0 , NonModal_Dwell = 4 , NonModal_SetCoordinateData = 10 , NonModal_GoHome_0 = 28 ,
  NonModal_SetHome_0 = 38 , NonModal_GoHome_1 = 30 , NonModal_SetHome_1 = 40 , NonModal_AbsoluteOverride = 53 ,
  NonModal_MacroCall = 65 , NonModal_SetCoordinateOffset = 92 , NonModal_ResetCoordinateOffset = 102 , NonModal_ClearCoordinateOffset = 112 ,
  NonModal_RestoreCoordinateOffset = 122
}
 
enum  modal_state_action_t {
  ModalState_NoAction = 0 , ModalState_Save = 70 , ModalState_Invalidate = 71 , ModalState_Restore = 72 ,
  ModalState_SaveAutoRestore = 73
}
 
enum  motion_mode_t {
  MotionMode_Seek = 0 , MotionMode_Linear = 1 , MotionMode_CwArc = 2 , MotionMode_CcwArc = 3 ,
  MotionMode_CubicSpline = 5 , MotionMode_QuadraticSpline = 51 , MotionMode_SpindleSynchronized = 33 , MotionMode_RigidTapping = 331 ,
  MotionMode_DrillChipBreak = 73 , MotionMode_Threading = 76 , MotionMode_CannedCycle81 = 81 , MotionMode_CannedCycle82 = 82 ,
  MotionMode_CannedCycle83 = 83 , MotionMode_CannedCycle85 = 85 , MotionMode_CannedCycle86 = 86 , MotionMode_CannedCycle89 = 89 ,
  MotionMode_ProbeToward = 140 , MotionMode_ProbeTowardNoError = 141 , MotionMode_ProbeAway = 142 , MotionMode_ProbeAwayNoError = 143 ,
  MotionMode_None = 80
}
 
enum  plane_select_t { PlaneSelect_XY = 0 , PlaneSelect_ZX = 1 , PlaneSelect_YZ = 2 }
 
enum  feed_mode_t { FeedMode_UnitsPerMin = 0 , FeedMode_InverseTime = 1 , FeedMode_UnitsPerRev = 2 }
 
enum  tool_offset_mode_t { ToolLengthOffset_Cancel = 0 , ToolLengthOffset_Enable = 1 , ToolLengthOffset_EnableDynamic = 2 , ToolLengthOffset_ApplyAdditional = 3 }
 
enum  cc_retract_mode_t { CCRetractMode_Previous = 0 , CCRetractMode_RPos = 1 }
 
enum  __attribute__ {
  Status_OK = 0 , Status_ExpectedCommandLetter = 1 , Status_BadNumberFormat = 2 , Status_InvalidStatement = 3 ,
  Status_NegativeValue = 4 , Status_HomingDisabled = 5 , Status_SettingStepPulseMin = 6 , Status_SettingReadFail = 7 ,
  Status_IdleError = 8 , Status_SystemGClock = 9 , Status_SoftLimitError = 10 , Status_Overflow = 11 ,
  Status_MaxStepRateExceeded = 12 , Status_CheckDoor = 13 , Status_LineLengthExceeded = 14 , Status_TravelExceeded = 15 ,
  Status_InvalidJogCommand = 16 , Status_SettingDisabledLaser = 17 , Status_Reset = 18 , Status_NonPositiveValue = 19 ,
  Status_GcodeUnsupportedCommand = 20 , Status_GcodeModalGroupViolation = 21 , Status_GcodeUndefinedFeedRate = 22 , Status_GcodeCommandValueNotInteger = 23 ,
  Status_GcodeAxisCommandConflict = 24 , Status_GcodeWordRepeated = 25 , Status_GcodeNoAxisWords = 26 , Status_GcodeInvalidLineNumber = 27 ,
  Status_GcodeValueWordMissing = 28 , Status_GcodeUnsupportedCoordSys = 29 , Status_GcodeG53InvalidMotionMode = 30 , Status_GcodeAxisWordsExist = 31 ,
  Status_GcodeNoAxisWordsInPlane = 32 , Status_GcodeInvalidTarget = 33 , Status_GcodeArcRadiusError = 34 , Status_GcodeNoOffsetsInPlane = 35 ,
  Status_GcodeUnusedWords = 36 , Status_GcodeG43DynamicAxisError = 37 , Status_GcodeIllegalToolTableEntry = 38 , Status_GcodeValueOutOfRange = 39 ,
  Status_GcodeToolChangePending = 40 , Status_GcodeSpindleNotRunning = 41 , Status_GcodeIllegalPlane = 42 , Status_GcodeMaxFeedRateExceeded = 43 ,
  Status_GcodeRPMOutOfRange = 44 , Status_LimitsEngaged = 45 , Status_HomingRequired = 46 , Status_GCodeToolError = 47 ,
  Status_ValueWordConflict = 48 , Status_SelfTestFailed = 49 , Status_EStop = 50 , Status_MotorFault = 51 ,
  Status_SettingValueOutOfRange = 52 , Status_SettingDisabled = 53 , Status_GcodeInvalidRetractPosition = 54 , Status_IllegalHomingConfiguration = 55 ,
  Status_GCodeCoordSystemLocked = 56 , Status_SDMountError = 60 , Status_SDReadError = 61 , Status_SDFailedOpenDir = 62 ,
  Status_SDDirNotFound = 63 , Status_SDFileEmpty = 64 , Status_BTInitError = 70 , Status_ExpressionUknownOp = 71 ,
  Status_ExpressionDivideByZero = 72 , Status_ExpressionArgumentOutOfRange = 73 , Status_ExpressionInvalidArgument = 74 , Status_ExpressionSyntaxError = 75 ,
  Status_ExpressionInvalidResult = 76 , Status_AuthenticationRequired = 77 , Status_AccessDenied = 78 , Status_NotAllowedCriticalEvent = 79 ,
  Status_FlowControlNotExecutingMacro = 80 , Status_FlowControlSyntaxError = 81 , Status_FlowControlStackOverflow = 82 , Status_FlowControlOutOfMemory = 83 ,
  Status_StatusMax = Status_FlowControlOutOfMemory , Status_UserException = 253 , Status_Handled , Status_Unhandled ,
  CoordinateSystem_G54 = 0 , CoordinateSystem_G55 , CoordinateSystem_G56 , CoordinateSystem_G57 ,
  CoordinateSystem_G58 , CoordinateSystem_G59 , CoordinateSystem_G59_1 , CoordinateSystem_G59_2 ,
  CoordinateSystem_G59_3 , N_WorkCoordinateSystems , CoordinateSystem_G28 = N_WorkCoordinateSystems , CoordinateSystem_G30 ,
  CoordinateSystem_G92 , N_CoordinateSystems
}
 
enum  control_mode_t { ControlMode_ExactPath = 0 , ControlMode_ExactStop = 1 , ControlMode_PathBlending = 2 }
 
enum  spindle_rpm_mode_t { SpindleSpeedMode_RPM = 0 , SpindleSpeedMode_CSS = 1 }
 
enum  program_flow_t {
  ProgramFlow_Running = 0 , ProgramFlow_Paused = 3 , ProgramFlow_OptionalStop = 1 , ProgramFlow_CompletedM2 = 2 ,
  ProgramFlow_CompletedM30 = 30 , ProgramFlow_CompletedM60 = 60 , ProgramFlow_Return = 99
}
 
enum  override_mode_t {
  Override_FeedSpeedEnable = 48 , Override_FeedSpeedDisable = 49 , Override_FeedRate = 50 , Override_SpindleSpeed = 51 ,
  Override_FeedHold = 53 , Override_Parking = 56
}
 
enum  io_mcode_t {
  IoMCode_OutputOnSynced = 62 , IoMCode_OutputOffSynced = 63 , IoMCode_OutputOnImmediate = 64 , IoMCode_OutputOffImmediate = 65 ,
  IoMCode_WaitOnInput = 66 , IoMCode_AnalogOutSynced = 67 , IoMCode_AnalogOutImmediate = 68
}
 
enum  user_mcode_t {
  OpenPNP_SetPinState = 42 , UserMCode_Generic1 = 101 , UserMCode_Generic2 = 102 , UserMCode_Generic3 = 103 ,
  UserMCode_Generic4 = 104 , OpenPNP_GetADCReading = 105 , Fan_On = 106 , Fan_Off = 107 ,
  OpenPNP_GetCurrentPosition = 114 , OpenPNP_FirmwareInfo = 115 , Trinamic_DebugReport = 122 , Trinamic_ReadRegister = 123 ,
  Trinamic_WriteRegister = 124 , LaserPPI_Enable = 126 , LaserPPI_Rate = 127 , LaserPPI_PulseLength = 128 ,
  RGB_WriteLEDs = 150 , OpenPNP_SetAcceleration = 204 , PWMServo_SetPosition = 280 , RGB_Inspection_Light = 356 ,
  OpenPNP_FinishMoves = 400 , Probe_Deploy = 401 , Probe_Stow = 402 , OpenPNP_SettingsReset = 502 ,
  Trinamic_ModeToggle = 569 , Trinamic_StepperCurrent = 906 , Trinamic_ReportPrewarnFlags = 911 , Trinamic_ClearPrewarnFlags = 912 ,
  Trinamic_HybridThreshold = 913 , Trinamic_HomingSensitivity = 914 , Trinamic_ChopperTiming = 919 , Spindle_Select = UserMCode_Generic4
}
 
enum  wait_mode_t {
  WaitMode_Immediate = 0 , WaitMode_Rise , WaitMode_Fall , WaitMode_High ,
  WaitMode_Low , WaitMode_Max
}
 M66 Allowed L-parameter values. More...
 
enum  pos_update_t { GCUpdatePos_Target = 0 , GCUpdatePos_System , GCUpdatePos_None }
 Parser position updating flags. More...
 
enum  gc_probe_t {
  GCProbe_Found = GCUpdatePos_System , GCProbe_Abort = GCUpdatePos_None , GCProbe_FailInit = GCUpdatePos_None , GCProbe_FailEnd = GCUpdatePos_Target ,
  GCProbe_CheckMode = GCUpdatePos_Target
}
 
enum  gc_value_type_t {
  ValueType_NA = 0 , ValueType_UInt8 , ValueType_UInt32 , ValueType_Int32 ,
  ValueType_Float
}
 
enum  gc_taper_type { Taper_None = 0 , Taper_Entry , Taper_Exit , Taper_Both }
 Thread taper types. More...
 

Functions

void gc_init (void)
 
char * gc_normalize_block (char *block, status_code_t *status, char **message)
 
status_code_t gc_execute_block (char *block)
 
bool gc_laser_ppi_enable (uint_fast16_t ppi, uint_fast16_t pulse_length)
 
parser_state_tgc_get_state (void)
 
axes_signals_t gc_get_g51_state (void)
 
float * gc_get_scaling (void)
 
float gc_get_offset (uint_fast8_t idx, bool real_time)
 
spindle_tgc_spindle_get (spindle_num_t spindle)
 
void gc_spindle_off (void)
 
void gc_coolant (coolant_state_t state)
 
void gc_set_tool_offset (tool_offset_mode_t mode, uint_fast8_t idx, int32_t offset)
 
plane_tgc_get_plane_data (plane_t *plane, plane_select_t select)
 
parameter_words_t gc_get_g65_arguments (void)
 
bool gc_modal_state_restore (gc_modal_t *copy)
 

Variables

parser_state_t gc_state
 

Macro Definition Documentation

◆ gc_sync_position

#define gc_sync_position ( )    system_convert_array_steps_to_mpos (gc_state.position, sys.position)

◆ MAX_OFFSET_ENTRIES

#define MAX_OFFSET_ENTRIES   4

◆ sync_position

#define sync_position ( )    plan_sync_position(); system_convert_array_steps_to_mpos (gc_state.position, sys.position)

Typedef Documentation

◆ macro_id_t

typedef uint16_t macro_id_t

◆ offset_id_t

typedef int8_t offset_id_t

◆ output_command_t

Data for M62, M63 and M67 commands when executed synchronized with motion.

◆ tool_id_t

typedef uint32_t tool_id_t

Enumeration Type Documentation

◆ __attribute__

Modal Group G12 and G0: Coordinate system identificators

Do not alter values!

Enumerator
Status_OK 
Status_ExpectedCommandLetter 
Status_BadNumberFormat 
Status_InvalidStatement 
Status_NegativeValue 
Status_HomingDisabled 
Status_SettingStepPulseMin 
Status_SettingReadFail 
Status_IdleError 
Status_SystemGClock 
Status_SoftLimitError 
Status_Overflow 
Status_MaxStepRateExceeded 
Status_CheckDoor 
Status_LineLengthExceeded 
Status_TravelExceeded 
Status_InvalidJogCommand 
Status_SettingDisabledLaser 
Status_Reset 
Status_NonPositiveValue 
Status_GcodeUnsupportedCommand 
Status_GcodeModalGroupViolation 
Status_GcodeUndefinedFeedRate 
Status_GcodeCommandValueNotInteger 
Status_GcodeAxisCommandConflict 
Status_GcodeWordRepeated 
Status_GcodeNoAxisWords 
Status_GcodeInvalidLineNumber 
Status_GcodeValueWordMissing 
Status_GcodeUnsupportedCoordSys 
Status_GcodeG53InvalidMotionMode 
Status_GcodeAxisWordsExist 
Status_GcodeNoAxisWordsInPlane 
Status_GcodeInvalidTarget 
Status_GcodeArcRadiusError 
Status_GcodeNoOffsetsInPlane 
Status_GcodeUnusedWords 
Status_GcodeG43DynamicAxisError 
Status_GcodeIllegalToolTableEntry 
Status_GcodeValueOutOfRange 
Status_GcodeToolChangePending 
Status_GcodeSpindleNotRunning 
Status_GcodeIllegalPlane 
Status_GcodeMaxFeedRateExceeded 
Status_GcodeRPMOutOfRange 
Status_LimitsEngaged 
Status_HomingRequired 
Status_GCodeToolError 
Status_ValueWordConflict 
Status_SelfTestFailed 
Status_EStop 
Status_MotorFault 
Status_SettingValueOutOfRange 
Status_SettingDisabled 
Status_GcodeInvalidRetractPosition 
Status_IllegalHomingConfiguration 
Status_GCodeCoordSystemLocked 
Status_SDMountError 
Status_SDReadError 
Status_SDFailedOpenDir 
Status_SDDirNotFound 
Status_SDFileEmpty 
Status_BTInitError 
Status_ExpressionUknownOp 
Status_ExpressionDivideByZero 
Status_ExpressionArgumentOutOfRange 
Status_ExpressionInvalidArgument 
Status_ExpressionSyntaxError 
Status_ExpressionInvalidResult 
Status_AuthenticationRequired 
Status_AccessDenied 
Status_NotAllowedCriticalEvent 
Status_FlowControlNotExecutingMacro 
Status_FlowControlSyntaxError 
Status_FlowControlStackOverflow 
Status_FlowControlOutOfMemory 
Status_StatusMax 
Status_UserException 
Status_Handled 
Status_Unhandled 
CoordinateSystem_G54 

0 - G54 (G12)

CoordinateSystem_G55 

1 - G55 (G12)

CoordinateSystem_G56 

2 - G56 (G12)

CoordinateSystem_G57 

3 - G57 (G12)

CoordinateSystem_G58 

4 - G58 (G12)

CoordinateSystem_G59 

5 - G59 (G12)

CoordinateSystem_G59_1 

6 - G59.1 (G12) - availability depending on COMPATIBILITY_LEVEL <= 1

CoordinateSystem_G59_2 

7 - G59.2 (G12) - availability depending on COMPATIBILITY_LEVEL <= 1

CoordinateSystem_G59_3 

8 - G59.3 (G12) - availability depending on COMPATIBILITY_LEVEL <= 1

N_WorkCoordinateSystems 

9 when COMPATIBILITY_LEVEL <= 1, 6 otherwise

CoordinateSystem_G28 

9 - G28 (G0) when COMPATIBILITY_LEVEL <= 1, 6 otherwise

CoordinateSystem_G30 

10 - G30 (G0) when COMPATIBILITY_LEVEL <= 1, 7 otherwise

CoordinateSystem_G92 

11 - G92 (G0) when COMPATIBILITY_LEVEL <= 1, 8 otherwise

N_CoordinateSystems 

12 when COMPATIBILITY_LEVEL <= 1, 9 otherwise

◆ cc_retract_mode_t

Modal Group G10: Canned cycle return mode

Do not alter values!

Enumerator
CCRetractMode_Previous 

0 - G98 - Default, must be zero

CCRetractMode_RPos 

1 - G99

◆ control_mode_t

Modal Group G13: Control mode

Do not alter values!

Enumerator
ControlMode_ExactPath 

0 - G61 - Default, must be zero

ControlMode_ExactStop 

1 - G61.1

ControlMode_PathBlending 

2 - G64

◆ feed_mode_t

Modal Group G5: Feed rate mode

Do not alter values!

Enumerator
FeedMode_UnitsPerMin 

0 - G94 - Default, must be zero

FeedMode_InverseTime 

1 - G93

FeedMode_UnitsPerRev 

2 - G95

◆ gc_probe_t

enum gc_probe_t

Probe cycle exit states, used for proper proper position updating.

Assigned from pos_update_t enum values.

Enumerator
GCProbe_Found 

1

GCProbe_Abort 

2

GCProbe_FailInit 

2

GCProbe_FailEnd 

0

GCProbe_CheckMode 

0

◆ gc_taper_type

Thread taper types.

Enumerator
Taper_None 

0

Taper_Entry 

1

Taper_Exit 

2

Taper_Both 

3

◆ gc_value_type_t

Enumerator
ValueType_NA 
ValueType_UInt8 
ValueType_UInt32 
ValueType_Int32 
ValueType_Float 

◆ io_mcode_t

enum io_mcode_t

Modal Group M10: i/o control

Enumerator
IoMCode_OutputOnSynced 

62 - M62

IoMCode_OutputOffSynced 

63 - M63

IoMCode_OutputOnImmediate 

64 - M64

IoMCode_OutputOffImmediate 

65 - M65

IoMCode_WaitOnInput 

66 - M66

IoMCode_AnalogOutSynced 

67 - M67

IoMCode_AnalogOutImmediate 

68 - M68

◆ modal_state_action_t

Enumerator
ModalState_NoAction 

0 - Default, must be zero

ModalState_Save 

70 - M70

ModalState_Invalidate 

71 - M71

ModalState_Restore 

72 - M72

ModalState_SaveAutoRestore 

73 - M73

◆ motion_mode_t

Modal Group G1: Motion modes

Do not alter values!

Enumerator
MotionMode_Seek 

0 - G0 - Default, must be zero

MotionMode_Linear 

1 - G1

MotionMode_CwArc 

2 - G2

MotionMode_CcwArc 

3 - G3

MotionMode_CubicSpline 

5 - G5

MotionMode_QuadraticSpline 

51 - G5.1

MotionMode_SpindleSynchronized 

33 - G33

MotionMode_RigidTapping 

331 - G33.1

MotionMode_DrillChipBreak 

73 - G73

MotionMode_Threading 

76 - G76

MotionMode_CannedCycle81 

81 - G81

MotionMode_CannedCycle82 

82 - G82

MotionMode_CannedCycle83 

83 - G83

MotionMode_CannedCycle85 

85 - G85

MotionMode_CannedCycle86 

86 - G86

MotionMode_CannedCycle89 

89 - G89

MotionMode_ProbeToward 

140 - G38.2

MotionMode_ProbeTowardNoError 

141 - G38.3

MotionMode_ProbeAway 

142 - G38.4

MotionMode_ProbeAwayNoError 

143 - G38.5

MotionMode_None 

80 - G80

◆ non_modal_t

Modal Group G0: Non-modal actions

Do not alter values!

Enumerator
NonModal_NoAction 

0 - Default, must be zero

NonModal_Dwell 

4 - G4

NonModal_SetCoordinateData 

10 - G10

NonModal_GoHome_0 

28 - G28

NonModal_SetHome_0 

38 - G28.1

NonModal_GoHome_1 

30 - G30

NonModal_SetHome_1 

40 - G30.1

NonModal_AbsoluteOverride 

53 - G53

NonModal_MacroCall 

65 - G65

NonModal_SetCoordinateOffset 

92 - G92

NonModal_ResetCoordinateOffset 

102 - G92.1

NonModal_ClearCoordinateOffset 

112 - G92.2

NonModal_RestoreCoordinateOffset 

122 - G92.3

◆ override_mode_t

Enumerator
Override_FeedSpeedEnable 

48 - M48

Override_FeedSpeedDisable 

49 - M49

Override_FeedRate 

50 - M50

Override_SpindleSpeed 

51 - M51

Override_FeedHold 

53 - M53

Override_Parking 

56 - M56

◆ plane_select_t

Modal Group G2: Plane select

Do not alter values!

Enumerator
PlaneSelect_XY 

0 - G17 - Default, must be zero

PlaneSelect_ZX 

1 - G18

PlaneSelect_YZ 

2 - G19

◆ pos_update_t

Parser position updating flags.

Enumerator
GCUpdatePos_Target 

0

GCUpdatePos_System 

1

GCUpdatePos_None 

2

◆ program_flow_t

Modal Group M4: Program flow

Do not alter values!

Enumerator
ProgramFlow_Running 

0 - Default, must be zero

ProgramFlow_Paused 

3 - M0

ProgramFlow_OptionalStop 

1 - M1

ProgramFlow_CompletedM2 

2 - M2

ProgramFlow_CompletedM30 

30 - M30

ProgramFlow_CompletedM60 

60 - M60

ProgramFlow_Return 

99 - M99

◆ spindle_rpm_mode_t

Modal Group G14: Spindle Speed Mode

Do not alter values!

Enumerator
SpindleSpeedMode_RPM 

0 - G97 - Default, must be zero

SpindleSpeedMode_CSS 

1 - G96

◆ tool_offset_mode_t

Modal Group G8: Tool length offset

Do not alter values!

Enumerator
ToolLengthOffset_Cancel 

0 - G49 - Default, must be zero

ToolLengthOffset_Enable 

1 - G43

ToolLengthOffset_EnableDynamic 

2 - G43.1

ToolLengthOffset_ApplyAdditional 

3 - G43.2

◆ user_mcode_t

Modal Group M10: User/driver/plugin defined M commands NOTE: Not used by the core, may be used by private user code, drivers or plugins.

Enumerator
OpenPNP_SetPinState 

42 - M42

UserMCode_Generic1 

101 - For private use only

UserMCode_Generic2 

102 - For private use only

UserMCode_Generic3 

103 - For private use only

UserMCode_Generic4 

104 - For private use only

OpenPNP_GetADCReading 

105 - M105

Fan_On 

106 - M106, Marlin format

Fan_Off 

107 - M107, Marlin format

OpenPNP_GetCurrentPosition 

114 - M114

OpenPNP_FirmwareInfo 

115 - M115

Trinamic_DebugReport 

122 - M122, Marlin format

Trinamic_ReadRegister 

123 - M123

Trinamic_WriteRegister 

124 - M124

LaserPPI_Enable 

126 - M126

LaserPPI_Rate 

127 - M127

LaserPPI_PulseLength 

128 - M128

RGB_WriteLEDs 

150 - M150, Marlin format

OpenPNP_SetAcceleration 

204 - M204

PWMServo_SetPosition 

280 - M280, Marlin format

RGB_Inspection_Light 

356 - M356

OpenPNP_FinishMoves 

400 - M400

Probe_Deploy 

401 - M401, Marlin format

Probe_Stow 

402 - M402, Marlin format

OpenPNP_SettingsReset 

502 - M502

Trinamic_ModeToggle 

569 - M569, Marlin format

Trinamic_StepperCurrent 

906 - M906, Marlin format

Trinamic_ReportPrewarnFlags 

911 - M911, Marlin format

Trinamic_ClearPrewarnFlags 

912 - M912, Marlin format

Trinamic_HybridThreshold 

913 - M913, Marlin format

Trinamic_HomingSensitivity 

914 - M914, Marlin format

Trinamic_ChopperTiming 

919 - M919, Marlin format

Spindle_Select 

Value to be assigned later!

◆ wait_mode_t

M66 Allowed L-parameter values.

Enumerator
WaitMode_Immediate 

0 - This is the only mode allowed for analog inputs

WaitMode_Rise 

1

WaitMode_Fall 

2

WaitMode_High 

3

WaitMode_Low 

4

WaitMode_Max 

For internal use.

Function Documentation

◆ gc_coolant()

void gc_coolant ( coolant_state_t  state)

◆ gc_execute_block()

status_code_t gc_execute_block ( char *  block)

◆ gc_get_g51_state()

axes_signals_t gc_get_g51_state ( void  )

◆ gc_get_g65_arguments()

parameter_words_t gc_get_g65_arguments ( void  )

◆ gc_get_offset()

float gc_get_offset ( uint_fast8_t  idx,
bool  real_time 
)

◆ gc_get_plane_data()

plane_t* gc_get_plane_data ( plane_t plane,
plane_select_t  select 
)

◆ gc_get_scaling()

float* gc_get_scaling ( void  )

◆ gc_get_state()

parser_state_t* gc_get_state ( void  )

◆ gc_init()

void gc_init ( void  )

◆ gc_laser_ppi_enable()

bool gc_laser_ppi_enable ( uint_fast16_t  ppi,
uint_fast16_t  pulse_length 
)

◆ gc_modal_state_restore()

bool gc_modal_state_restore ( gc_modal_t copy)

◆ gc_normalize_block()

char* gc_normalize_block ( char *  block,
status_code_t *  status,
char **  message 
)

◆ gc_set_tool_offset()

void gc_set_tool_offset ( tool_offset_mode_t  mode,
uint_fast8_t  idx,
int32_t  offset 
)

◆ gc_spindle_get()

spindle_t* gc_spindle_get ( spindle_num_t  spindle)

◆ gc_spindle_off()

void gc_spindle_off ( void  )

Variable Documentation

◆ gc_state

parser_state_t gc_state
extern