summaryrefslogtreecommitdiff
path: root/documentation
diff options
context:
space:
mode:
authorslhuan <[email protected]>2023-03-08 10:26:30 +0800
committerMan, Jianting (Meco) <[email protected]>2023-03-07 22:04:09 -0500
commite72273317832e79dec218450b4661103e65dfbac (patch)
treed4a094178f972a31aaba39d18f6d2643f2c5042e /documentation
parent7c95cc98f92cde63823033240c9409359ca4ff62 (diff)
修改doc文件夹下pwm例程中将led的io设置为输出模式后再使用PWM控制LED,经验证使用这样是无法正常输出PWM的
Diffstat (limited to 'documentation')
-rw-r--r--documentation/device/pwm/pwm.md5
1 files changed, 0 insertions, 5 deletions
diff --git a/documentation/device/pwm/pwm.md b/documentation/device/pwm/pwm.md
index b1b88180ba..e87c1328f9 100644
--- a/documentation/device/pwm/pwm.md
+++ b/documentation/device/pwm/pwm.md
@@ -218,11 +218,6 @@ static int pwm_led_sample(int argc, char *argv[])
dir = 1; /* Increase or decrease direction of PWM pulse width value */
pulse = 0; /* PWM pulse width value, the unit is nanoseconds*/
- /* Set LED pin mode to output */
- rt_pin_mode(LED_PIN_NUM, PIN_MODE_OUTPUT);
- /* Set high LED pin mode */
- rt_pin_write(LED_PIN_NUM, PIN_HIGH);
-
/* Search the Device */
pwm_dev = (struct rt_device_pwm *)rt_device_find(PWM_DEV_NAME);
if (pwm_dev == RT_NULL)