kw2xrf_getset.h File Reference

get/set interfaces for kw2xrf driver More...

Detailed Description

get/set interfaces for kw2xrf driver

Author
Johann Fischer j.fis.nosp@m.cher.nosp@m.@phyt.nosp@m.ec.d.nosp@m.e

Definition in file kw2xrf_getset.h.

#include "kw2xrf.h"
+ Include dependency graph for kw2xrf_getset.h:

Go to the source code of this file.

void kw2xrf_set_tx_power (kw2xrf_t *dev, int16_t txpower)
 Set tx power of given device. More...
 
uint16_t kw2xrf_get_txpower (kw2xrf_t *dev)
 Get tx power value of given device. More...
 
int kw2xrf_set_channel (kw2xrf_t *dev, uint8_t val)
 Set channel of given device. More...
 
uint8_t kw2xrf_get_channel (kw2xrf_t *dev)
 Get channel of given device. More...
 
void kw2xrf_abort_sequence (kw2xrf_t *dev)
 Abort current sequence of device. More...
 
void kw2xrf_set_idle_sequence (kw2xrf_t *dev)
 Set idle sequence state of device. More...
 
void kw2xrf_set_sequence (kw2xrf_t *dev, kw2xrf_physeq_t seq)
 Set sequence state of device. More...
 
void kw2xrf_set_pan (kw2xrf_t *dev, uint16_t pan)
 Set PAN ID of a given device. More...
 
void kw2xrf_set_addr_short (kw2xrf_t *dev, uint16_t addr)
 Set short address of a given device. More...
 
void kw2xrf_set_addr_long (kw2xrf_t *dev, uint64_t addr)
 Set long address of a given device. More...
 
uint16_t kw2xrf_get_addr_short (kw2xrf_t *dev)
 Get short address of a given device. More...
 
uint64_t kw2xrf_get_addr_long (kw2xrf_t *dev)
 Get long address of a given device. More...
 
int8_t kw2xrf_get_cca_threshold (kw2xrf_t *dev)
 Get CCA threshold of a given device. More...
 
void kw2xrf_set_cca_threshold (kw2xrf_t *dev, int8_t value)
 Set CCA threshold of a given device. More...
 
void kw2xrf_set_cca_mode (kw2xrf_t *dev, uint8_t mode)
 Set CCA mode of a given device. More...
 
uint8_t kw2xrf_get_cca_mode (kw2xrf_t *dev)
 Get CCA mode of a given device. More...
 
int16_t kw2xrf_get_rssi (uint32_t value)
 Get RSSI from LQI value. More...
 
netopt_state_t kw2xrf_get_status (kw2xrf_t *dev)
 Get state of a given device. More...
 
int kw2xrf_cca (kw2xrf_t *dev)
 Enable continuous CCA. More...
 
void kw2xrf_set_rx_watermark (kw2xrf_t *dev, uint8_t value)
 Set receive watermark. More...
 
void kw2xrf_set_option (kw2xrf_t *dev, uint16_t option, bool state)
 Set netopt a given device. More...
 

Function Documentation

◆ kw2xrf_abort_sequence()

void kw2xrf_abort_sequence ( kw2xrf_t dev)

Abort current sequence of device.

Parameters
[in]devkw2xrf device descriptor

◆ kw2xrf_cca()

int kw2xrf_cca ( kw2xrf_t dev)

Enable continuous CCA.

Parameters
[in]devkw2xrf device descriptor
Returns
CCA value

◆ kw2xrf_get_addr_long()

uint64_t kw2xrf_get_addr_long ( kw2xrf_t dev)

Get long address of a given device.

Parameters
[in]devkw2xrf device descriptor
Returns
current long address

◆ kw2xrf_get_addr_short()

uint16_t kw2xrf_get_addr_short ( kw2xrf_t dev)

Get short address of a given device.

Parameters
[in]devkw2xrf device descriptor
Returns
current short address

◆ kw2xrf_get_cca_mode()

uint8_t kw2xrf_get_cca_mode ( kw2xrf_t dev)

