diff options
Diffstat (limited to 'quantum/send_string.c')
| -rw-r--r-- | quantum/send_string.c | 22 | 
1 files changed, 15 insertions, 7 deletions
| diff --git a/quantum/send_string.c b/quantum/send_string.c index 1a7f7a1315..0de12ba12d 100644 --- a/quantum/send_string.c +++ b/quantum/send_string.c @@ -142,9 +142,13 @@ __attribute__((weak)) const uint8_t ascii_to_keycode_lut[128] PROGMEM = {  // Note: we bit-pack in "reverse" order to optimize loading  #define PGM_LOADBIT(mem, pos) ((pgm_read_byte(&((mem)[(pos) / 8])) >> ((pos) % 8)) & 0x01) -void send_string(const char *str) { send_string_with_delay(str, 0); } +void send_string(const char *str) { +    send_string_with_delay(str, 0); +} -void send_string_P(const char *str) { send_string_with_delay_P(str, 0); } +void send_string_P(const char *str) { +    send_string_with_delay_P(str, 0); +}  void send_string_with_delay(const char *str, uint8_t interval) {      while (1) { @@ -173,7 +177,8 @@ void send_string_with_delay(const char *str, uint8_t interval) {                      ms += keycode - '0';                      keycode = *(++str);                  } -                while (ms--) wait_ms(1); +                while (ms--) +                    wait_ms(1);              }          } else {              send_char(ascii_code); @@ -182,7 +187,8 @@ void send_string_with_delay(const char *str, uint8_t interval) {          // interval          {              uint8_t ms = interval; -            while (ms--) wait_ms(1); +            while (ms--) +                wait_ms(1);          }      }  } @@ -214,7 +220,8 @@ void send_string_with_delay_P(const char *str, uint8_t interval) {                      ms += keycode - '0';                      keycode = pgm_read_byte(++str);                  } -                while (ms--) wait_ms(1); +                while (ms--) +                    wait_ms(1);              }          } else {              send_char(ascii_code); @@ -223,14 +230,15 @@ void send_string_with_delay_P(const char *str, uint8_t interval) {          // interval          {              uint8_t ms = interval; -            while (ms--) wait_ms(1); +            while (ms--) +                wait_ms(1);          }      }  }  void send_char(char ascii_code) {  #if defined(AUDIO_ENABLE) && defined(SENDSTRING_BELL) -    if (ascii_code == '\a') {  // BEL +    if (ascii_code == '\a') { // BEL          PLAY_SONG(bell_song);          return;      } | 
