Hello guys,
I'm using some samr21-xpro boards and the output radio power of the
modul is very strong.
I want to reduce the power a little bit. The datasheet ([1], Page 979 -
980) says, I have to manipulate register
"PHY_TX_PWR" (Address 0x5).
Does anyone have an idea how the implementation looks like in C.
[1]: Datasheet:
http://ww1.microchip.com/downloads/en/DeviceDoc/SAM-R21_Datasheet.pdf
Hello Oliver,
For that purpose you can use the `at86rf2xx_set_txpower` function [1]
(if you are using the raw radio) or use the netdev interface (`set` [2]
function with NETOPT_TX_POWER netopt).
If you are using GNRC, you can use `netapi` to set the TX power on a
given interface(check e.g this [3])
Cheers,
José
[1]:
https://github.com/RIOT-OS/RIOT/blob/master/drivers/at86rf2xx/at86rf2xx_getset.c#L243
[2]:
http://doc.riot-os.org/structnetdev__driver.html#ad5c8c409276a702877ad50ad09e87a58
[3]:
https://github.com/RIOT-OS/RIOT/blob/master/sys/shell/commands/sc_gnrc_netif.c#L1052