M957
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.
Parameters
- E"type" Event type name
- Dnn Device number to which the event relates
- Bnn (optional) CAN address of the board that the event should appear to originate from
- Pnn (optional) Additional data about the event (unsigned integer)
- S"text" (optional) Short test string to be appended to the event message
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.
Example
- M957 E"heaterFault" D1 B2
Raise a heater fault from expansion board at CAN address 2 on heater 1
Notes
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.
0 Comments