Commit Graph

213 Commits (41b038a028882172190598c3a41655f3b9e0b929)

Author SHA1 Message Date
Martin Kojtal d0d3462781
Merge pull request #11846 from manchoz/manchoz_makerdiary-nrf52840-mdk
Add support for Makerdiary nRF52840-MDK
2019-11-21 10:54:21 +01:00
Martin Kojtal 699372421a
Merge pull request #11790 from 0xc0170/master-rob
nrf52: reset UARTE peripheral in serial_free
2019-11-14 10:42:08 +01:00
Giampaolo Mancini 1804b40fac Fix indentation 2019-11-12 14:48:54 +01:00
Giampaolo Mancini fd3088867e Add support for Makerdiary nRF52840-MDK 2019-11-12 09:56:04 +01:00
Przemyslaw Stekiel b24afed5ae SPI fpga test: use get_capabilities() function to skip test cases for unsupported features 2019-11-06 10:09:20 +01:00
Rob Vlaar 6f31229f48 Workaround to reset UARTE peripheral to be able to go into deep sleep 2019-10-31 15:29:30 +00:00
Przemyslaw Stekiel c83307e96c NRF52: Fix PWM driver
Fix pwm nrf
2019-10-30 14:37:30 +01:00
Martin Kojtal 4b21157085
Merge pull request #11739 from maciejbocianski/nrf52_i2c_byte_rw_fix
Nrf52 i2c byte rw fix
2019-10-28 13:16:49 +01:00
Maciej Bocianski 703348acc8 NRF52: fix i2c byte read/write implementation
i2c_byte_write implementation was broken.
Data sending was inside addressing block

Changed from:
i2c_byte_write
{
   if (start) {
      if (read_address)
         start read;
      esle
         start write;
      write byte;
   }
}

to:
i2c_byte_write
{
   if (start) {
      // if first call after start
      // address for reading or writing
      if (read_address)
         start read;
      esle
         start write;
      } else {
         // send data byte
         write byte;
   }
}
2019-10-28 08:41:12 +01:00
Martin Kojtal 8637069b36
Merge pull request #11698 from kjbracey-arm/armstack
Clean up ARM toolchain heap+stack setup in targets
2019-10-24 11:37:11 +02:00
Maciej Bocianski 7d5f6cf4a9 NRF52: fix i2c timeouts
add tick to us conversion
2019-10-23 15:00:11 +02:00
Kevin Bracey fb6aa3ef4f Clean up ARM toolchain heap+stack setup in targets
ARM Compiler 6.13 testing revealed linker errors pointing out
conflicting use of `__user_setup_stackheap` and
`__user_initial_stackheap` in some targets. Remove the unwanted
`__user_initial_stackheap` from the targets - the setup is
centralised in the common platform code.

Looking into this, a number of other issues were highlighted

* Almost all targets had `__initial_sp` hardcoded in assembler,
  rather than getting it from the scatter file. This was behind
  issue #11313. Fix this generally.
* A few targets' `__initial_sp` values did not match the scatter
  file layout, in some cases meaning they were overlapping heap
  space. They now all use the area reserved in the scatter file.
  If any problems are seen, then there is an error in the
  scatter file.
* A number of targets were reserving unneeded space for heap and
  stack in their startup assembler, on top of the space reserved in
  the scatter file, so wasting a few K. A couple were using that
  space for the stack, rather than the space in the scatter file.

To clarify expected behaviour:

* Each scatter file contains empty regions `ARM_LIB_HEAP` and
  `ARM_LIB_STACK` to reserve space. `ARM_LIB_STACK` is sized
  by the macro `MBED_BOOT_STACK_SIZE`, which is set by the tools.
  `ARM_LIB_HEAP` is generally the space left over after static
  RAM and stack.
* The address of the end of `ARM_LIB_STACK` is written into the
  vector table and on reset the CPU sets MSP to that address.
