mirror of
https://github.com/espressif/openthread.git
synced 2026-08-20 17:39:51 +00:00
[mle] log rloc16 changes (#4486)
This commit is contained in:
committed by
Jonathan Hui
parent
f816635465
commit
583873c133
@@ -962,6 +962,13 @@ uint16_t Mle::GetRloc16(void) const
|
||||
|
||||
void Mle::SetRloc16(uint16_t aRloc16)
|
||||
{
|
||||
uint16_t oldRloc16 = GetRloc16();
|
||||
|
||||
if (aRloc16 != oldRloc16)
|
||||
{
|
||||
otLogNoteMle("RLOC16 %04x -> %04x", oldRloc16, aRloc16);
|
||||
}
|
||||
|
||||
Get<ThreadNetif>().RemoveUnicastAddress(mMeshLocal16);
|
||||
|
||||
Get<Mac::Mac>().SetShortAddress(aRloc16);
|
||||
|
||||
Reference in New Issue
Block a user