Hi,
Without any other info the only thing that comes to mind is the lack of environment variables when running mplayer (and probably aplay) from the crontab. Mplayer needs some of these to work properly (not sure about aplay, but if I have to guess....).
One way of tackling this problem is by parsing your user profile from the script:
# Needed due to crontab issue: profile user not parsed
[[ "`/usr/bin/tty`" == "not a tty" ]] && . ~/.profile
This will check if the program is run from the command line or crontab and parses the user .profile if needed.
Hope this helps.
|