Commit Graph

19411 Commits (1e625e2a54ba6f62f9ab50e3037354e32b51ce40)

Author SHA1 Message Date
jeromecoutant 75eab8be70 STM32 LPTICKER : set default LPTICKER_DELAY_TICKS to 1
For both implementation, RTC and LPTIM, there is some delay in the
set_interrupt function due to HW constraints.

Value has been set to 4 for STM32L0,
because SystemClock is slower than other families.
2018-10-08 15:29:18 +01:00
jeromecoutant db7b22878c STM32 LPTICKER with RTC : Fix tickless and lp wrapper
When both tickless and LPTICKER_DELAY_TICKS are enabled some ST
devices randomly get stuck sleeping forever. This is because the
wake up time passed to the rtc is ignored if the previous match is
about to occur. This causes the device to get stuck in sleep.

This patch prevents matches from getting dropped by the rtc by
deactivating the rtc wake up timer before setting a new value.

Events leading up to this failure for the RTC:

-1st call to lp_ticker_set_interrupt
-delay until ticker interrupt is about to fire
-2nd call to lp_ticker_set_interrupt
-interrupt for 1st call fires and match time for 2nd call is dropped
-LowPowerTickerWrapper gets ticker interrupt but treats it as a
 spurious interrupt and drops it since it comes in too early
-device enters sleep without a wakeup source and locks up
2018-10-08 15:29:18 +01:00
jeromecoutant 3d0acbc866 STM32 LPTICKER with LPTIM : Fix tickless and lp wrapper
This fixes issue with mbed_hal/lp_ticker/lp_ticker_early_match_race_test
2018-10-08 15:29:18 +01:00
jeromecoutant 357e126d56 STM32L0 internal channel ADC_TEMP
Temperature measurement was not stable
2018-10-08 15:29:18 +01:00
jeromecoutant c3fcec21c8 STM32L072 : ADC internal channels correction 2018-10-08 15:29:18 +01:00
Jenny Plunkett 1c5b343fd8 Fix typos 2018-10-08 15:29:18 +01:00
Jenny Plunkett 55b5d6cb7e Added LPC1769 template file for MCUXpresso 2018-10-08 15:29:18 +01:00
Antti Kauppila dbe2b15daa equeue_stub updated and code fixed accordingly 2018-10-08 15:29:18 +01:00
Antti Kauppila 04c16412cf cmake Paths corrected 2018-10-08 15:29:18 +01:00
Antti Kauppila 18a1e66ebc LoRaMac unittested 2018-10-08 15:29:18 +01:00
Antti Kauppila 8bed43e4f8 LoRaWANStack unit tested 2018-10-08 15:29:18 +01:00
Antti Kauppila 41d0648fdd LoRaMacCrypto unittested 2018-10-08 15:29:18 +01:00
Antti Kauppila 1f24d725a7 LoRaPHY unittested, small fixed done during tests 2018-10-08 15:29:18 +01:00
Antti Kauppila 07d2ce69ca LoRa regions unittested, stubs licences revisited 2018-10-08 15:18:50 +01:00
Antti Kauppila 323ea129be LoraPhy and regions unit test skeletons added 2018-10-08 15:18:50 +01:00
Antti Kauppila b1c62a9ecd Unit test for LorawanInterface 2018-10-08 15:18:50 +01:00
Antti Kauppila ed8ebf335a LorawanInterface unit test added 2018-10-08 15:18:50 +01:00
Antti Kauppila 474b652820 More lorawan unit tests added 2018-10-08 15:18:50 +01:00
Antti Kauppila b70d23a175 Lorawan unittests 2018-10-08 15:18:50 +01:00
jeromecoutant 0afe05388e STM32L496 : wrong ADC init 2018-10-08 15:18:50 +01:00
Przemyslaw Stekiel 12a0446dab tests-mbed_hal-sleep: add message with failure details 2018-10-08 15:18:50 +01:00
Przemyslaw Stekiel 4a35dcb7dd tests-mbed_hal-sleep: finish UART transmission before sleep test
There is no problem with this test during the morph, but some issue has been noticed while testing new Jenkins CI in Oulu on NRF52_DK.
I was able to reproduce the issue locally. The difference between morph and local run is that CPU statistics are enabled on morph. This makes the difference and test passes.

The sleep test case perform sleep for 100 us, 200 us, ... ,1000 us in loop (us ticker wakes the board) and verifies if sleep time matches the assumption.
I got the following results:

sleep                 wake-up after
100 us                   ~100 us    ok
200 us                   ~200 us    ok
300 us                   ~300 us    ok
400 us                   ~400 us    ok
500 us                   ~14 us     (??)

When requested sleep time is equal to 500 us some unexpected interrupt occurs which wakeup the board and force the test to fail.
Register state just after exit from sleep:
Control and State Register: 0x00400000 (ISRPENDING - Interrupt pending flag is set).
NVIC Interrupt Set-pending Register[0]: 0x00000004 (UARTE0_UART0_IRQn) or 0x00000200 (TIMER1_IRQn - timer used by us ticker).

