Applied patch #88 from @Aviateur17. This fixes the compile issues for sensor sketches. Gateway sketches still do not compile. Will check if this can be just applied the same way as the fix for the sensors.
After the local and global settings have been checked, the corresponding FDRS_xxx must be used. Changed this as not doing so leads to compile errors if the local setting is not set but the global one.
- moved configuration checkup to external file to make sensor and gateway files smaller.
- for sensors the config now only is shown if the sensor does NOT return from Deep Sleep. For example when pressing the reset button or after a crash.
- for gateways the configuration is shown once and also can be forced to be shown with a reset. Code should work for ESP32 and ESP8266 - have only tested it with ESP32.
- fixed issue in fdrs_functions.h - if MQTT_AUTH was enabled but WIFI disabled, the compile crashed.
Not immediately useful, but it is interesting to know how low an FDRS ping is (in ms). I won't ruin the surprise, but it's pretty low.
More importantly however, I laid out how SystemPackets will work. I might rename those.
Further work on #71 :
- Added config code to fdrs_functions.h.
- Commented all local config settings -> global config settings will be taken by default.
- added a debugConfig function, to check from where settings have been taken. May be moved to a place where sensors and gateways can share code as this is needed only once. For the sake of simplicity the function made it into fdrs_sensor.h and fdrs_functions.h Needs to be refined, as there is redundancy right now.
Fixed the configuration system for sensor nodes. Gateway nodes are still to be fixed (work still in process :) )
This has been addressed in #71
Important: For this system to work and make the onboarding easier for new users, global settings must be used by default and therefore local settings must be commented out by default.
Added Id and data content to debug message.
Also changed the order to meet the serial debug output of the gateway - this way it is much easier to check if what has been sent is what has been received.
- added missing categories in keywords.txt
- added dependency of ArduinoJson in library.properties (I didn't add LoRa and PubSubClient but think they should go there as well)
- reformatted paragraph on dependencies as list for better readability