1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

69 Commits

Author SHA1 Message Date
Benjamin Valentin
1496149bba cpu/sam0: don't hard-code peripheral clocks
Instead of hard-coding the peripheral clocks to CLOCK_CORECLOCK
introduce helper functions to return the frequency of the individual
GCLKs and use those for baud-rate calculations.

This requires the GCLK to be part of the peripheral's config struct.
While this is already the case for most peripherals, this also adds
it for those where it wasn't used before.

As it defaults to 0 (CLOCK_CORECLOCK) no change is to be expected.
2020-02-04 21:06:21 +01:00
925445d0ff
cpu/sam0: factorize dependencies in Makefile.dep 2020-01-28 13:18:39 +01:00
Benjamin Valentin
0d977b3b3c cpu/sam0_common/periph/uart: implement buffered write
Implement interrupt based uart_write() using a tsrb for the TX buffer.

To enable it, add

    USEMODULE += periph_uart_nonblocking

to your Makefile.
2019-11-27 19:01:00 +01:00
Dylan Laduranty
9b0ef62d64 saml1x/pm: fix doxygen ingroup 2019-11-22 22:20:19 +01:00
Benjamin Valentin
9df377d699 cpu/sam*: pm: make use of DEBUG_PUTS()
`pm_set()` gets called by the idle thread whose stack is too small
for normal DEBUG()/printf().

Use DEBUG_PUTS() instead to print the static debug strings.
2019-11-22 01:30:03 +01:00
Yegor Yefremov
5b0252b150 doxygen/ADC: don't include overridden typedefs
Add missing #ifndefs to overridden ADC resolution typedefs.

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
2019-11-15 10:35:32 +01:00
Francisco Molina
5e9b92a326 cpu: remove CPU_ARCH exports 2019-10-18 08:55:33 +02:00
Marian Buschsieweke
df27dbef7a
cpu: Moved stdio_init() into cpu_init()
- Removed stdio_init() from newlib's _init(), as this is too late in the boot
  process to allow DEBUG()ing during periph_init()
- Added stdio_init() to the various cpu_init() routines of the ARM CPUs just
  before periph_init()
2019-09-06 16:54:23 +02:00
dylad
f92eb109e7 cpu/saml1x: fix adc resolution issue 2019-08-06 19:08:39 +02:00
Benjamin Valentin
a9b0db3ba4 cpu/sam0_common: add hwrng driver 2019-08-03 14:50:58 +02:00
Benjamin Valentin
c9c3cb84bf cpu: saml1x/saml21: setup 32kHz Oscilator in cpu.c
Clock setup does not belong in the peripheral driver.
2019-06-18 13:20:04 +02:00
Benjamin Valentin
46565ad339 cpu: saml1x/saml21: reduce differences in cpu.c
The init code for both MCUs is so alike, but it diverged over time.
Re-order the code, so that it's the same on both families again.
2019-06-18 13:20:04 +02:00
Dylan Laduranty
0da43ba4ee cpu/saml1x: set custom PM_BLOCKER_INITIAL 2019-05-24 16:40:08 +02:00
Dylan Laduranty
aba9405dd4 saml1x: enable use for pm_layered 2019-05-22 17:04:55 +02:00
Benjamin Valentin
849dd4cdce sam0_common: make Timer implementation common across all sam0 MCUs
The currently supported SAM0 MCUs (samd21, saml21, saml1x) share the same
Timer peripheral, yet each of them carries it's own copy of the Timer
driver.

This introduces a new timer driver that is common for all sam0 MCUs and
uses structs for configuration instead of defines.
2019-05-21 11:47:59 +02:00
Benjamin Valentin
077056b949 sam0_common: make RTT implementation common across all sam0 MCUs
The currently supported SAM0 MCUs (samd21, saml21, saml1x) share the
same RTC peripheral, yet each of them carries it's own copy of the RTT
driver.

Unify the drivers and move them to sam0_common.
2019-05-09 20:54:00 +02:00
Benjamin Valentin
9aa8c619c1 sam0_common: make RTC implementation common across all sam0 MCUs
The currently supported SAM0 MCUs (samd21, saml21, saml1x) share the
same RTC peripheral, yet each of them carries it's own copy of the RTC
driver.

Unify the drivers and move them to sam0_common.
2019-04-15 22:25:47 +02:00
dylad
82aa6c0280 cpu/saml1x: set wait state according to datasheet 2019-03-24 10:43:40 +01:00
Dylan Laduranty
adeb19339c cpu/saml1x: add support for saml10/saml11 MCUs 2019-01-21 17:05:04 +01:00