Commit Graph

459 Commits (d8c2c6f97fe419d682cdc11d859a4ce2952ca23d)

Author SHA1 Message Date
Wilfried Chauveau e6b19d838c add support for STM32L443RC & WISE-1510 2018-01-26 17:06:39 +00:00
jeromecoutant c9c6857c7c STM32 NUCLEO F413ZH and L433RC : STDIO configuration
#5795 patches are missing for these 2 targets
STDIO_UART_TX and STDIO_UART_RX can be now user defined
2018-01-26 17:50:10 +01:00
jeromecoutant 7979f4d255 SMT32L4 : add missing ST HAL LPUART functions
To enable/disable UART Clock in Stop Mode
2018-01-26 16:24:54 +01:00
Cruz Monrreal f1cf77fa44
Merge pull request #5844 from adustm/DiscoIot_L475_iarlink
ST-DISCO_L475VG_IOT01A: Improve SRAM use for IAR toolchain
2018-01-23 16:23:08 -06:00
jeromecoutant 6086c51234 STM32LX : HAL_RCC_OscConfig update in PLL configuration
check PLL settings before retuuning error
2018-01-22 13:35:11 +01:00
Cruz Monrreal 635a82495c
Merge pull request #5834 from bcostm/PULL_REQUEST_CUBE_UPDATE_L4_V1.11.0
STM32L4: Update ST Cube HAL to V1.11.0
2018-01-16 16:36:37 -06:00
adustm 5104f2d1cc Improve SRAM use for IAR toolchain
Use the entire SRAM2 with NVIC buffer + stack
  Increase HEAP size to 0x10000 in SRAM1
  Increase the available SRAM1 by 0x2000
2018-01-12 15:49:27 +01:00
bcostm d50c329c68 Use legacy CAN api 2018-01-12 11:17:29 +01:00
bcostm 06f097884c Update stm32l4xxxx.h files 2018-01-12 11:11:32 +01:00
bcostm a4f9012a0a Update stm32l4xx.h files 2018-01-12 11:11:31 +01:00
bcostm dda34ea206 Update system_stm32l4xx.c with latest version 2018-01-12 11:11:31 +01:00
bcostm 43a31557dc Remove release notes file 2018-01-12 11:11:31 +01:00
bcostm 0448d64f62 Add more comments 2018-01-12 11:11:31 +01:00
bcostm 84577f9634 L4 ST CUBE V1.11.0
Update to STM32CubeL4 V1.11.0

Conflicts solved:
	targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L433xC/device/stm32l433xx.h
	targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L486xG/device/stm32l4xx.h
	targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L496xG/device/stm32l496xx.h
	targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L496xG/device/stm32l4xx.h
	targets/TARGET_STM/TARGET_STM32L4/device/stm32l4xx_hal_conf.h
	targets/TARGET_STM/TARGET_STM32L4/device/stm32l4xx_hal_def.h
	targets/TARGET_STM/TARGET_STM32L4/device/stm32l4xx_hal_i2c.c
	targets/TARGET_STM/TARGET_STM32L4/device/stm32l4xx_hal_spi.h
2018-01-12 11:11:31 +01:00
jeromecoutant 59b4b228c4 STM32L4: STDIO_UART_TX and STDIO_UART_RX can be now user defined 2018-01-08 11:12:35 +01:00
Jimmy Brisson 62a7ecddd3
Merge pull request #5570 from jeromecoutant/PR_STDIO
STM32 UART init update
2018-01-04 09:50:18 -06:00
jeromecoutant 4637279f51 STM32L4 : compilation issue
Issue comes only when ST HAL macro USE_FULL_ASSERT is enabled
2017-12-13 13:57:17 +01:00
Helmut Tschemernjak 63ad3aeae3 Added the proper defines for the STM32L432 bootloader support 2017-11-27 15:41:30 +01:00
Helmut Tschemernjak 4778a40643 Changed NVIC Flash base address to support the bootloader 2017-11-27 15:32:53 +01:00
Helmut Tschemernjak 632b2f1660 Updated wrongly defined UART3_BASE into USART3_BASE 2017-11-27 15:19:43 +01:00
Helmut Tschemernjak fb914149dd Updated to toolchain startup/linker files to support the 433 devices
Also added the symbolic MBED_APP_START/MBED_APP_END defines
2017-11-27 15:03:43 +01:00
Helmut Tschemernjak 94c46b102b defined STM32L433xx 2017-11-27 14:52:37 +01:00
Helmut Tschemernjak e25dfc07f0 Added stm32l433xx.h defined STM32L433xx 2017-11-27 14:51:46 +01:00
Helmut Tschemernjak 6907b6d9e5 Updated PeripheralNames.h, PeripheralPins.c and PinNames.h for STM32L433 devices 2017-11-27 14:44:35 +01:00
Helmut Tschemernjak 90bb8fc368 Copied TARGET_STM32L432 to TARGET_STM32L433, renamed 432 files to 433 2017-11-27 14:36:47 +01:00
jeromecoutant 6d64c2fbf4 STM32 UART init update
- serial_init, serial_free and serial_baud function moved from serial_device.c (specific to each STM32 family) to serial_api.c (common STM32 file)
- default baudrate value was hardcoded to 9600
  - Value is set now to MBED_CONF_PLATFORM_STDIO_BAUD_RATE for STDIO
  - Value is set now to MBED_CONF_PLATFORM_DEFAULT_SERIAL_BAUD_RATE for other use
