Home
last modified time | relevance | path

Searched refs:macMsg (Results 1 – 7 of 7) sorted by relevance

/loramac-node-3.4.0/src/mac/
DLoRaMacSerializer.c24 LoRaMacSerializerStatus_t LoRaMacSerializerJoinRequest( LoRaMacMessageJoinRequest_t* macMsg ) in LoRaMacSerializerJoinRequest() argument
26 if( ( macMsg == 0 ) || ( macMsg->Buffer == 0 ) ) in LoRaMacSerializerJoinRequest()
34 if( macMsg->BufSize < LORAMAC_JOIN_REQ_MSG_SIZE ) in LoRaMacSerializerJoinRequest()
39 macMsg->Buffer[bufItr++] = macMsg->MHDR.Value; in LoRaMacSerializerJoinRequest()
41 memcpyr( &macMsg->Buffer[bufItr], macMsg->JoinEUI, LORAMAC_JOIN_EUI_FIELD_SIZE ); in LoRaMacSerializerJoinRequest()
44 memcpyr( &macMsg->Buffer[bufItr], macMsg->DevEUI, LORAMAC_DEV_EUI_FIELD_SIZE ); in LoRaMacSerializerJoinRequest()
47 macMsg->Buffer[bufItr++] = macMsg->DevNonce & 0xFF; in LoRaMacSerializerJoinRequest()
48 macMsg->Buffer[bufItr++] = ( macMsg->DevNonce >> 8 ) & 0xFF; in LoRaMacSerializerJoinRequest()
50 macMsg->Buffer[bufItr++] = macMsg->MIC & 0xFF; in LoRaMacSerializerJoinRequest()
51 macMsg->Buffer[bufItr++] = ( macMsg->MIC >> 8 ) & 0xFF; in LoRaMacSerializerJoinRequest()
[all …]
DLoRaMacParser.c24 LoRaMacParserStatus_t LoRaMacParserJoinAccept( LoRaMacMessageJoinAccept_t* macMsg ) in LoRaMacParserJoinAccept() argument
26 if( ( macMsg == 0 ) || ( macMsg->Buffer == 0 ) ) in LoRaMacParserJoinAccept()
33 macMsg->MHDR.Value = macMsg->Buffer[bufItr++]; in LoRaMacParserJoinAccept()
35 memcpy1( macMsg->JoinNonce, &macMsg->Buffer[bufItr], 3 ); in LoRaMacParserJoinAccept()
38 memcpy1( macMsg->NetID, &macMsg->Buffer[bufItr], 3 ); in LoRaMacParserJoinAccept()
41 macMsg->DevAddr = ( uint32_t ) macMsg->Buffer[bufItr++]; in LoRaMacParserJoinAccept()
42 macMsg->DevAddr |= ( ( uint32_t ) macMsg->Buffer[bufItr++] << 8 ); in LoRaMacParserJoinAccept()
43 macMsg->DevAddr |= ( ( uint32_t ) macMsg->Buffer[bufItr++] << 16 ); in LoRaMacParserJoinAccept()
44 macMsg->DevAddr |= ( ( uint32_t ) macMsg->Buffer[bufItr++] << 24 ); in LoRaMacParserJoinAccept()
46 macMsg->DLSettings.Value = macMsg->Buffer[bufItr++]; in LoRaMacParserJoinAccept()
[all …]
DLoRaMacCrypto.c980 LoRaMacCryptoStatus_t LoRaMacCryptoPrepareJoinRequest( LoRaMacMessageJoinRequest_t* macMsg ) in LoRaMacCryptoPrepareJoinRequest() argument
982 if( macMsg == 0 ) in LoRaMacCryptoPrepareJoinRequest()
996 macMsg->DevNonce = CryptoNvm->DevNonce; in LoRaMacCryptoPrepareJoinRequest()
1000 if( DeriveLifeTimeSessionKey( J_S_INT_KEY, macMsg->DevEUI ) != LORAMAC_CRYPTO_SUCCESS ) in LoRaMacCryptoPrepareJoinRequest()
1004 if( DeriveLifeTimeSessionKey( J_S_ENC_KEY, macMsg->DevEUI ) != LORAMAC_CRYPTO_SUCCESS ) in LoRaMacCryptoPrepareJoinRequest()
1011 if( LoRaMacSerializerJoinRequest( macMsg ) != LORAMAC_SERIALIZER_SUCCESS ) in LoRaMacCryptoPrepareJoinRequest()
1017 …mentComputeAesCmac( NULL, macMsg->Buffer, ( LORAMAC_JOIN_REQ_MSG_SIZE - LORAMAC_MIC_FIELD_SIZE ), … in LoRaMacCryptoPrepareJoinRequest()
1023 if( LoRaMacSerializerJoinRequest( macMsg ) != LORAMAC_SERIALIZER_SUCCESS ) in LoRaMacCryptoPrepareJoinRequest()
1031 LoRaMacCryptoStatus_t LoRaMacCryptoPrepareReJoinType1( LoRaMacMessageReJoinType1_t* macMsg ) in LoRaMacCryptoPrepareReJoinType1() argument
1034 if( macMsg == 0 ) in LoRaMacCryptoPrepareReJoinType1()
[all …]
DLoRaMacCrypto.h242 LoRaMacCryptoStatus_t LoRaMacCryptoPrepareJoinRequest( LoRaMacMessageJoinRequest_t* macMsg );
251 LoRaMacCryptoStatus_t LoRaMacCryptoPrepareReJoinType1( LoRaMacMessageReJoinType1_t* macMsg );
260 LoRaMacCryptoStatus_t LoRaMacCryptoPrepareReJoinType0or2( LoRaMacMessageReJoinType0or2_t* macMsg );
271 …oinAccept( JoinReqIdentifier_t joinReqType, uint8_t* joinEUI, LoRaMacMessageJoinAccept_t* macMsg );
282 …acCryptoSecureMessage( uint32_t fCntUp, uint8_t txDr, uint8_t txCh, LoRaMacMessageData_t* macMsg );
294 …drID, uint32_t address, FCntIdentifier_t fCntID, uint32_t fCntDown, LoRaMacMessageData_t* macMsg );
DLoRaMacSerializer.h77 LoRaMacSerializerStatus_t LoRaMacSerializerJoinRequest( LoRaMacMessageJoinRequest_t* macMsg );
85 LoRaMacSerializerStatus_t LoRaMacSerializerReJoinType1( LoRaMacMessageReJoinType1_t* macMsg );
93 LoRaMacSerializerStatus_t LoRaMacSerializerReJoinType0or2( LoRaMacMessageReJoinType0or2_t* macMsg );
101 LoRaMacSerializerStatus_t LoRaMacSerializerData( LoRaMacMessageData_t* macMsg );
DLoRaMacParser.h78 LoRaMacParserStatus_t LoRaMacParserJoinAccept( LoRaMacMessageJoinAccept_t *macMsg );
86 LoRaMacParserStatus_t LoRaMacParserData( LoRaMacMessageData_t *macMsg );
DLoRaMac.c401 …ntDown( AddressIdentifier_t addrID, FType_t fType, LoRaMacMessageData_t* macMsg, Version_t lrWanVe…
603 LoRaMacStatus_t DetermineFrameType( LoRaMacMessageData_t* macMsg, FType_t* fType );
1907 …ntDown( AddressIdentifier_t addrID, FType_t fType, LoRaMacMessageData_t* macMsg, Version_t lrWanVe… in GetFCntDown() argument
1910 if( ( macMsg == NULL ) || ( fCntID == NULL ) || in GetFCntDown()
1952 return LoRaMacCryptoGetFCntDown( *fCntID, macMsg->FHDR.FCnt, currentDown ); in GetFCntDown()
3436 LoRaMacStatus_t DetermineFrameType( LoRaMacMessageData_t* macMsg, FType_t* fType ) in DetermineFrameType() argument
3438 if( ( macMsg == NULL ) || ( fType == NULL ) ) in DetermineFrameType()
3463 if( ( macMsg->FHDR.FCtrl.Bits.FOptsLen > 0 ) && ( macMsg->FPort > 0 ) ) in DetermineFrameType()
3467 else if( macMsg->FRMPayloadSize == 0 ) in DetermineFrameType()
3471 else if( ( macMsg->FHDR.FCtrl.Bits.FOptsLen == 0 ) && ( macMsg->FPort == 0 ) ) in DetermineFrameType()
[all …]