dpp-nfc: Update listen channel based on channel list when writing a tag
Do not use the hardcoded channel 1 (2412 MHz) with DPP_LISTEN if a channel list is specified when writing an NFC Tag. Instead, pick the first channel from that list as the listen channel. Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
This commit is contained in:
parent
66ffe9d246
commit
315422196a
1 changed files with 2 additions and 0 deletions
|
@ -202,6 +202,8 @@ def wpas_get_nfc_uri(start_listen=True, pick_channel=False, chan_override=None):
|
||||||
chan = chan_override
|
chan = chan_override
|
||||||
else:
|
else:
|
||||||
chan = chanlist
|
chan = chanlist
|
||||||
|
if chan and chan.startswith("81/"):
|
||||||
|
listen_freq = int(chan[3:].split(',')[0]) * 5 + 2407
|
||||||
if chan is None and get_status_field(wpas, "bssid[0]"):
|
if chan is None and get_status_field(wpas, "bssid[0]"):
|
||||||
freq = get_status_field(wpas, "freq")
|
freq = get_status_field(wpas, "freq")
|
||||||
if freq:
|
if freq:
|
||||||
|
|
Loading…
Reference in a new issue