Zephyr API 3.6.99
Loading...
Searching...
No Matches
lora.h File Reference

Public LoRa driver APIs. More...

#include <stdint.h>
#include <zephyr/kernel.h>
#include <zephyr/device.h>

Go to the source code of this file.

Data Structures

struct  lora_modem_config
 Structure containing the configuration of a LoRa modem. More...
 

Enumerations

enum  lora_signal_bandwidth { BW_125_KHZ = 0 , BW_250_KHZ , BW_500_KHZ }
 LoRa signal bandwidth. More...
 
enum  lora_datarate {
  SF_6 = 6 , SF_7 , SF_8 , SF_9 ,
  SF_10 , SF_11 , SF_12
}
 LoRa data-rate. More...
 
enum  lora_coding_rate { CR_4_5 = 1 , CR_4_6 = 2 , CR_4_7 = 3 , CR_4_8 = 4 }
 LoRa coding rate. More...
 

Functions

static int lora_config (const struct device *dev, struct lora_modem_config *config)
 Configure the LoRa modem.
 
static int lora_send (const struct device *dev, uint8_t *data, uint32_t data_len)
 Send data over LoRa.
 
static int lora_send_async (const struct device *dev, uint8_t *data, uint32_t data_len, struct k_poll_signal *async)
 Asynchronously send data over LoRa.
 
static int lora_recv (const struct device *dev, uint8_t *data, uint8_t size, k_timeout_t timeout, int16_t *rssi, int8_t *snr)
 Receive data over LoRa.
 
static int lora_recv_async (const struct device *dev, lora_recv_cb cb)
 Receive data asynchronously over LoRa.
 
static int lora_test_cw (const struct device *dev, uint32_t frequency, int8_t tx_power, uint16_t duration)
 Transmit an unmodulated continuous wave at a given frequency.
 

Detailed Description

Public LoRa driver APIs.

Public LoRa APIs.