svn commit: r237520 - user/adrian/ath_radar_stuff/lib/libradarpkt
Adrian Chadd
adrian at FreeBSD.org
Sun Jun 24 06:00:29 UTC 2012
Author: adrian
Date: Sun Jun 24 06:00:29 2012
New Revision: 237520
URL: http://svn.freebsd.org/changeset/base/237520
Log:
Use the "right" RSSI for AR9280, so the RSSI value is positive rather
than the radiotap generated signal level.
Modified:
user/adrian/ath_radar_stuff/lib/libradarpkt/ar9280_radar.c
Modified: user/adrian/ath_radar_stuff/lib/libradarpkt/ar9280_radar.c
==============================================================================
--- user/adrian/ath_radar_stuff/lib/libradarpkt/ar9280_radar.c Sun Jun 24 05:59:32 2012 (r237519)
+++ user/adrian/ath_radar_stuff/lib/libradarpkt/ar9280_radar.c Sun Jun 24 06:00:29 2012 (r237520)
@@ -65,7 +65,7 @@ ar9280_radar_decode(struct ieee80211_rad
* XXX which rssi should we use?
* XXX ext rssi?
*/
- comb_rssi = rx->wr_antsignal;
+ comb_rssi = rx->wr_v.vh_rssi; /* Combined RSSI */
pri_rssi = rx->wr_v.rssi_ctl[0];
ext_rssi = rx->wr_v.rssi_ext[0];
nf = rx->wr_antnoise;
@@ -76,6 +76,15 @@ ar9280_radar_decode(struct ieee80211_rad
return (0);
}
+ /*
+ * XXX TODO: there's lots of other things that need to be
+ * done with the RSSI and pulse durations. It's quite likely
+ * that the pkt format should just have all of those
+ * (pri/ext/comb RSSI, flags, pri/ext pulse duration) and then
+ * the "decided" values to match the logic in the current
+ * HAL/DFS code, so they can all be plotted as appropriate.
+ */
+
#if 0
printf("tsf: %lld", tsf);
printf(" len: %d", len);
@@ -91,10 +100,10 @@ ar9280_radar_decode(struct ieee80211_rad
#endif
re->re_timestamp = tsf;
- re->re_rssi = comb_rssi; /* XXX extension rssi? */
+ re->re_rssi = pri_rssi; /* XXX extension rssi? */
re->re_dur = pkt[len - 3]; /* XXX extension duration? */
+ re->re_freq = 0;
/* XXX flags? */
- /* XXX freq? */
return(1);
}
More information about the svn-src-user
mailing list