From 358374f9a6084ee57741678853b5ebf306661114 Mon Sep 17 00:00:00 2001 From: Jason Axelson Date: Wed, 16 Feb 2022 12:53:56 +0000 Subject: [PATCH] Explicitly list how to get scanned wifi points in docs For someone unfamiliar with VintageNet it previously wasn't clear how to get the scanned wifi access points --- lib/vintage_net.ex | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/vintage_net.ex b/lib/vintage_net.ex index e2a7cd44..6199ee24 100644 --- a/lib/vintage_net.ex +++ b/lib/vintage_net.ex @@ -315,9 +315,12 @@ defmodule VintageNet do Initiate an access point scan on a wireless interface The scan results are posted asynchronously to the `["interface", ifname, "wifi", "access_points"]` - property as they come in. It appears that there's some variation in how scanning - is implemented on WiFi adapters. One strategy that seems to work is to call `scan/1` every - 10 seconds or so while prompting a user to pick a WiFi network. + property as they come in. After waiting a second or two they can be fetched via + `VintageNet.get(["interface", ifname, "wifi", "access_points"])`. + + It appears that there's some variation in how scanning is implemented on WiFi adapters. One + strategy that seems to work is to call `scan/1` every 10 seconds or so while prompting a user to + pick a WiFi network. This is a utility function for calling the `:scan` ioctl. """