• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..--

app_makefiles/29-Dec-2025-933552

hw_modem/29-Dec-2025-3,9432,933

main_examples/29-Dec-2025-2,7541,550

mcu_drivers/29-Dec-2025-737,730437,251

radio_hal/29-Dec-2025-3,5012,345

smtc_hal_l0_LL/29-Dec-2025-3,8371,397

smtc_hal_l4/29-Dec-2025-4,4831,998

smtc_modem_hal/29-Dec-2025-553354

MakefileD29-Dec-202510.2 KiB267192

README.mdD29-Dec-20254.5 KiB14785

main.cD29-Dec-20253.8 KiB10421

main.hD29-Dec-20253.1 KiB9019

modem_pinout.hD29-Dec-20254.4 KiB12846

README.md

1# LoRa Basics Modem examples
2
3This folder contains implementations of LoRa Basics Modem on some MCU boards and some application examples.
4
5## Hardware
6
7### MCU Board
8
9- Nucleo L476RG board ( with STM32L476RGT6 MCU)
10- Nucleo L073RZ board ( with STM32L073RZ MCU)
11
12### Radio Boards
13
14Semtech chosen radio board:
15
16- lr1110 (EVK board)
17- lr1120 (EVK board)
18- lr1121 (EVK board)
19- sx1261 (SX1261MB2xAS)
20- sx1262 (SX1262MB2xAS)
21
22## Getting Started
23
24Please use `make help` to see all build options.
25
26Compilation options can be provided within command line or directly in the makefile option file that can be found in [app_options.mk](app_makefiles/app_options.mk)
27
28### Main Examples
29
30#### Periodical Uplink
31
32This simple example joins LoRaWAN network and then send uplinks periodically or when Nucleo blue button is pushed
33
34LoRaWAN credentials shall be provided in [example_options.h](main_examples/example_options.h)
35
36Build command example for lr1110 radio
37
38```bash
39make lr1110 MODEM_APP=PERIODICAL_UPLINK
40```
41
42#### Hardware Modem
43
44This example proposes an implementation of a all integrated modem that can be addressed using UART RX/TX and 3 gpios for commands handling (command and busy) and events notification (event)
45All functions included in lora basics modem api can be called using commands.
46
47Build command example for lr1110 radio
48
49```bash
50make lr1110 MODEM_APP=HW_MODEM
51```
52
53#### Porting tool
54
55This tool provides a automatic suite of tests that will help user ensures that lora basics modem mcu and radio HAL functions are implemented in a good way (SPI, radio_irq, time, timer, random, radio config, sleep and low power).
56
57Build command example for lr1110 radio
58
59```bash
60make lr1110 MODEM_APP=PORTING_TESTS
61```
62
63#### LCTT Certification
64
65This example provides an application that can be used to run the LCTT certification tool.
66Pushing Blue button will allow the modem to go in certification mode (ie it will accept communication on port 224)
67LoRaWAN credentials and region shall be provided in [example_options.h](main_examples/example_options.h)
68
69Build command example for lr1110 radio
70
71```bash
72make lr1110 MODEM_APP=LCTT_CERTIF
73```
74
75### Relay
76
77#### Relay Tx
78
79This example provides an application where the Relay Tx feature is enabled.
80
81This example uses the Periodical Uplink main example.
82
83The end-device is configured in **ENABLE** mode (refer to TS011-1.0.1 table 40). After the reset, the end-device will enable the Relay Tx feature and add a WOR frame before every LoRaWAN uplink. The relay feature will be automatically disable if the end-device receive a downlink on Rx1 or Rx2.
84
85In this example, the CSMA is compiled and enabled by default.
86
87LoRaWAN credentials shall be provided in [example_options.h](main_examples/example_options.h)
88
89Build command example for lr1110 radio
90
91```bash
92
93make full_lr1110 MODEM_APP=PERIODICAL_UPLINK ALLOW_RELAY_TX=yes
94```
95
96Or to be tested with the LCTT
97
98```bash
99
100make full_lr1110 MODEM_APP=LCTT_CERTIF ALLOW_RELAY_TX=yes
101```
102
103#### Relay Rx
104
105This example provides an application where the relay Rx feature is enabled.
106
107This example uses the Periodical Uplink main example.
108
109In this example, the CSMA is compiled and enabled by default.
110
111LoRaWAN credentials shall be provided in [example_options.h](main_examples/example_options.h)
112
113Build command example for lr1110 radio
114
115```bash
116
117make full_lr1110 MODEM_APP=PERIODICAL_UPLINK ALLOW_RELAY_RX=yes
118```
119
120Or to be tested with the LCTT
121
122```bash
123
124make full_lr1110 MODEM_APP=LCTT_CERTIF ALLOW_RELAY_RX=yes
125```
126
127### MCU Porting
128
129 All MCU specific code can be found under following folders:
130
131- [mcu_drivers](mcu_drivers): contains ST Microelectronics HAL and ARM CMSIS lib
132- [smtc_hal_l4](smtc_hal_l4): contains the helper functions for STM32L4 that use ST HAL lib and that will be needed by modem hal (ex: RTC, GPIO, SPI, UART, WDOG, LPTIM...).
133- [smtc_hal_l0](smtc_hal_l0_LL): contains the helper functions for STM32L0 that use ST HAL lib and that will be needed by modem hal (ex: RTC, GPIO, SPI, UART, WDOG, LPTIM...).
134
135## Radio Porting folder
136
137Radio HAL and BSP implementation are done in [radio_hal](radio_hal) folder
138
139## Modem Porting folder
140
141Modem HAL implementation is done in [smtc_modem_hal.c](smtc_modem_hal/smtc_modem_hal.c).
142Any smtc_modem_hal function will be mapped with corresponding mcu porting function.
143
144## Fuota support
145
146Once the Fuota services are enabled (refer to the main readme for instructions on how to activate Fuota), the periodical example is sufficient to launch a Fuota campaign. However, you will need to enable the flag `ALLOW_FUOTA` to "yes" in the `app_options.mk` file.
147