popcornmix / omxplayer

omxplayer
GNU General Public License v2.0
1.01k stars 334 forks source link

System freezing when playing 1080p video for ~30 minutes on RPi Zero W. #711

Open 44670 opened 5 years ago

44670 commented 5 years ago

I am using omxplayer to play a 1080p h264 video on RPi Zero W, it works pretty good at the beginning. However, after playing for about 30~60 minutes, the screen will freeze. I think it is a system-wide freeze because the ssh connection will lose and the rpi will no longer respond pings.

I have allocated 192MB as gpu memory, the hdmi video mode is 1280x720 60p. A USB Speaker is connected and omxplayer was configured to use the alsa audio output.

Video file encoding information:


Video
ID                             : 1
Format                         : AVC
Format/Info                    : Advanced Video Codec
Format profile                 : High@L4.1
Format settings                : CABAC / 5 Ref Frames
Format settings, CABAC         : Yes
Format settings, ReFrames      : 5 frames
Codec ID                       : V_MPEG4/ISO/AVC
Duration                       : 1 h 46 min
Bit rate                       : 8 714 kb/s
Width                          : 1 920 pixels
Height                         : 808 pixels
Display aspect ratio           : 2.40:1
Frame rate mode                : Constant
Frame rate                     : 23.976 (24000/1001) FPS
Color space                    : YUV
Chroma subsampling             : 4:2:0
Bit depth                      : 8 bits
Scan type                      : Progressive
Bits/(Pixel*Frame)             : 0.234
Stream size                    : 6.47 GiB (74%)
Writing library                : x264 core 148 r2762 90a61ec
Encoding settings              : cabac=1 / ref=5 / deblock=1:-3:-3 / analyse=0x3:0x133 / me=umh / subme=9 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=2 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=0 / chroma_qp_offset=-2 / threads=18 / lookahead_threads=1 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=1 / b_bias=0 / direct=3 / weightb=1 / open_gop=0 / weightp=2 / keyint=250 / keyint_min=23 / scenecut=40 / intra_refresh=0 / rc_lookahead=50 / rc=2pass / mbtree=1 / bitrate=8714 / ratetol=1.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / ip_ratio=1.40 / aq=1:1.00
Language                       : English
Default                        : Yes
Forced                         : No

Memory usage when playing the video:

              total        used        free      shared  buff/cache   available
Mem:            305          79          30           2         195         174
Swap:             0           0           0

CPU usage of omxplayer.bin is ~27%

Omxplayer version:

omxplayer - Commandline multimedia player for the Raspberry Pi
        Build date: Fri, 07 Jun 2019 19:49:22 +0000
        Version   : f06235c [master]
        Repository: https://github.com/popcornmix/omxplayer.git

Linux kernel and RPi firmware are on the latest version (upgraded with rpi-upd).

micha1pu commented 5 years ago

Does it freeze with USB speaker disconnected? I had similar problem with freezing after 15-60minutes while i was using USB touchscreen connected without USB hub. After trying everything i switched USB driver in config.txt to dtoverlay=dwc2 and it stoped freezing.

44670 commented 5 years ago

Does it freeze with USB speaker disconnected? I had similar problem with freezing after 15-60minutes while i was using USB touchscreen connected without USB hub. After trying everything i switched USB driver in config.txt to dtoverlay=dwc2 and it stoped freezing.

Thanks, I will have a try.