netlib: Get and/or set PAN ID of IEEE 802.15.4 radio.

This commit is contained in:
Gregory Nutt
2017-04-21 14:55:24 -06:00
parent 874553ee59
commit 450f962602
3 changed files with 7 additions and 10 deletions

View File

@@ -46,6 +46,7 @@
#include <string.h>
#include <errno.h>
#include "wireless/ieee802154.h"
#include "netutils/netlib.h"
#if defined(CONFIG_NET_6LOWPAN) && CONFIG_NSOCKET_DESCRIPTORS > 0
@@ -80,13 +81,10 @@ int netlib_getpanid(FAR const char *ifname, FAR uint16_t *panid)
int sockfd = socket(PF_INET6, NETLIB_SOCK_IOCTL, 0);
if (sockfd >= 0)
{
/* Put the driver name into the request */
#warning Missing logic
/* Perform the ioctl to get the current PAN ID */
/* Use the helper provided in libradio */
ret = ieee802154_getpanid(sockfd, ifname, panid);
close(sockfd);
/* Reuturn the current PAN ID */
}
}