- UART init will not be stopped before calling serial_baud function
2017-11-23 14:47:54 +01:00
Jimmy Brisson 369187cadf
Merge pull request #5535 from MikeDK/nucleo_l432kc_async_serial_fix
NUCLEO_L432KC: Fixed async serial
2017-11-22 10:19:53 -06:00
Michael Kaplan 8a1c29c2e5 TARGET_STM32L4: added missing #ifdef in serial_device.c 2017-11-20 15:49:18 +01:00
bcostm c54e9079b8 STM32 ADC: replace flags type from int to bool 2017-11-17 13:50:59 +01:00
bcostm 1d3eb508bf STM32: fix linker error with adc_read() 2017-11-17 13:50:59 +01:00
bcostm 34fdcc926b STM32: move analogin_read functions in a common file 2017-11-17 13:50:59 +01:00
bcostm 4dbe95dded STM32: rename analogin_api.c in analogin_device.c 2017-11-17 13:50:59 +01:00
bcostm 072ec2e765 STM32L4 ADC: remove adc_inited flag 2017-11-17 13:50:59 +01:00
Martin Kojtal 114e019675
Merge pull request #5486 from bcostm/fix_CAN3
STM32: Add support of CAN3
2017-11-16 16:12:27 +00:00
Martin Kojtal 41eb565d9c
Merge pull request #5342 from ARMmbed/feature_cortex_a
Update CMSIS/RTX with Cortex-A support
2017-11-15 11:24:36 +00:00
bcostm be2a6ae273 STM32: Use CAN3_BASE + typos 2017-11-14 09:48:02 +01:00
Bartek Szatkowski c5a5438256 Update params in calls to LD/STREXW to be uint32_t 2017-11-10 09:53:42 +00:00
jeromecoutant dde615b8a8 NUCLEO_L496ZG minor update 2017-11-03 10:54:49 +01:00
Jimmy Brisson 9163ddfe61
Merge pull request #5399 from jeromecoutant/PR_MSP
STM32F4/STM32L4: remove MSP template file
2017-11-02 10:42:04 -05:00
Jimmy Brisson c40b642455
Merge pull request #4650 from catiedev/master
NUCLEO_L496ZG: Add new Platform
2017-11-02 10:36:23 -05:00
jeromecoutant c51f0f3d5f STM32F4/STM32L4: remove MSP template file
HAL_MspInit/HAL_MspDeInit/HAL_PPP_MspInit/HAL_PPP_MspDeInit weak functions can now be overwritten as it is expected
2017-10-30 10:38:43 +01:00
Anna Bridge 38ba693c57 Merge pull request #5327 from bcostm/remove_warnings
STM32: Remove compilation warnings
2017-10-26 11:05:20 +01:00
Martin Kojtal 2af7213c51 Merge pull request #5104 from architech-boards/master
add support for SILICA_SENSOR_NODE platform
2017-10-19 16:44:17 +01:00
bcostm ad55bc26dc STM32: Remove GCC_ARM compilation warnings 2017-10-17 14:04:59 +02:00
Jimmy Brisson de3784f6da Merge pull request #5288 from bcostm/NUCLEO32_add_ALT_pins
STM32: Add alternate pins on NUCLEO 32pins boards
2017-10-13 09:27:53 -05:00
Jimmy Brisson 6a74cdb39c Merge pull request #5263 from bcostm/fix_init_struct
STM32: Fix analogout structure/variable wrong initialization
2017-10-13 09:25:59 -05:00
Roberto Spelta 35736f57a3 removed memory allocation 2017-10-10 16:46:12 +02:00
Roberto Spelta 7af6e88999 fixed pin LEDs 2017-10-10 16:04:52 +02:00
Roberto Spelta 182d689b8c setted pin USBTX and USBRX 2017-10-10 13:58:41 +02:00
Roberto Spelta f63dfce4bb modification to .ld to improve memory 2017-10-10 13:58:41 +02:00
Roberto Spelta e466685666 copy of L476RG ld file 2017-10-10 13:58:41 +02:00
Roberto Spelta 4d75cbec01 peripherals pins adaptation 2017-10-10 13:58:41 +02:00
Roberto Spelta a95acdabb3 copy of L476RG target 2017-10-10 13:58:41 +02:00
bcostm 6ac1b0e046 NUCLEO_L432KC: add ALT pins + cleanup 2017-10-10 10:51:04 +02:00
Jimmy Brisson 80ff7071b4 Merge pull request #5210 from bcostm/L4_add_adc_calib
STM32: add ADC calibration for L4, F1, F3 devices
2017-10-09 11:15:31 -05:00
Pierre-Marie Ancele c476a600a2 remove sys.cpp file of the ARM_STD toolchain as done in the MR #4949 2017-10-06 11:37:03 +02:00
Pierre-Marie Ancele ed32f57070 fix can_s struct definition 2017-10-06 11:37:03 +02:00
adustm 4e83d7fb15 Fix for IAR tests 2017-10-06 11:35:16 +02:00
adustm 554125ef07 Align IAR files with mbed-os implementation (tests are still failing) 2017-10-06 11:35:16 +02:00
adustm 3ca0b64318 Replace tab by spaces 2017-10-06 11:35:16 +02:00
adustm fa54e1ecba Make ARM test pass on mbed-os5 tests 2017-10-06 11:35:16 +02:00
adustm 02df64b7d6 replace tab by spaces 2017-10-06 11:35:16 +02:00
Nabil Elqatib 507d05915d Remove analogin_s definition from objects.h
The structure being already defined in
targets/TARGET_STM/TARGET_STM32L4/common_objects.h#L119, there is a
redefinition conflict.
2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele fb27107416 NUCLEO_L496ZG change LPUART1 clock source to fix crash on serial init 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele abb5e2d0d3 NUCLEO_L496ZG JSON Clock Configuration 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele 65fec215ab NUCLEO_L496ZG Fix IAR startup script 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele 4219ffc626 NUCLEO_L496ZG Fix ARM startup script 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele 3b2bc2d10c STM32L496xG fix objects.h to fit common_objects definition 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele 313a933c09 NUCLEO_L496ZG Update comments 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele cca32d8196 NUCLEO_L496ZG Use new alternative pins definition 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele aebc227c15 NUCLEO_L496ZG update date in file copyrights headers 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele 7c6c710ee1 NUCLEO_L496ZG Use correct linker script for IAR 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele eea667567e STM32L496ZG add IAR toolchain 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele dc2f29c86e STM32L496ZG add ARM_STD toolchain 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele 53d66bb013 STM32L496ZG add ARM_MICRO toolchain 2017-10-06 11:35:16 +02:00
Nabil Elqatib fd7008c779 Add BSP files for NUCLEO_L496ZG 2017-10-06 11:35:16 +02:00
Pierre-Marie Ancele 6d3e17cb3c add compatibility with STM32L496xG MCUs 2017-10-06 11:35:16 +02:00
bcostm 88b82e312d fix init struct analogout 2017-10-05 16:35:05 +02:00
Jimmy Brisson cc0b3d05aa Merge pull request #5130 from bcostm/freeze_timer_in_debug
STM32: Freeze master timer on stop/breakpoint
2017-10-02 10:38:57 -05:00
Jimmy Brisson c06368a21e Merge pull request #5171 from jeromecoutant/PR_L432_RAM
STM32L432KC: increase RAM size from 48k to 64k
2017-09-27 15:35:44 -05:00
Jimmy Brisson 6cb0258344 Merge pull request #5026 from LMESTM/flash_init_issue_4967
STM32: Lock / Unlock flash for each operation
2017-09-27 15:17:26 -05:00
bcostm 4824e18a95 STM32L4: add ADC calibration 2017-09-27 14:38:34 +02:00
Jimmy Brisson a2cdb10bf7 Merge pull request #4932 from LMESTM/can_reset
Fix STM32 CAN reset to not lose context
2017-09-20 16:24:40 -05:00
jeromecoutant 8b0ee27819 STM32L432KC: increase RAM size from 48k to 64k
WARNING: you have to update ST-Link FW to V2J29M18
http://www.st.com/en/development-tools/stsw-link007.html
2017-09-19 15:11:23 +02:00
bcostm 9f86a32baf Add freeze timer on debug for all STM32 devices
This is a continuation of the work done on the STM32F401xE devices only.
2017-09-18 13:31:46 +02:00
Jimmy Brisson 15a9a0382b Enable Compiling with ARMC6 across all targets
remove duplicate sys.cpp
2017-09-11 13:20:32 -05:00
Jimmy Brisson e009d9f7be Merge pull request #4975 from LMESTM/STM32_SPI3W
Stm32 spi 3 wires mode support
2017-09-05 11:16:53 -05:00
Laurent MEUNIER f5aa7c7c82 STM32: Lock / Unlock flash for each operation
Rather than Unlocking flash during flash object creation, and leaving
the flash possibly continuously unlocked a(s object might bever be freed),
we decide to Unlock then Lock again at each erase or program call.
2017-09-05 17:49:07 +02:00
Laurent MEUNIER 04ac65a4e6 STM32: CAN: restore registers after can_reset
After reset the MCR register content needs to be restored so we're
introducing the can_registers_init function to be called at the first
init stage, but also after reset. We also store the can frequency to
go through the initialisation phase again.
2017-09-05 10:27:21 +02:00
Laurent MEUNIER 759642af8e STM32: Define CAN handle as part of can object
Instead of a static object, this will make driver
instantiation more robust and allow to re-use init
configuration on a need basis.

