svn commit: r245180 - user/adrian/ath_radar_stuff/lib/libradarpkt

Adrian Chadd adrian at FreeBSD.org
Tue Jan 8 21:37:32 UTC 2013


Author: adrian
Date: Tue Jan  8 21:37:31 2013
New Revision: 245180
URL: http://svnweb.freebsd.org/changeset/base/245180

Log:
  Use the right number of HT20 samples when calculating stuff.

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	Tue Jan  8 21:37:14 2013	(r245179)
+++ user/adrian/ath_radar_stuff/lib/libradarpkt/ar9280_radar.c	Tue Jan  8 21:37:31 2013	(r245180)
@@ -63,6 +63,8 @@
 #define	AR9280_SPECTRAL_SAMPLE_SIZE_HT20	60
 #define	AR9280_SPECTRAL_SAMPLE_SIZE_HT40	135
 
+#define	NUM_SPECTRAL_ENTRIES_HT20		56
+
 /*
  * GPLed snippet from Zefir on the linux-wireless list; rewrite this
  * soon!
@@ -85,8 +87,8 @@
 int
 convert_data_ht20(struct radar_entry *re, struct radar_fft_entry *fe)
 {
-	int dc_pwr_idx = AR9280_SPECTRAL_SAMPLE_SIZE_HT20 / 2;
-	int pwr_count = AR9280_SPECTRAL_SAMPLE_SIZE_HT20;
+	int dc_pwr_idx = NUM_SPECTRAL_ENTRIES_HT20 / 2;
+	int pwr_count = NUM_SPECTRAL_ENTRIES_HT20;
 	int i;
 	int nf0 = -96;	/* XXX populate re with this first! */
 	float bsum = 0.0;


More information about the svn-src-user mailing list