Skip to content

Commit b673b59

Browse files
committed
Adding debug output to show when connected to gateway/cloud
1 parent 7c213f6 commit b673b59

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/ArduinoIoTCloudLPWAN.cpp

+4-2
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ static size_t const CBOR_LORA_MSG_MAX_SIZE = 255;
3939

4040
extern "C" unsigned long getTime()
4141
{
42-
return ArduinoCloud.getTime();
42+
return ArduinoCloud.getInternalTime();
4343
}
4444

4545
/******************************************************************************
@@ -107,6 +107,7 @@ ArduinoIoTCloudLPWAN::State ArduinoIoTCloudLPWAN::handle_SyncTime()
107107
{
108108
unsigned long const internal_posix_time = _time_service.getTime();
109109
DBG_VERBOSE("ArduinoIoTCloudLPWAN::%s internal clock configured to posix timestamp %d", __FUNCTION__, internal_posix_time);
110+
DBG_INFO("Connected to Arduino IoT Cloud");
110111
return State::Connected;
111112
}
112113

@@ -158,7 +159,8 @@ int ArduinoIoTCloudLPWAN::writeProperties(const byte data[], int length)
158159
{
159160
int retcode = _connection->write(data, length);
160161
int i = 0;
161-
while (_retryEnable && retcode < 0 && i < _maxNumRetry) {
162+
while (_retryEnable && retcode < 0 && i < _maxNumRetry)
163+
{
162164
delay(_intervalRetry);
163165
retcode = _connection->write(data, length);
164166
i++;

0 commit comments

Comments
 (0)