Commit Graph
596 Commits
Author SHA1 Message Date
Petr Nejedly a5afbec143 Nenik: Fix scheduling at the end of delay(), #537
See https://devzone.nordicsemi.com/f/nordic-q-a/63828/vtaskdelay-on-nrf52-freertos-port-wastes-cpu-power
for reference
2020-08-12 22:04:24 -07:00
Ha Thach 782ab61b82 Merge pull request #546 from adafruit/fix-usbpower-racing
fix power usbready not handled if bluefruit begin() is called fast enough
2020-08-04 16:10:44 +07:00
hathach 24f39073da update tinyusb core to commit c36ecdaf54aaa88cb678f05ea973d6795f2d6cae 2020-08-04 14:52:45 +07:00
hathach b54bcf3df6 a few delay before enter dfu by touch1200 2020-08-03 22:17:40 +07:00
hathach 5bb5b132e5 fix power usbready not handled if bluefruit begin() is called fast enough 2020-08-01 21:47:38 +07:00
hathach cb6d216c9c move usb hardware init and tud_init into usb device thread
help to prevent USB IRQ when scheduler is not started yet
2020-07-23 07:45:09 +07:00
hathach ca4f2bcbb4 sync with Adafruit_TinyUSB_ArduinoCore commit 238a5c0b95fcd402d24524c7bebbdd822168a51e 2020-07-23 07:07:22 +07:00
hathach 9a2f1384ad move Adafruit_TinyUSB_Core_init() inside loop() task 2020-07-22 22:25:20 +07:00
hathach 81a78d74ed update TinyUSB core to commit 11d669b4d2a40eb2fc5e51b2a9707a6de9d42363
Note: due to osal_freertos changes https://github.com/hathach/tinyusb/pull/468 the Adafruit_TinyUSB_Core_init() should be near the task scheduler (or better inside loop task) to prevent calling portYIELD_FROM_ISR() when scheduler not started
2020-07-22 21:54:55 +07:00
Ha Thach b332555863 Merge pull request #503 from orrmany/fix-issue502
Fix issue502
2020-07-11 01:01:01 +07:00
hathach 92a583accc sync tinyusb core to 0749077 2020-07-05 17:03:03 +07:00
hathach eb50925296 upgrade cmsis to v5 to build with TFL 2020-07-05 15:16:10 +07:00
Gábor Ziegler 180ef771c2 Fixing pgm_read_ptr(addr) macro 2020-05-10 19:45:42 +02:00
Henry Gabryjelski 70c947dfbb fixup macro name to reflect logic 2020-05-09 23:51:14 -07:00
Henry Gabryjelski fc0dc290bc type-safe array macros 2020-05-06 20:06:46 -07:00
Ha Thach b03d6e5d81 Merge pull request #485 from henrygab/GPIOTE_Fix
GPIOTE fixes for attachInterrupt() / detachInterrupt()
2020-04-28 10:46:34 +07:00
Henry Gabryjelski 55c1b9f53d Remove sequence points / barriers ...
when programming the GPIOTE peripheral.
the memory barrier is still used once in the ISR,
to prevent spurious interrupts caused by delay
writing over the (16MHz) AHB bus.
2020-04-27 11:25:54 -07:00
Henry Gabryjelski c3c8ac3c8f Updated per @hathach requested changes
* Changed to use compiler intrinsics
* Significantly reduced comments near memory barrier usage, as per request
* Updating `attachInterrupt()` loops to more closely match requested style
2020-04-26 16:20:13 -07:00
Henry Gabryjelski 48fda18996 one more edge case covered 2020-04-24 11:59:53 -07:00
Henry Gabryjelski 1c90673a64 Ensure config is written before enabling the corresponding interrupt enable flag 2020-04-23 16:33:01 -07:00
Henry Gabryjelski cbbc57bd0d Ensure CONFIG is fully cleared 2020-04-23 16:15:09 -07:00
Henry Gabryjelski 280ecaf5aa Three bugs fixed
* First loop should not be checking pinmap for -1.

* Second loop should ensure no pending event when
  first allocating the GPIOTE channel.

* Second loop needs to update pinmap with pin when
  allocated the GPIOTE channel.
2020-04-23 15:56:50 -07:00
hathach 26223a28d4 Update TinyUSB to commit c59fa77 due to a bug in the stack
increase version and update changelog
2020-04-23 23:40:25 +07:00
hathach 9f63c9c55a increase buffer for MIDI to 128
follow to https://github.com/adafruit/ArduinoCore-samd/pull/222
2020-04-22 11:10:36 +07:00
Henry Gabryjelski 9d47073cae fix obvious typo 2020-04-21 19:53:15 -07:00
Henry Gabryjelski 0cb59145fd Reduce ISR overhead
Reduce the number of cycles spent in the GPIOTE ISR,
by reading common volatile registers across AHB only
once, and using a safer hack to prevent spurious ISR
firing when the last channel's event was cleared.
2020-04-21 17:00:55 -07:00
Henry Gabryjelski 3ac53c52b4 Fix GPIOTE channel usage
First, when looking for a channel, first loop through
all mapped channels to see if the GPIO was already mapped.
This prevents a single GPIO being configured for more than
one channel at a time.

