Commit Graph

8595 Commits (c50f490cf47cc3fb5cbe140d1e420fcd1ed23f95)

Author SHA1 Message Date
Martin Kojtal c6d814e68c
Merge pull request #15215 from jeromecoutant/PR_STM32L4_ADD
STM32 : add MCU_STM32L4P5xG and MCU_STM32L412xB support
2022-02-09 16:57:53 +01:00
Martin Kojtal c4fd338adc
Merge pull request #15212 from mothacehe/master
STM32H7: increase i2c slave rx limit.
2022-02-01 16:40:26 +01:00
Martin Kojtal 26876c0b91
Merge pull request #15190 from hazzlim/make_gpio_irq_api_portable
Make gpio irq api portable
2022-01-31 10:27:18 +01:00
Jerome Coutant 12757de057 STM32L4 : add MCU_STM32L412xB support 2022-01-28 13:49:49 +01:00
Mathieu Othacehe 3c0c9c2b33
STM32: increase i2c slave rx limit.
Use uint16_t variables for i2c slave_rx_buffer_size and slave_rx_count
variables. This allows to receive more than 255 bytes in slave mode. The
bytes are received one by one in slave mode so there are no hardware
limitations forcing a 1 byte rx count limit.
2022-01-28 11:58:52 +01:00
Jerome Coutant 4ecbf935ce STM32L4 : add MCU_STM32L4P5xG support 2022-01-28 11:46:39 +01:00
Martin Kojtal f75ff22714
Merge pull request #15207 from wally0258/master
Add Nuvoton NuMaker-IoT-M263A CAN bus support
2022-01-28 10:58:34 +01:00
wally0258 4a0df44ec9
Resolve compiler warning and disable CAN0 IRQ 2022-01-27 09:40:55 +08:00
Hari Limaye f4e5359710 GPIO: Use uintptr_t for gpio_irq_api context
The HAL gpio_irq_api stores object IDs, which serve as a form of context
for the dispatch of the interrupt handler in the drivers level
InterruptIn Class. The way this is achieved is that the InterruptIn
Class casts its address to uint32_t, which is stored as the ID.
This results in compilation failure when the size of an object pointer
is greater than uint32_t, for example when building on a PC for unit
testing.

In order to allow Unit Testing of the InterruptIn Class, we replace the
use of uint32_t with uintptr_t (type capable of holding a pointer),
which allows portability and expresses intentions more clearly.
In aid of this latter goal, we also replace the use of the name "id"
with "context", to improve clarity - these are addresses of the context
related to that callback.
2022-01-26 18:12:52 +00:00
Hari Limaye a580c418cc HAL: Remove duplication in TARGET_NRF52 gpio_api 2022-01-26 11:14:30 +00:00
wally0258 94833a0ba6
Update can_api.c
Update Copyright
2022-01-25 09:05:31 +08:00
Jerome Coutant b9d51b6255 ST: correct LED pins for DISCO_L562QE 2022-01-21 09:41:21 +01:00
Martin Kojtal 1443257e40
Merge pull request #15206 from vznncv/iss_stm32_spi_16_bit
STM32: fix SPI 16 bit mode
2022-01-17 16:39:01 +01:00
Martin Kojtal d234b35aee
Merge pull request #15205 from mikrodust-henrikp/add_usbdevice_to_nucleo_f722ze
Add USBDEVICE to NUCLEO_F722ZE target
2022-01-17 16:10:06 +01:00
Wally 6e09135b58 Add Nuvoton NuMaker-IoT-M263A CAN bus support 2022-01-17 14:32:42 +08:00
Konstantin Kochin 0c9d5b0605 Fix STM32 SPI async API for STM32H7 (SPI_IP_VERSION_V2)
By default, HAL functions (HAL_SPI_TransmitReceive_IT/HAL_SPI_Transmit_IT/HAL_SPI_Receive_IT) assume that SPI is disabled between function invocation.
It's needed to set transfer size (CR2 register), that can be modified only if SPI disabled. But `stm32_spi_api.c` keeps SPI enabled after initialization.

This commit adds helper code for STM32H7 (SPI_IP_VERSION_V2) that disables SPI before HAL_SPI_TransmitReceive_IT/HAL_SPI_Transmit_IT/HAL_SPI_Receive_IT
and after end of transaction for HAL API compatibility.
2022-01-15 14:51:41 +03:00
Konstantin Kochin 756f6f5199 Fix STM32 SPI 16-bit logic
Update SPI logic to process 16 bit words in the same way by sync/async,
3/4 wires modes:
- fix 3-wire synchronous transmission to move 2 or more bytes between buffer and
  SPI register per word tarnsmission
- fix 4-wire synchronous transmission to move 2 or more bytes between buffer and
  SPI register per word tarnsmission
