Forum: GNU Radio Cycle time calculation

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
895162eb8f65673b6eefca9e7e8acf62?d=identicon&s=25 Kaleem Ahmad (kaleem)
on 2009-03-17 12:10
(Received via mailing list)
Hello every one,

I am using USRP1 with RFX2400 daughter card.

I have a system (any state of the art system, let say Atmel's narroband
which works in 2.4 GHz band) transmitting a fixed packet cyclically (let
cycle time = T ms).

I want to use USRP system to sense the spectrum and calculate (or guess)
cycle time of this FSK system, and to do this I have following idea:

I am using to sense the spectrum with FFT = 512 at a fixed
center frequency (which must be exactly same as FSK system). Then I set
decimation rate = 160 , hence getting B = 400 kHz (FSK's B = 800 kHz).
start scanning the spectrum and in each scan it come up with 512 bins
and I
compare the max(of 512 bins) with a predefined threshold energy level.
I find this max energy above my predefined threshold value, I suppose
FSK is
detected, I save this number and start counting the number of scans
which do
not detect the FSK system (lets call it empty scan). After 'n'  empty
there is again a scan with FSK detection. In this way between two FSK
detected scans I calculate the value of 'n' empty scans. Now I already
that one 512 bin scan take 'K micrseconds', so I simply calculate the
time in the following way:

cycle tile = K(time for one scan) * n (no. of empty scans between two
detected scans)

BUT IT IS NOT WORKING!!!!!!!!!!!!!!!!!!!!

If 'p' stands for peak (the scan which detect the FSK system), and dots
represent empty scans, then I was expecting an output as follows:

>----n----<           >-----n---<               [all n's should be equal
because cycle time is fixed]
p . . . . . . p . . . . . .p . . . . . . p . . . . . . p

mean that after running for long time I would get the value of n (n=6 in
above example scenerio), the value of n would be almost same between any
peaks as shown in above scenerio. BUT I get following results:
   >----n---<     > n <       >---------n----------<  [all n's are not

Means that there is no consistency between the value of n between

*POSSIBLE REASONING: I guessed that one possible reason can be that
are multiple threads and the scan process is not really continues and
because of this some times the FSK system is not detected (because when
FSK system transmits the scanning thread is not executing??? Is it
possible)which makes some p's to disappear and hence leaving the length
intervals between different p's (value of n) unequal.????

Now I want your suggestions:

1- Is the thread sharing time so significant that above given reasoning
(*POSSIBLE REASONING) has some worth.
2- What other possiblitities can be there
3- Can you suggest some different way to solve this problem, The problem
simply to calculate the cycle time of some system which is already
in the environment

Thaks in advance and Best Regards
View this message in context:
Sent from the GnuRadio mailing list archive at
This topic is locked and can not be replied to.