The CANName struct member is actually the CAN registers base address,
which is now available in the CanHandle.Instance field, so we don't need
CANName anymore.
2017-09-05 10:27:21 +02:00
Laurent MEUNIER 66162c6b1d STM32: move can_s definition to common_objects.h
This will ease up further changes to the structure.
2017-09-05 10:27:21 +02:00
Laurent MEUNIER e6631c02a4 STM32: adjust flash.get_page_size() to minimum programable size
Users of FlashIAP usually get the minimum programable size
by calling flash.get_page_size(), so let's return the minimum
to allows a most efficient usage of flash.

For F4 devices, this is 1 byte.
For L0 and L1 devices, this is a word (4 bytes).
For L4 devices, this is a double word (8 bytes).
2017-08-25 17:21:30 +02:00
Laurent MEUNIER 8c99bf3b62 SPI: HAL: disable IP at the end of transmit
in case of 1LINE direction
2017-08-17 11:02:43 +02:00
Jimmy Brisson f08d5a496c Merge pull request #4623 from LMESTM/analogin_handle
Improve management handling of multiple instances of analogin ojects
2017-07-31 15:23:31 +00:00
Jimmy Brisson 732f7328f8 Merge pull request #4762 from jeromecoutant/PR_L4_ADC
DISCO_L475VG_IOT : pin update
2017-07-24 10:57:18 -05:00
Jimmy Brisson 9e443e9d14 Merge pull request #4734 from LMESTM/stm32_uart_irq
Avoid data loss with serial interrupt used at high baudrates
2017-07-24 10:55:07 -05:00
Laurent MEUNIER 7414b1266b STM32: ADC: Fix PinMap_ADC_Internal
The instance needs to be searched in PinMap_ADC_Internal, not PinMap_ADC.
This was a copy paste error...
2017-07-20 14:15:37 +02:00
jeromecoutant b654af2d80 STM32L4 : json clock source configuration
- default value is the same as before patch
- system_stm32l4xx.c file is copied to family level with all other ST cube files
- specific clock configuration is now in a new file: system_clock.c (target level)
- nvic_addr.h file is now in TARGET_STM level
2017-07-19 16:39:26 +02:00
jeromecoutant a98594d132 DISCO_L475VG_IOT: remove unavailable pins 2017-07-17 14:09:01 +02:00
jeromecoutant e0e332f5d9 STM32L4 AnalogIn init issue with _ALT pins 2017-07-17 13:33:50 +02:00
Laurent MEUNIER efbeb0d057 STM32: analogin: adc struct member not needed anymore
The adc in analogin_t has the same value as the Instance member of
ADC_HandleTypeDef. So we can only rely on the later one.
2017-07-17 13:27:22 +02:00
Laurent MEUNIER 8540e8a1dd STM32: Analogin - define handle in object not as a global
In this commit, the analogin_s structure is moved to commonn_objects.h file
to limit the duplicaion.

The ADC handle is moved from a global variable to a struct member of the
analogin object. This allows multiple ADC instances to work correctly.

Note that State needs to be explicitely set to HAL_ADC_STATE_RESET
because the object is not zero initialized.
2017-07-17 13:23:45 +02:00
Laurent MEUNIER b5cbaaa0d0 STM32: Serial - use TXE as tx_irq instead of TC
TXE indicates that a byte can be written to UART register for sending,
while TC indicates that last byte was completely sent. So the TXE flag
can be used in case of interrupt based Serial communication, to allow
faster and efficient application buffer emptying.

Also TXE flag will be erased from the interrupt when writing to register.
In case there is nothing to write in the register, the application is
expected to disable the interrupt.
2017-07-17 08:46:00 +02:00
Laurent MEUNIER 85711eb09e STM32: Serial - do no clear RXNE flag
The RXNE flag is getting cleared when reading Data Register so it should
not be cleared here. Especially in case of high data rate, another byte of
data could have received during irq_handler call and clearing the flag
would read and discard this data which would be lost for application.
2017-07-17 08:46:00 +02:00
Martin Kojtal 58d0aa5ce8 Merge pull request #4694 from bcostm/typo_pins_disco_l475vg
DISCO_L475VG_IOT01A: typo corrections in PeripheralPins.c
2017-07-13 16:42:00 +02:00
Laurent MEUNIER be8024de28 STM32: serial: use proper GET_IT macro
Depending on families, different HAL macros are defined to check the
state of serial interrupts. In several cases, we can find only 1 macro:
__HAL_UART_GET_IT_SOURCE
Checks whether the specified UART interrupt has occurred or not

