Skip to content

Commit b49e385

Browse files
kartbencfriedt
authored andcommitted
include: drivers: lora: add missing doxygen comments
Add doxygen documentation where missing in lora.h Signed-off-by: Benjamin Cabé <[email protected]>
1 parent 6f1e216 commit b49e385

File tree

1 file changed

+31
-14
lines changed

1 file changed

+31
-14
lines changed

include/zephyr/drivers/lora.h

Lines changed: 31 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66

77
/**
88
* @file
9+
* @ingroup lora_api
910
* @brief Public LoRa driver APIs
1011
*/
1112
#ifndef ZEPHYR_INCLUDE_DRIVERS_LORA_H_
@@ -31,34 +32,50 @@ extern "C" {
3132

3233
/**
3334
* @brief LoRa signal bandwidth
35+
*
36+
* This enumeration defines the bandwidth of a LoRa signal.
37+
*
38+
* The bandwidth determines how much spectrum is used to transmit data. Wider bandwidths enable
39+
* higher data rates but typically reduce sensitivity and range.
3440
*/
3541
enum lora_signal_bandwidth {
36-
BW_125_KHZ = 0,
37-
BW_250_KHZ,
38-
BW_500_KHZ,
42+
BW_125_KHZ = 0, /**< 125 kHz */
43+
BW_250_KHZ, /**< 250 kHz */
44+
BW_500_KHZ, /**< 500 kHz */
3945
};
4046

4147
/**
4248
* @brief LoRa data-rate
49+
*
50+
* This enumeration represents the data rate of a LoRa signal, expressed as a Spreading Factor (SF).
51+
*
52+
* The Spreading Factor determines how many chirps are used to encode each symbol (2^SF chips per
53+
* symbol). Higher values result in lower data rates but increased range and robustness.
4354
*/
4455
enum lora_datarate {
45-
SF_6 = 6,
46-
SF_7,
47-
SF_8,
48-
SF_9,
49-
SF_10,
50-
SF_11,
51-
SF_12,
56+
SF_6 = 6, /**< Spreading factor 6 (fastest, shortest range) */
57+
SF_7, /**< Spreading factor 7 */
58+
SF_8, /**< Spreading factor 8 */
59+
SF_9, /**< Spreading factor 9 */
60+
SF_10, /**< Spreading factor 10 */
61+
SF_11, /**< Spreading factor 11 */
62+
SF_12, /**< Spreading factor 12 (slowest, longest range) */
5263
};
5364

5465
/**
5566
* @brief LoRa coding rate
67+
*
68+
* This enumeration defines the LoRa coding rate, used for forward error correction (FEC).
69+
*
70+
* The coding rate is expressed as 4/x, where a lower denominator (e.g., 4/5) means less redundancy,
71+
* resulting in a higher data rate but reduced robustness. Higher redundancy (e.g., 4/8) improves
72+
* error tolerance at the cost of data rate.
5673
*/
5774
enum lora_coding_rate {
58-
CR_4_5 = 1,
59-
CR_4_6 = 2,
60-
CR_4_7 = 3,
61-
CR_4_8 = 4,
75+
CR_4_5 = 1, /**< Coding rate 4/5 (4 information bits, 1 error correction bit) */
76+
CR_4_6 = 2, /**< Coding rate 4/6 (4 information bits, 2 error correction bits) */
77+
CR_4_7 = 3, /**< Coding rate 4/7 (4 information bits, 3 error correction bits) */
78+
CR_4_8 = 4, /**< Coding rate 4/8 (4 information bits, 4 error correction bits) */
6279
};
6380

6481
/**

0 commit comments

Comments
 (0)