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

47 Commits

Author SHA1 Message Date
Frederik Haxel
ec7fe8d598 drivers: Use size_t print format specifier
Co-authored-by: Marian Buschsieweke <marian.buschsieweke@posteo.net>
2023-12-21 12:02:28 +01:00
Benjamin Valentin
d611a264fd drivers/cc2420: register with netdev 2021-04-27 17:37:52 +02:00
Marian Buschsieweke
3a378c24a2
drivers/cc2420: make TX/RX IRQs read only
This brings the implementation in sync with the API.
2021-03-22 08:15:54 +01:00
Bas Stottelaar
92b1dfc703 drivers/*: realign ENABLE_DEBUG 2020-10-23 01:26:09 +02:00
d8794d7c5a drivers/cc2420: fix bogus cc2420_set_state(dev, CC2420_GOTO_RX)
It doesn't compile, compiler complains that the enum type of
CC2420_GOTO_RX cannot be converted to netopt_state_t as required by the
function.
The numerical value of CC2420_GOTO_RX would be NETOPT_STATE_IDLE (2), which
makes sense as it puts the device into RX mode.
2020-08-04 13:56:49 +02:00
kYc0o
c6b424f4ff drivers/cc2420: don't append to FIFO if iol->iol_len == 0
This prevents SPI transfers with len == 0, which triggers
an assert failure.
2019-04-02 16:00:03 +02:00
Kees Bakker
d79350f2ab drivers/cc2420: do normal assignment instead of memcpy 2019-01-10 19:43:43 +01:00
Marian Buschsieweke
aac69c3a56
drivers/cc2420: Fixed behavior on too small buffer
As decided in https://github.com/RIOT-OS/RIOT/issues/10413 when
netdev_driver_t::recv() is called with a too small buffer the incoming frame
should be dropped and `-ENOBUFS` returned. This commit makes cc2420 compliant.
2019-01-08 23:45:06 +01:00
Marian Buschsieweke
078444902f
drivers/cc2420: Implemented missing drop feature
The netdev_driver_t::recv implementation of the cc2420 does not provide the drop
feature. This commit adds it.
2019-01-08 23:42:03 +01:00
Jose Alamos
87e9172643 drivers/cc2420: add datasheet documentation to duplicated strobe call 2019-01-08 13:46:32 +01:00
Jose Alamos
b965b47d9b drivers/cc2420: move flush sequence to inline function 2019-01-08 13:46:32 +01:00
d2ddc4ef2e
cc2420: Remove PAN ID initialization from reset 2018-11-28 11:31:02 +01:00
965cece510
cc2420: Remove default event report settings 2018-07-16 14:43:12 +02:00
327295a1e1
cc2420: use netdev reset function 2018-07-11 09:39:17 +02:00
23b414b732 drivers: net: adapt to iolist-using netdev 2018-03-06 14:00:31 +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
047b8172ae cc2420: Add RSSI dBm conversion 2017-11-27 21:49:15 +01:00
Martine Lenders
29842bb5e4 netdev2: rename to netdev and remove gnrc_netdev
With some minor hand-edits I used the following chain of commands:

```sh
git rm sys/include/net/gnrc/netdev.h
git grep --name-only -i netdev2 | \
        xargs sed -i -e 's/^\(NETDEV\)2\(.*\)\( [("]\)/\1\2 \3/g' \
                     -e 's/\(netdev\)2\(.*\)\( \/\*\*<\)/\1\2 \3/I' \
                     -e 's/\(netdev\)2/\1/gI'
git add -p
git commit --amend
git ls-tree --full-tree -r HEAD --name-only | \
        grep "netdev2" | xargs -I'{}' dirname '{}' | uniq | \
        grep "netdev2" | while read dir; do
                new_dir="$(echo "$dir" | sed "s/netdev2/netdev/g")"
                git mv -f "$dir" "$new_dir"
        done
git commit --amend
git ls-tree --full-tree -r HEAD --name-only | \
        grep "netdev2" | while read file; do
                new_file="$(echo "$file" | sed "s/netdev2/netdev/g")"
                git mv -f "$file" "$new_file"
        done
git commit --amend
git grep --name-only "\<drivers_netdev_netdev\>" | \
        xargs sed -i "s/\<drivers_netdev_netdev\>/drivers_netdev_api/g"
git add -p
git commit --amend
```
2017-03-15 09:31:20 +01:00
Hauke Petersen
79a113d1ba sys/drivers: renamed uuid module to luid 2017-02-27 11:01:20 +01:00
Hauke Petersen
5639b1d52f drivers/cc2420: adapted to SPI API changes 2017-01-25 16:46:45 +01:00
Hauke Petersen
88636b6919 drivers/cc2420: use uuid module for addr gen 2017-01-19 11:09:29 +01:00
PeterKietzmann
6d4011a325 drivers/cc2420:improve send performance 2016-11-29 09:03:23 +01:00
Thomas Eichinger
103c426cdc drivers/cc2420: calculate CRC and check CRC_OK bit on packet reception
First start calculating the CRC in hardware when receiving a frame.

Then, other than the at86rf2xx transceivers the cc2420 don't consider the
CRC_OK flag when reporting a successful packet reception. This change
introduces a check for this bit and drops the packet else by flushing
the RX FIFO.
2016-11-08 23:28:09 -08:00
Thomas Eichinger
b57ce103a3 drivers/cc2420: adapt FIFO access to recent msp430 SPI changes
When redoing the SPI driver for the msp430 platforms an assert
statement was introduced to prohibit SPI access without any
buffers. Since in the existing code the FIFO pointer is incremented
through a dummy read this results in triggering aforementioned
assert.
2016-11-07 11:09:45 -08:00
Martine Lenders
bd2429f299 cpu: drivers: adapt devices for netdev2 parameter type change 2016-08-03 12:30:51 +02:00
kYc0o
62d8b9a268 drivers/cc2420: factorise/reorganise overall code 2016-07-06 20:23:23 +02:00
Hauke Petersen
abc6b5ccdf drivers: added support for CC2420 radio 2016-07-06 18:14:48 +02:00
5d8349298f remove bulk of legacy network stack and drivers 2015-08-06 12:12:47 +02:00
Oleg Hahm
f23e7f90d2 cc2420: mask FSCTRL register for frequency access 2015-07-27 20:15:20 +02:00
Oleg Hahm
828839316b core: renamed crash.h to panic.h 2015-05-09 18:44:10 +02:00
Ludwig Ortmann
47ca52cb8d SQUASHME: clean out extern kernel_pid_t transceiver_pid redefinitions 2014-08-02 14:29:07 +02:00
Oleg Hahm
983d056c75 core: harmonizes the data type for the process ID
Instead of using differing integer types use kernel_pid_t for process
identifier. This type is introduced in a new header file to avoid
circular dependencies.
2014-08-01 12:02:54 +02:00
Ludwig Ortmann
3ca4f18479 doc: use lgplv2.1-short license header instead of lgpl-short-riot 2014-07-31 22:57:20 +02:00
Kévin Roussel
165e5ee52f Extend CC2420 driver to comply with interfaces described in 'radio_driver.h' 2014-07-08 11:46:13 +02:00
Kévin Roussel
4ed4cc51fb Fixed implementation of channel_clear() function 2014-04-09 10:38:44 +02:00
Kévin Roussel
6c40108c9c Added standard way to query CCA status on CC2420 transceiver (squashed) 2014-04-02 17:56:07 +02:00
Kévin Roussel
0b4a1342c7 Fixed errors in addresses/PAN setting functions 2014-03-18 10:01:17 +01:00
Martin Lenders
d51816d2e0 Fix cc2420 driver 2014-02-24 16:14:28 +01:00
Martin
742b49eb47 fix made transceiver_pid extern for cc2420 2014-02-10 08:53:53 +01:00
Ludwig Ortmann
04b94e0e9a replace uint16_t with radio_address_t in cc2420
adpot includes
2014-02-07 18:56:04 +01:00
Martin Lenders
cc1cfcf166 Uncircumvent radio chip's status for IEEE 802.15.4 hardware
Currently the cc2420 and at86rf231 hardware addresses (IEEE 802.15.4
short and long) and frequency channel are read only from a global
variable in the driver.  This global variable is only set when the
user sets the address/channel though both parameters might be preset
by the hardware. This change lets the driver read this parameters
directly from the hardware.
2014-01-24 13:15:35 +01:00
Oleg Hahm
903ec54a43 making include directives consistent 2013-12-19 15:31:37 +01:00
Oleg Hahm
599e266b55 Revert "removed redefined ENABLE_DEBUG"
This reverts commit 69c526f44d.

Instead of removing ENABLE_DEBUG, define it as zero and replacing the
ifdef preprocessor commands by a simple #if
2013-07-24 00:38:43 +02:00
Christian Mehlis
69c526f44d removed redefined ENABLE_DEBUG 2013-07-16 15:27:19 +02:00
Milan Babel
db1fc96ffe added driver for cc2420
also added cc2420 to transceiver and added cc2420 shell commands
2013-06-06 08:35:17 +02:00