Use log for debug message.
author(no author) <(no author)@38d2e660-2303-0410-9eaa-f027e97ec537>
Thu, 20 Aug 2009 14:08:23 +0000 (14:08 +0000)
committer(no author) <(no author)@38d2e660-2303-0410-9eaa-f027e97ec537>
Thu, 20 Aug 2009 14:08:23 +0000 (14:08 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2772 38d2e660-2303-0410-9eaa-f027e97ec537

bertos/drv/pwm.c

index 11c4e04bbb845563b17e2c15e9aad9dc85a7ef8e..cb5a45fb0e7293b7f5c292ff2fad620dc9f09a3b 100644 (file)
  * \author Daniele Basile <asterix@develer.com>
  */
 
+#include "cfg/cfg_pwm.h"
+
 #include <cfg/macros.h>
+
+// Define logging setting (for cfg/log.h module).
+#define LOG_LEVEL         PWM_LOG_LEVEL
+#define LOG_VERBOSITY     PWM_LOG_FORMAT
+
+#include <cfg/log.h>
 #include <cfg/debug.h>
 
 #include <drv/pwm.h>
@@ -63,7 +71,7 @@ void pwm_setDuty(PwmDev dev, pwm_duty_t duty)
 
        real_duty = (uint64_t)(duty * period) >> (uint64_t)PWM_MAX_PERIOD_LOG2;
 
-//     TRACEMSG("real_duty[%d] duty[%d], period[%d]", real_duty, duty, period);
+       LOG_INFO("real_duty[%d] duty[%d], period[%d]", real_duty, duty, period);
        pwm_hw_setDutyUnlock(dev, real_duty);
 }