added servo
This commit is contained in:
@@ -1,20 +1,27 @@
|
||||
/ {
|
||||
aliases {
|
||||
led0 = &user_led;
|
||||
led0 = &red_led_1;
|
||||
led1 = &yellow_led_1;
|
||||
led2 = &green_led_1;
|
||||
|
||||
servo0 = &pwm_servo0;
|
||||
};
|
||||
|
||||
leds {
|
||||
compatible = "gpio-leds";
|
||||
user_led: user_led_0 {
|
||||
gpios = <&gpiob 0 GPIO_ACTIVE_HIGH>;
|
||||
label = "USER_LED_0";
|
||||
};
|
||||
};
|
||||
pwmleds: pwmleds {
|
||||
compatible = "pwm-leds";
|
||||
status = "okay";
|
||||
|
||||
pwm_servo0: pwm_servo0 {
|
||||
pwms = <&pwm4 3 PWM_MSEC(20) PWM_POLARITY_NORMAL>;
|
||||
label = "servo 0";
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
status = "okay";
|
||||
current-speed = <921600>;
|
||||
current-speed = <460800>;
|
||||
pinctrl-0 = <&uart4_tx_pa0 &uart4_rx_pd0>;
|
||||
pinctrl-names = "default";
|
||||
};
|
||||
@@ -23,15 +30,13 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&timers1 {
|
||||
&timers4 {
|
||||
status = "okay";
|
||||
st,prescaler = <119>;
|
||||
|
||||
st,prescaler = <0>; /* Required */
|
||||
|
||||
pwm0: pwm {
|
||||
compatible = "st,stm32-pwm";
|
||||
pwm4: pwm {
|
||||
status = "okay";
|
||||
pinctrl-0 = <&tim1_ch1_pa8>;
|
||||
pinctrl-0 = <&tim4_ch3_pb8>;
|
||||
pinctrl-names = "default";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user