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

294 Commits

Author SHA1 Message Date
93246dbedd cpu: sam0: reorganize Makefile.features 2017-11-02 12:59:45 +01:00
6be74db22b cpu/samd21: skip pwm if not defined in board config 2017-10-12 12:07:41 +02:00
Hauke Petersen
b75672628a Merge pull request #7632 from smlng/cpu/sam0_common/vendor_header
cpu, sam0_common: update vendor headers
2017-10-09 10:45:36 +02:00
Dan Evans
a59714b02c samd21:add prescaler option for rtt.c 2017-10-02 20:35:07 -07:00
Hauke Petersen
938ba0b3c5 Merge pull request #7535 from haukepetersen/opt_cortexm_vectordefs
cpu: use shared Cortex-M base vector table
2017-10-01 21:46:17 +02:00
dylad
1e5262506d cpu/sam0: merge GPIO driver 2017-10-01 14:48:12 +02:00
smlng
700793e1ce cpu, samd21: adapt periph drivers for rtt and timer to updated vendor headers 2017-09-20 17:12:10 +02:00
Hauke Petersen
3ede8e9d95 cpu: force size of CPU specific vector table 2017-09-04 15:13:43 +02:00
Hauke Petersen
1a20ef8223 cpu: unified cortex-m base interrupt vector 2017-09-04 15:13:32 +02:00
dylad
89c885ea40 sam0/uart: merge samd21 & saml21 uart driver
Signed-off-by: dylad <dylan.laduranty@mesotic.com>
2017-08-29 21:26:42 +02:00
Thomas Eichinger
f286f2a276 Merge pull request #7492 from Hyungsin/forupstream_samr21_uart 2017-08-29 08:58:08 -07:00
Hyungsin
5dac8fc263 cpu/samd21: include uart driver only when UART_NUMOF is defined 2017-08-29 08:51:10 -07:00
24a1aacca2 cpu/sam0: add missing doxygen group definition + cleanup 2017-08-24 14:54:47 +02:00
4d54dc43fc Merge pull request #7359 from photonthunder/samd21_DFLL_fix
samd21:DFLL bug
2017-08-16 18:18:26 +02:00
03caac8951 Merge pull request #7307 from Hyungsin/forupstream_gpio_fix
samd21: gpio support samr21e18a
2017-08-15 19:44:27 +02:00
Hyungsin
e8e06949eb cpu/samd21: add gpio support for samr21e18a 2017-08-15 09:43:18 -07:00
Francisco Acosta
f2efd88f98 Merge pull request #7129 from haukepetersen/opt_periph_sharetimerset
cpu: add and use shared code for timer_set()
2017-08-01 15:09:48 +02:00
Dan Evans
354803110d samd21:DFLL bug 2017-07-13 13:09:42 -06:00
Dan Evans
08224bd85a samd21/clock: add xosc32/DFLL option 2017-06-26 10:42:23 -06:00
smlng
692cf96297 doc: fix doxygen grouping of cpu periph drivers 2017-06-26 14:42:11 +02:00
1d062a93d7 Merge pull request #7125 from kbumsik/mkr-fix
cpu/samd21: Added CPU_MODEL_SAMD21G18A interrupt config
2017-06-22 16:00:39 +02:00
biboc
0e41861db0 Change my email address:
<baptiste.clenet@xsoen.com>
to
<bapclenet@gmail.com>
2017-06-19 10:38:16 +02:00
Hauke Petersen
a1499f4190 cpu: add and use shared code for timer_set() 2017-06-02 12:21:56 +02:00
Bumsik Kim
ab7ab168fb samd21: Added CPU_MODEL_SAMD21G18A interrupt config 2017-06-01 15:40:07 -04:00
0fcc7d3834 cleanup: apply headerguard script output 2017-05-24 17:54:02 +02:00
8501a03cbc cleanup: apply enable_debug_false.cocci to codebase (coccinelle)
Skipped sys/cbor/cbor.c, examples/microcoap_server/microcoap_sock.c,
as they use different semantics.
2017-05-15 18:45:43 +02:00
Hauke Petersen
de4611f830 Merge pull request #6989 from photonthunder/samd21_waitstates
samd21/cpu:waitstates for low voltage
2017-05-15 11:48:39 +02:00
6b0cf6a728 Merge pull request #7027 from dylad/saml21_adc
saml21/adc: initial support
2017-05-12 23:33:47 +02:00
Dan Evans
7a8551574b samd21/cpu:waitstates for low voltage 2017-05-12 14:13:09 -07:00
dylad
44dd56c3e8 sam0/adc: merged samd21 & saml21 adc driver
Signed-off-by: dylad <dylan.laduranty@mesotic.com>
2017-05-12 21:02:17 +02:00
8f239e4c61 Merge pull request #6812 from haukepetersen/fix_cortexm_usecommonsleep
cpu/sam0|stm32: use common cortexm_sleep()
2017-05-11 14:44:05 +02:00
Bumsik Kim
dfba4394c6 cpu/samd21: move adc channel struct definition to periph_cpu.h 2017-05-05 10:19:39 -04:00
Travis Griggs
828a47dd6a samd21/adc: initial implementation 2017-04-27 14:54:29 -07:00
524ba8f55a Merge pull request #6885 from dylad/saml21_exti_pb00
cpu/sam0: fix or add missing EXTI on GPIO
2017-04-26 09:56:58 +02:00
dylad
0bb43529b3 cpu/samd21: do the difference between samr21 and samd21 EXTI
Signed-off-by: dylad <dylan.laduranty@mesotic.com>
2017-04-25 21:47:54 +02:00
dylad
2b1a1e70c3 cpu/samd21: fix NVM wait states
Signed-off-by: dylad <dylan.laduranty@mesotic.com>
2017-04-12 20:23:51 +02:00
dylad
e5ef668ac1 cpu/samd21: fix or add missing EXTI on GPIO
Signed-off-by: dylad <dylan.laduranty@mesotic.com>
2017-04-10 21:03:16 +02:00
Joakim Nohlgård
339a4da9dc Makefiles: move to new directory /makefiles 2017-04-04 15:11:54 +02:00
Hauke Petersen
190f319066 cpu/sam0|stm32: use common cortexm_sleep() 2017-03-28 20:00:03 +02:00
Hauke Petersen
5c7ed2228d pm_layerd: fix initial value for PM_BLOCKER_INITIAL
the current value was a debugging left-over and should
actually be 0.
2017-03-28 19:32:32 +02:00
Hauke Petersen
8064bd9fa9 periph/pwm: remove pwm_(start|stop) + doc
- joined start/stop and poweron/poweroff
- added general documentation
2017-02-13 09:37:31 +01:00
Hauke Petersen
4bfce892d3 drivers/periph&cpu: add and use common periph_init() 2017-01-25 16:46:46 +01:00
Hauke Petersen
ea07a6817c cpu/sam0+boards: adapted to new SPI API
- adapted the SPI driver
- merged SPI driver for samr21 and saml21
- adapted all boards using the CPU
2017-01-25 16:46:45 +01:00
865008ea7e cpu: samd21: make isr vector table -pedantic safe 2017-01-25 10:22:02 +01:00
9ec39de1d0 cpu: samd21: misc Wextra fixes 2017-01-25 10:10:47 +01:00
245f60edfa cpu: fix typo in author email 2017-01-19 21:45:23 +01:00
Oleg Hahm
d0316fa7ae periph timer: remove timer_irq_(en|dis)able 2017-01-14 15:34:53 +01:00
db823679aa board: samr21-xpro: move periph_pm to cpu/samd21/Makefile.features 2017-01-12 16:26:02 +01:00
f42e5381ee cpu: samd21: add periph/pm support 2017-01-12 16:26:01 +01:00
0194091673 remove obsolete lpm code 2017-01-12 11:24:15 +01:00
Hauke Petersen
3a00fe8e49 cpus: make use of cortexm_isr_end() 2016-12-21 11:28:46 +01:00
Hauke Petersen
fcb1e68732 cpu/sam0: renamed sam21_common to sam0_common 2016-12-15 11:47:03 +01:00
Hauke Petersen
bfb52afde9 cpu/sam21: unified structure for sam[drl]21 CPUs 2016-12-15 11:39:19 +01:00
Hauke Petersen
2eebf36eb2 cpu/uart: make use of named return values 2016-10-28 10:32:00 +02:00
Ludwig Ortmann
cabb20036f cpu/samd21: implement low power modes 2016-10-16 20:20:55 +02:00
Hauke Petersen
ac6b73a35c cpu/samd21(common): cleaned up pad selection macros
- renamed uart and spi pad selection macros to consistent style
- adapted uart and spi implementation to use new names
2016-10-07 11:02:14 +02:00
Peter Kietzmann
9063121558 Merge pull request #5910 from haukepetersen/fix_sam0_muxstuff
cpu/sam21: removed superfluous gpio_init_sercom
2016-10-07 08:08:02 +02:00
Hauke Petersen
d3e41e7b58 cpu/sam21: removed superfluous gpio_init_sercom
This function was a duplication of the existing gpio_init_mux,
where the exiting function is the more general one, as the mux
inititalization is not only valid for the sercom module...
2016-10-05 13:19:52 +02:00
68acc8857e boards/arduino-zero: add initial support 2016-10-04 18:34:51 +02:00
Kees Bakker
076d5bda11 boards: add support for SODAQ Autonomo
The following features were tested (briefly):
* UART (the first)
* I2C using a BMP180 on a SODAQ TPH board
* SPI0, connected to the on-board serial data flash (only DevID was read
using the periph_spi test program)
* xtimer is working (it's the same code as in samr21)

boards/sodaq-autonomo: Disable the "big" unittests because it does not fit
2016-09-28 18:02:16 +02:00
Michael Andersen
68f9916ab6 samd21: spi: fix power regression
The MISO pin cannot be left floating as it increases power consumption
2016-09-26 19:59:51 -07:00
Kees Bakker
ea8b90fa5f cpu/samd21: uart: now using padd setting from board config
Notice the extra fields in uart_conf_t for rx_pad and tx_pad.
2016-09-21 20:34:22 +02:00
Kees Bakker
845ef0decd cpu/samd21: Refactor spi using ArduinoCore as example
The pinmux is now part of the board config. The pad setting is done with
clear names instead of numbers.
2016-09-21 20:34:22 +02:00
Kees Bakker
f794bd4c8e cpu/samd21: spi: change #ifdef's to #if's
The board config can define SPI_1_EN as 0, and in that case #ifdef won't
work.

Add some more comments, and fix typos.
2016-09-21 20:34:22 +02:00
Kees Bakker
574b565e2a cpu/samd21: add helper functions spi_power_on/off 2016-09-21 20:34:22 +02:00
Kees Bakker
be1113fa6c cpu/sam21_common: move i2c.c from samd21 to sam21_common
Notice that saml21 does not use I2C (yet).
2016-09-21 20:34:22 +02:00
Kees Bakker
4ad3313ae5 cpu/sam21_common: add a few typedefs for SERCOM
A generic function is added to initialize a SERCOM.

Notice that uart_conf_t was expanded with pad settings, but it isn't used
yet.
2016-09-21 20:34:21 +02:00
Kees Bakker
8644b5f7a0 cpu/samd21: introduce sam0.h so that we can select samr21.h or other
In the Makefile.include of the board it is required to set the correct
define.

Currently only SAMRG18A is supported, as required by samr21-xpro.
2016-09-21 19:43:30 +02:00
Kees Bakker
88e84f68ff cpu/sam21_common: update ASF CMSIS (samr21) include files using ASF 3.21
Notice that RIOT was using FDPLL96M, which is indeed the name in the
datasheet. But Atmel is using GCLK_GENCTRL_SRC_FDPLL.
2016-09-21 19:43:30 +02:00
Kees Bakker
2869d7729d cpu/samr21: rename ASF include files to prepare for ASF update 2016-09-21 19:43:30 +02:00
Joakim Nohlgård
6be334b4f4 Merge pull request #5833 from immesys/fix-i2c-checks
samd21: i2c: check all busstate bits
2016-09-20 10:06:40 +02:00
Michael Andersen
e367ab93f6 samd21: i2c: improve busstate comparison 2016-09-19 10:54:17 -07:00
Michael Andersen
082d8e85a9 samd21: i2c: clear timeout_counter
If not cleared, long writes timeout incorrectly
2016-09-07 18:21:38 -07:00
5ab97fe38b cpu: build cortexm vectors.c without LTO 2016-08-29 13:30:17 +02:00
Kees Bakker
ac3683b09f cpu/samd21:i2c: the wait for SYNCBUSY must come after enable or disable
The power on/off code is refactored somewhat.
2016-07-28 22:01:12 +02:00
Kees Bakker
64cc7c63c8 cpu/samd21/periph/i2c: power off did enable instead of disable 2016-07-28 21:33:28 +02:00
Oleg Hahm
d2e8efc6cc samd21: do not redefine LITTLE_ENDIAN 2016-07-05 12:10:30 +02:00
Ian Martin
49ae438dd5 doc: eliminate clutter in adc and gpio periph docs 2016-06-29 15:08:32 -04:00
Kees Bakker
417023c256 cpu/samd21: remove include instance_sercom3.h
That include will be already picked up by cpu.h -> cpu_conf.h -> samd21.h
2016-06-22 22:14:36 +02:00
zhuoshuguo
efbbca1322 cpu: Fix header include guards 2016-06-20 10:18:59 +02:00
PeterKietzmann
5ab2297b25 samd21/i2c: wait for bus idle after stop condition 2016-05-27 11:23:05 +02:00
Hauke Petersen
39043b5e6e cpu/samd21: fix ISR mapping for PB27 2016-04-19 20:46:41 +02:00
Baptiste
0215b08998 SAMD21/GPIO driver: Add missing interrupts 2016-04-14 20:06:36 +02:00
Oleg Hahm
8f47dcbbf8 Merge pull request #4719 from immesys/feature-samr21e
Add linker file for Atmel SAMR21E18A
2016-03-25 22:12:28 +01:00
Michael Andersen
83f9cecc12 cpu/samd21: Change linker file to support E variant 2016-03-23 16:49:24 -07:00
Hauke Petersen
d3b21ddf96 cpu/samd21: adapted GPIO driver 2016-03-17 14:39:11 +01:00
Hauke Petersen
b23cde98cf cpus: adapted UART implementations to cb type change 2016-03-15 11:02:06 +01:00
Oleg Hahm
596c25daca Merge pull request #4943 from gebart/pr/while-loops
Use {} notation for empty while loops
2016-03-09 13:42:32 +01:00
6881f65f46 cpu: cortexm*: move cpu_conf.h stuff from cpu.h into cpu_conf_common.h 2016-03-05 18:20:17 +01:00
Joakim Nohlgård
2ea2cdc9e1 cpu/samd21: Use {} notation for empty while loops 2016-03-03 16:31:28 +01:00
Hauke Petersen
b11a3ad74b cpus: adapted timer implementations to API changes 2016-02-29 14:45:00 +01:00
Joakim Nohlgård
3ff4a334b1 cpu/samd21: Cast enum to unsigned int for comparison 2016-02-28 00:09:03 +01:00
Joakim Nohlgård
af64264346 cpu/samd21: uart: Remove unnecessary check unsigned < 0 2016-02-28 00:08:59 +01:00
Hauke Petersen
bc1013b54e cpu/samd21: allowed third PWM channel per device 2016-02-21 16:49:45 +01:00
Joakim Nohlgård
e2f7ac78f0 Merge pull request #4040 from gebart/pr/periph-timer-init-freq
periph/timer: Change timer_init API to support arbitrary (integer) frequencies
2016-02-15 23:36:44 +01:00
Joakim Nohlgård
4aa21ff5c1 cpu/samd21: Update to match timer_init API change 2016-02-13 21:29:36 +01:00
Hauke Petersen
41cbc35b73 cpu/samd21: adapted to PWM interface changes 2016-02-12 16:09:58 +01:00
Hauke Petersen
48a639f8fd cpu/sam21_common: used shared periph_cpu.h 2016-02-08 19:04:28 +01:00
Hauke Petersen
722b342df3 cpu/sam21_common: unified CPUID implementation 2016-02-08 18:55:43 +01:00
Hauke Petersen
1d766bdb9e cpu/samd21: use sam21_common implementations 2016-02-08 18:45:16 +01:00
Hauke Petersen
940097336a cpu: cleanup and unification of CPUID implementations
- moved definition of CPUID_LEN to periph_cpu.h
- fixed some doxygen
- simplyfied some implementations
2016-02-08 14:36:03 +01:00
Hauke Petersen
ad0abdcadd cpus: use default isr_ctx struct in GPIO drivers 2016-01-27 17:00:37 +01:00
Hauke Petersen
dda721ca06 cpu/samd21: s/F_CPU/CLOCK_CORECLOCK/ 2016-01-27 09:52:44 +01:00
Hauke Petersen
476167a86c cpu: fixed any doxygen warning realated to 'periph' 2015-11-19 16:08:38 +01:00
Hauke Petersen
86da628971 Merge pull request #4081 from daniel-k/pr/samd21_rtt_fix_irq_priority
samd21: don't change priority of interrupts, this is really evil
2015-11-10 13:05:10 +01:00
Andreas "Paul" Pauli
bf63e09a65 Merge pull request #4137 from haukepetersen/opt_samr21_pwm
cpu/samd21: optimized pin config for PWM driver
2015-11-05 16:14:05 +01:00
Ludwig Knüpfer
406aea453c cpu/samd21: fix typo in gpio.c 2015-10-31 17:28:16 +01:00
Hauke Petersen
a93f15b5cb cpu/samd21: adapted UART driver 2015-10-27 14:59:38 +01:00
Peter Kietzmann
e539db10ee Merge pull request #4104 from gebart/pr/drop-timer-reset
periph/timer: Drop timer_reset
2015-10-26 08:36:01 +01:00
Hauke Petersen
13fcefb638 s cpu: moved pwm_conf_[chan_]t to periph_cpu.h 2015-10-23 11:41:04 +02:00
Hauke Petersen
fe6b3e7d54 cpu/samd21: optimized pin config for PWM driver 2015-10-23 11:41:04 +02:00
Hauke Petersen
82c843a000 cpu: removed init_slave from I2C drivers 2015-10-20 16:57:39 +02:00
Joakim Nohlgård
cbaeccdb90 periph/timer: Drop timer_reset 2015-10-17 20:11:03 +02:00
daniel-k
1f98e06956 samd21/gpio: check if interrupt is enabled in isr, fixes #4087
The interrupt flag for a previously configured external gpio interrupt
will be set regardless of the actual configuration. So when another source
causes an interrupt, the callback of a disabled gpio interrupt will be serviced
although it was disabled if the interrupt occured in the meantime.
2015-10-15 17:05:40 +02:00
Hauke Petersen
d43dc9182f cpu: s/GPIO(x,y)/GPIO_PIN(x,y)/ 2015-10-13 14:59:54 +02:00
daniel-k
70c8f355c5 samd21: don't change priority of interrupts, this is really evil 2015-10-12 19:53:43 +02:00
Peter Kietzmann
be8f63769c Merge pull request #3879 from sgso/fix_spi_slave_return_codes
cpu: let spi_init_slave() stubs return error codes
2015-09-30 14:07:54 +02:00
Daniel Krebs
85f5a86f7e Merge pull request #3887 from daniel-k/pr/samd21_clocks
samd21: tidy up peripheral clocks and fix potential bugs
2015-09-30 10:42:10 +02:00
Peter Kietzmann
d081adeda9 Merge pull request #3751 from daniel-k/pr/samd21_i2c
samd21/i2c: add feedback in case transfer failed
2015-09-29 20:14:43 +02:00
daniel-k
0b6da4609e samd21: tidy up peripheral clocks and fix potential bugs in pwm and i2c clocks 2015-09-29 18:49:46 +02:00
Joakim Nohlgård
98c465008b all: Update @gebart family name, email 2015-09-20 13:47:39 +02:00
Sebastian Sontberg
8b4fcc2a14 cpu: let spi_init_slave() stubs return error codes 2015-09-17 11:19:31 +02:00
Martine Lenders
2184c97002 Merge pull request #3838 from haukepetersen/opt_samuart
cpu/samd21: optimized and extended UART impl.
2015-09-17 03:39:36 +02:00
dd9de14e49 cpu: samd21: remove hwtimer support 2015-09-16 10:58:51 +02:00
Hauke Petersen
1a29163b63 cpu/samd21: optimized UART implementation 2015-09-14 17:20:01 +02:00
daniel-k
c747d7dae4 samd21/i2c: add feedback in case transfer failed 2015-08-31 17:31:17 +02:00
Iván Briano
1481b01df8 cpu: samd21: Enable the interrupt line for PA28
So the onboard button on the Samr21-xpro works again.
2015-08-27 14:08:16 -03:00
0a859b91ee cpu: samd21: use periph_common SPI functions 2015-08-14 14:46:35 +02:00
Hauke Petersen
75472eddf4 cpu: remove transceiver defines from cpu_conf files 2015-08-06 12:13:54 +02:00
bapclenet
10f3f715cb Merge pull request #3205 from kaspar030/fix_samr21-xpro_clock_setup
cpu: samd21: fix synchronization loop in clk_init
2015-06-28 20:15:08 +02:00
Peter Kietzmann
f62bc56648 Merge pull request #3215 from haukepetersen/fix_periphcpu_addenums
cpu: added dev_enums.h include to all periph_cpu.h
2015-06-22 08:44:26 +02:00
Hauke Petersen
4ae5204b36 cpu: added dev_enums.h include to all periph_cpu.h 2015-06-16 22:41:16 +02:00
1172597594 cpu: samd21: fix synchronization loop in clk_init 2015-06-15 21:33:13 +02:00
Hauke Petersen
e8dd6afa38 cpu/samd21: optimization of startup code
- make use of common startup code
- make use of common exception handlers
- renamed startup.c to vectors.c
2015-06-15 16:00:51 +02:00
Hauke Petersen
138a6a7d1b cpu/samd21: added custom GPIO_UNDEF define 2015-06-14 16:15:53 +02:00
Hauke Petersen
368f5fb64f cpu/samd21: remodeled GPIO driver implementation 2015-06-12 19:10:48 +02:00
daniel-k
9703d324f6 samd21/rtt: fix bug in rtt_set_alarm that caused interrupt immediately after calling 2015-06-08 15:37:22 +02:00
Hauke Petersen
d9deb569b2 cpu/samd21: added peripheral PWM driver 2015-06-05 11:19:48 +02:00
Hauke Petersen
164721657d cpu/samd21: added cpu clock configuration
- choosable between PLL and internal 8MHz osciallator
- configurable to a wide range of frequencies
2015-06-04 11:58:26 +02:00
Hauke Petersen
744ec88a74 cpu: use cortexm common linkerscript 2015-05-30 13:43:19 +02:00
Joakim Gebart
c09a8484e2 cortexm: Move ldscripts into separate directory
Less clutter inside the cpu/* directories by placing linker scripts
under cpu/*/ldscripts/CPUNAME.ld
2015-05-30 12:20:07 +02:00
Joakim Gebart
41e1b57624 Merge pull request #3100 from haukepetersen/opt_cortexm_init
cpu: centralized cortex initialization and some defines
2015-05-30 09:21:46 +02:00
Hauke Petersen
dfb717c308 cpu/samd21: adapted to centralized cpu conf 2015-05-29 16:44:52 +02:00
Hauke Petersen
32410bbfe5 cpu/samd21: set optimization level to -Os 2015-05-29 12:15:40 +02:00
haukepetersen
38f4fc7027 cpu/samd21: moved -O0 from board to cpu 2015-05-28 19:30:07 +02:00
haukepetersen
0d5c8546f3 cpu: adapted Makefiles to unified cortexm module 2015-05-28 19:30:07 +02:00
Hauke Petersen
a5e4b02ed8 cpu: fixed doxygen for multiple headers 2015-05-28 15:45:05 +02:00
Hauke Petersen
9943f51080 global: renamed cpu-conf.h into cpu_conf.h 2015-05-28 15:45:05 +02:00
Hauke Petersen
138ac603de Merge pull request #3033 from haukepetersen/fix_samd21_spi
cpu/samd21: fixed broken spi_transfer_byte function
2015-05-26 15:39:55 +02:00
Peter Kietzmann
68dd9a3996 Merge pull request #2865 from kaspar030/fix_samd21_gpio_compile_issue
cpu: samd21: fix gpio irq handling compile handling
2015-05-26 14:08:45 +02:00