But in F0, F3, F7, L0, L4 there are 2 different macros
__HAL_UART_GET_IT
Checks whether the specified UART interrupt has occurred or not
__HAL_UART_GET_IT_SOURCE
Checks whether the specified UART interrupt source is enabled.

In the later case, __HAL_UART_GET_IT_SOURCE was being used so far,
but actually needs to be replaced by __HAL_UART_GET_IT. Using the right
macro, we also check the proper flags accordingly.
2017-07-11 17:22:33 +02:00
bcostm d58070b658 DISCO_L475VG_IOT01A: typo corrections in PeripheralPins.c 2017-07-03 16:12:14 +02:00
Jimmy Brisson d382d44f06 Merge pull request #4529 from LMESTM/issue_1083
Manage multiple instances of analog out
2017-06-30 13:53:46 -05:00
Jimmy Brisson bb3bedad79 Merge pull request #4638 from bcostm/fix_cmsis5_disco_l475vg
DISCO_L475VG_IOT01A: Fix startup files for cmsis5
2017-06-28 09:20:05 -05:00
Jimmy Brisson e907079456 Merge pull request #4603 from jeromecoutant/PR_OVERRIDE
STM32 : mbed_overrides.c is common for all families
2017-06-27 14:59:24 -05:00
Laurent MEUNIER 07575b33f0 STM32: STM32L475xG dac_s common definition
Fixing conflict as STM32L475xG target has been merged after the first
version of moving dac_s structure definition to common_ojects.h.
2017-06-27 09:27:46 +02:00
Laurent MEUNIER 024b3da5f1 STM32: analog_out: generalize code for multiple instance handling
Moving some code in common to be able to manage several ADC instances,
or several channels of an instance.

The change involves:
- moving dac_s structure definition to common_object.h
- create TARGET_STM/analogout_api.c and move fully common analog_out
functions in there
- rename analogout_api.c of each target family into analogout_device.c
to keep platform specific code
- update analogout_device.c to rely on obj->handle and obj->channel
- align analogout_init function as much as possible between families in
analogout_device.c files
2017-06-27 09:27:46 +02:00
bcostm 03930b88f6 DISCO_L475VG_IOT01A: Add missing nvic_addr.h file 2017-06-26 20:14:08 +02:00
bcostm 72be051088 DISCO_L475VG_IOT01A: Update system init for cmsis5 2017-06-26 19:04:44 +02:00
bcostm bd6d7382a3 DISCO_L475VG_IOT01A: Update toolchain files for cmsis5 2017-06-26 19:02:52 +02:00
Anna Bridge 55355d7374 Merge pull request #4401 from jeromecoutant/PR_USB_PIN
STM32 : Add USB used pins in PinNames.h files
2017-06-23 11:37:19 +01:00
Anna Bridge 4f5d4f040e Merge pull request #4375 from LMESTM/STM32_SPI_LL
Stm32 spi : use LL API to improve performances
2017-06-23 11:33:55 +01:00
jeromecoutant 18572cc65b STM32 : mbed_overrides.c is common for all families 2017-06-21 16:03:05 +02:00
Anna Bridge c5e1fa70d9 Merge pull request #4242 from bcostm/dev_disco-l475-iot
DISCO_L475VG_IOT01A : Add new target
2017-06-20 11:41:42 +01:00
Jimmy Brisson 3f464217f1 Merge pull request #4554 from LMESTM/L476RG_ld_file
Fix NUCLEO_L476RG linker scripts
2017-06-19 11:04:10 -05:00
Jimmy Brisson 737a64c988 Merge pull request #4502 from LMESTM/issue_899
STM32: serial: clear Overrun flag if it is set when checking if readable
2017-06-19 11:00:23 -05:00
Laurent MEUNIER 20bd774a6c STM32 SPI specific mode for higher performance
This commit implements a SPI mode which will offer better performance
thanks to usage of Lower Layer API which use fewer registers access,
at the cost of lower robustness (no error management).
2017-06-16 10:23:48 +02:00
Laurent MEUNIER 73eebaad19 NUCLEO_L476RG: FLASH size of 1MB, not 2MB
MBED_APP_SIZE was erroneously defined to 2MB for this target,
while it's only 1MB.
2017-06-14 16:52:08 +02:00
Laurent MEUNIER 1d802028cf NUCLEO_L476RG: GCC_ARM ld file fix
Following
Merge pull request #4063 from LMESTM/17q2_L4_bootloader
the NUCLEO_L476RG binairies could not boot anymore.

The change done in #4063 was derived from work on NUCLEO_L429ZI target
which supports uvisor. The VECTORS defintiion is introduced as part of
uvisor support and requires further changes in ld file which were missing.
As uvisor is not considered yet, we remove VECTORS for now and will
introduce only when needed.
2017-06-14 16:48:29 +02:00
Russ Butler 47b78a2d17 Fix STM32 crashes on boot due to unset VTOR
Remove HAL_Init and related code from SystemInit and move it to
mbed_sdk_init. The function SystemInit is called early in the boot
sequence before RAM is initialized or the VTOR is setup, so it should
not be used to perform the HAL initialization.