2022-01-15 14:51:41 +03:00
Michal Majcherski 6263af9aff Support for the NUCLEO_G0B1RE board 2022-01-14 12:11:47 +01:00
Henrik Persson 6f73f5deb3 Add USBDEVICE to NUCLEO_F722ZE target
USB was missing from NUCLEO_F722ZE but is present and working on the
board.
2022-01-14 11:46:44 +01:00
Jerome Coutant 5e5d2ab9a5 STM32G0 FLASH : support MCU with dual bank 2022-01-13 11:44:21 +01:00
Martin Kojtal 6bb606f62d
Merge pull request #15194 from deepak-shreshti/master
Add Toshiba M4KN Platform
2022-01-10 13:49:32 +01:00
Chun-Chieh Li 926cda5e8f M487: Fix UART 6/7 base address encoding
Fix UART 6/7 base addresses are incorrectly encoded into peripheral names
2022-01-07 16:39:59 +08:00
Deepak V. Shreshti 5bc3aa18c0 Updated code to remove float symbols 2021-12-23 19:19:57 +05:30
Deepak V. Shreshti cd4ee72979 Added SPDX Header
Updated PIN Names
Added M4KN MCU Deatils in index.json
Removed Special Chars
2021-12-23 19:19:57 +05:30
Deepak V. Shreshti 44249f0d40 Added M4KN Platform
New Platform M4KN for Toshiba has been added
2021-12-23 19:19:56 +05:30
ATmobica 6a5cc40182 Fix mbed-cy8cproto-062s3-4343w target 2021-12-15 22:16:14 +01:00
ATmobica 9e1444f88d Add <"CM0P_SLEEP" IN_LIST MBED_TARGET_LABELS> condition to Cypress boards and common PSOC6 cmake files 2021-12-15 21:37:14 +01:00
Martin Kojtal 7a6262c3bc
Merge pull request #15189 from boraozgen/nrf52-gpio-assert-init
nRF52: GPIO: Assert that init succeeds
2021-12-15 14:42:47 +00:00
Martin Kojtal fe5e648147
Merge pull request #15192 from ATmobica/master
Add option to disable WHD component for Cypress targets
2021-12-15 11:59:33 +00:00
Bora Özgen 352beffedf nRF52: GPIO: Assert that init succeeds 2021-12-14 10:01:08 +01:00
Jerome Coutant de3f9efb67 STM32H7 : remove warning
[Warning] stm32h7xx_hal_hrtim.c@1621,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32h7xx_hal_hrtim.c@1625,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32h7xx_hal_hrtim.c@2238,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32h7xx_hal_hrtim.c@2242,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32h7xx_hal_hrtim.c@5332,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32h7xx_hal_hrtim.c@5767,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32h7xx_hal_hrtim.c@5771,21: equality comparison with extraneous parentheses [-Wparentheses-equality]

[Warning] analogin_device.c@63,30: comparison between 'PinName' and 'enum <anonymous>' [-Wenum-compare]
2021-12-10 17:16:47 +01:00
Jerome Coutant 3237bff990 STM32F7 : remove warning
[Warning] flash_api.c@191,14: unused variable 'tmp' [-Wunused-variable]
2021-12-10 17:16:47 +01:00
Jerome Coutant 4d63929898 STM32L5 : remove warning
[Warning] serial_device.c@657,41: comparison of different enumeration types ('PinName' and 'UARTName') [-Wenum-compare]
[Warning] serial_device.c@666,41: comparison of different enumeration types ('PinName' and 'UARTName') [-Wenum-compare]
[Warning] serial_device.c@675,41: comparison of different enumeration types ('PinName' and 'UARTName') [-Wenum-compare]
[Warning] serial_device.c@676,41: comparison of different enumeration types ('PinName' and 'UARTName') [-Wenum-compare]
2021-12-10 17:16:47 +01:00
Jerome Coutant 1bf801a4f7 STM32G4 : remove warning
[Warning] serial_device.c@644,41: comparison of integer expressions of different signedness: 'PinName' and 'enum <anonymous>' [-Wsign-compare]
[Warning] serial_device.c@644,41: comparison between 'PinName' and 'enum <anonymous>' [-Wenum-compare]
[Warning] serial_device.c@653,41: comparison of integer expressions of different signedness: 'PinName' and 'enum <anonymous>' [-Wsign-compare]
[Warning] serial_device.c@653,41: comparison between 'PinName' and 'enum <anonymous>' [-Wenum-compare]
[Warning] serial_device.c@662,41: comparison of integer expressions of different signedness: 'PinName' and 'enum <anonymous>' [-Wsign-compare]
[Warning] serial_device.c@662,41: comparison between 'PinName' and 'enum <anonymous>' [-Wenum-compare]
[Warning] serial_device.c@663,41: comparison of integer expressions of different signedness: 'PinName' and 'enum <anonymous>' [-Wsign-compare]
[Warning] serial_device.c@663,41: comparison between 'PinName' and 'enum <anonymous>' [-Wenum-compare]

