From 93b063fedfcf7409a67df035170ea5670cad22e1 Mon Sep 17 00:00:00 2001 From: Josh Rahm Date: Tue, 24 Nov 2020 13:46:41 -0700 Subject: Moved action to top level. Removed old iterations of the project and moved the files from 02-usart to the root directory since that's the sole place where the action is and that subproject has outgrown its initial title. --- include/arch/stm32l4xxx/peripherals/flash.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 include/arch/stm32l4xxx/peripherals/flash.h (limited to 'include/arch/stm32l4xxx/peripherals/flash.h') diff --git a/include/arch/stm32l4xxx/peripherals/flash.h b/include/arch/stm32l4xxx/peripherals/flash.h new file mode 100644 index 0000000..28a3d6c --- /dev/null +++ b/include/arch/stm32l4xxx/peripherals/flash.h @@ -0,0 +1,20 @@ +#ifndef H__FLASH_ +#define H__FLASH_ + +#include "kern/common.h" + +/* + * Header file for dealing with flash. + */ + +#define FLASH_BASE 0x40022000 + +typedef struct { + __IO uint32_t ac_r; /* Flash access control register. */ + + /* TODO fill out the rest. */ +} PACKED flash_t; + +#define FLASH (*(__IO flash_t*)FLASH_BASE) + +#endif /* H__FLASH_ */ -- cgit