@@ -167,6 +167,7 @@ bool LoRaWanClass::setDataRate(_data_rate_t dataRate, _physical_type_t physicalT
167
167
loraDebugPrint (DEFAULT_DEBUGTIME);
168
168
#endif
169
169
delay (DEFAULT_TIMEWAIT);
170
+ return true ;
170
171
}
171
172
172
173
void LoRaWanClass::setPower (short power)
@@ -430,8 +431,8 @@ short LoRaWanClass::receivePacket(char *buffer, short length, short *rssi)
430
431
ptr += 5 ;
431
432
for (short i = 0 ; ; i ++)
432
433
{
433
- char temp[2 ] = {0 };
434
- unsigned char tmp, result = 0 ;
434
+ char temp[2 ] = {0 , 0 };
435
+ unsigned char tmp = ' ? ' , result = 0 ;
435
436
436
437
temp[0 ] = *(ptr + i * 3 );
437
438
temp[1 ] = *(ptr + i * 3 + 1 );
@@ -473,7 +474,7 @@ short LoRaWanClass::receivePacket(char *buffer, short length, short *rssi)
473
474
for (short i = 0 ; ; i ++)
474
475
{
475
476
char temp[2 ] = {0 };
476
- unsigned char tmp, result = 0 ;
477
+ unsigned char tmp = ' ? ' , result = 0 ;
477
478
478
479
temp[0 ] = *(ptr + i * 3 );
479
480
temp[1 ] = *(ptr + i * 3 + 1 );
@@ -858,7 +859,7 @@ short LoRaWanClass::receivePacketP2PMode(unsigned char *buffer, short length, sh
858
859
for (short i = 0 ; i < number; i ++)
859
860
{
860
861
char temp[2 ] = {0 };
861
- unsigned char tmp, result = 0 ;
862
+ unsigned char tmp= ' ? ' , result = 0 ;
862
863
863
864
temp[0 ] = *(ptr + i * 2 );
864
865
temp[1 ] = *(ptr + i * 2 + 1 );
@@ -985,7 +986,7 @@ short LoRaWanClass::readLine(char *buffer, short length, unsigned char timeout)
985
986
{
986
987
short i = 0 ;
987
988
unsigned long timerStart, timerEnd;
988
- char c;
989
+ char c= ' \n ' ;
989
990
990
991
timerStart = millis ();
991
992
0 commit comments