4 releases

0.2.2 Nov 30, 2024
0.2.1 Jan 25, 2021
0.2.0 Jan 25, 2021
0.1.0 Jan 25, 2021

#1382 in Network programming

Download history 61/week @ 2024-09-28 48/week @ 2024-10-05 69/week @ 2024-10-12 38/week @ 2024-10-19 32/week @ 2024-10-26 30/week @ 2024-11-02 21/week @ 2024-11-09 31/week @ 2024-11-16 33/week @ 2024-11-23 294/week @ 2024-11-30 84/week @ 2024-12-07 49/week @ 2024-12-14 141/week @ 2024-12-21 82/week @ 2024-12-28 67/week @ 2025-01-04 50/week @ 2025-01-11

345 downloads per month
Used in 2 crates

Apache-2.0

23KB
456 lines

tokio-wifiscanner

The project is a simple tokio wrapper around wifiscanner library.

Usage

This crate is on crates.io and can be used by adding tokio-wifiscanner to the dependencies in your project's Cargo.toml.

[dependencies]
tokio-wifiscanner = "0.2.*"

and this to your crate root:

extern crate tokio_wifiscanner;

Example

#[tokio::main(flavor = "current_thread")]
async fn main() {
    let networks = tokio_wifiscanner::scan().await.expect("Cannot scan network");
    for network in networks {
        println!(
            "{} {:15} {:10} {:4} {}",
            network.mac, network.ssid, network.channel, network.signal_level, network.security
        );
    }
}

Alternatively if you've cloned the Git repo, you can run the above example using: cargo run --example scan.


lib.rs:

A crate to list WiFi hotspots in your area.

As of v0.5.x now supports macOS, Linux and Windows. 🎉

Usage

This crate is on crates.io and can be used by adding tokio-wifiscanner to the dependencies in your project's Cargo.toml.

[dependencies]
tokio-wifiscanner = "0.2.*"

and this to your crate root:

extern crate tokio_wifiscanner;

Example

#[tokio::main(flavor = "current_thread")]
async fn main() {
   let networks = tokio_wifiscanner::scan().await.expect("Cannot scan network");
   for network in networks {
       println!(
           "{} {:15} {:10} {:4} {}",
           network.mac, network.ssid, network.channel, network.signal_level, network.security
       );
   }
}

Alternatively if you've cloned the the Git repo, you can run the above examples using: cargo run --example scan.

Dependencies

~5–15MB
~172K SLoC