diff options
Diffstat (limited to 'tools/gencfg/processors')
-rw-r--r-- | tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl | 2 | ||||
-rw-r--r-- | tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.h.ftl | 9 |
2 files changed, 10 insertions, 1 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 e97f20c82..cd8b17a01 100644 --- a/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl +++ b/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl @@ -32,6 +32,8 @@ #include "ch.h"
#include "hal.h"
+#include "${fname + ".h"}"
+
/*===========================================================================*/
/* Module local definitions. */
/*===========================================================================*/
diff --git a/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.h.ftl b/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.h.ftl index b8f350ff9..050b2f84d 100644 --- a/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.h.ftl +++ b/tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.h.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 + ".h" /]
/*
@@ -57,7 +59,12 @@ #ifdef __cplusplus
extern "C" {
#endif
-
+[#list doc1.configuration.configs.* as config]
+ [#assign config_type = config?node_name /]
+ [#if config_type == "adc_config"]
+ [@stm32f4xx.EmitADCConfigExtern config /]
+ [/#if]
+[/#list]
#ifdef __cplusplus
}
#endif
|