[Warning] stm32g4xx_hal_hrtim.c@1817,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32g4xx_hal_hrtim.c@1821,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32g4xx_hal_hrtim.c@2461,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32g4xx_hal_hrtim.c@2465,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32g4xx_hal_hrtim.c@6600,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32g4xx_hal_hrtim.c@7162,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
[Warning] stm32g4xx_hal_hrtim.c@7166,21: equality comparison with extraneous parentheses [-Wparentheses-equality]
2021-12-10 17:16:47 +01:00
Jerome Coutant 999d98a3d7 STM32L4 : remove warning
This is the MBED current implementation, no need to warn
2021-12-10 17:16:47 +01:00
Jerome Coutant b5e28baf45 STM32 CAN : remove warning [-Wsign-compare]
Detected with NUCLEO_G474RE build:
[Warning] stm32g4xx_hal_fdcan.h@1325,84: comparison is always true due to limited range of data type [-Wtype-limits]
[Warning] stm32g4xx_hal_fdcan.h@1331,46: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
[Warning] stm32g4xx_hal_fdcan.h@1331,65: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
[Warning] stm32g4xx_hal_fdcan.h@1325,61: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
[Warning] stm32g4xx_hal_fdcan.h@1325,84: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
2021-12-10 17:16:35 +01:00
ATmobica 78a7859fa8 Add <"WHD" IN_LIST MBED_TARGET_LABELS> condition to Cypress boards and wifi driver cmake files 2021-12-10 13:14:29 +01:00
Martin Kojtal b129f6ebad
Merge pull request #15184 from ihf-uk-team/master
Fix initialisation sequence of RTC
2021-12-07 13:57:32 +00:00
Jerome Coutant e49036dd56 STM32WL : update readme 2021-12-06 17:48:35 +01:00
Michael Hasling dc30b7afe9 Fix initialisation sequence of RTC
Initialisation of RTC was wrong for boot from sysreset, and resulted
in RTOS with nothing to do in its main thread. This fixes the bug.
2021-11-29 16:45:22 +00:00
Martin Kojtal 01ef431f88
Merge pull request #15174 from OpenNuvoton/nuvoton_m2354_tfm_sram-bank_sector-map_scratch
M2354: Fix potential issues in TF-M
2021-11-22 10:48:21 +00:00
Chun-Chieh Li d0f72015c0 M2354: Fix potential issues in TF-M
Fix the following issues in TF-M to avoid emergence in the future:
1.  Enable initial stack not located in SRAM bank0
    On reset, only SRAM bank0 is enabled. And SRAM bank1/2 will be enabled in immediately following SystemInit().
    When initial stack is located in SRAM bank1/2, we will meet trouble because SystemInit() itself needs to use initial stack.
    To conquer the dilemma, we add preceding code in front of original Systeminit(), which is responsible for enabling SRAM bank1/2 and guarantees no using initial stack.
2.  Fix sector maps of internal/external (SDH) Flash are incompatible, caused by TF-M's MCUboot port.
    This is done by adapting external (SDH) Flash sector size to internal Flash's.
3.  Enlarge firmware upgrade scratch size. There are two advantages:
    (1) Get around MCUboot limit which requires scratch size not smaller than image trailer size
    (2) Improve wear leveling for the scratch area
2021-11-22 13:57:22 +08:00
Jerome Coutant be6e9a16a5 B_U585I_IOT02A supports OSPI 2021-11-18 12:26:21 +01:00
Martin Kojtal ae5c9ec70e
Merge pull request #15153 from bakatrouble/master
STM32F722ZE port
2021-11-17 15:22:30 +00:00
Jerome Coutant 9675b6ccb6 STM32L1: add support of MCU_STM32L151xB
for custom boards like RAK811
2021-11-10 10:12:28 +01:00
Jerome Coutant 8e26a05f50 STM32: readme update for MBED_SLEEP_TRACING_ENABLED 2021-11-08 09:46:20 +01:00
Chun-Chieh Li 5992676276 M2354: Adjust TF-M configuration to fit AWS IoT
1.  In TF-M, enlarge ITS max asset number/size
    NOTE: RSA key size is larger
2.  In TF-M, enlarge mbedtls dedicated heap
    NOTE: RSA algorithm needs more memory.
    NOTE: psa_aead_decrypt() (for mbedtls_ssl_read()) needs memory proportional to data size.
2021-10-29 10:38:27 +08:00
bakatrouble 6c9ae1e9fc Add STM32F722ZE target 2021-10-28 19:18:30 +03:00
bakatrouble 0e64ff9a90 Support missing SPI6 on STM32F7 2021-10-28 19:18:30 +03:00
bakatrouble 469d681bd9 Support different STM32F7 flash configurations 2021-10-28 19:18:30 +03:00