Loading...
Searching...
No Matches
furi_hal_pwm.h
Go to the documentation of this file.
1
5#pragma once
6
7#ifdef __cplusplus
8extern "C" {
9#endif
10
11#include <stdint.h>
12#include <stdbool.h>
13
14typedef enum {
15 FuriHalPwmOutputIdTim1PA7,
16 FuriHalPwmOutputIdLptim2PA4,
17} FuriHalPwmOutputId;
18
25void furi_hal_pwm_start(FuriHalPwmOutputId channel, uint32_t freq, uint8_t duty);
26
31void furi_hal_pwm_stop(FuriHalPwmOutputId channel);
32
39void furi_hal_pwm_set_params(FuriHalPwmOutputId channel, uint32_t freq, uint8_t duty);
40
46bool furi_hal_pwm_is_running(FuriHalPwmOutputId channel);
47
48#ifdef __cplusplus
49}
50#endif
void furi_hal_pwm_set_params(FuriHalPwmOutputId channel, uint32_t freq, uint8_t duty)
Set PWM channel parameters.
Definition furi_hal_pwm.c:99
void furi_hal_pwm_start(FuriHalPwmOutputId channel, uint32_t freq, uint8_t duty)
Enable PWM channel and set parameters.
Definition furi_hal_pwm.c:22
bool furi_hal_pwm_is_running(FuriHalPwmOutputId channel)
Is PWM channel running?
Definition furi_hal_pwm.c:89
void furi_hal_pwm_stop(FuriHalPwmOutputId channel)
Disable PWM channel.
Definition furi_hal_pwm.c:77