This fixes crashes due the vector table being used before it has been
relocated.
2017-06-13 12:12:20 -05:00
jeromecoutant 8301ee04ca STM32 Add USB pins name in PinNames.h files 2017-06-13 17:15:27 +02:00
bcostm 8ede14dac1 DISCO_L475VG_IOT01A: Add include of LL timer file 2017-06-12 17:12:57 +02:00
bcostm 66cbc8b452 DISCO_L475VG_IOT01A: Update device files after CubeL4 update 2017-06-12 17:03:12 +02:00
bcostm af2078f38d DISCO_L475VG_IOT01A: Update cmsis_nvic files 2017-06-12 17:03:12 +02:00
bcostm f6a48838ad DISCO_L475VG_IOT01A: Move USB device config files 2017-06-12 17:03:12 +02:00
bcostm 3519d535a0 DISCO_L475VG_IOT01A: Add generic buttons declaration 2017-06-12 17:03:12 +02:00
bcostm 2ed207efd4 DISCO_L475VG_IOT01A: change comment for 8-byte aligned adress for IAR .icf file 2017-06-12 17:03:12 +02:00
bcostm 7a2d1bd74a DISCO_L475VG_IOT01A: Move ADC internal channels in dedicated table. 2017-06-12 17:03:12 +02:00
bcostm 05c023bcad DISCO_L475VG_IOT01A: Add all pins even those not available on connectors. 2017-06-12 17:03:12 +02:00
bcostm a8ab839e2c DISCO_L475VG_IOT: Re-organize folder
- Move TARGET_DISCO_L475VG_IOT01A/ in TARGET_STM32L475xG/
- Add STM32L475xG extra label in targets.json
2017-06-12 17:03:12 +02:00
bcostm b40591f1e1 DISCO_L475VG_IOT: Add USB Device files 2017-06-12 17:03:12 +02:00
bcostm 2871545bd7 Assign LED4 definition same as LED3 2017-06-12 17:03:12 +02:00
bcostm b9cf7dbe69 Set ADC pins to MODE_ANALOG_ADC_CONTROL 2017-06-12 17:03:12 +02:00
bcostm ac27f8288d Add back PB_6/PB_7 pins definition used by STDIO_UART_TX/RX 2017-06-12 17:03:12 +02:00
bcostm 23140da035 Update PeripheralPins: add _ALTx pins and remove pins not available on connectors 2017-06-12 17:03:12 +02:00
bcostm 8c7000cce4 Add "01A" suffix in target name 2017-06-12 17:03:12 +02:00
bcostm 116d35ad9b Update PinNames.h and remove PortNames.h after rebase with master 2017-06-12 17:03:12 +02:00
bcostm 074e11dcc1 Add DISCO_L475VG_IOT specific files 2017-06-12 17:03:12 +02:00
Martin Kojtal ecc737e14f Merge pull request #4484 from c1728p9/workshop_rebase_4058
STM32L4 Flash support
2017-06-09 15:05:46 +01:00
Laurent MEUNIER f77ecf4e12 STM32: Put some serial code in common between families 2017-06-09 13:30:54 +02:00
Sam Grove 1607c83d77 Merge pull request #4469 from kegilbert/17q2-l4-bootloader-rebase
17q2 l4 bootloader - Rebase
2017-06-08 11:38:25 -05:00
Laurent MEUNIER c5c33f1d0f STM32: serial: clear Overrun flag if it is set when checking if readable
Note that this could have side effects on the application as it would
not be aware that data has been missed. This may be later solved by
adding an error management parameter to the Serial API in mbed.

The advantage is that the serial link can work again.
2017-06-08 17:01:30 +02:00
Sam Grove 8232afa53e Merge pull request #4216 from fmanno/issue-4189
STM32s Serial: Correct handling of parity bits
2017-06-06 20:00:19 -05:00
Sam Grove 72de85c62f Merge pull request #4417 from monkiineko/master
STM32: Fix 32-bit us ticker interrupt scheduling
2017-06-06 19:59:52 -05:00
Laurent MEUNIER 1c57df37d4 STM32 L4: Flash API typo 2017-06-06 18:10:38 -05:00
Laurent MEUNIER a9d237012c Removing duplicate defines
Those defines are already available in STM32 L4 SDK and don't need to
be (re)defined here.
2017-06-06 18:10:18 -05:00
Laurent MEUNIER ec89ea8ac9 Fix L432KC compilation error 2017-06-06 18:09:53 -05:00
Laurent MEUNIER b1ae8a9f9d STM32L4 : add Flash API support 2017-06-06 18:09:12 -05:00
Laurent MEUNIER 7ec9fe23c1 Update stm32l476rg linker scripts for bootloader
Add MBED_APP_START and MBED_APP_SIZE to the linker scripts
so the start and size of an image can be specified. This allows the
ROM to be split into a bootloader region and an application region.
2017-06-06 15:43:54 -05:00
Laurent MEUNIER 5fbe3299d7 Rebase of: e51c40c061
Fix vector table

The address of the vector table is hardcoded to the start of flash.
This patch updates make it properly handle updating the VTOR with
a bootloader.
2017-06-06 15:43:17 -05:00
Sam Grove 5f138810a9 Merge pull request #4294 from ARMmbed/feature_cmsis5
Update CMSIS-Core and RTX to version 5
2017-06-02 23:44:32 -05:00
Bradley Scott 260378e774 STM32: Fix 32-bit us ticker interrupt scheduling
For STM32 targets using a 32-bit timer for the microsecond ticker, the
driver did not properly handle timestamps that are in the past.  It
would just blindly set the compare register to the requested timestamp,
resulting in the interrupt being serviced up to 4295 seconds late
(i.e. after the 32-bit timer counts all the way around to hit the
timestamp again).

This problem can easily be reproduced by creating a Timeout object
then calling the timeout's attach_us() member function to attach a
callback with a timeout of 0 us.  The callback will not get called for
over 2147 seconds, and possibly up to 4295 seconds late if no other
microsecond ticker events are getting scheduled in the meantime.

Now, after the compare register has been set, the timestamp is checked
against the current time to see if the timestamp is in the past, and
if so, the compare event is manually set.

NOTE: By checking if the timestamp is in the past after configuring the
capture register, we ensure proper handling in the case where the timer
updates past the timestamp while setting the capture register.
2017-06-01 12:52:03 -04:00
Jimmy Brisson 944a17fe3c Merge pull request #4402 from LMESTM/STM32_F2_CUBE_v160
Stm32 f2 cube sdk update to v1.6.0
2017-05-31 11:28:36 -05:00
Bartek Szatkowski b97ffe8fdc CMSIS5: Replace target defined NVIC_Set/GetVector with CMSIS implementation 2017-05-30 18:55:51 +01:00
Francisco J. Manno 5e98da14d3 STM32s Serial does not properly handle parity bits
Reworked the serial_format() function for STM32F0x
devices to take the format in the form:
data_bits - parity - stop_bits

E.g. 8 - N - 1

where data_bits exclude the parity bit.
Added a case for 7 bits data as at least the chips
STM32F0x1/STM32F0x2/STM32F0x8 support 7 bits data.

Consolidated serial_format() and uart_init()
functions into a general TARGET_STM serial_api.c
file since the functions are common to all STM targets.

Fixes #4189
2017-05-30 17:17:20 +01:00
Laurent MEUNIER 8576993a1a Introduce stm32_assert.h for MBED port
When we want to activate USE_FULL_ASSERT macro in STM32 CUBE, there is a
need to have the assert map to MBED.

