mirror of
https://github.com/espressif/openthread.git
synced 2026-07-28 22:57:47 +00:00
[trel] implementing Thread Radio Encapsulation Link (TREL) (#4440)
This commit implements TREL protocol to encapsulate and exchange IEEE 802.15.4 frames over a packet switched network (e.g., a wireless LAN). This commit also provides a TREL IPv6/UDP interface implementation (using link-local IPv6 unicast/multicast addresses to communicate over a subnet). It defines a platform abstraction (`otPlatTrelUdp6*`) for TREL over IPv6/UDP. This commit also provides an implementation of the TREL platform under `examples/posix` focusing on simulating the behavior of the link.
This commit is contained in:
committed by
Jonathan Hui
parent
ffb3fdf9bd
commit
2d36853fe6
@@ -610,4 +610,47 @@ void otPlatOtnsStatus(const char *aStatus)
|
||||
}
|
||||
#endif // OPENTHREAD_CONFIG_OTNS_ENABLE
|
||||
|
||||
#if OPENTHREAD_CONFIG_RADIO_LINK_TREL_ENABLE
|
||||
|
||||
void otPlatTrelUdp6Init(otInstance *aInstance, const otIp6Address *aUnicastAddress, uint16_t aUdpPort)
|
||||
{
|
||||
OT_UNUSED_VARIABLE(aInstance);
|
||||
OT_UNUSED_VARIABLE(aUnicastAddress);
|
||||
OT_UNUSED_VARIABLE(aUdpPort);
|
||||
}
|
||||
|
||||
void otPlatTrelUdp6UpdateAddress(otInstance *aInstance, const otIp6Address *aUnicastAddress)
|
||||
{
|
||||
OT_UNUSED_VARIABLE(aInstance);
|
||||
OT_UNUSED_VARIABLE(aUnicastAddress);
|
||||
}
|
||||
|
||||
void otPlatTrelUdp6SubscribeMulticastAddress(otInstance *aInstance, const otIp6Address *aMulticastAddress)
|
||||
{
|
||||
OT_UNUSED_VARIABLE(aInstance);
|
||||
OT_UNUSED_VARIABLE(aMulticastAddress);
|
||||
}
|
||||
|
||||
otError otPlatTrelUdp6SendTo(otInstance * aInstance,
|
||||
const uint8_t * aBuffer,
|
||||
uint16_t aLength,
|
||||
const otIp6Address *aDestAddress)
|
||||
{
|
||||
OT_UNUSED_VARIABLE(aInstance);
|
||||
OT_UNUSED_VARIABLE(aBuffer);
|
||||
OT_UNUSED_VARIABLE(aLength);
|
||||
OT_UNUSED_VARIABLE(aDestAddress);
|
||||
|
||||
return OT_ERROR_ABORT;
|
||||
}
|
||||
|
||||
otError otPlatTrelUdp6SetTestMode(otInstance *aInstance, bool aEnable)
|
||||
{
|
||||
OT_UNUSED_VARIABLE(aInstance);
|
||||
OT_UNUSED_VARIABLE(aEnable);
|
||||
return OT_ERROR_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
#endif // OPENTHREAD_CONFIG_RADIO_LINK_TREL_ENABLE
|
||||
|
||||
} // extern "C"
|
||||
|
||||
Reference in New Issue
Block a user