From c3671a07ad44c9ad4fcd23d76409f268f1a6895e Mon Sep 17 00:00:00 2001 From: Juerd Waalboer Date: Tue, 22 Dec 2020 05:11:33 +0100 Subject: [PATCH] Exit demo with demo button --- operame.ino | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/operame.ino b/operame.ino index 18cbdb2..cc2b592 100644 --- a/operame.ino +++ b/operame.ino @@ -143,6 +143,12 @@ void ppm_demo() { delay(1000); for (int p = 400; p < 1200; p++) { display_ppm(p); + if (!digitalRead(demobutton)) { + display_logo(); + delay(500); + while (!digitalRead(demobutton)); + return; + } delay(30); } display_logo();