The easiest way to have this definition in a single place for all STM32
HAL and LL files using it, is to add a specific header file where the
porting to MBED is done.
2017-05-29 13:48:29 +02:00
adustm 897625cc96 Give access to HAL_GetTick function 2017-05-29 10:24:03 +02:00
Sam Grove 2500ab03f2 Merge pull request #4351 from jeromecoutant/PULL_REQUEST_CUBE_UPDATE_L4_V1.8.0
STM32L4 cube update from v1.5.0 to v1.8.0
2017-05-26 16:58:37 -05:00
Sam Grove d11289b576 Merge pull request #4165 from adustm/can_init
fix #3863 Add an mbed API that allows the init of the CAN at the bus frequency
2017-05-26 10:45:19 -05:00
jeromecoutant 5dc49b7d6c STM32L4 replace deprecated macro name 2017-05-19 11:59:38 +02:00
jeromecoutant 0178969e90 STM32Cube_FW_L4_V1.8.0
CMSIS v1.1.1 => v1.3.1
    STM32L4 HAL v1.5.1 => v1.7.1
2017-05-18 14:36:32 +02:00
adustm a769d2b6a5 add comment in peripheral pin of DISCO_L476VG so that
the user is aware of conflicts
2017-05-15 15:06:29 +02:00
Michel Jaouen c581230cd3 USBHOST: TARGET_STM fix in hal for hub support 2017-05-09 16:18:33 +02:00
Anna Bridge a85873c863 Merge pull request #4248 from screamerbg/fix/stm32-usb-support
Fixed STM32 USB Device support for mbed Classic
2017-05-05 13:51:38 +01:00
Jimmy Brisson 0c2af26523 Merge pull request #4249 from kegilbert/button-mapping-kg
Add consistent button names across targets
2017-05-03 11:26:36 -05:00
Kevin Gilbert 0268c85101 Fixed typos 2017-05-02 13:16:14 -05:00
Kevin Gilbert 418d83b6c2 Addressed review comments: fixed unmapped switches and added Hexiware buttons 2017-05-02 12:20:05 -05:00
Kevin Gilbert 28d1ac5a44 Added mapping to USER_BUTTON-labelled switches
Revert HRM1017 file source deletion

Added in small comment next to additions

Added mapping to BTN-labelled switches

Added mapping to USER_BUTTON-labelled switches

Undo incorrect mapping to SWIO pin in NORDIC target
2017-04-28 11:37:23 -05:00
Mihail Stoyanov 301ce550c9 Fixed STM32 USB Device support by migrating all specific target headers to unsupported features where they belong until USB support is officially introduced in mbed OS 5 2017-04-28 17:23:07 +01:00
Laurent MEUNIER 4eea8fa863 STM32 Fixed warning related to __packed redefinition
Before this patch, many warnings like below were generated
during compilation with ArmCC
[Warning] lwip_ethernet.h@57,0:  #3135-D: attribute does not apply to any entity

This happens here as ``--gnu`` option of ArmCC is being used, which
enables the GNU compiler extensions that the ARM compiler supports.

This is solve by adding a extra check on __CCARM .
2017-04-27 10:32:00 +02:00
jeromecoutant 03972ebb0c STM32L4 Internal ADC channels rework
Internal ADC pins are now out of PinMap_ADC array
2017-04-12 13:14:58 +02:00
Sam Grove bfb86a7f51 Merge pull request #4125 from jeromecoutant/PR_F4_USB_CONFIG_FILE
STM32 USB configuration file move
2017-04-10 11:07:59 -05:00
jeromecoutant 3bbbabf202 STM32L4 USB configuration file move 2017-04-06 11:51:26 +02:00
jeromecoutant 0c2720bc19 NUCLEO_L476RG : minor serial pin update
SERIAL_TX and SERIAL_RX pins used for debug printf cannot be set as available
2017-04-04 14:38:17 +02:00
Michel Jaouen fc972f0a98 fix STM USB config after L4 ,F4, F7 file tree changes 2017-03-14 15:57:40 +01:00
Michel Jaouen 873cacfc73 Revert "Revert "Target stm usb config""
This reverts commit ec329be6f2.
2017-03-14 15:57:28 +01:00
Martin Kojtal 68dc25331a Merge pull request #3843 from bcostm/fix_stm32l4_apb2_80MHz
STM32L476xG: set APB2 clock to 80MHz (instead of 40MHz)
2017-03-09 15:44:08 +00:00
Martin Kojtal fd6fdd5f8c Merge pull request #3795 from LMESTM/fix_pwm_period_calc
Fix pwm period calc
2017-03-09 15:39:00 +00:00
bcostm ae6899b448 STM32L4xx: set APB2 clock to 80MHz (instead of 40MHz) 2017-03-06 13:34:01 +01:00
Laurent MEUNIER 747e8e1ea1 STM32: move pwmout device tables to C file
In order to avoid possible multiple definitions errors, move the table
initialization to the C file instead of header file
2017-02-27 17:07:01 +01:00
Christopher Haster aff49d8d1e Renamed files in platform to match source names
critical.h     -> mbed_critical.h
sleep.h        -> mbed_sleep.h
toolchain.h    -> mbed_toolchain.h
rtc_time.h     -> mbed_rtc_time.h
semihost_api.h -> mbed_semihost_api.h
wait_api.h     -> mbed_wait_api.h
2017-02-22 18:17:54 -06:00
Sam Grove a8a31da2e8 Merge pull request #3737 from bcostm/dev_can_factorization
STM32: can_api.c files factorization
2017-02-22 13:36:59 -06:00
Sam Grove b7dce71510 Merge pull request #3665 from LMESTM/dev_stm32_gpio_pins_rework
Dev stm32 gpio pins rework
2017-02-21 10:41:16 -06:00
bcostm f527ff95ab Add support to L4 targets. 2017-02-20 11:19:53 +01:00
Sam Grove 99dda9a60b Merge pull request #3740 from jeromecoutant/PR_L4_RTC
STM32L4 HAL update for RTC Wake Up Timer
2017-02-17 09:12:01 -06:00
Laurent MEUNIER 1cbb3e18ac STM32: make PWM driver into a common file
The pwmout driver is very similar for each STM32 family.

