質問

Hardware: Beaglebone + LCD cap

OS: Ubuntu 12.10

Problem: Basic java app that sets the background to a color - won't run from command line:

Exception in thread "main" java.lang.InternalError: Can't connect to X11 window server using '0.0' as the value of the DISPLAY variable....

How do I export DISPLAY so that my java app will access the LCD cape? (I presume that is the problem)

Thanks in advance.

役に立ちましたか?

解決

You probably need to at least invoke 'xhost +' from a terminal invoked in the graphical shell. There's probably some way to make that the default, but generally X11 disables access from other consoles that aren't the GUI login console until you invoke that command.

To get it to work at boot time, you can check out this thread or this thread. I think what would likely work best for you is to add to your .xinitrc file:

xhost +local:
ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top