aboutsummaryrefslogtreecommitdiffstats
path: root/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl
diff options
context:
space:
mode:
Diffstat (limited to 'tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl')
-rw-r--r--tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl33
1 files changed, 33 insertions, 0 deletions
diff --git a/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl b/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl
index 3f70e952d..e97f20c82 100644
--- a/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl
+++ b/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl
@@ -21,6 +21,8 @@
[@pp.dropOutputFile /]
[#import "/@lib/libutils.ftl" as utils /]
[#import "/@lib/liblicense.ftl" as license /]
+[#import "/@lib/libcode.ftl" as code /]
+[#import "/@lib/libstm32f4xx.ftl" as stm32f4xx /]
[#assign fname = doc1.configuration.@name[0] /]
[@pp.changeOutputFile name = fname + ".c" /]
/*
@@ -29,3 +31,34 @@
#include "ch.h"
#include "hal.h"
+
+/*===========================================================================*/
+/* Module local definitions. */
+/*===========================================================================*/
+
+/*===========================================================================*/
+/* Module exported variables. */
+/*===========================================================================*/
+
+[#list doc1.configuration.configs.* as config]
+ [#assign config_type = config?node_name /]
+ [#if config_type == "adc_config"]
+ [@stm32f4xx.EmitADCConfig config /]
+ [/#if]
+
+[/#list]
+/*===========================================================================*/
+/* Module local variables. */
+/*===========================================================================*/
+
+/*===========================================================================*/
+/* Module local functions. */
+/*===========================================================================*/
+
+/*===========================================================================*/
+/* Module interrupt handlers. */
+/*===========================================================================*/
+
+/*===========================================================================*/
+/* Module exported functions. */
+/*===========================================================================*/