TuyaOS
函数
tkl_pwm.h 文件参考

Common process - adapter the pwm api 更多...

#include "tuya_cloud_types.h"
tkl_pwm.h 的引用(Include)关系图:
此图展示该文件直接或间接的被哪些文件引用了:

浏览源代码.

函数

OPERATE_RET tkl_pwm_deinit (TUYA_PWM_NUM_E ch_id)
 pwm deinit 更多...
 
OPERATE_RET tkl_pwm_duty_set (TUYA_PWM_NUM_E ch_id, UINT32_T duty)
 pwm duty set 更多...
 
OPERATE_RET tkl_pwm_frequency_set (TUYA_PWM_NUM_E ch_id, UINT32_T frequency)
 pwm frequency set 更多...
 
OPERATE_RET tkl_pwm_info_get (TUYA_PWM_NUM_E ch_id, TUYA_PWM_BASE_CFG_T *info)
 get pwm info 更多...
 
OPERATE_RET tkl_pwm_info_set (TUYA_PWM_NUM_E ch_id, CONST TUYA_PWM_BASE_CFG_T *info)
 set pwm info 更多...
 
OPERATE_RET tkl_pwm_init (TUYA_PWM_NUM_E ch_id, CONST TUYA_PWM_BASE_CFG_T *cfg)
 pwm init 更多...
 
OPERATE_RET tkl_pwm_multichannel_start (TUYA_PWM_NUM_E *ch_id, UINT8_T num)
 multiple pwm channel start 更多...
 
OPERATE_RET tkl_pwm_multichannel_stop (TUYA_PWM_NUM_E *ch_id, UINT8_T num)
 multiple pwm channel stop 更多...
 
OPERATE_RET tkl_pwm_polarity_set (TUYA_PWM_NUM_E ch_id, TUYA_PWM_POLARITY_E polarity)
 pwm polarity set 更多...
 
OPERATE_RET tkl_pwm_start (TUYA_PWM_NUM_E ch_id)
 pwm start 更多...
 
OPERATE_RET tkl_pwm_stop (TUYA_PWM_NUM_E ch_id)
 pwm stop 更多...
 

详细描述

Common process - adapter the pwm api

版本
0.1
日期
2021-08-06

函数说明

◆ tkl_pwm_deinit()

OPERATE_RET tkl_pwm_deinit ( TUYA_PWM_NUM_E  ch_id)

pwm deinit

参数
[in]ch_idpwm channal id, id index starts at 0
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_duty_set()

OPERATE_RET tkl_pwm_duty_set ( TUYA_PWM_NUM_E  ch_id,
UINT32_T  duty 
)

pwm duty set

参数
[in]ch_idpwm channal id, id index starts at 0
[in]dutypwm duty cycle
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_frequency_set()

OPERATE_RET tkl_pwm_frequency_set ( TUYA_PWM_NUM_E  ch_id,
UINT32_T  frequency 
)

pwm frequency set

参数
[in]ch_idpwm channal id, id index starts at 0
[in]frequencypwm frequency
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_info_get()

OPERATE_RET tkl_pwm_info_get ( TUYA_PWM_NUM_E  ch_id,
TUYA_PWM_BASE_CFG_T info 
)

get pwm info

参数
[in]ch_idpwm channal id, id index starts at 0
[out]infopwm info
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_info_set()

OPERATE_RET tkl_pwm_info_set ( TUYA_PWM_NUM_E  ch_id,
CONST TUYA_PWM_BASE_CFG_T info 
)

set pwm info

参数
[in]ch_idpwm channal id, id index starts at 0
[in]infopwm info
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_init()

OPERATE_RET tkl_pwm_init ( TUYA_PWM_NUM_E  ch_id,
CONST TUYA_PWM_BASE_CFG_T cfg 
)

pwm init

参数
[in]ch_idpwm channal id, id index starts at 0
[in]cfgpwm config
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_multichannel_start()

OPERATE_RET tkl_pwm_multichannel_start ( TUYA_PWM_NUM_E *  ch_id,
UINT8_T  num 
)

multiple pwm channel start

参数
[in]ch_idpwm channal id list
[in]num: num of pwm channal to start
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_multichannel_stop()

OPERATE_RET tkl_pwm_multichannel_stop ( TUYA_PWM_NUM_E *  ch_id,
UINT8_T  num 
)

multiple pwm channel stop

参数
[in]ch_idpwm channal id list
[in]num: num of pwm channal to stop
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_polarity_set()

OPERATE_RET tkl_pwm_polarity_set ( TUYA_PWM_NUM_E  ch_id,
TUYA_PWM_POLARITY_E  polarity 
)

pwm polarity set

参数
[in]ch_idpwm channal id, id index starts at 0
[in]polaritypwm polarity
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_start()

OPERATE_RET tkl_pwm_start ( TUYA_PWM_NUM_E  ch_id)

pwm start

参数
[in]ch_idpwm channal id, id index starts at 0
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h

◆ tkl_pwm_stop()

OPERATE_RET tkl_pwm_stop ( TUYA_PWM_NUM_E  ch_id)

pwm stop

参数
[in]ch_idpwm channal id, id index starts at 0
返回
OPRT_OK on success. Others on error, please refer to tuya_error_code.h