Atheros driver and radiotap reliability

Sam Leffler sam at errno.com
Mon Aug 29 23:59:14 GMT 2005


Sam Pierson wrote:
> Hi guys,
> 
> I'm trying to get an accurate measurement of signal strength (preferably 
> in dBm) on a per-packet basis between two atheros cards that I have.  I
> had some correspondence with the ethereal developers and David Young
> and apparently there is a bug in how ethereal handles the radiotap header.

News to me; the last time I checked it looked correct.

> David told me that tcpdump will correctly report whatever the device driver
> tells it is the correct signal signal strength, but not to trust it until the
> devices have been calibrated.  How does the ath driver report the signal
> strength in the radiotap header?   From tcpdump, it's giving me this value:
> 
> /* taken from /sys/net80211/ieee80211_radiotap.h */
>  * IEEE80211_RADIOTAP_DB_ANTSIGNAL      u_int8_t        decibel (dB)
>  *
>  *      RF signal power at the antenna, decibel difference from an
>  *      arbitrary, fixed reference.
> ...
> 
> In this same file, there is a u_int8_t ANTSIGNAL reported in dBm.  It appears
> as though everything is driver (and device, probably) dependent, so I'd like
> to know how the driver computes this value.  

The radiotap header includes the rssi returned by the hardware for rx'd 
frames.
                         sc->sc_rx_th.wr_antsignal = ds->ds_rxstat.rs_rssi;

Nothing is recorded for tx frames.  You can typically treat it as being 
in .5dBm units relative to the current noise floor.  Note however that 
there is currently no way to calibrate these values to physical units; 
doing that is not a simple matter.

> 
> As a side question, does anyone have an easier way to reliably measure 
> per-packet signal strength?   The area has a decent amount of traffic and 
> I have to be able to analyze the packets themselves, so a plain hardware
> solution will not do.  Thanks,

rssi is provided and is accurate.  If you want the rssi of the ack on 
xmit you need to collect that yourself from the tx descriptor when it's 
reaped.  The sample tx rate control algorithm uses it (for example).

	Sam


More information about the freebsd-hackers mailing list