Get CCA mode of a given device.

Parameters
[in]devkw2xrf device descriptor
Returns
current CCA mode

◆ kw2xrf_get_cca_threshold()

int8_t kw2xrf_get_cca_threshold ( kw2xrf_t dev)

Get CCA threshold of a given device.

Parameters
[in]devkw2xrf device descriptor
Returns
current CCA threshold

◆ kw2xrf_get_channel()

uint8_t kw2xrf_get_channel ( kw2xrf_t dev)

Get channel of given device.

Parameters
[in]devkw2xrf device descriptor
Returns
current channel

◆ kw2xrf_get_rssi()

int16_t kw2xrf_get_rssi ( uint32_t  value)

Get RSSI from LQI value.

Parameters
[in]valueCurrent LQI value
Returns
deduced RSSI in dBm

◆ kw2xrf_get_status()

netopt_state_t kw2xrf_get_status ( kw2xrf_t dev)

Get state of a given device.

Parameters
[in]devkw2xrf device descriptor
Returns
current state

◆ kw2xrf_get_txpower()

uint16_t kw2xrf_get_txpower ( kw2xrf_t dev)

Get tx power value of given device.

Parameters
[in]devkw2xrf device descriptor
Returns
current tx power value

◆ kw2xrf_set_addr_long()

void kw2xrf_set_addr_long ( kw2xrf_t dev,
uint64_t  addr 
)

Set long address of a given device.

Parameters
[in]devkw2xrf device descriptor
[in]addrlong address

◆ kw2xrf_set_addr_short()

void kw2xrf_set_addr_short ( kw2xrf_t dev,
uint16_t  addr 
)

Set short address of a given device.

Parameters
[in]devkw2xrf device descriptor
[in]addrshort address

◆ kw2xrf_set_cca_mode()

void kw2xrf_set_cca_mode ( kw2xrf_t dev,
uint8_t  mode 
)

Set CCA mode of a given device.

Parameters
[in]devkw2xrf device descriptor
[in]modeCCA mode

◆ kw2xrf_set_cca_threshold()

void kw2xrf_set_cca_threshold ( kw2xrf_t dev,
int8_t  value 
)

Set CCA threshold of a given device.

Parameters
[in]devkw2xrf device descriptor
[in]valueCCA threshold

◆ kw2xrf_set_channel()

int kw2xrf_set_channel ( kw2xrf_t dev,
uint8_t  val 
)

Set channel of given device.

Parameters
[in]devkw2xrf device descriptor
[in]valchannel

◆ kw2xrf_set_idle_sequence()

void kw2xrf_set_idle_sequence ( kw2xrf_t dev)

Set idle sequence state of device.

Parameters
[in]devkw2xrf device descriptor

◆ kw2xrf_set_option()

void kw2xrf_set_option ( kw2xrf_t dev,
uint16_t  option,
bool  state 
)

Set netopt a given device.

Parameters
[in]devkw2xrf device descriptor
[in]optionNetopt option type
[in]statestate

◆ kw2xrf_set_pan()

void kw2xrf_set_pan ( kw2xrf_t dev,
uint16_t  pan 
)

Set PAN ID of a given device.

Parameters
[in]devkw2xrf device descriptor
[in]panPAN ID value

◆ kw2xrf_set_rx_watermark()

void kw2xrf_set_rx_watermark ( kw2xrf_t dev,
uint8_t  value 
)

Set receive watermark.

Parameters
[in]devkw2xrf device descriptor
[in]valuewatermark

◆ kw2xrf_set_sequence()

void kw2xrf_set_sequence ( kw2xrf_t dev,
kw2xrf_physeq_t  seq 
)

Set sequence state of device.

Parameters
[in]devkw2xrf device descriptor
[in]seqsequence

◆ kw2xrf_set_tx_power()

void kw2xrf_set_tx_power ( kw2xrf_t dev,
int16_t  txpower 
)

Set tx power of given device.

Parameters
[in]devkw2xrf device descriptor
[in]txpowertransmit power in dBm