Lora support for the STM B_L072Z_LRWAN1 board out of the box. Also supports HopeRF RFM95, Murata CMWX1ZZABZ and Semtech SX1276MB1MAS/SX1276MB1LAS modules.

Dependencies:   BufferedSerial SX1276GenericLib mbed USBDeviceHT

Committer:
Helmut64
Date:
Sun Jun 03 19:25:37 2018 +0000
Revision:
20:a1029437adca
Parent:
19:992eda680d91
When USB is active we keep a Timer running to avoid deepsleep.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Helmut64 0:c43b6919ae15 1 /*
Helmut64 17:98f2528e8399 2 * Copyright (c) 2018 HELIOS Software GmbH
Helmut64 0:c43b6919ae15 3 * 30826 Garbsen (Hannover) Germany
Helmut64 0:c43b6919ae15 4 * Licensed under the Apache License, Version 2.0);
Helmut64 0:c43b6919ae15 5 */
Helmut64 0:c43b6919ae15 6 #include "main.h"
Helmut64 0:c43b6919ae15 7
Helmut64 0:c43b6919ae15 8
Helmut64 19:992eda680d91 9 DigitalOut led(LED);
Helmut64 0:c43b6919ae15 10
Helmut64 19:992eda680d91 11
Helmut64 19:992eda680d91 12 int main() {
Helmut64 17:98f2528e8399 13 /*
Helmut64 17:98f2528e8399 14 * inits the Serial or USBSerial when available (230400 baud).
Helmut64 17:98f2528e8399 15 * If the serial uart is not is not connected it swiches to USB Serial
Helmut64 17:98f2528e8399 16 * blinking LED means USBSerial detected, waiting for a connect.
Helmut64 17:98f2528e8399 17 * It waits up to 30 seconds for a USB terminal connections
Helmut64 17:98f2528e8399 18 */
Helmut64 19:992eda680d91 19 InitSerial(30*1000, &led);
Helmut64 17:98f2528e8399 20 dprintf("Welcome to the SX1276GenericLib");
Helmut64 18:d5527ce82e6b 21
Helmut64 17:98f2528e8399 22 dprintf("Starting a simple LoRa PingPong");
Helmut64 19:992eda680d91 23
Helmut64 17:98f2528e8399 24 SX1276PingPong();
Helmut64 0:c43b6919ae15 25 }