← Back to team overview

mythbuntu-bugs team mailing list archive

[Bug 1308105] Re: Xfce resets TV mode to NULL when power cycled

 

I've spent a good amount of hours researching and making tests,
unfortunately I can't make it work and I'm really desperate, so I'd
really thank any help.

I hope someone can lend me a hand (mainly on the procedures of patches of alexander and sean, I can't make them work).
----

The script of first solution works (in my case replacing HDMI-0 with HDMI1), I create it in ~/fixhdmi.sh and chmod 755 it.
 
The question here is automating the process, and in this I've not been able to, It only works running script manually from terminal (I've no try to make a shortcut, it's not valid for my needs) :(

I even added a wait time before the process (since the TV takes some
time in beign ready I thought it could help) and a message after with
zenity:

[code]#!/bin/sh
#Fix TV state when HDMI link is lost.
#By Mario Limonciello <email address hidden>
sleep 10
OUTPUT="HDMI1"
BAD_MODE="1280x720"
GOOD_MODE="1920x1080"

for MODE in $BAD_MODE $GOOD_MODE; do
 DISPLAY=:0 xrandr --output $OUTPUT --mode $MODE
 sleep 2
done
zenity --info --title="HDMI" --text="fixhdmi.sh has been executed"
[/code]

I've found a few entries explaining the procedure of udev, so I've
create a the file /etc/udev/rules.d/hdmi.rules with this content

[code]KERNEL=="card0", SUBSYSTEM=="drm", ACTION=="change",
RUN+="/home/fkervin/fixhdmi.sh[/code]

I also tryed:
[code]SUBSYSTEM=="drm", ACTION=="change", RUN+="/home/fkervin/fixhdmi.sh[/code]

I tried another ones I don't remember...

The result without the udev entry is "no signal message", with it I have
cursor on screen over black for a seconds but then dissapear and "no
signal" message again. It makes me think that

the udev could be working on TV disconnect but not on connect (only an
idea). Later when I tried the alexander's mod I had the same effect,
(cursor and blank screen), I don't how it there is any relation.

I've try udevadm in a power-off/power-on of the TV, having this result:

[code]
fkervin@fkervin:~$ sudo udevadm monitor
[sudo] password for fkervin: 
monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[121.525065] change   /devices/pci0000:00/0000:00:02.0/drm/card0 (drm)
UDEV  [135.590008] change   /devices/pci0000:00/0000:00:02.0/drm/card0 (drm)
KERNEL[142.156140] change   /devices/pci0000:00/0000:00:02.0/drm/card0 (drm)
UDEV  [156.226634] change   /devices/pci0000:00/0000:00:02.0/drm/card0 (drm)
[/code]

I can't figure out how to make udev rule work :(

-----

I've try to install Xfce 4.12 packages:

[code]
sudo add-apt-repository ppa:xubuntu-dev/xfce-4.12
sudo apt-get update
sudo apt-get upgrade
[/code]

It unfortunately doesn't solve the problem.

------

killing xfsettingsd makes it work, but since it interfere on the icons,
text and many elements, it's not appropiate.

------

In the option of installing an older xfce4-settings:

by adding the saucy mirrors to you sources.list, and running apt-get
update && apt-get install xfce4-settings/saucy or apt-get -t saucy
install xfce4-settings

I don't know what should I add to sources.list.

------

Alexander and sean's procedures:
I've try several times with no results, for example:

fkervin@fkervin:~$ sudo apt-get install xfce4-dev-tools libexo-1-dev libgarcon-1-0-dev libxfce4ui-1-dev
Result in pastebin: [url]http://pastebin.com/eWsYxqY7[/url]

fkervin@fkervin:~$ git clone git://git.xfce.org/xfce/xfce4-settings
[code]Cloning into 'xfce4-settings'...
remote: Counting objects: 11824, done.
remote: Compressing objects: 100% (5517/5517), done.
remote: Total 11824 (delta 9542), reused 7817 (delta 6301)
Receiving objects: 100% (11824/11824), 4.66 MiB | 3.55 MiB/s, done.
Resolving deltas: 100% (9542/9542), done.
Checking connectivity... done.[/code]

fkervin@fkervin:~$ cd xfce4-settings

fkervin@fkervin:~/xfce4-settings$ curl [url]https://bugzilla.xfce.org/attachment.cgi?id=5681[/url] > alexander-patch.diff
[code]  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
fkervin@fkervin:~/xfce4-settings$ [/code]


elhtpc@elhtpc:~/xfce4-settings$ patch -p1 < alexander-patch.diff
(this command returns nothing)

fkervin@fkervin:~/xfce4-settings$ ./autogen.sh && make && sudo make install
result: [url]http://pastebin.com/ig8GSefj[/url]

I also tried as you suggested me, sixsixfive:
./autogen.sh --prefix=/usr && make && sudo checkinstall

fkervin@fkervin:~/xfce4-settings$ /usr/local/bin/xfsettingsd --replace
[code]fkervin@fkervin:~/xfce4-settings$ /usr/share/themes/Cratos-lion/gtk-2.0/gtkrc:269: Unable to locate image file in pixmap_path: "Range/null.png"
/usr/share/themes/Cratos-lion/gtk-2.0/gtkrc:272: Background image options specified without filename

(xfsettingsd:11819): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks",
/usr/share/themes/Cratos-lion/gtk-2.0/gtkrc:537: Unable to locate image file in pixmap_path: "Handles/handle-vert-paned.png"
/usr/share/themes/Cratos-lion/gtk-2.0/gtkrc:544: Background image options specified without filename
/usr/share/themes/Cratos-lion/gtk-2.0/apps/scrollbar_lion.rc:85: Unable to locate image file in pixmap_path: "Scrollbars/slider-horiz-insens.png"
/usr/share/themes/Cratos-lion/gtk-2.0/apps/scrollbar_lion.rc:93: Background image options specified without filename
/usr/share/themes/Cratos-lion/gtk-2.0/apps/midori.rc:114: Unable to locate image file in pixmap_path: "/Handle/handle-thunar.png"
/usr/share/themes/Cratos-lion/gtk-2.0/apps/midori.rc:117: Background image options specified without filename
/usr/share/themes/Cratos-lion/gtk-2.0/apps/midori.rc:161: error: invalid string constant "pixmap-sidebar-handle-left", expected valid string constant
DBG[workspaces.c:456] xfce_workspaces_helper_wait_for_window_manager_destroyed(): found window manager after 1 tries[/code]

In this point terminal gets frozen and I have to open a new one. I have
to say that in this point (/usr/local/bin/xfsettings --replace) many
times the system told there was not such file or directory

elhtpc@elhtpc:~/xfce4-settings$ sudo make uninstall
result: [url]http://pastebin.com/ZgwLrNii[/url]

I think that in this procedure I can be failing in some obvious thing,
I'm doing something wrong, but I don't know what is.


Many thanks

-- 
You received this bug notification because you are a member of Mythbuntu
Bug Team, which is subscribed to Mythbuntu.
https://bugs.launchpad.net/bugs/1308105

Title:
  Xfce resets TV mode to NULL when power cycled

Status in Mythbuntu, Ubuntu derivative focused upon MythTV:
  Confirmed
Status in xfce4-settings:
  Confirmed
Status in nvidia-graphics-drivers package in Ubuntu:
  Invalid
Status in nvidia-graphics-drivers-331 package in Ubuntu:
  Invalid
Status in xfce4-settings package in Ubuntu:
  Confirmed

Bug description:
  I had an HTPC with Mythbuntu 12.04 installed.  Upon upgrading a new
  behavior that if the TV is power cycled it no longer detects a link
  with the HTPC.

  When this happens I can find in the xorg log that there is an
  accompanying log item:

  [ 39829.509] (II) NVIDIA(0): Setting mode "NULL"

  After debugging with NVIDIA at
  https://devtalk.nvidia.com/default/topic/729955/linux/tv-stops-being-
  detected/ we've deteremined it's a X client that reacts to the RANDR
  events causing the mode to be set to NULL.

  Working through the list in an Xfce environment, the culprit is
  xfsettingsd.  If xfsettingsd is running, it causes the TV to come up
  in a NULL mode.  If it's killed, it remains in the mode it was
  previously running in.

  
  Until this is fixed, this behavior can be worked around with a simple shell script:
  ==============================
  #!/bin/sh
  #Fix TV state when HDMI link is lost.
  #By Mario Limonciello <superm1@xxxxxxxxxx>

  OUTPUT="HDMI-0"
  BAD_MODE="1280x720"
  GOOD_MODE="1920x1080"

  for MODE in $BAD_MODE $GOOD_MODE; do
   DISPLAY=:0 xrandr --output $OUTPUT --mode $MODE
   sleep 2
  done
  ==============================

To manage notifications about this bug go to:
https://bugs.launchpad.net/mythbuntu/+bug/1308105/+subscriptions