smlng
214ddc4fc4
cpu/cc2538: adapt and cleanup periph/hwrng
...
Some minor adaptions due to cleanup in periph/adc and usage of
vendor header files.
2018-09-03 09:01:42 +02:00
smlng
d40cfab95a
cpu/cc2538: enhance periph ADC
...
Adapt the periph ADC implementation to use vendor defines where
ever possible. Remove duplicate or obsolete defines and adapt
board configuration as required.
2018-09-03 09:01:42 +02:00
Peter Kietzmann
a05e2f22e2
Merge pull request #9693 from smlng/pr/cc2538/timer
...
cc2538: cleanup and optimisation of periph timer
2018-08-13 08:40:51 +02:00
smlng
d9c9c9479e
cpu/cc2538: add debug output in periph/spi
2018-08-10 10:38:51 +02:00
smlng
e246c19fe1
cpu/cc2538: adapt periph/spi to gpio API
...
Rework SPI periph driver to use proper RIOT GPIO API functions.
Also cleanup header files by using vendor defines and remove
obsolete code. Further, adapt board config accordingly.
2018-08-10 10:38:51 +02:00
smlng
d8e2611ed9
cpu/cc2538: refine gpio_init_mux
...
Introduces a define to inidicate an unused function parameter.
2018-08-10 10:38:51 +02:00
smlng
7ff2e44821
cpu/cc2538: cleanup periph timer headers and code
...
Remove unused or obsolete defines in headers, due to usage of
vendor headers. Also remove register bit definition in timer
struct because they where not used in the implementation.
2018-08-07 08:13:47 +02:00
smlng
b7ab6b4b36
cpu/cc2538: cleanup periph timer implementation
...
Refine periph timer implementation to use vendor header defines
where possible, remove unnecessary structs and general cleanup.
2018-08-07 08:13:47 +02:00
smlng
eee4f36ef5
cpu/cc2538: adapt periph/i2c to new api
2018-07-25 12:01:38 +02:00
smlng
a27ae261b8
cpu/cc2538: add gpio_init_mux function
2018-07-25 12:01:38 +02:00
938677cc83
cpu*: fix doxygen grouping
2018-06-11 19:12:02 +02:00
ebbb071e0a
cpu/cc2538: remove useless periph file guard
2018-04-16 10:07:00 +02:00
danpetry
cd449e388b
cpu/cc2538: Adapted UART driver incl. board config
...
Changed the style of the UART configuration for different boards,
from a define based configuration to one based on an array of
structs, one struct for each UART, with the format of the struct defined
in cc2538/include/periph_cpu.h.
- Defined the fields of the struct in periph_cpu.h
- Removed the compilation includes that were in uart.c for each UART
- Implemented a generic ISR subroutine for clarity
- combined uart_base and uart_init in uart.c
- used bitmask for the interrupt setup
- took the uart Rx, Tx, and IRQ numbers out of the config
(as this has to match the .dev field). Replaced with
macros from the uart number
- took out some unused code
- implemented power on/off commands
- removed reset function - now bytes are just discarded on error
- Rx now not initialised if Rx callback = NULL, as per
drivers/periph/uart.h
- device is now enabled after callbacks are set, not before
- asserts raised if rts and cts are enabled for UART0
- BIT macro removed
2018-02-08 14:36:51 +01:00
4dd854da74
cpu/cc2538: DEBUG fixes
2018-01-15 14:37:05 +01:00
smlng
ba324ef07c
cpu, cc2538: adapt uart to RIOT gpio API
2017-12-14 10:32:04 +01:00
Martine Lenders
39c122155c
Merge pull request #7995 from smlng/make/fix/unused_params
...
make: fix unused-params error
2017-11-28 14:46:23 +01:00
smlng
7309171303
build: fix unused parameter errors
...
cpu, sam0_common: fix unused parameter in periph/spi
cpu, kinetis_common: fix unused parameter in periph/spi
cpu, cc2538: fix unused param in periph/i2c
cpu, cc2538: fix unused param in periph/spi
cpu, sam3: fix unused param in periph/spi
cpu, stm32_common: fix unused param in periph/pm
cpu, stm32f3: fix unused params in periph/i2c
cpu, nrf5x_common: fix unused param in periph/gpio
cpu, nrf5x_common: fix unused param in periph/spi
cpu, lpc2387: fix unused params in periph/spi
cpu, cc2538: fix unused params in radio/netdev
cpu, cc2650: fix unused params in periph/uart
cpu, lm4f120: fix unused param in periph/spi
cpu, lm4f120: fix unused params in periph/timer
cpu, lm4f120: fix unused params in periph/uart
cpu, stm32_common: fix unused params in periph/dac
cpu, stm32l0: fix unused params in periph/i2c
cpu, msp430fxyz: fix unused params in periph/uart
cpu, mips: fix unused params
cpu, cc430: fix unused-params in periph/timer
cpu, msp430fxyz: fix unused params in periph/spi
drivers, cc2420: fix unused param
cpu, mips32r2_common: fix unused params in periph/timer
cpu, cc2538: fix unused-param in periph/i2c
cpu, mips32r2_common: fix unused-param in periph/timer
cpu, msp430fxyz: fix unused params in periph/timer
cpu, atmega_common: fix unused params in periph/spi
driver, nrfmin: fix unused params
cpu, cc2538_rf: fix unused params
driver, netdev_ieee802514: fix unused param
cpu, mip_pic32m: fix unused params
cpu, lpc2387: fix unused params in periph/pwm
tests/driver_sdcard_spi: fix unused params
cpu, sam3: fix unused param in periph/pwm
tests/driver_dynamixel: fix unused params, and style issues
cpu, cc430: fix unused param in periph/rtc
cpu, atmega_common: fix unused params in periph/i2c
2017-11-28 14:36:01 +01:00
smlng
e381317fbf
make: fix sign-compare errors
...
cpu, nrf5x_common: fix sign-compare in periph/flashpage
drivers, periph_common: fix sign-compare in flashpage
cpu, sam0_common: fix sign-compare error in periph/gpio
cpu, cc2538: fix sign-compare in periph/timer
cpu, sam3: fix sign-compare in periph/gpio
cpu, stm32_common: fix sign-compare in periph/pwm
cpu, stm32_common: fix sign-compare in periph/timer
cpu, stm32_common: fix sign-compare in periph/flashpage
cpu, nrf5x_common: fix sign-compare in radio/nrfmin
cpu, samd21: fix sign-compare in periph/pwm
cpu, ezr32wg: fix sign-compare in periph/gpio
cpu, ezr32wg: fix sign-compare in periph/timer
drivers, ethos: fix sign-compare
sys, net: fix sign-compare
cpu, atmega_common: fix sign-compare error
cpu, msp430fxyz: fix sign-compare in periph/gpio
boards, msb-430-common: fix sign-compare in board_init
driver, cc2420: fix sign-compared
sys/net: fix sign-compare in gnrc_tftp
driver, pcd8544: fix sign-compare
driver, pn532: fix sign-compare
driver, sdcard_spi: fix sign-compare
tests: fix sign_compare
sys/net, lwmac: fix sign_compare
pkg, lwip: fix sign-compare
boards, waspmote: make CORECLOCK unsigned long to fix sign_compare error
tests, sock_ip: fix sign compare
tests, msg_avail: fix sign compare
tests, sock_udp: fix sign compare
boards: fix sign-compare for calliope and microbit matrix
2017-11-28 11:55:48 +01:00
smlng
d03551756f
cpu, cc2538: adapt periph drivers to refined gpio handling
2017-11-17 20:06:41 +01:00
smlng
8fb71afa79
cpu, cc2538: refine gpio handling
...
- hide (more) internal functions
- optimize gpio_init_af
- remove obsolete code
2017-11-17 20:06:35 +01:00
a20745b6c5
cpu: make use of Makefile.periph
2017-11-06 12:01:19 +01:00
167bd30453
all: fix my email address
2017-10-20 15:02:41 +02:00
smlng
fc5c432510
cpu, cc2538: fix pm, don't go into cortexm_sleep(0)
...
fixes #7746
2017-10-18 16:01:38 +02:00
Hauke Petersen
70e17ee5a3
cpu/cc2538/gpio: do not clear output pin on init
2017-10-04 12:15:03 +02:00
Andreas "Paul" Pauli
a12dcaa299
Merge pull request #7361 from smlng/enh/cc2538/periph_timer
...
cpu, cc2538: enhance and cleanup periph timer
2017-08-29 20:03:35 +02:00
smlng
12868d2416
cpu, cc2538: cleanup periph/timer
2017-08-28 21:43:12 +02:00
smlng
46facf4ff7
cpu, cc2538: add gpio alternative functions
2017-08-24 15:31:52 +02: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
smlng
b30d0617aa
cpu, cc2538: add low-lever adc driver
2017-07-20 20:47:49 +02:00
smlng
e94672599d
cpu, cc2538: gpio helper functions
2017-07-07 11:57:07 +02:00
Anon Mall
c4584aca2b
gpio interrupt fix
2017-07-04 00:03:13 +02:00
smlng
01af6d94c4
cpu, periph: retain constness in spi_transfer_bytes
2017-06-29 15:47:13 +02:00
smlng
bb82789644
cc2538: fix cppcheck warning in periph i2c driver
2017-06-26 15:29:04 +02:00
smlng
692cf96297
doc: fix doxygen grouping of cpu periph drivers
2017-06-26 14:42:11 +02:00
Hauke Petersen
a1499f4190
cpu: add and use shared code for timer_set()
2017-06-02 12:21:56 +02:00
Joakim Nohlgård
6cda6a6560
periph/cpuid: Unify implementations to a common driver for several platforms
2017-04-05 09:03:49 +02:00
smlng
e0f19f3394
cc2538: fix timer_set for channel B
2017-03-02 14:49:16 +01:00
Hauke Petersen
2f9e3c89e1
periph/hwrng: use void* buf for hwrng_read()
2017-02-07 13:20:39 +01:00
PeterKietzmann
3fa8a5e87c
cpu/cc2538: fix spi_transfer_bytes
2017-01-25 16:46:46 +01:00
Hauke Petersen
ca5f1befb3
cpu/cc2538+boards: adapted to SPI API changes
...
- adapted the SPI driver
- adapted all boards using the CPU
2017-01-25 16:46:05 +01:00
Oleg Hahm
4f4214235b
timex: unambiguous time conversion macros
2017-01-19 13:18:08 +01:00
Oleg Hahm
d0316fa7ae
periph timer: remove timer_irq_(en|dis)able
2017-01-14 15:34:53 +01:00
Hauke Petersen
8feeea9a12
cpu/cc2538: reworked GPIO driver
2017-01-11 10:19:06 +01:00
Hauke Petersen
3a00fe8e49
cpus: make use of cortexm_isr_end()
2016-12-21 11:28:46 +01:00
Oleg Hahm
ccb9179c23
Merge pull request #5824 from kaspar030/change_default_c_dialect
...
make: use -std=c99 as default
2016-12-08 13:44:34 -05:00
Peter Kietzmann
e547ff1d60
Merge pull request #6013 from haukepetersen/opt_periph_uartreturntypes
...
periph/uart: added names to return values
2016-11-29 19:14:09 +01:00
f4bee2672c
cpu: cc2538: remove typeof() usage
2016-11-15 14:59:36 +01:00
Francisco Acosta
eb06b13722
Merge pull request #5754 from locicontrols/cc2538-timer-pr
...
CC2538 periph/timer overhaul
2016-11-01 23:22:21 +01:00
Hauke Petersen
2eebf36eb2
cpu/uart: make use of named return values
2016-10-28 10:32:00 +02:00
Kees Bakker
bac5cda1e3
periph/i2c: convert char to uint8_t where applicapable
...
In general, data transferred through I2C are bytes and thus should have
type uint8_t, not char.
Also convert uint8_t ptrs to void ptrs
2016-10-04 20:26:39 +02:00
Ian Martin
abae801105
cpu/cc2538/periph/timer overhaul. support 16-bit and 32-bit modes
2016-08-16 15:07:26 -04:00
Aaron Sowry
a301c37c2e
cpu/cc2538: Remove union names from structs
...
Make the unions anonymous, since this makes referencing
their bytes much simpler.
2016-07-16 12:55:12 +12:00
Joakim Nohlgård
c2b20f1f27
cpu/cc2538: Cast enum to unsigned int for comparison
2016-06-01 16:42:15 +02:00
DipSwitch
eb6eed6c2c
cpu/cc2538/spi: Fix compiler warning of possible uninitialized variable
2016-04-19 22:43:51 +02:00
kYc0o
699410efc8
Merge pull request #5124 from locicontrols/fixes
...
cpu/cc2538: fix build errors when UART1 or the 32 kHz crystal is enabled
2016-04-14 12:00:53 +02:00
Cenk Gündoğan
8b7512f0bf
Merge pull request #5187 from Yonezawa-T2/i2c_debug
...
i2c: add missing #ifdef block
2016-03-30 09:34:40 +02:00
Yonezawa-T2
7271c928cc
i2c: add missing #ifdef block
2016-03-30 16:24:38 +09:00
Yonezawa-T2
dc9f769835
NEEDS SQUASHING i2c: revert partially
2016-03-29 17:37:50 +09:00
Yonezawa-T2
1ce140d910
debug: fix compilation error for %p formatter
2016-03-29 11:46:29 +09:00
Ian Martin
a553fe0f84
cpu/cc2538: fix build errors when UART1 or the 32 kHz crystal is enabled
2016-03-28 17:31:58 -04:00
Ian Martin
a2ac92b2bd
cpu/cc2538: add periph/spi driver
2016-03-28 17:24:07 -04:00
Ian Martin
7b8c86ec16
cpu/cc2538/periph/gpio: fix gpio_init() bugs in cfed0e3
2016-03-23 13:59:02 -04:00
Hauke Petersen
cfed0e33cc
cpu/cc2538: adapted to GPIO inerface changes
2016-03-17 14:39:11 +01:00
Joakim Nohlgård
30ed36b236
cpu/cc2538: i2c: Make WARN_IF use {} to silence Clang warning when ENABLE_DEBUG=0
2016-03-13 08:14:39 +01:00
Ian Martin
705879741c
cpu/cc2538: use the MCU's default UART FIFO interrupt levels
2016-03-07 17:52:06 -05:00
Ian Martin
5f05a956db
cpu/cc2538: clear only the latched UART interrupt flags
...
Otherwise incoming bytes can remain in the receive FIFO indefinitely.
2016-03-07 17:52:06 -05:00
Ian Martin
9642f2531a
cpu/cc2538: add periph/i2c driver
2016-03-03 11:04:39 -05:00
kYc0o
e730f1bdc3
Merge pull request #4878 from locicontrols/cc2538-periph-timer
...
cpu/cc2538/periph/timer overhaul
2016-03-03 11:11:57 +01:00
kYc0o
ec1bea389b
Merge pull request #2753 from locicontrols/baudrate-fix
...
cpu/cc2538: avoid using bitfields with the LCRH register
2016-03-02 11:41:02 +01:00
Ian Martin
b6fbdb2f79
Avoid rounding errors during frequency scaling.
2016-03-01 15:18:45 -05:00
Ian Martin
4176d04b02
cpu/cc2538/periph/timer overhaul
...
* Use the 32-bit counter mode.
* Apply frequency scaling for non-16 MHz frequencies.
2016-03-01 15:15:16 -05:00
Hauke Petersen
b11a3ad74b
cpus: adapted timer implementations to API changes
2016-02-29 14:45:00 +01:00
Ian Martin
04bd6e5f7c
cpu/cc2538: avoid using bitfields with the LCRH register
...
Otherwise the UART ignores the new baudrate divisor.
2016-02-26 11:42:32 -05: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
Hauke Petersen
216a4cb432
cpu/cc2538: adapted HWRNG implementation
2016-02-14 12:58:30 +01:00
Joakim Nohlgård
943c106461
cpu/cc2538: Update to match timer_init API change
2016-02-13 21:29:36 +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
Oleg Hahm
4780b5cba1
cc2538: fix pedantic compiler warnings
2015-12-07 20:28:53 +01:00
Hauke Petersen
a58d577cb1
cpu/cc2538: adapted UART driver
2015-10-27 14:59:38 +01:00
Joakim Nohlgård
cbaeccdb90
periph/timer: Drop timer_reset
2015-10-17 20:11:03 +02:00
Ian Martin
40b93ea6ad
cpu/cc2538: uart init overhaul
2015-09-29 12:26:13 -04:00
Ian Martin
aca53006b0
cpu/cc2538: preserve UART_CTL flags when clearing an error condition
2015-09-29 12:26:13 -04:00
Ian Martin
b2c51bed6a
cpu/cc2538: eliminate unused macros UART_1_CTS_PORT and UART_1_RTS_PORT
2015-09-29 12:26:13 -04:00
Ian Martin
d70705f840
cpu/cc2538: round when computing the UART baudrate divisor
2015-09-29 12:26:13 -04:00
Hauke Petersen
47e8472949
cpu/cc2538: adjusted to changed GPIO interface
2015-06-12 19:10:49 +02:00
Joakim Gebart
13832d8e62
everything: Remove filename from @file Doxygen command
2015-05-22 07:34:41 +02:00
Hauke Petersen
e7fbaf3815
cpu: removed NAKED attribute from ISRs
...
- removed the __attribute__((naked)) from ISRs
- removed ISR_ENTER() and ISR_EXIT() macros
Rationale: Cortex-Mx MCUs save registers R0-R4 automatically
on calling ISRs. The naked attribute tells the compiler not
to save any other registers. This is fine, as long as the
code in the ISR is not nested. If nested, it will use also
R4 and R5, which will then lead to currupted registers on
exit of the ISR. Removing the naked will fix this.
2014-10-30 19:33:32 +01:00
Ian Martin
34086fc6c6
cpu/cc2538 bug fix: OE (output enable) bit was set by gpio_init_in().
2014-10-24 14:36:06 -04:00
Hauke Petersen
9051c7be4b
Merge pull request #1861 from haukepetersen/fix_cc2538_irqvector
...
cpu/cc2538: cleaned up IRQ vector definition
2014-10-24 14:40:10 +02:00
Hauke Petersen
ca20603d54
cpu/cc2538: made ISR names configurable by a board
2014-10-24 14:00:53 +02:00
Hauke Petersen
24ac5a7e94
cpu/cc2538: cleaned up IRQ vector definition
2014-10-24 14:00:47 +02:00
Hauke Petersen
ccd601b429
cpu/cc2538: centralized all cpu specific includes
...
- added all CPU specific includes to cpu-conf.h
- removed now not needed includes from cpu .c files
2014-10-23 14:04:57 +02:00
Ian Martin
0605a7eb95
Add support for the Texas Instruments CC2538 ARM Cortex-M3 MCU and developer kit.
2014-10-13 09:29:49 -04:00