2

I am running this code

#!/usr/bin/env python2.7

cmd = "mplayer -slave -input file=/home/user/mplayer-control duha.mp4 -loop 3000"
import subprocess
process = subprocess.Popen(cmd.split(), stdout=subprocess.PIPE, stdin=subprocess.PIPE)
output = process.communicate()[0]

then in terminal I want to pause mplayer with echo "pause" > /home/user/mplayer-control But mplayer is not responding to my commands. What am I doing wrong?

peter
  • 4,289
  • 12
  • 44
  • 67

0 Answers0