mirror of
git://projects.qi-hardware.com/ben-wpan.git
synced 2024-11-04 23:14:06 +02:00
tools/dirtpan/dirtpan.c (open_net): turn off WPAN_WANTACK
The IEEE 802.15.4 kernel stack doesn't implement ACKs yet and prints a warning if we request them. Since dirtpan has its own ACKs, we just disable IEEE 802.15.4 ACKs for now.
This commit is contained in:
parent
a1a508e749
commit
171500e414
@ -435,6 +435,7 @@ static void event(void)
|
||||
static int open_net(uint16_t pan, uint16_t me, uint16_t peer)
|
||||
{
|
||||
struct sockaddr_ieee802154 addr;
|
||||
int zero = 0;
|
||||
int s;
|
||||
|
||||
s = socket(PF_IEEE802154, SOCK_DGRAM, 0);
|
||||
@ -459,6 +460,12 @@ static int open_net(uint16_t pan, uint16_t me, uint16_t peer)
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (setsockopt(s, SOL_IEEE802154, WPAN_WANTACK, &zero, sizeof(zero))
|
||||
< 0) {
|
||||
perror("setsockopt SOL_IEEE802154 WPAN_WANTACK");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
return s;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user