willprice / python-omxplayer-wrapper

:tv: Control OMXPlayer, the Raspberry Pi media player, from Python
http://python-omxplayer-wrapper.readthedocs.io
GNU Lesser General Public License v3.0
253 stars 71 forks source link

DBus Cannot connect to the OMXPlayer process With --display 5 option (HDMI OUT) #187

Open ProdigyView opened 5 years ago

ProdigyView commented 5 years ago

Issue Report

Description

I get the standard "DBus cannot connect to the OMXPlayer process"). I am streaming the video from a url. My code is as follow:

     args = None

        if(audio == "local"):
          args = ["-o", "local"]
        else:
          args = ["-o", "hdmi"]

        args.append(["--display", "5"])

        path = "https://bw-videos-producition.s3-us-west-2.amazonaws.com/audio_preview_b3ace585-3327-4ca7-8905-db55dfdd5e4d.mp4"
        self.player = OMXPlayer(path,args=args, dbus_name='org.mpris.MediaPlayer2.omxplayer0')

The code is also run from inside a wx.Frame. What is also interesting about this issue is if I take the --display 5 out, which forces the pi to display via hdmi and not on screen(I have a touch screen), it works! It only fails with I am outputting to the hdmi out.

Environment details

Software Version
python-omxplayer-wrapper latest
python-dbus (dpkg -s python-dbus) 1.10.28-0+deb9u1
python (python --version) 3.5
omxplayer (omxplayer --version) f06235c