The only family specific part is defined in pwmout_device.h file.
It mainly contains few specific information:
- The mapping of PWM/TIMERS to APB1 or APB2 so that we can get the clock
- The clock calculation uses the right APB clock, which was sometimes
not the case before and could have lead to errors in case dividers were
enabled on APB clock settings. This case is now covered.
- Inactivation of inverted support on feaw families
2017-02-17 14:11:56 +01:00
Laurent MEUNIER 32ecd00c3a STM32: move pin_lines_desc to c file
Move the const table initialization from the header file
to a new C file to avoid any multiple defined errors.
2017-02-16 19:34:11 +01:00
Laurent MEUNIER 73955b678e STM32: pins: move pin_lines_desc table to const 2017-02-16 19:34:05 +01:00
Laurent MEUNIER 273ac81680 stm32: use default in switch case
As commented during PR review, better use default case.
2017-02-16 19:34:01 +01:00
Laurent MEUNIER 21bc5af3c2 STM32: common pinmap using LL layer to access registers
this first makes pinmap.c a common file

then rework it with several goals:
- avoid gpio / irq / pin management extra dependencies
- improve performances when switching between pin modes

This change is based on LL layer to access to registers level
instead of using HAL higher level API.

The family specific functions are implemented in pin_device.h
of each family. Mostly this is F1 family that is differnt
from other ones.
2017-02-16 18:57:18 +01:00
Laurent MEUNIER 6bd488db4d STM32: gpio irq: Use LL registers access
Instead of using HAL_GPIO_Init / Deinit which makes a lot of registers
being written and re-written, and which creates extra gpio / pin / irq
dependencies, we directly set the IRQ related registers thanks for the
STM32 LL layers which provides APIs to modify registers.
2017-02-16 18:55:36 +01:00
Laurent MEUNIER 74774f9424 STM32 Make gpio_irq_api.c a common files
This requires the creation of gpio_irq_device.h file, where
family specific EXTI IRQ mapping is defined
2017-02-16 18:55:28 +01:00
Laurent MEUNIER 0e2cc3824b STM32 : Make port_api.c a common file 2017-02-16 18:55:20 +01:00
jeromecoutant 2433b1ad95 STM32L4 HAL update for RTC Wake Up Timer 2017-02-10 16:26:10 +01:00
Sam Grove ec329be6f2 Revert "Target stm usb config" 2017-02-09 15:37:19 -06:00
Sam Grove d990385058 Merge pull request #3684 from jamike/TARGET_STM_USB_CONFIG
Target stm usb config
2017-02-09 09:35:16 -06:00
Michel Jaouen 4d59c8857d TARGET_STM :move usb config file to target dir 2017-02-03 10:32:19 +01:00
adustm 885515acc9 STM32L432xC folder structure rework 2017-01-27 17:41:59 +01:00
adustm 389d9ba358 STM32L476xG STM32L486xG folder structure modification 2017-01-27 17:35:27 +01:00
Martin Kojtal bdcda386d5 Merge pull request #3618 from LMESTM/dev_stm32_PinNamesTypes
STM32: Move types definitions to a common file
2017-01-26 10:35:59 +02:00
Laurent MEUNIER 42f6622f8e STM32: Move types definitions to a common file
Only one point of attention:
STM_MODE_ANALOG_ADC_CONTROL is a specific mode that is only supported on L4.
So STM_MODE_ANALOG_ADC_CONTROL was moved to index 13 (last entry)
of gpio_mode table so that all the other modes are common and only the last
one is specific.
2017-01-24 10:58:36 +01:00
Laurent MEUNIER 5d04b97b80 STM32: make PortNames.h a common file
the same file can be used for all targets
2017-01-19 15:27:19 +01:00
Martin Kojtal 3933ccf76e Merge pull request #3584 from LMESTM/dev_stm32_common_peripheralpins
STM32: make PeripheralPins.h a common file
2017-01-16 16:29:28 +00:00
Martin Kojtal cc8a132f10 Merge pull request #3575 from LMESTM/dev_stm_factorize_gpio
Dev stm factorize gpio
2017-01-16 16:28:27 +00:00
Laurent MEUNIER 1a4394a4a2 STM32: make PeripheralPins.h a common file
Simple effort to avoid duplicate code.
2017-01-13 13:25:33 +01:00
Brian Daniels 24a9a4824f Fixes linking errors when building with debug profile
When building with the debug profile, certain ST plaforms error with
'get_i2c_timing' not being defined. This is because the function is not
defined as 'static inline', but just 'inline'.
2017-01-12 15:09:28 -06:00
Laurent MEUNIER 57e0225248 STM32: gpio: factorize gpio_api.c and gpio_object.h
Let's make the code more common for gpios.

The only difference between STM32 families is that BRR register may
not be available. In case BRR is not available, we use the 16 left bits
of BSRR instead. We could always use BSRR, but BRR saves one left-shift
operation, so let's use it when available.

