AllWize Library
configuration.h
Go to the documentation of this file.
1 /*
2 
3 Configuration file
4 
5 */
6 
7 #pragma once
8 
9 //------------------------------------------------------------------------------
10 // General configuration
11 //------------------------------------------------------------------------------
12 
13 #define DEBUG_PORT Serial // Serial debug port
14 #define DEBUG_PORT_BAUDRATE 115200 // Serial debuf baud rate
15 
16 //------------------------------------------------------------------------------
17 // WiFi credentials
18 //------------------------------------------------------------------------------
19 
20 #define WIFI_SSID "daoiz" // SSID to connect to
21 #define WIFI_PASSWORD "calamento" // Wifi password
22 
23 //------------------------------------------------------------------------------
24 // Radio module connections
25 //------------------------------------------------------------------------------
26 
27 #define RESET_PIN 14 // GPIO for the reset pad in the RC1701HP module
28 #define RX_PIN 5 // GPIO connected to the TX pad in the RC1701HP module
29 #define TX_PIN 4 // GPIO connected to the RX pad in the RC1701HP module
30 
31 //------------------------------------------------------------------------------
32 // Wize configuration
33 //------------------------------------------------------------------------------
34 
35 #define WIZE_CHANNEL CHANNEL_04 // Wize channel to use (nodes must be sending on the same channel)
36 #define WIZE_DATARATE DATARATE_2400bps // Wize datarate to use (nodes must be using the same datarate)
37 
38 //------------------------------------------------------------------------------
39 // LoRaWAN server configuration
40 //------------------------------------------------------------------------------
41 
42 #define FORWARDER_SERVER IPAddress(52,169,76,203) // LoRaWAN server (The Things Network EU server)
43 #define FORWARDER_PORT 1700 // UDP port
44 #define FORWARDER_LATITUDE 41.60123934 // Gateway latitude (degrees, north positive)
45 #define FORWARDER_LONGITUDE 2.62249336 // Gateway longitude (degrees, east positive)
46 #define FORWARDER_ALTITUDE 10 // Gateway altitude (meters)
47 #define FORWARDER_GATEWAY_TYPE "AllWize G1 ESP8266" // Gateway type
48 #define FORWARDER_EMAIL "xose@allwize.io" // Administrator email
49 #define FORWARDER_DESCRIPTION "allwize-gw01" // Gateway description
50 
51 //------------------------------------------------------------------------------
52 // NTP configuration
53 //------------------------------------------------------------------------------
54 
55 #define NTP_SERVER "pool.ntp.org" // NTP server
56 #define NTP_SYNC_INTERVAL 10 // On boot, try to sync every 10 seconds
57 #define NTP_UPDATE_INTERVAL 1800 // Once sync'ed, re-sync every 30 minutes