audio=${10}
is correct. As the bash
manual says:
When a positional parameter consisting of more than a single digit is expanded, it must be enclosed in braces (see EXPANSION below).
The error is the line after that:
echo audio>/home/brftv/tiovar
It should be:
echo "$audio" > /home/brftv/tiovar
You forgot the $
.
I'm not sure why you're getting an empty file, you should be getting a file with the word "audio" in it.
BTW, you should use escapeshellarg
when putting URL parameters into a command line, otherwise you're opening yourself up to some serious injection problems.