Commit graph

13 commits

Author SHA1 Message Date
Gerard Marull-Paretas 76f0d72e5d drivers: pwm: stm32: add support for polarity
Add support for the polarity flag in the STM32 PWM driver.

STM32 boards using PWM have been updated accordingly.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2020-06-19 15:18:50 +02:00
Gerard Marull-Paretas c6b1375400 drivers: pwm: stm32: remove remaining Kconfig instances
Following other drivers, Kconfig based instances are now entirely
removed. In order to do this change, PWM nodes in board DT files have
been given a pwm{N} label so that both:

- DT API checks such as #if DT_HAS_NODE(DT_NODELABEL(pwmN)) can be
  used (N being PWM instance number).
- DT references can be written as pwms = <&pwmN x y>; instead of
  pwms = <&{/soc/timers@XXXXXXXX/pwm} x y>;

This approach is also used on the Linux Kernel.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2020-05-05 10:52:51 -05:00
Erwan Gouriou fc52f097b8 boards: stm32: Fix buttons and leds configuration
On some stm32 based boards buttons and leds configuration
was wrong. Fix that.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2020-02-05 12:00:36 +01:00
Erwan Gouriou 31ed7e931b boards: stm32: Update board definition using new GPIO api
Move GPIO_ACTIVE_INT_HIGH/LOW to GPIO_ACTIVE_HIGH/LOW.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2020-02-05 12:00:36 +01:00
Erwan Gouriou 4dc303b99b dts: stm32: Remove pinctrl definitions
dts pinctrl definitions were pushed in tree without the code
available to deal with it. They have been kept waiting for the
code, but this is taking much more time than initially thought.

So in current zephyr tree, for all STM32 boards, we have pinmux.c
file which is used to configure pins and these files that are
basically no-op. This situation is creating a lot of confusion
especially to new comers, and create useless maintenance effort.

Remove these files for now.
When zephyr will ready to use them, this commit could be reverted.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2019-11-06 18:26:04 +01:00
Erwan Gouriou 628a0336bf boards: stm32: Set arduino gpio connector on nucleo 144 pins boards
Apply same scheme for all nucleo 144 pins boards:
-provide a separate arduino connector dtsi file
-provide complete gpio map
-update board.yaml vs arduino support (i2c, spi and gpio)

Done using following references:
http://www.st.com/resource/en/user_manual/dm00105823.pdf
http://www.st.com/resource/en/user_manual/dm00368330.pdf

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2019-10-09 18:04:28 -05:00
Ioannis Konstantelias 4bda345685 boards: arm: nucleo_{f401re, l496zg}: Enable WWDG
Added support for System Window Watchdog.

Signed-off-by: Ioannis Konstantelias <ikonstadel@gmail.com>
2019-09-11 22:13:36 -05:00
Ulf Magnusson a84ded74ea dts: Replace status = "ok" with status = "okay"
The DT spec. only has "okay" and not "ok". The Linux kernel has around
12k "okay"s and 300 "ok"s.

The scripts/dts scripts only check for "disabled", so should be safe re.
those at least.

The replacement was done with

    git ls-files | xargs sed -i 's/status\s*=\s*"ok"/status = "okay"/'

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-06-14 19:51:13 -05:00
Ioannis Konstantelias 677bae5980 boards: nucleo_l496zg: Use shell-uart
Added shell-uart for this board.

Signed-off-by: Ioannis Konstantelias <ikonstadel@gmail.com>
2019-01-23 09:18:35 -06:00
Ioannis Konstantelias d5d10bcec0 boards: nucleo_l496zg: Add SPI, I2C
Added Aduino SPI and I2C mappings.

Signed-off-by: Ioannis Konstantelias <ikonstadel@gmail.com>
2019-01-23 09:18:35 -06:00
Ioannis Konstantelias 5151e8a094 boards: nucleo_l496zg: Add pwm mapping and RTC
Supported PWM at pins A0, D3, D5 and D6 which are also Arduino
compatible. Also the onboard red LED can be used with PWM.

The basic/{fade_led, blink_led} samples to apply to this board
seemlessly and operate on the onboard red LED.

Also supported RTC.

Signed-off-by: Ioannis Konstantelias <ikonstadel@gmail.com>
2019-01-23 09:18:35 -06:00
Ioannis Konstantelias 68147a9b83 boards: nucleo_l496zg: Add UART for console
Used LPUART 1 for console subsys. Also, added USART2 and USART3.

Signed-off-by: Ioannis Konstantelias <ikonstadel@gmail.com>
2019-01-23 09:18:35 -06:00
Ioannis Konstantelias 3a002da53e boards: arm: Add initial support for NUCLEO-L496ZG
This commit adds the simplest configuration for this Nucleo-144 board
stripped down to the parts that are currently tested.

Signed-off-by: Ioannis Konstantelias <ikonstadel@gmail.com>
2019-01-23 09:18:35 -06:00