Arduino_EMBRYO_2 - readBtnStart()

Returns the boolean value in the pin connected to the Start Button. This button invokes the initialization ISR and the start() method.

Syntax

axis.readBtnStart()

Returns

The start button signal: LOW or HIGH.

Example

#include <Arduino_EMBRYO_2.h>

StepMotor axis(1, A5, 5, 6, 3, 4, A2, A1, 2, 12);

void setup() {
  Serial.begin(9600);
  while (!Serial) {};
  axis.begin();
  Serial.println("Start button logic");
  Serial.println("Not pressed: " + String(axis.readBtnStart()));
  Serial.println("Pressed: " + String(!axis.readBtnStart()));
}
void loop() {}

See also