Add local-mac-address on DT and enable it on rf2xx driver. If user
define local-mac-address this value will be used as default mac address.
Otherwise driver automatically add a random mac address.
On application level user can change default mac address using net_mgmt
command with NET_REQUEST_IEEE802154_SET_EXT_ADDR parameter defined on
include/net/ieee802154_mgmt.h header.
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
The rx timeout timer callback need update trx_state variable and this
variable is protected by a mutex. Because of that, when compiling the
system with CONFIG_ASSERT=y the system reports 'ASSERTION FAIL
[!arch_is_in_isr()] @ ZEPHYR_BASE/kernel/include/ksched.h:262'.
This refactor the driver remove trx_state variable dependency and
consequently removes phy_mutex and rx timeout timer to be compliant
with kernel rules.
Fixes: #23198
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
The current version of at86rf2xx RX implementation don't uses advanced
capabilities offer by the transceiver. This access SRAM space to gatter
PHR information in parallel with transceiver frame reception. It allows
improve RX reception by handling properlly the frame protection feature
removing transceiver states changes.
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
Add initial Atmel at86rf2xx transceiver driver. This driver uses device
tree to configure the physical interface. The driver had capability to
use multiple transceiver and systems with multiple bands can be used.
With this, 2.4GHz ISM and Sub-Giga can be used simultaneous.
Below a valid DT example. This samples assume same SPI port with two
transceivers.
&spi0 {
status = "okay";
label = "SPI_RF2XX";
cs-gpios = <&porta 31 0 &porta 30 0>;
rf2xx@0 {
compatible = "atmel,rf2xx";
reg = <0x0>;
label = "RF2XX_0";
spi-max-frequency = <7800000>;
irq-gpios = <&portb 2 0>;
reset-gpios = <&porta 3 0>;
slptr-gpios = <&portb 3 0>;
status = "okay";
};
rf2xx@1 {
compatible = "atmel,rf2xx";
reg = <0x1>;
label = "RF2XX_1";
spi-max-frequency = <7800000>;
irq-gpios = <&portb 4 0>;
reset-gpios = <&porta 4 0>;
slptr-gpios = <&portb 4 0>;
status = "okay";
};
};
At the moment driver assume two transceiver are enouth for majority of
appications. Sub-Giga band will be enabled in future.
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>