From e74fe315fbb3b94aabbc8f01c36bd30c63ff5847 Mon Sep 17 00:00:00 2001 From: MikyM0use Date: Sun, 6 Nov 2016 10:59:23 +0100 Subject: [PATCH] add jafar delay to head --- jafar_sketch/jafar_sketch.ino | 8 ++++++++ jafar_sketch/jafar_util.ino | 7 ------- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/jafar_sketch/jafar_sketch.ino b/jafar_sketch/jafar_sketch.ino index e545bc1..b496fd8 100644 --- a/jafar_sketch/jafar_sketch.ino +++ b/jafar_sketch/jafar_sketch.ino @@ -51,6 +51,14 @@ TVout TV; #endif //USE OSD +void inline jafar_delay(const uint16_t __delay) { +#ifdef USE_OSD + TV.delay(__delay); +#else + delay(__delay); +#endif +} + //////********* SETUP ************//////////////////// void setup() { diff --git a/jafar_sketch/jafar_util.ino b/jafar_sketch/jafar_util.ino index 5c28bfc..d1ef9ca 100644 --- a/jafar_sketch/jafar_util.ino +++ b/jafar_sketch/jafar_util.ino @@ -38,13 +38,6 @@ inline uint8_t readSwitch() { #endif } -void inline jafar_delay(const uint16_t __delay) { -#ifdef USE_OSD - TV.delay(__delay); -#else - delay(__delay); -#endif -} void set_and_wait(uint8_t band, uint8_t menu_pos) { int16_t rssi_b = 0, rssi_a = 0, rssi_b_norm = 0, rssi_a_norm = 0, prev_rssi_b_norm = 0, prev_rssi_a_norm = 0, global_max_rssi; u8 current_rx;