mirror of
https://github.com/Fishwaldo/bl_mcu_sdk.git
synced 2025-07-07 13:28:48 +00:00
[fix][pwm] fix device ctrl definition
This commit is contained in:
parent
2d4df8a271
commit
a1912eeec1
1 changed files with 2 additions and 2 deletions
|
@ -54,12 +54,12 @@ int main(void)
|
||||||
|
|
||||||
while (1) {
|
while (1) {
|
||||||
for (pwm_cfg.threshold_high = 0; pwm_cfg.threshold_high <= 32; pwm_cfg.threshold_high++) {
|
for (pwm_cfg.threshold_high = 0; pwm_cfg.threshold_high <= 32; pwm_cfg.threshold_high++) {
|
||||||
device_control(led_breath, DEIVCE_CTRL_PWM_DUTYCYCLE_CONFIG, &pwm_cfg);
|
device_control(led_breath, DEVICE_CTRL_PWM_DUTYCYCLE_CONFIG, &pwm_cfg);
|
||||||
bflb_platform_delay_ms(50);
|
bflb_platform_delay_ms(50);
|
||||||
}
|
}
|
||||||
|
|
||||||
for (pwm_cfg.threshold_high = 32; 0 <= pwm_cfg.threshold_high && pwm_cfg.threshold_high <= 32; pwm_cfg.threshold_high--) {
|
for (pwm_cfg.threshold_high = 32; 0 <= pwm_cfg.threshold_high && pwm_cfg.threshold_high <= 32; pwm_cfg.threshold_high--) {
|
||||||
device_control(led_breath, DEIVCE_CTRL_PWM_DUTYCYCLE_CONFIG, &pwm_cfg);
|
device_control(led_breath, DEVICE_CTRL_PWM_DUTYCYCLE_CONFIG, &pwm_cfg);
|
||||||
bflb_platform_delay_ms(50);
|
bflb_platform_delay_ms(50);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue