aboutsummaryrefslogtreecommitdiff
path: root/stm32f091/util.h
diff options
context:
space:
mode:
Diffstat (limited to 'stm32f091/util.h')
-rw-r--r--stm32f091/util.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/stm32f091/util.h b/stm32f091/util.h
index 92f093f..9f5c1ec 100644
--- a/stm32f091/util.h
+++ b/stm32f091/util.h
@@ -14,3 +14,7 @@
HAL_UART_Transmit(&huart2, (uint8_t*) temp, sizeof(char) * strlen(temp), HAL_MAX_DELAY); \
}
+#define ws_dbg_set_usart2_tty_color(color) { \
+ uint8_t sgr[] = { 0x1b, 0x5b, 0x33, 0x30 + color, 0x6d }; \
+ HAL_UART_Transmit(&huart2, sgr, sizeof(sgr), 100); \
+}