From c0e1b4cdf20c55f2cbbdf3a5889f447974135fd8 Mon Sep 17 00:00:00 2001 From: Josh Rahm Date: Mon, 16 Nov 2020 21:02:48 -0700 Subject: Got the DMA to send a simple message through UART2. --- 02-usart/include/common.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to '02-usart/include/common.h') diff --git a/02-usart/include/common.h b/02-usart/include/common.h index 01b6a47..8e0cb06 100644 --- a/02-usart/include/common.h +++ b/02-usart/include/common.h @@ -31,6 +31,9 @@ #define RESERVE(type) \ __IO type RESERVED_MACRO_CONCAT(_r, __COUNTER__) -typedef uint32_t bits_t; +#define ptr2reg(ptr) \ + ((uint32_t) (ptrdiff_t) (ptr)) + +typedef __IO uint32_t bits_t; #endif /* COMMON_H */ -- cgit