File: fading_files.sh

package info (click to toggle)
codec2 1.0.5-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 121,056 kB
  • sloc: ansic: 414,118; sh: 2,612; objc: 2,574; python: 2,105; cpp: 2,091; asm: 683; makefile: 598
file content (14 lines) | stat: -rwxr-xr-x 596 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/usr/bin/env bash
#
# Generate fading files used for channel simulation

output_path=$1
echo "Generating fading files ......"
cmd='cd ../octave; pkg load signal; ch_fading("'${output_path}'/fast_fading_samples.float", 8000, 1.0, 8000*60)'
octave --no-gui -qf --eval "$cmd"
[ ! $? -eq 0 ] && { echo "octave failed to run correctly .... exiting"; exit 1; }
cmd='cd ../octave; pkg load signal; ch_fading("'${output_path}'/faster_fading_samples.float", 8000, 2.0, 8000*60)'
octave --no-gui -qf --eval "$cmd"
[ ! $? -eq 0 ] && { echo "octave failed to run correctly .... exiting"; exit 1; }
exit 0