Commit Graph

32 Commits (f29c5b22a1bf2f285dad6ebd1b0a6991a2e68d00)

Author SHA1 Message Date
Russ Butler 8d205ab430 Add testing pinmaps to NRF5X devices
Add pinmap tables to the NRF5X families to allow testing.
2019-02-08 09:10:46 -06:00
Russ Butler 8669417e7b Add HAL API for spi pinmap
Add the functions to get spi pinmaps to all targets.
2019-02-08 09:10:37 -06:00
Russ Butler 34c176654d Add HAL API for serial pinmap
Add the functions serial_tx_pinmap, serial_rx_pinmap, serial_cts_pinmap
and serial_rts_pinmap to all targets.
2019-02-08 09:10:28 -06:00
Russ Butler be492fe07a Add HAL API for pwmout pinmap
Add the function pwm_pinmap to all targets.
2019-02-08 09:10:19 -06:00
Russ Butler 22a89773fa Add HAL API for i2c pinmap
Add the functions i2c_master_sda_pinmap, i2c_master_scl_pinmap,
i2c_slave_sda_pinmap and i2c_slave_scl_pinmap to all targets.
2019-02-08 09:10:12 -06:00
Russ Butler 4818f88d73 Add HAL API for analog in pinmap
Add the function analogin_pinmap to all targets.
2019-02-08 09:09:51 -06:00
Przemyslaw Stekiel 888f49dade [NORDIC] Support boot stack size configuration option 2019-01-08 15:32:07 +01:00
Deepika 61404e62d8 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-09 10:15:07 -05:00
Przemyslaw Stekiel c0ee843d63 Add lp/us ticker_free() functions stub.
This patch adds only empty stubs of `us_ticker_free()` and `lp_ticker_free()` for all boards where these functions are not implemented.
2018-07-25 08:58:38 +02:00
Martin Kojtal 2661f6fe40 us ticker: fix fire interrupt handling
Few targets need more than just pending IRQ set. They include some flags to be
set that are checked in IRQ handler. This is the case for targets in this
commit.
2018-02-23 09:13:40 +01: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 1f94ede86c Merge pull request #4744 from deepikabhavnani/spi_issue_4743
Allow user to set default transfer byte for block read
2017-07-24 14:45:30 -05:00
Deepika 1b797e9081 Closed review comments
1. Doxygen and Grammar related
2. Change dummy to spi_fill
3. Remove NXP driver and add default loop in spi block read (same as all
other drivers)
2017-07-21 09:46:22 -05: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
iotvietmember 5c0c964291 Add support for VBLUno51 board [TARGET_VBLUNO51]
+ VBLUno51 board:
Nordic nRF51822
Bluetooth Low Energy
DAPLink interface
Arduino UNO pinout compatible
4 Power

+ Wiki: https://vngiotlab.github.io/vbluno/

+ Pass all test case in mbed test suite

Signed-off-by: iotvietmember <robotden@gmail.com>
2017-06-25 20:16:58 +07: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
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
Bartek Szatkowski b97ffe8fdc CMSIS5: Replace target defined NVIC_Set/GetVector with CMSIS implementation 2017-05-30 18:55:51 +01:00
Christopher Haster c1de19e49e spi: Added default spi_master_block_write implementation to all targets
There is an easy default implementation of spi_master_block_write that
just calls spi_master_write in a loop, so the default implementation
of spi_master_block_write has been added to all targets.
2017-05-25 12:04:58 -05: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
Bartek Szatkowski 762e15e772 NRF51822: HAL: Restore WEAK declaration for hal_(deep)sleep
Otherwise we have a conflict between NRF51822 and DELTA_DFCM_NNN40.
2017-02-01 09:30:48 +00:00
Bartek Szatkowski f2c00c7cb5 NRF51822: Remove MBED_WEAK from hal_sleep functions 2017-01-19 11:56:13 +00: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
Rida Jichi ac17fb7cf8 Modified micro:bit pin names to mirror micro:bit edge connector
Resolved issue: https://github.com/ARMmbed/mbed-os/issues/2713

Removed pins p{0..30} definitions
Defined pins P{0..20} as per micro:bit DAL's mappings:
(https://github.com/lancaster-university/microbit-dal/blob/master/inc/drivers/MicroBitPin.h)

Developers can now use the pin names as they appear on the mbed micro:bit pinout
in https://developer.mbed.org/platforms/Microbit/#pinout

Change-Id: I72b81dbe23b11d5ef215583adb211f364b4a5e91
2016-11-01 09:20:24 +00:00
Rida Jichi 3a1af14803 Replaced p{0..30} with P0_{0..30} in the NRF51822 api's
Change-Id: I0e080a30717ee0bcfa2db3f134acb08be851d767
2016-11-01 09:00:34 +00:00
Rida Jichi f1bcde8f45 Ensured all NORDIC platforms define P0_{0..30} to match existing p{0..30} in PinNames.h
Change-Id: I8d7ff6fe5ff5377f7ec8d3bc790dde0b0627f072
2016-11-01 08:57:38 +00:00
Sam Grove e410157557 Merge pull request #2865 from anangl/hal_fixes
TARGET_NRF5: A few corrections in HAL implementation.
2016-10-13 11:40:10 -05:00
Głąbek, Andrzej 691969c315 TARGET_NORDIC: restored old 'sleep()' implementation in legacy HAL, moved the new one to FEATURE_BLE, so it is picked only when SoftDevice is in use. 2016-10-06 11:51:41 +02:00
Głąbek, Andrzej bb6af4d8a6 TARGET_NORDIC: editorial corrections in 'sleep()' implementations to better fit mbed coding style. 2016-10-05 14:51:22 +02:00
Głąbek, Andrzej 1b593b125a TARGET_NORDIC: simplified the checking if SD is enabled in 'sleep()', used the new implementation in legacy HAL for NRF51822. 2016-10-05 09:10:29 +02:00
Christopher Haster 26ced98734 restructure - Restructured cmsis directory
targets/cmsis -> cmsis
targets/cmsis/TARGET_* -> targets/TARGET_*/device
targets/cmsis/TARGET_*/mbed_rtx.h -> targets/TARGET_*/mbed_rtx.h
2016-10-04 17:51:44 -05:00
Christopher Haster 0bad622a16 restructure - Moved targets out to top level
hal/targets -> targets
hal/targets.json -> targets/targets.json
2016-09-30 19:18:09 -05:00