From: James Cameron <quozl@laptop.org>
To: Shengrong Yin <syin@uh.edu>
Cc: linux-wireless@vger.kernel.org
Subject: Re: How to set a scan on a given frequency
Date: Tue, 1 Sep 2015 12:53:08 +1000 [thread overview]
Message-ID: <20150901025307.GE1329@us.netrek.org> (raw)
In-Reply-To: <CAAGWusB5n7=62VFdq-=h7BsP3fkwnG6dvjFdixL_SPBhw06S3A@mail.gmail.com>
On Mon, Aug 31, 2015 at 03:53:18PM -0500, Shengrong Yin wrote:
> Hello,
>
> I was using iw to scan a given frequency.
> For example,
> iw wlan0 scan freq 2412 | grep freq:
> However, the result was scanned ssids with different frequencies
> across 2.4 GHz band, which is
> freq: 2462
> freq: 2462
> freq: 2437
> freq: 2412
> ...
> Why this happened? Shouldn't it return only the ssid with 2412?
No. A radio receiver in a wireless device can receive beacons on
adjacent frequencies to the frequency it is tuned for. The signal
strength will be lower, but not low enough to prevent receive.
If you want to restrict results to the frequency you are interested
in, then filter the data after you have received it from the kernel.
But the data returned to you isn't the frequency of the received radio
burst, but is the frequency value in the beacon packet. Usually this
is the same, but faulty devices, deceptive devices, or high speed
movement could make it different.
You should specify a frequency in your scan request if you can,
because it shortens the time taken by the scan. If you do not specify
a frequency, then the scan must be repeated for every channel. There
is a time cost for switching, and a time spent listening on each
channel.
--
James Cameron
http://quozl.linux.org.au/
next prev parent reply other threads:[~2015-09-01 2:53 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-31 20:53 How to set a scan on a given frequency Shengrong Yin
2015-09-01 2:53 ` James Cameron [this message]
2015-09-02 4:48 ` Luca Coelho
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150901025307.GE1329@us.netrek.org \
--to=quozl@laptop.org \
--cc=linux-wireless@vger.kernel.org \
--cc=syin@uh.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).