diff options
Diffstat (limited to 'gr-radar-mono/src/utils')
-rw-r--r-- | gr-radar-mono/src/utils/calc_avg.m | 8 | ||||
-rw-r--r-- | gr-radar-mono/src/utils/czpad.m | 8 | ||||
-rw-r--r-- | gr-radar-mono/src/utils/echo_image.m | 6 | ||||
-rw-r--r-- | gr-radar-mono/src/utils/fftcorr.m | 4 | ||||
-rw-r--r-- | gr-radar-mono/src/utils/pulse | 396 | ||||
-rw-r--r-- | gr-radar-mono/src/utils/read_avg.m | 22 | ||||
-rw-r--r-- | gr-radar-mono/src/utils/read_avg_sec.m | 25 | ||||
-rw-r--r-- | gr-radar-mono/src/utils/read_echos.m | 7 |
8 files changed, 0 insertions, 476 deletions
diff --git a/gr-radar-mono/src/utils/calc_avg.m b/gr-radar-mono/src/utils/calc_avg.m deleted file mode 100644 index b240d245e..000000000 --- a/gr-radar-mono/src/utils/calc_avg.m +++ /dev/null @@ -1,8 +0,0 @@ -function avg = calc_avg(rlen, mintime) - avg = read_avg('echos.dat', rlen); - x = 1:rlen; - x = (x/64e6+mintime)*3e8/2; - plot(x, abs(avg), "^;Amplitude;"); - xlabel("Range (meters)"); - axis([max(x) 0]) -endfunction diff --git a/gr-radar-mono/src/utils/czpad.m b/gr-radar-mono/src/utils/czpad.m deleted file mode 100644 index e2131030d..000000000 --- a/gr-radar-mono/src/utils/czpad.m +++ /dev/null @@ -1,8 +0,0 @@ -# Center and zero pad v to length n -function pad = czpad(v, n) - c = n/2; - l = length(v); - pad(c-l/2+1:c+l/2) = v; - pad(c+l/2+1:n) = 0; -endfunction -
\ No newline at end of file diff --git a/gr-radar-mono/src/utils/echo_image.m b/gr-radar-mono/src/utils/echo_image.m deleted file mode 100644 index 2e066aef5..000000000 --- a/gr-radar-mono/src/utils/echo_image.m +++ /dev/null @@ -1,6 +0,0 @@ -function echo_image(filename, data) - d = abs(data); - d = d-min(min(d)); - d = d/(max(max(d)))*255; - pngwrite(filename, d, d, d, ones(size(d))); -endfunction
\ No newline at end of file diff --git a/gr-radar-mono/src/utils/fftcorr.m b/gr-radar-mono/src/utils/fftcorr.m deleted file mode 100644 index 548988973..000000000 --- a/gr-radar-mono/src/utils/fftcorr.m +++ /dev/null @@ -1,4 +0,0 @@ -# Perform circular correlation via FFT -function corr = fftcorr(v,ref) - corr = ifft(conj(fft(ref)).*fft(v)); -endfunction diff --git a/gr-radar-mono/src/utils/pulse b/gr-radar-mono/src/utils/pulse deleted file mode 100644 index 887558d1e..000000000 --- a/gr-radar-mono/src/utils/pulse +++ /dev/null @@ -1,396 +0,0 @@ -# Created by Octave 2.1.73, Tue Sep 25 14:17:22 2007 EDT <jcorgan@mobile> -# name: __nargin__ -# type: scalar -0 -# name: pulse321 -# type: complex matrix -# rows: 64 -# columns: 1 - (-0.0003662109375,0.9998779296875) - (-0.0003662109375,0.9998779296875) - (0,-0.9996337890625) - (0,-0.9996337890625) - (-0.0010986328125,-0.961181640625) - (-0.0010986328125,-0.961181640625) - (0.0072021484375,0.882568359375) - (0.0072021484375,0.882568359375) - (-0.0279541015625,-0.7666015625) - (-0.0279541015625,-0.7666015625) - (0.0765380859375,0.616943359375) - (0.0765380859375,0.616943359375) - (-0.1688232421875,-0.4447021484375) - (-0.1688232421875,-0.4447021484375) - (0.3212890625,0.26611328125) - (0.3212890625,0.26611328125) - (-0.54638671875,-0.1092529296875) - (-0.54638671875,-0.1092529296875) - (0.843994140625,0.012451171875) - (0.843994140625,0.012451171875) - (0.8046875,-0.019775390625) - (0.8046875,-0.019775390625) - (-0.444580078125,0.1688232421875) - (-0.444580078125,0.1688232421875) - (0.147705078125,-0.477294921875) - (0.147705078125,-0.477294921875) - (-0.0032958984375,0.921142578125) - (-0.0032958984375,0.921142578125) - (0.09228515625,0.5811767578125) - (0.09228515625,0.5811767578125) - (-0.4447021484375,-0.1688232421875) - (-0.4447021484375,-0.1688232421875) - (0.9996337890625,0.000244140625) - (0.9996337890625,0.000244140625) - (0.4127197265625,-0.19140625) - (0.4127197265625,-0.19140625) - (-0.0379638671875,0.728759765625) - (-0.0379638671875,0.728759765625) - (0.09228515625,0.5811767578125) - (0.09228515625,0.5811767578125) - (-0.617919921875,-0.0762939453125) - (-0.617919921875,-0.0762939453125) - (-0.6170654296875,0.0765380859375) - (-0.6170654296875,0.0765380859375) - (0.0621337890625,-0.654296875) - (0.0621337890625,-0.654296875) - (-0.127685546875,-0.511962890625) - (-0.127685546875,-0.511962890625) - (0.843994140625,0.012451171875) - (0.843994140625,0.012451171875) - (0.29296875,-0.293212890625) - (0.29296875,-0.293212890625) - (-0.01953125,-0.8046875) - (-0.01953125,-0.8046875) - (0.654296875,0.0618896484375) - (0.654296875,0.0618896484375) - (0.3505859375,-0.239990234375) - (0.3505859375,-0.239990234375) - (-0.0279541015625,-0.7666015625) - (-0.0279541015625,-0.7666015625) - (0.805419921875,0.01953125) - (0.805419921875,0.01953125) - (0.1688232421875,-0.444580078125) - (0.1688232421875,-0.444580078125) -# name: pulse325 -# type: complex matrix -# rows: 320 -# columns: 1 - (-0.0003662109375,0.9998779296875) - (-0.0003662109375,0.9998779296875) - (0,-0.9996337890625) - (0,-0.9996337890625) - (-0.0010986328125,-0.961181640625) - (-0.0010986328125,-0.961181640625) - (0.0072021484375,0.882568359375) - (0.0072021484375,0.882568359375) - (-0.0279541015625,-0.7666015625) - (-0.0279541015625,-0.7666015625) - (0.0765380859375,0.616943359375) - (0.0765380859375,0.616943359375) - (-0.1688232421875,-0.4447021484375) - (-0.1688232421875,-0.4447021484375) - (0.3212890625,0.26611328125) - (0.3212890625,0.26611328125) - (-0.54638671875,-0.1092529296875) - (-0.54638671875,-0.1092529296875) - (0.843994140625,0.012451171875) - (0.843994140625,0.012451171875) - (0.8046875,-0.019775390625) - (0.8046875,-0.019775390625) - (-0.444580078125,0.1688232421875) - (-0.444580078125,0.1688232421875) - (0.147705078125,-0.477294921875) - (0.147705078125,-0.477294921875) - (-0.0032958984375,0.921142578125) - (-0.0032958984375,0.921142578125) - (0.09228515625,0.5811767578125) - (0.09228515625,0.5811767578125) - (-0.4447021484375,-0.1688232421875) - (-0.4447021484375,-0.1688232421875) - (0.9996337890625,0.000244140625) - (0.9996337890625,0.000244140625) - (0.4127197265625,-0.19140625) - (0.4127197265625,-0.19140625) - (-0.0379638671875,0.728759765625) - (-0.0379638671875,0.728759765625) - (0.09228515625,0.5811767578125) - (0.09228515625,0.5811767578125) - (-0.617919921875,-0.0762939453125) - (-0.617919921875,-0.0762939453125) - (-0.6170654296875,0.0765380859375) - (-0.6170654296875,0.0765380859375) - (0.0621337890625,-0.654296875) - (0.0621337890625,-0.654296875) - (-0.127685546875,-0.511962890625) - (-0.127685546875,-0.511962890625) - (0.843994140625,0.012451171875) - (0.843994140625,0.012451171875) - (0.29296875,-0.293212890625) - (0.29296875,-0.293212890625) - (-0.01953125,-0.8046875) - (-0.01953125,-0.8046875) - (0.654296875,0.0618896484375) - (0.654296875,0.0618896484375) - (0.3505859375,-0.239990234375) - (0.3505859375,-0.239990234375) - (-0.0279541015625,-0.7666015625) - (-0.0279541015625,-0.7666015625) - (0.805419921875,0.01953125) - (0.805419921875,0.01953125) - (0.1688232421875,-0.444580078125) - (0.1688232421875,-0.444580078125) - (-0.1910400390625,-0.4127197265625) - (-0.1910400390625,-0.4127197265625) - (-0.6912841796875,0.049072265625) - (-0.6912841796875,0.049072265625) - (0.0009765625,0.9613037109375) - (0.0009765625,0.9613037109375) - (-0.8055419921875,-0.0194091796875) - (-0.8055419921875,-0.0194091796875) - (-0.076171875,0.6177978515625) - (-0.076171875,0.6177978515625) - (0.4771728515625,0.14794921875) - (0.4771728515625,0.14794921875) - (0.2144775390625,-0.3812255859375) - (0.2144775390625,-0.3812255859375) - (-0.3214111328125,-0.2659912109375) - (-0.3214111328125,-0.2659912109375) - (-0.29296875,0.293212890625) - (-0.29296875,0.293212890625) - (0.293212890625,0.29296875) - (0.293212890625,0.29296875) - (0.265869140625,-0.3212890625) - (0.265869140625,-0.3212890625) - (-0.3814697265625,-0.2144775390625) - (-0.3814697265625,-0.2144775390625) - (-0.1480712890625,0.4774169921875) - (-0.1480712890625,0.4774169921875) - (0.617919921875,0.0760498046875) - (0.617919921875,0.0760498046875) - (0.019287109375,-0.805419921875) - (0.019287109375,-0.805419921875) - (0.961181640625,-0.0009765625) - (0.961181640625,-0.0009765625) - (-0.049072265625,-0.6915283203125) - (-0.049072265625,-0.6915283203125) - (-0.412353515625,0.19091796875) - (-0.412353515625,0.19091796875) - (0.4444580078125,0.1689453125) - (0.4444580078125,0.1689453125) - (0.019287109375,-0.805419921875) - (0.019287109375,-0.805419921875) - (0.7664794921875,-0.02783203125) - (0.7664794921875,-0.02783203125) - (-0.2401123046875,-0.3507080078125) - (-0.2401123046875,-0.3507080078125) - (-0.06201171875,0.6541748046875) - (-0.06201171875,0.6541748046875) - (-0.804443359375,0.0194091796875) - (-0.804443359375,0.0194091796875) - (0.293212890625,0.29296875) - (0.293212890625,0.29296875) - (0.012451171875,-0.843994140625) - (0.012451171875,-0.843994140625) - (0.5118408203125,-0.127685546875) - (0.5118408203125,-0.127685546875) - (-0.6541748046875,-0.062255859375) - (-0.6541748046875,-0.062255859375) - (-0.07666015625,-0.6170654296875) - (-0.07666015625,-0.6170654296875) - (-0.076171875,0.6177978515625) - (-0.076171875,0.6177978515625) - (-0.581298828125,0.0921630859375) - (-0.581298828125,0.0921630859375) - (0.7286376953125,0.037841796875) - (0.7286376953125,0.037841796875) - (0.1912841796875,0.412353515625) - (0.1912841796875,0.412353515625) - (0,-0.9996337890625) - (0,-0.9996337890625) - (0.1688232421875,-0.444580078125) - (0.1688232421875,-0.444580078125) - (0.581298828125,-0.0924072265625) - (0.581298828125,-0.0924072265625) - (-0.9212646484375,-0.003662109375) - (-0.9212646484375,-0.003662109375) - (-0.4775390625,-0.1478271484375) - (-0.4775390625,-0.1478271484375) - (-0.1688232421875,-0.4447021484375) - (-0.1688232421875,-0.4447021484375) - (-0.01953125,-0.8046875) - (-0.01953125,-0.8046875) - (-0.012451171875,0.8438720703125) - (-0.012451171875,0.8438720703125) - (-0.109375,0.5462646484375) - (-0.109375,0.5462646484375) - (-0.26611328125,0.321533203125) - (-0.26611328125,0.321533203125) - (-0.444580078125,0.1688232421875) - (-0.444580078125,0.1688232421875) - (-0.6170654296875,0.0765380859375) - (-0.6170654296875,0.0765380859375) - (-0.7666015625,0.02783203125) - (-0.7666015625,0.02783203125) - (-0.882568359375,0.00732421875) - (-0.882568359375,0.00732421875) - (-0.9613037109375,0.0010986328125) - (-0.9613037109375,0.0010986328125) - (0.9996337890625,0.000244140625) - (0.9996337890625,0.000244140625) - (0.9996337890625,0.000244140625) - (0.9996337890625,0.000244140625) - (-0.9613037109375,0.0010986328125) - (-0.9613037109375,0.0010986328125) - (-0.882568359375,0.00732421875) - (-0.882568359375,0.00732421875) - (-0.7666015625,0.02783203125) - (-0.7666015625,0.02783203125) - (-0.6170654296875,0.0765380859375) - (-0.6170654296875,0.0765380859375) - (-0.444580078125,0.1688232421875) - (-0.444580078125,0.1688232421875) - (-0.26611328125,0.321533203125) - (-0.26611328125,0.321533203125) - (-0.109375,0.5462646484375) - (-0.109375,0.5462646484375) - (-0.012451171875,0.8438720703125) - (-0.012451171875,0.8438720703125) - (-0.01953125,-0.8046875) - (-0.01953125,-0.8046875) - (-0.1688232421875,-0.4447021484375) - (-0.1688232421875,-0.4447021484375) - (-0.4775390625,-0.1478271484375) - (-0.4775390625,-0.1478271484375) - (-0.9212646484375,-0.003662109375) - (-0.9212646484375,-0.003662109375) - (0.581298828125,-0.0924072265625) - (0.581298828125,-0.0924072265625) - (0.1688232421875,-0.444580078125) - (0.1688232421875,-0.444580078125) - (0,-0.9996337890625) - (0,-0.9996337890625) - (0.1912841796875,0.412353515625) - (0.1912841796875,0.412353515625) - (0.7286376953125,0.037841796875) - (0.7286376953125,0.037841796875) - (-0.581298828125,0.0921630859375) - (-0.581298828125,0.0921630859375) - (-0.076171875,0.6177978515625) - (-0.076171875,0.6177978515625) - (-0.07666015625,-0.6170654296875) - (-0.07666015625,-0.6170654296875) - (-0.6541748046875,-0.062255859375) - (-0.6541748046875,-0.062255859375) - (0.5118408203125,-0.127685546875) - (0.5118408203125,-0.127685546875) - (0.012451171875,-0.843994140625) - (0.012451171875,-0.843994140625) - (0.293212890625,0.29296875) - (0.293212890625,0.29296875) - (-0.804443359375,0.0194091796875) - (-0.804443359375,0.0194091796875) - (-0.06201171875,0.6541748046875) - (-0.06201171875,0.6541748046875) - (-0.2401123046875,-0.3507080078125) - (-0.2401123046875,-0.3507080078125) - (0.7664794921875,-0.02783203125) - (0.7664794921875,-0.02783203125) - (0.019287109375,-0.805419921875) - (0.019287109375,-0.805419921875) - (0.4444580078125,0.1689453125) - (0.4444580078125,0.1689453125) - (-0.412353515625,0.19091796875) - (-0.412353515625,0.19091796875) - (-0.049072265625,-0.6915283203125) - (-0.049072265625,-0.6915283203125) - (0.961181640625,-0.0009765625) - (0.961181640625,-0.0009765625) - (0.019287109375,-0.805419921875) - (0.019287109375,-0.805419921875) - (0.617919921875,0.0760498046875) - (0.617919921875,0.0760498046875) - (-0.1480712890625,0.4774169921875) - (-0.1480712890625,0.4774169921875) - (-0.3814697265625,-0.2144775390625) - (-0.3814697265625,-0.2144775390625) - (0.265869140625,-0.3212890625) - (0.265869140625,-0.3212890625) - (0.293212890625,0.29296875) - (0.293212890625,0.29296875) - (-0.29296875,0.293212890625) - (-0.29296875,0.293212890625) - (-0.3214111328125,-0.2659912109375) - (-0.3214111328125,-0.2659912109375) - (0.2144775390625,-0.3812255859375) - (0.2144775390625,-0.3812255859375) - (0.4771728515625,0.14794921875) - (0.4771728515625,0.14794921875) - (-0.076171875,0.6177978515625) - (-0.076171875,0.6177978515625) - (-0.8055419921875,-0.0194091796875) - (-0.8055419921875,-0.0194091796875) - (0.0009765625,0.9613037109375) - (0.0009765625,0.9613037109375) - (-0.6912841796875,0.049072265625) - (-0.6912841796875,0.049072265625) - (-0.1910400390625,-0.4127197265625) - (-0.1910400390625,-0.4127197265625) - (0.1688232421875,-0.444580078125) - (0.1688232421875,-0.444580078125) - (0.805419921875,0.01953125) - (0.805419921875,0.01953125) - (-0.0279541015625,-0.7666015625) - (-0.0279541015625,-0.7666015625) - (0.3505859375,-0.239990234375) - (0.3505859375,-0.239990234375) - (0.654296875,0.0618896484375) - (0.654296875,0.0618896484375) - (-0.01953125,-0.8046875) - (-0.01953125,-0.8046875) - (0.29296875,-0.293212890625) - (0.29296875,-0.293212890625) - (0.843994140625,0.012451171875) - (0.843994140625,0.012451171875) - (-0.127685546875,-0.511962890625) - (-0.127685546875,-0.511962890625) - (0.0621337890625,-0.654296875) - (0.0621337890625,-0.654296875) - (-0.6170654296875,0.0765380859375) - (-0.6170654296875,0.0765380859375) - (-0.617919921875,-0.0762939453125) - (-0.617919921875,-0.0762939453125) - (0.09228515625,0.5811767578125) - (0.09228515625,0.5811767578125) - (-0.0379638671875,0.728759765625) - (-0.0379638671875,0.728759765625) - (0.4127197265625,-0.19140625) - (0.4127197265625,-0.19140625) - (0.9996337890625,0.000244140625) - (0.9996337890625,0.000244140625) - (-0.4447021484375,-0.1688232421875) - (-0.4447021484375,-0.1688232421875) - (0.09228515625,0.5811767578125) - (0.09228515625,0.5811767578125) - (-0.0032958984375,0.921142578125) - (-0.0032958984375,0.921142578125) - (0.147705078125,-0.477294921875) - (0.147705078125,-0.477294921875) - (-0.444580078125,0.1688232421875) - (-0.444580078125,0.1688232421875) - (0.8046875,-0.019775390625) - (0.8046875,-0.019775390625) - (0.843994140625,0.012451171875) - (0.843994140625,0.012451171875) - (-0.54638671875,-0.1092529296875) - (-0.54638671875,-0.1092529296875) - (0.3212890625,0.26611328125) - (0.3212890625,0.26611328125) - (-0.1688232421875,-0.4447021484375) - (-0.1688232421875,-0.4447021484375) - (0.0765380859375,0.616943359375) - (0.0765380859375,0.616943359375) - (-0.0279541015625,-0.7666015625) - (-0.0279541015625,-0.7666015625) - (0.0072021484375,0.882568359375) - (0.0072021484375,0.882568359375) - (-0.0010986328125,-0.961181640625) - (-0.0010986328125,-0.961181640625) diff --git a/gr-radar-mono/src/utils/read_avg.m b/gr-radar-mono/src/utils/read_avg.m deleted file mode 100644 index 7df3d4cdd..000000000 --- a/gr-radar-mono/src/utils/read_avg.m +++ /dev/null @@ -1,22 +0,0 @@ -function avg = read_avg(name, vlen) - - f = fopen(name, "rb"); - s = zeros(1, vlen); - n = 0; - - while (!feof(f)) - t = fread(f, [2, vlen], "float"); - if (size(t) == [2, vlen]) - n = n+1; - c = t(1,:)+t(2,:)*j; - if (n > 10) - s = s+c; - endif - endif - endwhile - - avg = s/(n-1); - - fclose(f); - -endfunction diff --git a/gr-radar-mono/src/utils/read_avg_sec.m b/gr-radar-mono/src/utils/read_avg_sec.m deleted file mode 100644 index 7aa77675d..000000000 --- a/gr-radar-mono/src/utils/read_avg_sec.m +++ /dev/null @@ -1,25 +0,0 @@ -function avg = read_avg_sec(name, vlen) - - f = fopen(name, "rb"); - s = zeros(1, vlen); - n = 0; - m = 0; - - while (!feof(f)) - t = fread(f, [2, vlen], "float"); - if (size(t) == [2, vlen]) - n = n+1; - c = t(1,:)+t(2,:)*j; - s = s+c; - m = m+1; - if (m == 1000) - avg(n/1000,:) = s/1000; - s = zeros(1, vlen); - m = 0; - endif - endif - endwhile - - fclose(f); - -endfunction diff --git a/gr-radar-mono/src/utils/read_echos.m b/gr-radar-mono/src/utils/read_echos.m deleted file mode 100644 index 3fae47b4e..000000000 --- a/gr-radar-mono/src/utils/read_echos.m +++ /dev/null @@ -1,7 +0,0 @@ -# Read echos from file into array -function echos = read_echos(filename, len, drop) - e = read_complex_binary(filename); - n = length(e)/len-drop; - start = drop*len+1; - echos = reshape(e(start:end), len, n).'; -endfunction |