Farm-Data-Relay-System/examples/ESPNOW_Stress_Test/fdrs_sensor_config.h

34 lines
1.0 KiB
C
Raw Normal View History

2022-06-19 04:06:03 +00:00
// FARM DATA RELAY SYSTEM
//
// Sensor Configuration
2022-07-19 13:39:06 +00:00
#include <fdrs_globals.h>
2022-06-19 04:06:03 +00:00
2022-08-04 03:27:55 +00:00
#define READING_ID 3 //Unique ID for this sensor
#define GTWY_MAC 0x01 //Address of the nearest gateway
2022-06-19 04:06:03 +00:00
#define USE_ESPNOW
//#define USE_LORA
2022-07-19 13:39:06 +00:00
//#define DEEP_SLEEP
2022-06-19 04:06:03 +00:00
//#define POWER_CTRL 14
//#define FDRS_DEBUG
2022-06-19 04:06:03 +00:00
2022-07-19 13:39:06 +00:00
//SPI Configuration -- Needed only on chipsets with multiple SPI interfaces (ESP32)
2022-07-07 10:37:04 +00:00
#define SPI_SCK 5
#define SPI_MISO 19
#define SPI_MOSI 27
2022-07-07 10:38:57 +00:00
//LoRa Configuration
2022-07-07 10:37:04 +00:00
#define LORA_SS 18
#define LORA_RST 14
#define LORA_DIO0 26
2022-06-19 04:06:03 +00:00
//433E6 for Asia
//866E6 for Europe
//915E6 for North America
2022-08-04 03:27:55 +00:00
//#define LORA_BAND 915E6 // LoRa Frequency Band
//#define LORA_SF 7 // LoRa Spreading Factor
//#define LORA_TXPWR 17 // LoRa TX power in dBm (+2dBm - +20dBm), default is +17dBm
//#define LORA_ACK // Request LoRa acknowledgment. Increases battery usage.
//#define LORA_ACK_TIMEOUT 400 // LoRa ACK timeout in ms. (Minimum = 200)
//#define LORA_RETRIES 2 // LoRa ACK retries [0 - 3]