19#ifndef SX126X_PARAMS_H
20#define SX126X_PARAMS_H
24#include "sx126x_driver.h"
26#ifdef MODULE_SHIELD_LC68
27# include "arduino_iomap.h"
34#ifdef MODULE_SHIELD_LLCC68
35# define SX126X_PARAM_SPI ARDUINO_SPI_D11D12D13
36# define SX126X_PARAM_SPI_NSS ARDUINO_PIN_7
37# define SX126X_PARAM_RESET ARDUINO_PIN_A0
38# define SX126X_PARAM_BUSY ARDUINO_PIN_3
39# define SX126X_PARAM_DIO1 ARDUINO_PIN_5
48#ifndef SX126X_PARAM_SPI
49# define SX126X_PARAM_SPI SPI_DEV(0)
52#ifndef SX126X_PARAM_SPI_NSS
53# define SX126X_PARAM_SPI_NSS GPIO_PIN(0, 8)
56#ifndef SX126X_PARAM_RESET
57# define SX126X_PARAM_RESET GPIO_PIN(0, 0)
60#ifndef SX126X_PARAM_BUSY
61# define SX126X_PARAM_BUSY GPIO_PIN(1, 3)
64#ifndef SX126X_PARAM_DIO1
65# define SX126X_PARAM_DIO1 GPIO_PIN(1, 4)
68#ifndef SX126X_PARAM_REGULATOR
69# define SX126X_PARAM_REGULATOR SX126X_REG_MODE_DCDC
72#ifndef SX126X_PARAM_SET_RF_MODE_CB
73# define SX126X_PARAM_SET_RF_MODE_CB NULL
76#ifndef SX126X_PARAM_TX_PA_MODE
77# define SX126X_PARAM_TX_PA_MODE SX126X_RF_MODE_TX_LPA
80#ifndef SX126X_PARAM_TYPE
81# if IS_USED(MODULE_SX1261)
82# define SX126X_PARAM_TYPE SX126X_TYPE_SX1261
83# elif IS_USED(MODULE_SX1262)
84# define SX126X_PARAM_TYPE SX126X_TYPE_SX1262
85# elif IS_USED(MODULE_SX1268)
86# define SX126X_PARAM_TYPE SX126X_TYPE_SX1268
87# elif IS_USED(MODULE_LLCC68)
88# define SX126X_PARAM_TYPE SX126X_TYPE_LLCC68
89# elif IS_USED(MODULE_SX126X_STM32WL)
90# define SX126X_PARAM_TYPE SX126X_TYPE_STM32WL
92# error "You should select at least one of the SX126x variants."
96#if IS_USED(MODULE_SX126X_RF_SWITCH)
97# define SX126X_SET_RF_MODE .set_rf_mode = SX126X_PARAM_SET_RF_MODE_CB,
98# define SX126X_TX_PA_MODE .tx_pa_mode = SX126X_PARAM_TX_PA_MODE
100# define SX126X_SET_RF_MODE
101# define SX126X_TX_PA_MODE
105# define SX126X_PARAMS { .spi = SX126X_PARAM_SPI, \
106 .nss_pin = SX126X_PARAM_SPI_NSS, \
107 .reset_pin = SX126X_PARAM_RESET, \
108 .busy_pin = SX126X_PARAM_BUSY, \
109 .dio1_pin = SX126X_PARAM_DIO1, \
110 .type = SX126X_PARAM_TYPE, \
111 .regulator = SX126X_PARAM_REGULATOR, \
Device initialization parameters.
static const sx126x_params_t sx126x_params[]
Configuration struct.