Skip to content

Instantly share code, notes, and snippets.

@lofaldli
Last active December 2, 2024 09:06
Show Gist options
  • Select an option

  • Save lofaldli/8e46b92bbd9d2fbbaa9f8f2ee70dae55 to your computer and use it in GitHub Desktop.

Select an option

Save lofaldli/8e46b92bbd9d2fbbaa9f8f2ee70dae55 to your computer and use it in GitHub Desktop.
convert wave files to custom format used by MMSSTV (http://hamsoft.ca/pages/mmsstv.php)
#!/usr/bin/env bash
[ $# -eq 0 ] && { echo "no inputfile given"; exit 1; }
[ ! -f $1 ] && { echo "file $1 not found"; exit 1; }
printf "\x55\xaa\x00\x00" > /tmp/header.mmv
ffmpeg -ac 1 -ar 11025 -f s16le -acodec pcm_s16le -loglevel quiet -y -i $1 /tmp/data.mmv
cat /tmp/header.mmv /tmp/data.mmv > $1.mmv
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment