pwm_avr.h

Go to the documentation of this file.
00001 
00041 #ifndef DRV_PWM_AVR_H
00042 #define DRV_PWM_AVR_H
00043 
00044 #include "hw/pwm_map.h"
00045 
00046 #include <cpu/types.h>
00047 
00048 #define PWM_HW_MAX_PRESCALER_STEP         10
00049 #define PWM_HW_MAX_PERIOD             0xFFFF
00050 
00054 typedef uint16_t pwm_period_t;
00055 
00059 typedef struct PwmChannel
00060 {
00061     /*  */
00062 } PwmChannel;
00063 
00064 
00065 void pwm_hw_init(void);
00066 void pwm_hw_setFrequency(PwmDev dev, uint32_t freq);
00067 void pwm_hw_setDutyUnlock(PwmDev dev, uint16_t duty);
00068 void pwm_hw_disable(PwmDev dev);
00069 void pwm_hw_enable(PwmDev dev);
00070 void pwm_hw_setPolarity(PwmDev dev, bool pol);
00071 pwm_period_t pwm_hw_getPeriod(PwmDev dev);
00072 
00073 #endif /* DRV_ADC_AT91_H */