From: asterix Date: Fri, 6 Feb 2009 14:41:06 +0000 (+0000) Subject: Add cfg file and wizard info. X-Git-Tag: 2.1.0~378 X-Git-Url: https://codewiz.org/gitweb?a=commitdiff_plain;h=6184365e21d54c0e1f3461a45aaee4ad64558d77;p=bertos.git Add cfg file and wizard info. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2304 38d2e660-2303-0410-9eaa-f027e97ec537 --- diff --git a/bertos/cfg/cfg_phase.h b/bertos/cfg/cfg_phase.h new file mode 100644 index 00000000..f80b1ed0 --- /dev/null +++ b/bertos/cfg/cfg_phase.h @@ -0,0 +1,48 @@ +/** + * \file + * + * + * \brief Configuration file for phase module. + * + * \version $Id$ + * \author Daniele Basile + */ + +#ifndef CFG_PHASE_H +#define CFG_PHASE_H + +/// Max value of the duty cycle on triac. $WIZARD = { "type" : "int" } +#define TRIAC_MAX_DUTY 100 + +/// Max value of the triac power. $WIZARD = { "type" : "int" } +#define TRIAC_MAX_POWER 100 + +#endif /* CFG_PHASE_H */ diff --git a/bertos/drv/phase.h b/bertos/drv/phase.h index 9a2341e4..199832b3 100644 --- a/bertos/drv/phase.h +++ b/bertos/drv/phase.h @@ -31,22 +31,27 @@ * * \version $Id$ * - * \brief Phase control driver (interface) + * \brief Phase control driver, to manage triac swicth. * * \version $Id$ * \author Francesco Sacchi + * + * $WIZARD_MODULE = { + * "name" : "phase", + * "depends" : ["timer"], + * "configuration" : "bertos/cfg/cfg_phase.h" + * } */ #ifndef DRV_PHASE_H #define DRV_PHASE_H #include "hw/phase_map.h" -#include + +#include "cfg/cfg_phase.h" #include -#define TRIAC_MAX_DUTY 100 -#define TRIAC_MAX_POWER 100 #define TRIAC_POWER_K TRIAC_MAX_DUTY * (1 / sqrt(2 * TRIAC_MAX_POWER)) /**