mirror of
git://projects.qi-hardware.com/ben-wpan.git
synced 2024-11-22 13:32:28 +02:00
fix glitch in fft.c and add scripts to display data sets without temp file
- usrp/doall: new script to directly evaluate and plot data sets - usrp/fft.c (fft_complex): don't square the magnitude - usrp/plscan: if an argument name has the form title=name, use "name" as the file name and "title" as the title
This commit is contained in:
parent
404a0eea04
commit
eafb2a226f
11
usrp/doall
Executable file
11
usrp/doall
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/bash -x
|
||||
opts=
|
||||
while [ "$2" ]; do
|
||||
opts="$opts $1"
|
||||
shift
|
||||
done
|
||||
a=
|
||||
for n in $1; do
|
||||
a="$a `basename $n`=<(./evscan $n)"
|
||||
done
|
||||
eval ./plscan $opts $a
|
@ -32,7 +32,7 @@ static void fft_complex(int n, const float *re, const float *im, double *res)
|
||||
|
||||
for (i = 0; i != n; i++) {
|
||||
a = hypot(out[i][0], out[i][1])/n;
|
||||
a = a*a;
|
||||
// a = a*a;
|
||||
res[i] = a;
|
||||
}
|
||||
}
|
||||
|
@ -24,7 +24,14 @@ set title "Received signal strength"
|
||||
set data style errorlines
|
||||
plot \
|
||||
`for n in $@; do
|
||||
echo -n $comma \'$n\' title \'${n%.*}\'
|
||||
if [ "$n" = "${n#*=}" ]; then
|
||||
file=$n
|
||||
title=${n%.*}
|
||||
else
|
||||
file=${n#*=}
|
||||
title=${n%%=*}
|
||||
fi
|
||||
echo -n $comma \'$file\' title \'$title\'
|
||||
comma=,
|
||||
done`
|
||||
EOF
|
||||
|
Loading…
Reference in New Issue
Block a user