diff --git a/src/commandmessenger.h b/src/commandmessenger.h index 855286a4..4aa4be50 100644 --- a/src/commandmessenger.h +++ b/src/commandmessenger.h @@ -12,42 +12,55 @@ // In order to receive, attach a callback function to these events enum { - kInitModule, // 0 - kSetModule, // 1 - kSetPin, // 2 - kSetStepper, // 3 - kSetServo, // 4 - kStatus, // 5, Command to report status - kEncoderChange, // 6 - kButtonChange, // 7 - kStepperChange, // 8 - kGetInfo, // 9 - kInfo, // 10 - kSetConfig, // 11 - kGetConfig, // 12 - kResetConfig, // 13 - kSaveConfig, // 14 - kConfigSaved, // 15 - kActivateConfig, // 16 - kConfigActivated, // 17 - kSetPowerSavingMode, // 18 - kSetName, // 19 - kGenNewSerial, // 20 - kResetStepper, // 21 - kSetZeroStepper, // 22 - kTrigger, // 23 - kResetBoard, // 24 - kSetLcdDisplayI2C, // 25 - kSetModuleBrightness, // 26 - kSetShiftRegisterPins, // 27 - kAnalogChange, // 28 - kInputShifterChange, // 29 - kDigInMuxChange, // 30 - kDebug = 0xFF // 255 + kInitModule, // 0 + kSetModule, // 1 + kSetPin, // 2 + kSetStepper, // 3 + kSetServo, // 4 + kStatus, // 5, Command to report status + kEncoderChangeDeprecated, // 6 + kButtonChangeDeprecated, // 7 + kStepperChange, // 8 + kGetInfo, // 9 + kInfo, // 10 + kSetConfig, // 11 + kGetConfig, // 12 + kResetConfig, // 13 + kSaveConfig, // 14 + kConfigSaved, // 15 + kActivateConfig, // 16 + kConfigActivated, // 17 + kSetPowerSavingMode, // 18 + kSetName, // 19 + kGenNewSerial, // 20 + kResetStepper, // 21 + kSetZeroStepper, // 22 + kTrigger, // 23 + kResetBoard, // 24 + kSetLcdDisplayI2C, // 25 + kSetModuleBrightness, // 26 + kSetShiftRegisterPins, // 27 + kAnalogChangeDeprecated, // 28 + kInputShifterChangeDeprecated, // 29 + kDigInMuxChangeDeprecated, // 30 + + // functions which get be called from the UI via the command messenger + // must be added before. The command messenger has a fix buffer size + // for the functions which defined by MAXCALLBACKS=30. + // ------------------------------------------------------------------- + // new handler ID's for input devices must be added here + // This will save size of the Callback buffer + kButtonChange = 100, // 100 + kEncoderChange, // 101 + kAnalogChange, // 102 + kInputShifterChange, // 103 + kInputShifterChange, // 104 + kDigInMuxChange, // 105 + kDebug = 0xFF // 255 }; -void attachCommandCallbacks(); -uint32_t getLastCommandMillis(); -void setLastCommandMillis(); +void attachCommandCallbacks(); +uint32_t getLastCommandMillis(); +void setLastCommandMillis(); extern CmdMessenger cmdMessenger; \ No newline at end of file