diff options
author | Damien George <damien.p.george@gmail.com> | 2014-09-21 22:54:02 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-09-21 22:54:02 +0100 |
commit | 0e58c5810de2717f9707e9eef82cd57a43468a60 (patch) | |
tree | a7d15cf3e8ba61f441fa184bd8a6659df1d8c0ce /stmhal/timer.h | |
parent | becbc87fd73c98664b472b4a06c2b54558dd5669 (diff) | |
download | micropython-0e58c5810de2717f9707e9eef82cd57a43468a60.tar.gz micropython-0e58c5810de2717f9707e9eef82cd57a43468a60.zip |
stmhal: Add pulse_width_ratio to timer channel object.
This allows to set the pulse width (for PWM mode) as a ratio relative to
the period of the timer. Eg, 0.5 is a 50% duty cycle. You can set the
ratio in the channel init, or using channel.pulse_width_ratio; the
latter can also read the pulse width as a ratio.
Diffstat (limited to 'stmhal/timer.h')
-rw-r--r-- | stmhal/timer.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/stmhal/timer.h b/stmhal/timer.h index c737ee7635..2a892db285 100644 --- a/stmhal/timer.h +++ b/stmhal/timer.h @@ -34,7 +34,6 @@ extern TIM_HandleTypeDef TIM5_Handle; extern TIM_HandleTypeDef TIM6_Handle; extern const mp_obj_type_t pyb_timer_type; -extern const mp_obj_type_t pyb_timer_channel_type; void timer_init0(void); void timer_tim3_init(void); |