Wouldn't it be better to discover why it's necessary to restart the service?
ie.
Is the program playing the files causing the service to screw up?
Try another program.
Is it a hardware or driver fault?
Check the Eventlog.
When the service screws up is it because it has stopped or it is running but still needs a restart?
Really need more info, it's easy to do a small PowerShell script to restart the service if its stopped but where it's still shown as running is probably going to be a little trickier since how would you know if it's being used or not?
EDIT: Can also restart the audio service using a command file, eg.
sc stop Audiosrv
ping 127.0.0.1 -n 10 >NUL
sc start Audiosrv
No checks, waits 10 seconds after stopping (ping command 10 times), then starts it.
Could add check for status with
sc query Audiosrv but I think it'd be better to find out why it's necessary in the first place.