From 6618fa1cf6f6cf7a28fc949ce2f535aa2775cbfd Mon Sep 17 00:00:00 2001 From: GUI <39894654+GuEe-GUI@users.noreply.github.com> Date: Tue, 9 Dec 2025 09:49:02 +0800 Subject: [Driver][MISC] Update ADC/PWM (#11003) * [DM][MISC] Make Kconfig(ADC/PWM) import for DM * [Driver][MISC][ADC] Fixup ADC 1. Fixup error no. 2. Fixup type of control for args. 3. Fixup value no init. * [Driver][MISC][PWM] Enable `rt_pwm_get` API Signed-off-by: GuEe-GUI <2991707448@qq.com> --- components/drivers/include/drivers/dev_pwm.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'components/drivers/include') diff --git a/components/drivers/include/drivers/dev_pwm.h b/components/drivers/include/drivers/dev_pwm.h index bda3fed0c1..6cc70a543f 100644 --- a/components/drivers/include/drivers/dev_pwm.h +++ b/components/drivers/include/drivers/dev_pwm.h @@ -201,6 +201,14 @@ rt_err_t rt_pwm_set_dead_time(struct rt_device_pwm *device, int channel, rt_uint */ rt_err_t rt_pwm_set_phase(struct rt_device_pwm *device, int channel, rt_uint32_t phase); +/** + * @brief get the PWM configuration + * @param device the PWM device + * @param cfg the configuration of PWM + * @return rt_err_t error code + */ +rt_err_t rt_pwm_get(struct rt_device_pwm *device, struct rt_pwm_configuration *cfg); + /*! @}*/ #endif /* __DEV_PWM_H__ */ -- cgit v1.3.1