You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, i found a issue about the library, the function is located in the path(/util-lorawan-packets/lw_packets.c LoRaWAN_MarshalPacket())
the code is following:
if (packet->BODY.JoinAccept.hasCFlist) {
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH4, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH5, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH6, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH7, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH8, 3);
pos += 3;
}
In accordance with LoRaWAN standard protocols,the length of CFlist Field should be set with 16 bytes,but the above coding showed that the length of CFlist Field is 15 bytes,could you explain it?
The text was updated successfully, but these errors were encountered:
In LoRaWAN 1.0 (LoRaWAN 1.0.1_d3.pdf) the CFList is defined as 5x3 bytes + 1 byte RFU, which explains the "missing" byte.
The LoRaWAN 1.1 (LoRaWAN-Regional-Parameters-v1 1rA.pdf) spec defines that last byte as CFListType - which is not supported yet - pull requests are very welcome :)
The CFListType shall be equal to zero (0) to indicate that the CFList contains a list of frequencies.
Hi, i found a issue about the library, the function is located in the path(/util-lorawan-packets/lw_packets.c LoRaWAN_MarshalPacket())
the code is following:
if (packet->BODY.JoinAccept.hasCFlist) {
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH4, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH5, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH6, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH7, 3);
pos += 3;
memcpy(&(outBuffer[pos]), packet->BODY.JoinAccept.CFlist.FreqCH8, 3);
pos += 3;
}
In accordance with LoRaWAN standard protocols,the length of CFlist Field should be set with 16 bytes,but the above coding showed that the length of CFlist Field is 15 bytes,could you explain it?
The text was updated successfully, but these errors were encountered: