File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change 33#define CONNECTION_MANAGER_H_INCLUDED
44
55#ifndef ARDUINO_CLOUD_DEBUG_LEVEL
6- #define ARDUINO_CLOUD_DEBUG_LEVEL 3
6+ #define ARDUINO_CLOUD_DEBUG_LEVEL 0
77#endif
88
99#include < Client.h>
@@ -31,8 +31,10 @@ class ConnectionManager {
3131protected:
3232 unsigned long lastValidTimestamp = 0 ;
3333 NetworkConnectionState netConnectionState = CONNECTION_STATE_IDLE;
34+
3435};
3536
37+
3638#ifdef ARDUINO_SAMD_MKR1000
3739#include < WiFi101.h>
3840#define BOARD_HAS_WIFI
@@ -57,13 +59,17 @@ class ConnectionManager {
5759#define NETWORK_CONNECTED GSM3_NetworkStatus_t::GPRS_READY
5860#endif
5961
62+ static int debugMessageLevel = ARDUINO_CLOUD_DEBUG_LEVEL;
6063inline void debugMessage (char *_msg, uint8_t _debugLevel) {
61- if (_debugLevel <= ARDUINO_CLOUD_DEBUG_LEVEL ) {
64+ if (_debugLevel <= debugMessageLevel ) {
6265 char prepend[20 ];
6366 sprintf (prepend, " \n [ %d ] " , millis ());
6467 Serial.print (prepend);
6568 Serial.println (_msg);
6669 }
6770}
6871
72+ inline void setDebugMessageLevel (uint8_t _debugLevel){
73+ debugMessageLevel = _debugLevel;
74+ }
6975#endif
You can’t perform that action at this time.
0 commit comments