* The common platform code in Mbed OS provides `__user_setup_stackheap`
  for the ARM library. The ARM library calls this during startup, and
  it calls `__mbed_user_setup_stackheap`.
* The default weak definition of `__mbed_user_setup_stackheap` does not
  modify SP, so we remain on the boot stack, and the heap is set to
  the region described by `ARM_LIB_HEAP`. If `ARM_LIB_HEAP` doesn't
  exist, then the heap is the space from the end of the used data in
  `RW_IRAM1` to the start of `ARM_LIB_STACK`.
* Targets can override `__mbed_user_setup_stackheap` if they want.
  Currently only Renesas (ARMv7-A class) devices do.
* If microlib is in use, then it doesn't call `__user_setup_stackheap`.
  Instead it just finds and uses `ARM_LIB_STACK` and `ARM_LIB_HEAP`
  itself.
2019-10-23 14:53:49 +03:00
Giampaolo Mancini c30ca66e2b Add SPDX identifier 2019-10-21 15:41:41 +02:00
Giampaolo Mancini f9674adaad Fix overflow calculation for reload_value.
Please,  note that this patch fixes upstream bug. See:

https://devzone.nordicsemi.com/f/nordic-q-a/51674/maximum-reload-time-for-wdt
2019-10-21 15:41:41 +02:00
Giampaolo Mancini c79f54c67b Remove default conf macro because typo in nRF SDK 2019-10-21 15:41:41 +02:00
Giampaolo Mancini 92a316711e Fix timeout limits 2019-10-21 15:41:41 +02:00
Giampaolo Mancini 10c78f41e8 Add support for nRF52 Watchdog 2019-10-21 15:41:40 +02:00
Martin Kojtal c94ae909a8
Merge pull request #11622 from trowbridgec/increase-nrfx-gpiote-config-num-of-low-power-events
nRF52 SDK 15.0 - Enable more than 1 interrupt
2019-10-16 14:26:04 +08:00
Maciej Bocianski 98939e2749 nrf5x - add missing gpio_set implementation 2019-10-11 08:55:23 +02:00
Chris Trowbridge 26ebc997e0 Increase NRFX_GPIOTE_CONFIG_NUM_OF_LOW_POWER_EVENTS from a default of 1 to 4 2019-10-03 08:56:39 -04:00
Chris Trowbridge eb6a474ba8 EP_AGORA: Add config logic to enable BLE, cell, and LoRa by default 2019-09-25 12:28:04 -04:00
Martin Kojtal 530f1e9a24 NRF52: fix config
remove lib config and use target configuration instead. To avoid duplication of symbols, etc.

