Commit Graph

3796 Commits (mbed-os-5.10.4)

Author SHA1 Message Date
Leon Lindenfelser c80a2ac21c Configure IAR stack size to 1KB 2018-10-19 15:10:50 +01:00
Leon Lindenfelser aa56ea4046 Remove LOWPOWERTIMER as it has been replaced by LPTICKER 2018-10-19 15:10:50 +01:00
Leon Lindenfelser 4161688618 Decrease heap size in IAR linker so tests compile and use SRAM2 for IAR and GCC 2018-10-19 15:10:50 +01:00
Leon Lindenfelser fcdac9e873 Rebase and changes for Dragonfly nano support 2018-10-19 15:10:50 +01:00
Leon Lindenfelser 8a778bdb82 Rebased on master mbed-os 9/7/18
This required replacing hal_tick.h with us_ticker_data.h
2018-10-19 15:10:50 +01:00
Leon Lindenfelser c9729bc948 Remove commented out code 2018-10-19 15:10:50 +01:00
Leon Lindenfelser 686d3e6af5 Fixed spacing/tabs and clean up targets.json 2018-10-19 15:10:50 +01:00
Leon Lindenfelser 37fa8a7e5f Fix rev D radio init/power/reset and add back bootloader capability 2018-10-19 15:10:50 +01:00
cedrick kukela 7f2684f9ec target changes 2018-10-19 15:10:50 +01:00
cedrick kukela 4ba937cb15 REV D change for modem on 2018-10-19 15:10:50 +01:00
cedrick kukela dd07f51f6d Rev c pin name fix 2018-10-19 15:10:50 +01:00
cedrick kukela 5b83ad8d3e remove blanks 2018-10-19 15:10:50 +01:00
cedrick kukela c43c8cf3c0 delete file 2018-10-19 15:10:50 +01:00
cedrick kukela b917133b12 change startup and s file names to match target 2018-10-19 15:10:50 +01:00
cedrick kukela 72901a9440 fixing onboard modem init bug on mts dragonfly l471 2018-10-19 15:10:50 +01:00
cedrick kukela c98f402e6c target fix 2018-10-19 15:10:50 +01:00
cedrick kukela 4866d9c3e2 Ublox and PinName fixes 2018-10-19 15:10:50 +01:00
cedrick kukela 8c14749508 adding TARGET MTS_DRAGONFLY_L471QG 2018-10-19 15:10:50 +01:00
Deepika db70070275 Reposition heap at the end of RAM to be 4K aligned
HEAP memory should be 4K aligned for GCC newlib, with ISR stack at the end of
RAM memory we loose 3K of RAM memory. This fix is for device with <16K RAM to
use RAM entirely.
2018-10-19 12:08:43 +01:00
Deepika 07b0e84622 Set main thread stack size as 3K for constrained targets 2018-10-19 12:08:20 +01:00
Deepika 0d5166ccc0 Set ISR stack and heap sizes for low end devices
Set the ISR stack to be 1KB. https://github.com/ARMmbed/mbed-os/pull/7238
Set the heap size to 3KB(2KB + overhead + spare) so that atleast 2KB free ram is
available for testing.
With dynamic heap size, explicit size is not required. IAR 7.8 supports
static heap, hence the change is needed in IAR linker files.
2018-10-19 12:07:55 +01:00
Deepika e6bf4946f8 [ST]: Fix alignment of execute region to 8-byte boundary in ARM linker files
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files should strictly align to 8-byte boundary
2018-10-19 12:05:12 +01:00
Ashok Rao 88d4572c75 QSPI pins added 2018-10-19 11:46:55 +01:00
Ashok Rao 2ebd07f92b Addressing comments w.r.t alignments 2018-10-19 11:46:55 +01:00
Ashok Rao c15ce399b3 Adding Laird BL654 as a new MTB target 2018-10-19 11:46:55 +01:00
Mahesh Mahadevan f88075d06b MCUXpresso: Ensure the RTC OSC is running at bootup on Kinetis platforms
This is a fix for Issue 5348.

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2018-10-19 11:46:55 +01:00
zhanglu@realtek-sg.com c3047401dc This PR retrieves the TimerSync function to fix the lockup issue
1.	Update library
2.	Add ‘hal_timer.h’, ‘rtl8195a_timer.h’
3.	Revert ‘HalTimerOpExt.HalTimerSync(SYS_TIM_ID)’ function in ‘us_ticker.c’
2018-10-19 11:46:55 +01:00
Mahesh Mahadevan 8585f7a30b MCUXpresso Flash Driver: Update Flash driver to support RAPIDIOT
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2018-10-19 11:46:55 +01:00
maclobdell 33d3e0e87f Add support for NXP Rapid IoT prototyping kit
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2018-10-19 11:46:55 +01:00
ccli8 8108da4924 Fix SW2/SW3 interchange error in NUMAKER_IOT_M487 2018-10-19 11:46:55 +01:00
Janne Kiiskila 42da703998 Use wait_ms instead of wait(n)
Small space savings, the casting from int to float will bloat
the code a bit. Using wait(1.0f) for example would avoid it,
but seems a bit silly to use floats for anything unless
really needed (in embedded products).
2018-10-19 11:46:55 +01:00
Mahesh Mahadevan 51f7f07ae8 MCUXpresso: Fix for the TRNG HAL driver
Apply the fix from K64F TRNG HAL driver.

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2018-10-19 11:46:55 +01:00
Ganesh Ramachandran ae18077a99 Implemented us_ticker free() & modified IAR stack 2018-10-19 11:46:55 +01:00
Ganesh Ramachandran 29e0e65b1f Added Support for TOSHIBA TMPM4G9 2018-10-19 11:46:55 +01:00
jeromecoutant a02f73d948 STM32L4 : sleep issue 2018-10-19 11:46:55 +01:00
bcostm 173190068b STM32: typo corrections 2018-10-19 11:46:55 +01:00
bcostm 344ff0f4ba STM32: fix issue with serial_is_tx_ongoing function 2018-10-19 11:46:55 +01:00
TomoYamanaka 9da1d4c975 Improve ARMCC linker script for Renesas boards
For Arm toolchain build, Mbed 2(classic) programs occur an unexpected error if there is "#include "mem_XXXX.h"" in the script file.
It seems that the linker script can't find the include file because "mem_XXXX.h" file is not in the same path with the linker script.
(Refer to Issue #6975.)
To address this issue, I remove inclusion processing and define the related macros at ARMCC linker script file.
2018-10-19 11:46:55 +01:00
ccli8 28538fb7ca Fix LED_GREEN naming error 2018-10-19 11:46:55 +01:00
Yossi Levy ca2076709d Fixing the order of component if more than one is included for a target. Revert deprecation of FlashIAPBlockDevice 2 argument constructor has this was a breaking change. This follows a similar change in the external flashiap-driver repo. 2018-10-19 11:46:55 +01:00
TomoYamanaka 69595ddfc5 Improve frequency setting proc of Renesas SPI driver
If the specified frequency exceeds the upper limit and lower limit at SPI driver, an error is output, but this does not match policy with other renesas drivers. Thus I revises the processing as follows.
- If "hz" is maximum over, it is rounded by the maximum value.
- If "hz" is minimum under, it is rounded by the minimum value.
2018-10-19 11:46:55 +01:00
jeromecoutant e698722621 DISCO_F413ZH : explicit WIFI pins name 2018-10-19 11:46:55 +01:00
jeromecoutant c61bbdc1dd DISCO_F413ZH : set default Wifi module SPI state to inactive 2018-10-19 11:46:55 +01:00
Eman869 f427af229d Check LPUART clock source in STOP mode
Check LPUART clock source before enable it in STOP mode, only LSE could be enabled in STOP mode.
2018-10-19 11:46:55 +01:00
Ganesh Ramachandran bdc63c81a0 Added usticker feature 2018-10-19 11:46:55 +01:00
Mahesh Mahadevan 51fba0d9a0 MCUXpresso: Add Flash support for KL43Z, KL82Z, KW41Z, K22F
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2018-10-19 11:46:55 +01:00
TomoYamanaka 85565733ab Modify typo of return value at mbed_get_a9_tick_irqn(). 2018-10-19 11:46:55 +01:00
TomoYamanaka 0c4c3c44db Change MTU2 channel number for LPTicker of GR-LYCHEE
MTU2(Multi function Timer pulse Unit 2) can create the low freaquency.
Currently GR-LYCHEE uses MTU2 channel 3 for LPTicker, but I noticed that a part of it is used by another function.
Thus, I changed MTU2 channel number for LPTicker to 2.
2018-10-19 11:46:55 +01:00
Brian Daniels 6e801e2567 Removing GCC_CR from target supported_toolchains 2018-10-19 11:46:55 +01:00
jeromecoutant ed268513c2 STM32F1 RTC : save values in register
Date is managed only by SW
  within CUBE functions HAL_RTC_GetDate and HAL_RTC_SetDate.
They are then replaced by functions that saved counters in HW registers.
RTC_ReadTimeCounter and RTC_WriteTimeCounter are then added to the ST API.
2018-10-19 11:46:55 +01:00
Aleshandre Diaz 81c8520889 choose which lpc1768 timer to use for us_ticker.c 2018-10-19 11:46:55 +01:00
Deepika 7b18b61247 NXP: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 4395ed4de5 Freescale: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 2969394d36 Ublox: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 710ec90213 Realtek: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 1882df9115 Wiznet: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 409f3a5b3f Onsemi: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 081487540d Analog Devices: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika b3e27cebc4 Renesas: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 9cbde92bf1 ARM: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika d97b960964 Maxim: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika cc12ada5cd Atmel: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika a71dc828b9 Toshiba: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika ae87e368d2 Nordic: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 68c7665826 Nuvoton: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Deepika 776b97a993 SiLabs: Fix alignment of execute region to 8-byte boundary
--legacyalign, --no_legacyalign are deprecated from ARMC6 compiler, in order to
remove deprecated flags all linker files (GCC and IAR as well to have uniformity)
should strictly align to 8-byte boundary
2018-10-19 11:46:55 +01:00
Juho Eskeli 6b0133d4b7 Adjust stack & heap for IAR on STM32F412xG 2018-10-19 11:46:55 +01:00
Juho Eskeli b3a69c54c7 Remove redundant error flag clearing operation 2018-10-19 11:46:55 +01:00
Juho Eskeli e9f845bb7a Clear error programming flags before erase & program operations 2018-10-19 11:46:55 +01:00
jeromecoutant 95c46b5d21 STM32 RTC : write RTC time while LPTICKER is enabled
This fix avoid a long waiting loop in rtc_write function,
  which was not acceptable in TICKLESS context.

Implementation comments added.

Global variable name has been updated for easier maintenance:
- LPTICKER_counter is the U32 continuous tick counter
- LPTICKER_RTC_time is the RTC time used to get the time difference
   between rtc_read_lp() calls
2018-10-19 11:46:55 +01:00
Ganesh Ramachandran b3d935c169 Fix for pinmap & usticker free() to TMPM3H6
Implemented usticker free()
Fix pinmap data overwriting to same port pins
2018-10-19 11:46:55 +01:00
bcostm 34530633e2 STM32: Fix I2C stop condition
Need to ensure the transmission has been started before sending a STOP condition.

Issue found on the NUCLEO_H743ZI due certainly to the high-speed clock used.

But this is normally needed also on all STM32 devices using the I2C peripheral version 2.
2018-10-19 11:46:55 +01:00
Ganesh Ramachandran 334dab3463 Fixed pwmout & serial fuart
pwmout:
Used SystemCoreClock

Serial fuart:
SERIAL_5 & SERIAL_3 have same CTS pin (PA7), only function register is different (4 & 2).
pinmap_peripheral() will always return first match from the map.
Hence changed as, if SERIAL_5 is used, then pinmap_peripheral() should return SERIAL_5 (function register 2 to be set).
2018-10-19 11:46:55 +01:00
Amanda Butler 2cd2292451 Copy edit REAMDE.md
Copy edit file, mostly for active voice and consistent spelling.
2018-10-19 11:46:55 +01:00
ccli8 ab3fb4357e Add README.md for secure library/executable 2018-10-19 11:46:55 +01:00
ccli8 cfa654ee82 Add license file for secure library/executable 2018-10-19 11:46:55 +01:00
jeromecoutant 32830342f5 DISCO_L496AG : enable ADC
See User Manual, VREF+ is not connected by default

NB: Use 2.5V as reference (instead of 3.3V)
for internal channels calculation
2018-10-19 11:46:55 +01:00
Ganesh Ramachandran 41875b25e0 Implemented us_ticker free() 2018-10-19 11:46:55 +01:00
Ganesh Ramachandran 1fdf672e19 Added usticker feature
To enable the feature US_TICKER, file is newly implemented with Timer B, which has proper clock prescale and free running after match interrupt.
Old us_ticker driver file (Timer A) is producing up to 100us tolerance, which causes to fail US_TICKER feature.
Hence, changed the peripheral ticker A to B.
2018-10-19 11:46:55 +01:00
TomoYamanaka 9894c50d71 Revise the value of return value of flash_get_page_size()
Currently the return value of flash_get_page_size() is 1 since the min size per one writing is 1 byte by Flash spec.
However, I noticed that this value causes a enormous write time When writing large data such as FW update.
So I revised this value to 8 byte by considering the writing time, memory alignment and memory hole.
2018-10-19 11:46:55 +01:00
TomoYamanaka 29aa22267a Support large Flash in Flash iap driver of Renesas
I addressed the cases Flash size is larger than 0x1000000.
2018-10-19 11:46:55 +01:00
TomoYamanaka 9236006557 Improve Flash iap driver of Renesas
I changed _page_program() func because "buf" which is an argument of data_send() for writing must be a RAM address in order to operate in SPI mode.
(ex: if it is ROM table data, writing will be failure.)
Also, I changed the period of interrupt disable/enable at _page_program() func and _sector_erase() func because lock period is too long.
2018-10-19 11:46:55 +01:00
Naveen Kaje 882642c2ab NRF52: Ensure that we configure hardware after flow control changes
Call the routines to program the hardware to reflect the updates made to
flow control so that the object and hardware are in synch.
2018-10-19 11:46:55 +01:00
Ashok Rao 31dcbc6540 Removing default flow control for BL652 2018-10-19 11:46:55 +01:00
Markus Siglreithmaier 442ec4a14f STM32L4: Use HAL layer functions for sleep implementation 2018-10-19 11:46:55 +01:00
Markus Siglreithmaier 103fa52818 STM32L4: Fix sleep implementation
Correctly detect and handle the low power run mode when entering and exiting sleep mode.

The generic `hal_sleep` implementation tries to exit LPR mode always, resulting in a spin-loop during a critical section (disabled IRQ).
The new approach returns from LPR to Run mode if enabled (LPR bit set), enters sleep, and resets to the original state on wakeup (WFI).
2018-10-19 11:46:55 +01:00
jeromecoutant 266dff0f37 STM32L1 ADC update for internal channels 2018-10-19 11:46:55 +01:00
ccli8 d9d737f67c Update secure library/executable
1. Remove hal_sleep/hal_deepsleep from secure library
2. Add CLK_Idle_S/CLK_PowerDown_S
2018-10-19 11:46:55 +01:00
ccli8 0faad50f2c Fix hal_deepsleep with serial_can_deep_sleep
Add secure functions CLK_PowerDown_S/CLK_Idle_S
2018-10-19 11:46:55 +01:00
ccli8 bb3875049c Fix serial corruption due to deep sleep
Prevent deep sleep when there is still any character being transmitted on the UART.
This allows tickless to be safely enabled.
2018-10-19 11:46:55 +01:00
ccli8 d8b35fe41d Fix HAL sleep test failure with lp_ticker
Replace wait_us with nu_busy_wait_us in lp_ticker since wait_us is not allowed in sleep test
which would suspend us ticker layer on which wait_us relies. nu_busy_wait_us is implemented
by calling us ticker HAL API directly rather than relying on us ticker layer.
2018-10-19 11:46:55 +01:00
ccli8 faa7c90543 Add nu_delay_cycle_x4
nu_delay_cycle_x4 is a replacement for wait_us when us ticker is not available.
2018-10-19 11:46:55 +01:00
ccli8 9f1b4ed967 Add nu_busy_wait_us
nu_busy_wait_us is a replacement for wait_us when intermediary us ticker layer is disabled.
2018-10-19 11:46:55 +01:00
ccli8 d9d506e1fa Move nu_countdown_init/expired/free implementations to nu_timer.c from nu_timer.h 2018-10-19 11:46:55 +01:00
Naveen Kaje 099d0500ef NRF52: serial_api: Use polling for putc
There are scenarios where putc is called within a critical section, e.g
to log ASSERTs in early initialization code. The interrupts being
disabled here prevents the handlers for the UARTE from executing.
This breaks the tx_in_progress flag based approach. The tx_in_progress
never gets reset. Poll on the TXDRDY instead.

It can be recreated with a simple program as shown here:

*************** Current Behavior ****************
++ MbedOS Error Info ++
Error Status: 0x80FF0100 Code: 256 Module: 255
Error Message: F

************** With Fix *************************

++ MbedOS Error Info ++
Error Status: 0x80FF0100 Code: 256 Module: 255
Error Message: Fatal Run-time error
Location: 0x2C0A9
Error Value: 0x0
Current Thread: Id: 0x20005520 Entry: 0x30EBF StackSize: 0x1000 StackMem: 0x20004520 SP: 0x20005490
For more info, visit: https://armmbed.github.io/mbedos-error/?error=0x80FF0100
-- MbedOS Error Info --
nrf failure at .\main.cpp:22
***************************************************
2018-10-19 11:46:55 +01:00
Mahesh Mahadevan 455b44bd0f MIMXRT1050_EVK: Add RTC support
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2018-10-19 11:46:55 +01:00
Andrew Leech 6334e71cc3 nrf: allow target.mbed_ram_start and target.mbed_ram_size to override settings in linker 2018-10-19 11:46:55 +01:00
alrodlim 61cda7eda9 Move I2C pins definition so that A4 and A5 are defined before using them 2018-10-19 11:46:55 +01:00
alrodlim 6c800b3e4e fixed pin names of I2C pins 2018-10-19 11:46:55 +01:00
Juho Eskeli 7b13cea74e Reduce heap size on stm32f207 2018-10-08 15:29:18 +01:00