Raises an event internally, based on the given parameters, as if the event had actually occurred, and executes any related handler macro for that event.
Back to the Gcode Dictionary
M957: Raise event
Supported in RepRapFirmware 3.4 and later.
- S"type" Event type name
- Pnn or Pbb.nn Device number to which the event relates, optionally including the CAN address of the board concerned
- Rnn Optional additional data about the event (unsigned integer)
This command is used to raise an event internally as if the event had actually occurred, and execute any related handler macro for that event. Its main use is to test event handler macros.
- M957 S"heaterFault" P1.1
Raise a heater fault on expansion board at CAN address 1, on heater 1
The event type names are firmware-dependent. In RepRapFirmware they are: mainBoardPowerFail, heaterFault, driverError, filamentError, driverWarning, mcuTemperatureWarning.
The meaning of the device number depends on the event type. For a driver error it is the driver number. For a heater fault it is the heater number. For a filament error it is the extruder number.
The meaning of the optional additional parameter also depends on the event type. For example, for a driver error it is the driver status.