Second, do not use a GPIOTE channel if the channel is
already in use (e.g., by a library, sketch, or other code
outside the Board Support Package).
2020-04-21 17:00:55 -07:00
hathach a7334a31a6 sync with tinyusb commit 1d33aa9 2020-04-22 00:23:37 +07:00
hathach 3f0cfb2d3b prepare for 0.20.0 release 2020-04-21 17:52:48 +07:00
hathach f7fae34c3e update tinyusb to commit 718db7e 2020-04-21 00:17:30 +07:00
hathach 7e86e7d0ea update tinyusb stack 2020-04-20 22:25:26 +07:00
hathach ad3ed9b2ab update nrfx to v2.1.0
this is required for latest tinyusb
2020-04-20 22:18:28 +07:00
Ha Thach d727583ad1 Merge pull request #481 from adafruit/dev2
remove the force Serial connected when debug is eanbled.
2020-04-13 15:02:47 +07:00
hathach fde823a322 remove the force Serial connected when debug is eanbled. 2020-04-13 14:24:07 +07:00
Henry Gabryjelski 20b080f9a2 Control SysView by CFG_SYSVIEW
Of course, this commit ensures the following:

* Zero change to BSP defaults
* Zero change to compiled code
* Zero change to UI / menu options
2020-03-25 16:20:33 -07:00
Henry Gabryjelski c91bed1448 Fix #458
Update HwPWM3 when it exists
2020-03-20 10:34:47 -07:00
hathach 045f4f8cca partial revert PRITNF in lfs_util.h due to compilation error 2020-03-20 11:32:42 +07:00
Henry Gabryjelski 03805f3c33 Define PRINTF macro regardless of debug level. 2020-03-11 15:25:40 -07:00
Henry Gabryjelski 4565d0cd7d Use uppercase PRINTF.
This is a step in preparation for the ability to
change the default handler for printf(), such as
when advanced debug output capabilities make it
more performant to output via an alternative route.
2020-03-11 15:25:39 -07:00
Henry Gabryjelski 64b05d33aa Fix stack trace debug level check 2020-03-11 15:25:39 -07:00
Limor "Ladyada" Fried 70ff084b16 Merge pull request #452 from adafruit/add-sound-service
Add more sensor services
2020-03-11 13:31:48 -04:00
hathach 8a402ab6e0 added gesture sensor, however attr memory is overflow 2020-03-11 21:40:33 +07:00
hathach a557014d95 skip wait for Serial in bleuart sketch 2020-03-07 17:19:56 +07:00
Ha Thach 569b9b21e6 Merge pull request #437 from henrygab/Segger_RTT_3
Update Segger SysView files to v3.10
2020-03-06 16:27:22 +07:00
hathach df6a459a10 remove requestPHY() from 1MB to 2MB, old Mac may not support 2MB. Leave it to central to switch
also add hci str debug
2020-03-02 22:11:30 +07:00
hathach a97d2454e3 finish quaternion service 2020-02-25 23:37:53 +07:00
Henry Gabryjelski 7c990c498c Fix compilation warning.
size_t is unsigned; the #defined constant was treated as an integer,
which caused the following warning:

In file included from cores\nRF5\Uart.cpp:21:0:
cores\nRF5\Arduino.h: In instantiation of
```C++
  decltype ( ((b < a) ? b :  a) )
   min(const T&, const L&)
   [with
    T = unsigned int;
    L = int;
    decltype (((b < a) ? b :  a)) = unsigned int
   ]:
```

cores\nRF5\Uart.cpp:228:54: required from here
cores\nRF5\Arduino.h:92:15: warning:
comparison between signed and unsigned integer expressions [-Wsign-compare]
     return (b < a) ? b : a;
2020-02-11 14:33:58 -08:00
Henry Gabryjelski 1cb51ff4a4 Remove contents when SysView is not enabled. 2020-02-11 14:24:27 -08:00
Henry Gabryjelski 5ed66d27d1 Apply FreeRTOSV10_Core.patch
Of course, had to apply them manually, as the patch file
did not apply directly.  This is because some files were
renamed / moved relative to the original distribution,
while others were deleted because they did not apply.
2020-02-11 14:03:16 -08:00
Henry Gabryjelski beb5c1bae4 Avoid link error from using ASM
When linking, get errors about undefined references
to `SEGGER_RTT_ASM_WriteSkipNoLock`
2020-02-11 14:02:25 -08:00