Table of Contents

ItimerStopAll()

ItimerStopAll() stops all running callback timers.

ItimerStopAll command operation flow

void ItimerStopAll()

Commands

Command Arguments Return Value Operation
ItimerStopAll() None void Stops all running callback timers.

Example

This uses the default callback timer (Timer2). The callback changes only a flag; serial output runs in loop().

void onTimer() {}
 
void setup() {
  Serial.begin(115200);
  if (!ItimerSet(1000, onTimer)) return;  // Configure the callback and interval first.
  ItimerStart();  // Start the configured callback timer.
}
 
void loop() {
  static bool stopped = false;
  if (!stopped && millis() >= 5000) {
    ItimerStopAll();  // Stop every running callback timer.
    stopped = true;
    Serial.println(F("timer stopped"));
  }
}

Precautions

Built-in Commands in the Same Category

← Built-in Command List