From dbfb5a1f70e69a3f412f2a69f528bf398633c10f Mon Sep 17 00:00:00 2001 From: gdisirio Date: Tue, 10 Jul 2012 20:08:46 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4457 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.c.ftl | 2 ++ tools/gencfg/processors/hal/stm32f4xx/templates/hal_cfg.h.ftl | 9 ++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) (limited to 'tools/gencfg/processors/hal') 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 -- cgit v1.2.3