Fixes #10655
2019-09-05 11:02:05 +01:00
Hugues Kamba f3df1c1d1e Relocate TARGET_MCU_NRF52840 to TARGET_NRF5x/TARGET_NRF52 2019-08-16 15:42:43 +01:00
Martin Kojtal be23d3c871
Merge pull request #11137 from facchinm/nano33ble_public
Add Arduino Nano 33 BLE target
2019-08-13 10:51:12 +02:00
Martino Facchin bd0988416e [TARGET] Add Arduino NANO33BLE 2019-08-08 17:24:56 +02:00
Seppo Takalo 5f6379a55d
Merge pull request #11119 from Reda-RM/master
Riot Micro cellular device
2019-08-07 14:07:27 +03:00
Seppo Takalo 6436f11335
Merge pull request #11123 from desmond-blue/fix-nrf52-us-ticker-free
NRF52 need to call TIMER_TASK_SHUTDOWN for current consumption
2019-08-06 11:33:55 +03:00
Reda Maher ef1d9778a9 [Riot Micro] Add Riot Micro cellular module targets 2019-08-05 18:57:43 +02:00
desmond.chen 7b5366f7a3 NRF52 need to call TIMER_TASK_SHUTDOWN for current consumption 2019-07-30 17:20:08 +08:00
Chris Trowbridge 04ca01d16f Update PinNames.h with the pinout for EP_AGORA HW rev 1.1 2019-07-26 11:48:36 -04:00
Seppo Takalo c505d25186
Merge pull request #11077 from bentcooke/52840_align
NRF52840: remove align instructions from gcc linker for ARM.extab exi…
2019-07-23 11:37:47 +03:00
Seppo Takalo 13873f388c
Merge pull request #11062 from AGlass0fMilk/fix-nrf52-saadc-res-again
Fix SAADC resolution for nRF52-based targets... again
2019-07-22 15:30:11 +03:00
Ben Cooke 36bd06c00a NRF52840: enable TRNG in Nordic SDK config 2019-07-19 13:24:12 -05:00
Ben Cooke 892adc6e91 nrf52840: remove align instructions from gcc linker for ARM.extab exidx sections 2019-07-19 10:22:05 -05:00
George Beckstein 7ff707c9b4 Fix SAADC resolution for nRF52-based targets... again 2019-07-17 11:43:20 -04:00
Martin Kojtal b47064ae65
Merge pull request #10933 from tymoteuszblochmobica/chache
Nordic NRF52832 cache ON
2019-07-05 10:09:59 +01:00
George Beckstein f2b88362fb Apply same resolution fix to nRF52832 targets 2019-07-01 12:22:04 -04:00
George Beckstein b08a26bfa0 Fix SAADC resolution set in sdk_config. analogin_read_u16 assumes 12-bit range but config was set to 10 bit range causing incorrect readings to be returned. 2019-07-01 12:09:27 -04:00
Tymoteusz Bloch 1af0fe89b8 Nordic NRF52832 onboard instruction cache is turned ON to increase MCU performance 2019-07-01 15:08:53 +02:00
Anna Bridge 07f1e068a9
Merge pull request #10689 from AGlass0fMilk/nrf52840-usbphy-implementation
nRF52840 USB Device Implementation
2019-06-18 16:28:20 +01:00
Anna Bridge 378e997e25
Merge pull request #10753 from desmond-blue/feature-fix-nrf52-uart-count
Fix nrf52 enabled uart count and enable uart0/1
2019-06-12 14:50:12 +01:00
desmond.chen d5624b6ec6 Fix nrf52 enabled uart count and enable uart0/1 2019-06-12 15:36:09 +08:00
Martin Kojtal 489bd10626
Merge pull request #10629 from trowbridgec/add-target-ep-agora
Add support for the Embedded Planet Agora target
2019-06-06 14:50:14 +01:00
Chris Trowbridge 7531c2bb56 Remove unneeded custom_board.h file 2019-05-30 14:16:29 -04:00
George Beckstein 5386b87693 Removing systick edit from sdk_config.h 2019-05-28 10:48:09 -04:00
George Beckstein d8fbdfcac3 Disabling systick 2019-05-28 10:48:09 -04:00
George Beckstein 1ab27aff1f Finished compatibility changes for nrfx renaming 2019-05-28 10:48:09 -04:00
George Beckstein bd2605cce9 Configured sdk for enabling USB. Preliminary implementation of USB for nRF52840 2019-05-28 10:48:09 -04:00
Chris Trowbridge f81130dd23 Update licenses for EP_AGORA target 2019-05-23 11:30:25 -04:00
RFulchiero 3343022f70 Remove redundant legacy files and definition of PACKED
* The following v14.2 files are removed from nrfx/legacy:
  nrf_drv_clock.h
  nrf_drv_common.h
  nrf_drv_gpiote.h
  nrf_drv_spi.h
  nrf_drv_twi.h
  nrf_drv_uarth.h
* Remove unneeded references to "nrfx_glue.h" and "nrf_drv_common.h"
* Remove the definition of PACKED from app_util_platform.h (already defined
  in mbed_toolchain.h)
2019-05-23 11:31:40 +08:00