UART interrupt is generated because of green-tea transmission. We know that it is performed while test is executed since we need to wait before going into deep-sleep since otherwise the transmission will be broken. So to take care of UART interrupt we need to wait before sleep test in the same way like it is done in deep-sleep test.
2018-10-08 15:18:50 +01:00
deepikabhavnani 7577ff5bb5 Added thread safety info to FatFs/LittleFs 2018-10-08 15:18:50 +01:00
paul-szczepanek-arm 9d81960b89 fix using an invalid cccd index 2018-10-08 15:18:50 +01:00
deepikabhavnani b858482ca9 Add `overhead_size` element to get the overhead of stats
Heap statistics are used for analysing heap stats, but it doesn't tell anything
about real heap usage or malloc overheads. Adding `overhead_size` element
will help users to get the real heap usage.
2018-10-08 15:18:50 +01:00
bcostm c61595f8be NUCLEO_L4R5ZI: remove IAR exporter
The STM32L4R5ZI device has been added in IAR V8.20.1

Remove the IAR exporter until IAR V8 is supported on mbed.
2018-10-08 15:18:50 +01:00
bcostm 7242150040 NUCLEO_L4R5ZI: set IAR linker stack size to 1KB 2018-10-08 15:18:50 +01:00
bcostm f6d4acc33c NUCLEO_L4R5ZI: change _ALTx pins 2018-10-08 15:18:50 +01:00
bcostm b5b3276a18 NUCLEO_L4R5ZI: remove PWM_5 pins as already used by us_ticker 2018-10-08 15:18:50 +01:00
bcostm f6feb9fba3 NUCLEO_L4R5ZI: enable bootloader 2018-10-08 15:18:50 +01:00
bcostm 41356a943c NUCLEO_L4R5ZI: add missing timer freeze macro 2018-10-08 15:18:50 +01:00
bcostm a60399cd05 NUCLEO_L4R5ZI: update iar and sw4stm32 exporters 2018-10-08 15:18:50 +01:00
bcostm 430f6fb6fd NUCLEO_L4R5ZI: update targets.json 2018-10-08 15:18:50 +01:00
bcostm 0c75711215 NUCLEO_L4R5ZI: update mbed_rtx.h 2018-10-08 15:18:50 +01:00
bcostm f40c5ee91b NUCLEO_L4R5ZI: add all board files 2018-10-08 15:18:50 +01:00
Shrikant Tudavekar c43f9dd864 use forced_reset_timeout as delay after reset 2018-10-08 15:18:50 +01:00
deepikabhavnani 040f4fe664 Cleanup SPI constructor and add destructor
_acquire() is not required in constructor, since we are not performing
any operation on SPI bus yet. Just initialize the pins/hw

Destructor is required to clear _owner else SPI format/frequency will not be
set if object is recreated. We do not free SPI bus, but init again in hardware
may or may not change frequency/format.

```
{
    SPI spi1(...);
    spi1.transfer(...);
}
{
    SPI spi1(...);
    spi1.transfer(...);
}
```
2018-10-08 15:18:50 +01:00
Cruz Monrreal II 8732fdb33b Modified version mismatch msg to be warning instead of error 2018-10-08 15:18:50 +01:00
Teppo Järvelin 918820c9ce Cellular: state machine and easycellular now return error fast if sim pin needed but not provided. 2018-10-08 15:18:50 +01:00
jeromecoutant 235aea0082 STM32 RTC : remove not necessary macro
__HAL_RCC_RTC_CLKPRESCALER is called in __HAL_RCC_RTC_CONFIG
2018-10-08 15:18:50 +01:00
jeromecoutant af35849a7d STM32 RTC with LSI : stop reset registers during init 2018-10-08 15:18:50 +01:00
jeromecoutant 8d995f3817 STM32 RTC : Start LSI clock asap 2018-10-08 15:18:50 +01:00
Wajahat Abbas 3d7f99775a Added PC2 pin to ADC pin map 2018-10-08 15:18:50 +01:00
Cruz Monrreal 3fd8a31327 Removed mbed-os-example-nfc-EEPROM from examples.json
Last thing blocking 5.10.1 release. Example will need to be fixed before it can be brought in.
2018-10-08 15:18:50 +01:00
Cruz Monrreal 0bdfc35fb1 Remove block device example in the short term 2018-10-08 15:18:50 +01:00
Cruz Monrreal 16b1063839 Replace storage example targets from K64F to K82F
Suggested here: https://github.com/ARMmbed/mbed-os/pull/8246#issuecomment-425199620
2018-10-08 15:18:50 +01:00
Cruz Monrreal 2bbfc4ff28 Removed trailing slashes in NFC examples URL
This apparently breaks the examples.py script.
2018-10-08 15:18:50 +01:00
Cruz Monrreal ac1f9d1e5a Restricted nfc example to two targets 2018-10-08 15:18:50 +01:00
adbridge 45e90ddc38 Add back examples updated for mbed-os-5.10
While feature changes were being added to mbed-os a number of
examples were removed from this list due to incompatibility issues.
This PR adds those examples back in:
Filesystem,
Blockdevice,
Mesh-minimal,
Bootloader.

This PR also adds in the new NFC example.
2018-10-08 15:18:50 +01:00
Juho Eskeli ae65a2a609 Align writes to blockdevice write size in MBRBlockDevice 2018-10-08 15:18:50 +01:00