Commit Graph

13 Commits (faec0c3ce52065e7f2dac0f89af04c2921cd6c51)

Author SHA1 Message Date
Jimmy Brisson 15a9a0382b Enable Compiling with ARMC6 across all targets
remove duplicate sys.cpp
2017-09-11 13:20:32 -05:00
Jimmy Brisson d5108e5a7a Merge pull request #4714 from bulislaw/expose_systemcoreclock
Expose SystemCoreClock via cmsis.h to support new CMSIS/RTX
2017-07-24 10:59:47 -05:00
Bartek Szatkowski 693a3a8837 sara_nbiot_evk: Expose SystemCoreClock via cmsis.h
This change is necessary as updated CMSIS/RTX require the
SystemCoreClock symbol.
2017-07-13 15:49:34 +01:00
Martin Kojtal 10ea63b8e7 Ticker: add fire interrupt now function
fire_interrupt function should be used for events in the past. As we have now
64bit timestamp, we can figure out what is in the past, and ask a target to invoke
an interrupt immediately. The previous attemps in the target HAL tickers were not ideal, as it can wrap around easily (16 or 32 bit counters). This new
functionality should solve this problem.

set_interrupt for tickers in HAL code should not handle anything but the next match interrupt. If it was in the past is handled by the upper layer.

It is possible that we are setting next event to the close future, so once it is set it is already in the past. Therefore we add a check after set interrupt to verify it is in future.
If it is not, we fire interrupt immediately. This results in
two events - first one immediate, correct one. The second one might be scheduled in far future (almost entire ticker range),
that should be discarded.

The specification for the fire_interrupts are:
- should set pending bit for the ticker interrupt (as soon as possible),
the event we are scheduling is already in the past, and we do not want to skip
any events
- no arguments are provided, neither return value, not needed
- ticker should be initialized prior calling this function (no need to check if it is already initialized)

All our targets provide this new functionality, removing old misleading if (timestamp is in the past) checks.
2017-07-13 12:23:25 +01:00
Jimmy Brisson c7d6bbe295 Upcase all assembler file extensions 2017-06-20 14:50:08 -05:00
Russ Butler 805374ed89 Restore cmsis_nvic for Cortex-M0 targets
Restore cmsis_nvic (cmsis_nvic.c and cmsis_nvic.h) files for the
implementations which use a mechanism other than the VTOR to set
interrupts. These are vendor specific and were done for M0 devices
which do not have a VTOR.

Note - There were two cmsis_nvic files which did not use the VTOR that
which not restored in this patch. This is because these targets were
not M0 devices and could use the new unified implementation instead.
These files are:
targets\TARGET_ARM_SSG\TARGET_MPS2\TARGET_MPS2_M0P\device\cmsis_nvic.c
targets\TARGET_ONSEMI\TARGET_NCS36510\device\cmsis_nvic.c

Note - cmsis_nvic.c and cmsis_nvic.h were initial removed in
(and restored from) the commit:
b97ffe8fdc -
"CMSIS5: Replace target defined NVIC_Set/GetVector with CMSIS implementation"
2017-06-08 22:50:23 -05:00
Bartek Szatkowski 85cc9c8381 Remove deprecated RTX4 config options 2017-05-30 18:55:55 +01:00
Bartek Szatkowski b793a3fb89 Update codebase for CMSIS5/RTX5
Update all of mbed-os to use RTX5.
2017-05-30 18:55:52 +01:00
Bartek Szatkowski b97ffe8fdc CMSIS5: Replace target defined NVIC_Set/GetVector with CMSIS implementation 2017-05-30 18:55:51 +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
Brian Daniels b0739d7520 Fixing Cortex-A and SARA_NBIOT_EVK build failures (#3)
* Adding Cortex-A support for gnuarmeclipse
* Preventing '-mthumb' from being added to Cortex-A builds.
Previously, both '-mthumb' and '-marm' were being supplied to the
compiler (in that order). Because '-marm' came last, the compiler
respected this option. This change makes it so '-mthumb' is added for
all 'Cortex-M' targets only.
* Renaming to capital .S for Eclipse compatibility
2017-02-07 21:18:18 +02:00
Bartek Szatkowski 6a045a49a9 Platform: Add sleep/deepsleep user facing functions
Add sleep/deepsleep functions to platform layer which are replacing HAL
functions with the same name, rename existing symbols in HAL layer
to hal_sleep/hal_deepsleep. This way sleep functions
are always available, even if target doesn't implement them, which makes
the code using sleep clearer. It also enables us to make decision on in
which builds (debug/release) the sleep will be enabled.
2017-01-19 09:39:29 +00:00
Rob Meades 4e808139d3 Add u-blox Sara-N target. 2016-10-15 12:06:29 +01:00