By default we will consider using BRR, except for platforms that define
GPIO_IP_WITHOUT_BRR.
2017-01-12 19:24:32 +01:00
Laurent MEUNIER 7a36614e74 STM32: remove useless include
gpio_object.h is included from common_objects.h,
so no need to have it here.
2017-01-12 19:11:36 +01:00
Sam Grove cefae22703 Merge pull request #3492 from Nodraak/fix/3463/can_read_return_value
Fix #3463 CAN read() return value
2017-01-09 10:17:27 -06:00
Sam Grove ddcd3ad711 Merge pull request #3488 from LMESTM/dev_stm_i2c_v2_unitary_functions
Dev stm i2c v2 unitary functions
2017-01-09 10:15:55 -06:00
Adrien Chardon 885b018f77
Set bit without reseting the whole register 2017-01-03 11:46:27 +01:00
Adrien Chardon 7e0b4fe3c9
Fix can_read() return value for STM32 boards 2017-01-03 11:46:25 +01:00
Michel Jaouen 8af69dcbd6 STM32 HAL HCD : USBHOST changes for f4,f2,l4,f7
- reset toggle_out , toggle_in at init
-  in/out toggle in on ctrl endpoint
- remove call back when transmission restarted
2017-01-02 09:48:15 +01:00
jeromecoutant ab28a5e5cb STM32: Refactor lp_ticker.c + rtc_api.c + sleep.c + rtc_api_hal.h files 2016-12-21 16:54:18 +00:00
Laurent MEUNIER 20c9af8bec STM32: I2C unitary functions for IP V2
STM32 supported targets have 2 possible versions of I2C.
This patch makes the start / stop / read and write byte work ok for IP V2.
This was not working before and does not seem to be widely used.
2016-12-21 09:27:52 +01:00
Anna Bridge d1aa6eea52 Merge pull request #3410 from jeromecoutant/PR_ST_L4_ASSERT
STM32L4 : map ST HAL assert into MBED assert
2016-12-19 17:33:13 +00:00
Martin Kojtal 04f940de2d Merge pull request #3324 from LMESTM/dev_i2c_common_code
Dev i2c common code
2016-12-09 15:30:00 +01:00
jeromecoutant 3734269326 STM32L4 : correct ST HAL API call
- ll_utils: compilation issue
- GPIO: mode was not allowed by ST HAL API
2016-12-09 13:58:22 +01:00
jeromecoutant 64e92a54de STM32L4 : refactor stm32l4xx_hal_conf.h and map ST HAL assert into MBED assert 2016-12-08 16:15:47 +01:00
Martin Kojtal bd499daae8 Merge pull request #3304 from jeromecoutant/PR_L476
STM32L476: no HSE is present in NUCLEO and DISCO boards
2016-12-02 15:48:38 +01:00
Martin Kojtal 1c2c121741 Merge pull request #3303 from adustm/stm_fix_interrupt_in
Fix #2956 #2939 #2957 #2959 #2960: Add HAL_DeInit function in gpio_irq destructor
2016-12-02 15:47:50 +01:00
jeromecoutant 448f501d4a STM32L476: comments update 2016-11-30 08:52:49 +01:00
jeromecoutant 757944ee24 STM32L476: no HSE is present in NUCLEO and DISCO boards 2016-11-30 08:51:18 +01:00
Laurent MEUNIER 3fad50287c [STM32] Make most of the I2C code into a common file
Since most of the code in i2c_api.c is now relying on STM32 HAL, there
is now a possibility to make a common usage of this code accross families.

The IP version definition is introduced per family, to allow a switch of
functionnalities, especially the frequency management which differs.
BTw, we fix the F0 frequency settings at the same time.

F1 is managed for now as an exception as the HAL API for sequential transmit
/receive is not yet available (coming soon)
2016-11-30 08:23:13 +01:00
Laurent MEUNIER 23926a2418 [STM32] HAL I2C (V2) sequential transmit / receive
In case of sequential transmit / receive, there is a need to:
- not use the reload option
- generate a new START on each new transaction

This applies to all HAL supporting the IP version V2.
2016-11-30 08:23:13 +01:00
Martin Kojtal c57427f77f Merge pull request #3321 from jeromecoutant/PR_L432KC
no HSE available by default for NUCLEO_L432KC
2016-11-29 18:25:17 +01:00
Martin Kojtal a8ebfaa058 Merge pull request #3288 from LMESTM/dev_spi_asynch_l0l1
Dev spi asynch l0l1
2016-11-29 18:17:06 +01:00
Martin Kojtal bb2d03f34b Merge pull request #3213 from bcostm/factorize_ticker
STM32: Refactor us_ticker.c + hal_tick.c files
2016-11-29 18:10:45 +01:00
jeromecoutant a933032a58 no HSE available by default for NUCLEO_L432KC 2016-11-24 11:33:43 +01:00
adustm 0219b64af4 fix #2956. Add HAL_DeInit function if gpio_irq destructor
This allows ci-test-shield tests-api-interruptin to pass
2016-11-21 15:55:15 +01:00
Laurent MEUNIER 7cdaba8474 [stm32] remove unused module member in spi_s struct 2016-11-18 09:59:53 +01:00
bcostm 896293d5be Replace TIM_MST_GET_PCLK_FREQ macro with TIM_MST_PCLK macro 2016-11-14 09:31:14 +01:00
bcostm 0524811c75 STM32xx - Remove hal_tick.c files and update hal_tick.h with new macro 2016-11-14 09:31:14 +01:00
bcostm bb10409954 Replace all devices us_ticker files with a common 16b and 32b file 2016-11-14 09:31:14 +01:00
Michel Jaouen 182c311fbd TARGET_STM : USB FS STM HAL changes 2016-11-09 12:08:45 +01:00
Michel Jaouen 9c4e7173a5 DISCO_L476VG : align memory mapping with ARM 2016-11-09 12:08:41 +01:00
Michel Jaouen c2032c0442 DISCO_L476VG: modify clock for USB support 2016-11-09 12:08:36 +01:00
Michel Jaouen 4a69072161 INIT:GCC add call to HAL_Init
system_init, stops all on going timer.
gcc _start , perform zero initialized.
=> HAL_Init must be done again also in GCC toolchain
2016-10-27 10:40:28 +02:00
Michel Jaouen 93a0b9ce60 STM32L4xx : GCC_ARM remove zero bss, in startup.
zero bss is done in libc init after call to _start.
2016-10-26 14:42:24 +02:00
Sam Grove f1d678f8a4 Merge pull request #3056 from LMESTM/fix_stm32_pull_overwrite
Fix stm32 pull overwrite
2016-10-19 05:50:30 -05:00
Sam Grove 2ae71777aa Merge pull request #3013 from bcostm/check_adcintch_pins
STM32xx - Change how the ADC internal pins are checked before pinmap_…
2016-10-19 05:43:15 -05:00
Laurent MEUNIER af51027f61 [STM32] Fix pull over write to all families
This applies the same fix as was done for F4 to solve issue #2638.
The fix applies ell to all other families excpet STM32F1.

Basically, to avoid over-writing the pull-up/-down settings, we read the
current state from HW.
2016-10-18 12:16:58 +02:00
adustm 78fd559d11 ADD NEW TARGET : NUCLEO_L486RG, based on existing NUCLEO_L476RG 2016-10-13 18:29:09 +02:00
bcostm a484f51904 STM32xx - Change how the ADC internal pins are checked before pinmap_pinout 2016-10-13 16:28:57 +02:00
Laurent MEUNIER 0aeea4950c [STM32] Deploy SPI_ASYNCH to all family
the SPI_ASYNCH feature has been already activated for STM32F4.
This patchset makes it supported on all STM32 families by:
- moving spi_s structure at family level instead of board level
- using the F4 spi_api.c reference implementation and making it a common
stm_spi_api.c file which makes maintenance a lot easier.
- the only part that needs to be implemented for each family is the computation
of the clock frequency input to the spi peripheral which is not the same
accross families. So this is what remains in the spi_api.c of each family.

Because of the introduction of the common file, all the above modifications
needs to be done at once.
2016-10-13 14:18:21 +02:00