diff options
| author | QMK Bot <hello@qmk.fm> | 2022-02-12 10:29:31 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-02-12 18:29:31 +0000 |
| commit | 63646e8906e062d1c1de3925cba70c4e3426a855 (patch) | |
| tree | 4e91648b77b838e1125cf86331d7e84bde6d07a9 /quantum/logging | |
| parent | afcdd7079c774dec2aa4b7f2d08adf8b7310919b (diff) | |
Format code according to conventions (#16322)
Diffstat (limited to 'quantum/logging')
| -rw-r--r-- | quantum/logging/debug.c | 10 | ||||
| -rw-r--r-- | quantum/logging/print.c | 12 | ||||
| -rw-r--r-- | quantum/logging/print.h | 2 | ||||
| -rw-r--r-- | quantum/logging/sendchar.c | 4 |
4 files changed, 18 insertions, 10 deletions
diff --git a/quantum/logging/debug.c b/quantum/logging/debug.c index ea62deaa8c..ca7654eda2 100644 --- a/quantum/logging/debug.c +++ b/quantum/logging/debug.c | |||
| @@ -17,9 +17,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
| 17 | #include "debug.h" | 17 | #include "debug.h" |
| 18 | 18 | ||
| 19 | debug_config_t debug_config = { | 19 | debug_config_t debug_config = { |
| 20 | .enable = false, // | 20 | .enable = false, // |
| 21 | .matrix = false, // | 21 | .matrix = false, // |
| 22 | .keyboard = false, // | 22 | .keyboard = false, // |
| 23 | .mouse = false, // | 23 | .mouse = false, // |
| 24 | .reserved = 0 // | 24 | .reserved = 0 // |
| 25 | }; | 25 | }; |
diff --git a/quantum/logging/print.c b/quantum/logging/print.c index e8440e55ee..50a6b826ee 100644 --- a/quantum/logging/print.c +++ b/quantum/logging/print.c | |||
| @@ -19,9 +19,15 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
| 19 | 19 | ||
| 20 | // bind lib/printf to console interface - sendchar | 20 | // bind lib/printf to console interface - sendchar |
| 21 | 21 | ||
| 22 | static int8_t null_sendchar_func(uint8_t c) { return 0; } | 22 | static int8_t null_sendchar_func(uint8_t c) { |
| 23 | return 0; | ||
| 24 | } | ||
| 23 | static sendchar_func_t func = null_sendchar_func; | 25 | static sendchar_func_t func = null_sendchar_func; |
| 24 | 26 | ||
| 25 | void print_set_sendchar(sendchar_func_t send) { func = send; } | 27 | void print_set_sendchar(sendchar_func_t send) { |
| 28 | func = send; | ||
| 29 | } | ||
| 26 | 30 | ||
| 27 | void _putchar(char character) { func(character); } | 31 | void _putchar(char character) { |
| 32 | func(character); | ||
| 33 | } | ||
diff --git a/quantum/logging/print.h b/quantum/logging/print.h index 8c055f549e..aa72fc7074 100644 --- a/quantum/logging/print.h +++ b/quantum/logging/print.h | |||
| @@ -37,7 +37,7 @@ void print_set_sendchar(sendchar_func_t func); | |||
| 37 | # include_next "_print.h" /* Include the platforms print.h */ | 37 | # include_next "_print.h" /* Include the platforms print.h */ |
| 38 | # else | 38 | # else |
| 39 | // Fall back to lib/printf | 39 | // Fall back to lib/printf |
| 40 | # include "printf.h" // lib/printf/printf.h | 40 | # include "printf.h" // lib/printf/printf.h |
| 41 | 41 | ||
| 42 | // Create user & normal print defines | 42 | // Create user & normal print defines |
| 43 | # define print(s) printf(s) | 43 | # define print(s) printf(s) |
diff --git a/quantum/logging/sendchar.c b/quantum/logging/sendchar.c index 9422382f6f..5bc744b743 100644 --- a/quantum/logging/sendchar.c +++ b/quantum/logging/sendchar.c | |||
| @@ -17,4 +17,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
| 17 | #include "sendchar.h" | 17 | #include "sendchar.h" |
| 18 | 18 | ||
| 19 | /* default noop "null" implementation */ | 19 | /* default noop "null" implementation */ |
| 20 | __attribute__((weak)) int8_t sendchar(uint8_t c) { return 0; } | 20 | __attribute__((weak)) int8_t sendchar(uint8_t c) { |
| 21 | return 0; | ||
| 22 | } | ||
