At initialization

Issues at initialization time can be a result of problems in the drivers, or your graphics configuration.

Configuration

Configuration file

Before starting Screen, it's a good idea to check your configuration file to make sure that it's what you expect it to be. For example, from a shell prompt on your target:

# cat /usr/lib/graphics/imx6x/graphics.conf
            

You can usually find the configuration file, graphics.conf, on your target under /usr/lib/graphics/platform, where platform is the name of your platform (e.g., imx6x). It's the file that's passed as the -c when starting screen.

If you're unsure what your graphics.conf configuration should look like, refer to Configuring Screen for more information.

System logs

Look at the system logs after you've launched screen, and at least once after loading a BSP on your target to ensure that everything started as expected. You can use the slog2info commmand to check the system logs. You can view only graphics events by using the -m option to specify the major code:

slog2info -m 8
            

Under normal circumstances you're not expected to find many error messages here with only the initialization of Screen. You'll need to check back here as applications start.

However, the lack of errors at startup deosn't necessarily mean that graphics is up and running and configured the way you think it should be.

Screen resources

After you've confirmed your configuration file and your system logs, you can look at the files under /dev/screen/ to verify that Screen has started correctly.

To see all the resources created by Screen so far, use this command from a shell prompt on your target:

# ls /dev/screen/0
            

You'll see all the displays, any pixmaps that are used for cursor shapes, any windows or streams that are used for framebuffers, or rotation buffers.

Displays

Let's first look at the displays. There'll be one file for each display. The current internal state of each display is serialized into text format. From your target, you can see the display configurations that Screen's currently using by looking at the dpy-display_id file in /dev/screen/0/. The values you see from this file are the values that are currently used at the moment when you read the file.

For example:
# cat /dev/screen/0/dpy-2
            

The file will look something like this with some of the more important configuration values shown in bold:

dpy-2/ctx-0/0(screen)
=================================================
id = screen-dpy-2-00000002-00000000000000000000000000000000
id string =
permissions = rwxrwxrwx--x--x--x--x---
status = CREATED
vendor = QNX Software Systems
renderer = OpenWF Display driver for Intel hardware using the Direct Rendering Manager (drm)
device id = 1
port id = 2
port type = HDMI
technology = other
WFD_QNX_egl_images = 0
WFD_QNX_cbabc = 0
WFD_QNX_bchs extension = 0
WFD_QNX_port_mode_info = 1
WFD_QNX_vsync extension = 1
WFD_QNX_writeback = 0
WFD_QNX_port_brightness = 0
WFD_QNX_pipeline_color_space = 0
active = 1
device_id = HDMI2
video modes =
   0  800  x 480  @ 60 (progressive) 13:8
   1  1024 x 768  @ 60 (progressive) 4:3
   2  1280 x 1024 @ 60 (progressive) 5:4
   3  1920 x 1080 @ 60 (progressive) 16:9
  *4  1280 x 720  @ 60 (progressive) 16:9
  +5  1920 x 1080 @ 60 (progressive) 16:9
   6  1280 x 1024 @ 75 (progressive) 5:4
   7  1280 x 1024 @ 60 (progressive) 5:4
   8  1152 x 864  @ 75 (progressive) 4:3
   9  1024 x 768  @ 75 (progressive) 4:3
   10 1024 x 768  @ 60 (progressive) 4:3
   11 800  x 600  @ 75 (progressive) 4:3
   12 800  x 600  @ 60 (progressive) 4:3
   13 640  x 480  @ 75 (progressive) 4:3
   14 640  x 480  @ 60 (progressive) 4:3
   15 720  x 400  @ 70 (progressive) 16:9
video mode = 1280 x 720 @ 60 (progressive)
native resolution = 0 x 0
physical size = 0 x 0
color primaries = red(0, 0) green(0, 0) blue(0, 0) white(0, 0)
detachable = 0
protection requested = (none)
protection enabled = DISPLAY_PROTECTION_NEXTERNAL
rotation support = WFD_ROTATION_SUPPORT_NONE
rotation mode = undefined
rotation = 0, 0
fill port area = 1
destination = WFD_INVALID_HANDLE
gamma range = [1 .. 1]
gamma = 1
aspect ratio = 16:9
refresh = 0
formats = rgb565 rgba8888 rgbx8888 yuv420 nv12 yv12 uyvy yuy2 yvyu v422
power mode = SCREEN_POWER_MODE_ON
brightness = -1
mirror mode = disabled
viewport = (0,0 0x0)
updates = 0
counter = 0
priority = 15
rebuild = 0
splash = 0
background color = ff000000
transparent color = 00000000
brightness = 0
contrast = 1
hue = 0
saturation = 0
idle timeout = 0
idle state = not idle
stream = (none)
frame buffer = (none)
rotation buffer = (none)
cursor = auto
cursor[arrow] = (none)
cursor[keyboard] = (none)
cursor[home] = (none)
cursor[menu] = (none)
cursor[none] = (none)
cursor[hand] = (none)
cursor[ibeam] = (none)
cursor[wait] = (none)
cursor[zoom-in] = (none)
cursor[zoom-out] = (none)
cursor[grab] = (none)
cursor[grabbing] = (none)
cursor[cross] = (none)
cursor[move] = (none)
cursor updates = 0
shadow = (none)
window manager = (none)
composition module = inteldrm (not loaded)
effect module = (null) (not loaded)
keep awakes = 0
gesture focus = (none)
joystick focus = (none)
keyboard focus = (none)
touch focus =
modifiers = (none)
scene = (empty)
strategy = (none)
bypass = 0
dirty = (none)
windows = (none)
sessions = (none)
background = (none)
holes = (none)
update mutex = 0x7f2e460
update condvar = 0x7f2e468
plane 0 {
  pipeline id = 1
  direct refresh = 1
  order = 1
  scale range = [0.125 .. 2]
  rotation support = WFD_ROTATION_SUPPORT_NONE
  format = SCREEN_FORMAT_RGBX8888
  layer = 1
  cursor = off
  source = (none)
}
metrics.attach = 0
metrics.power = 0
metrics.idle = 0
metrics.events = 0
            

Framebuffers

Note that the example for this display has no framebuffer (frame buffer = (none)) immediately after initialization because of Screen's boot optimization strategy. If you start an application that triggers the creation of a framebuffer, then you would see that Screen creates a framebuffer (e.g., win-1). The win-1 file in /dev/screen/0/win-1 shows the configurations of the framebuffer that Screen's currently using. When you have an application running, Screen creates a directory for each window and stream, and each of these directories contains files associated with the window and streams. Without any applications running, you won't see the framebuffer directory.

The values you see from this file are the values that are currently used at the moment when you read the file.

For example, you can use this command from a shell prompt on your target:

# cat /dev/screen/0/win-1
            

The file will look something like this with some of the more important configuration values shown in bold:

win-1/ctx-0/0(screen)
=================================================
id = screen-win-1-0000000e-45d451310638782e978a548c34787d13
id string = framebuffer
permissions = rwx--x--x--x--x--x--x---
acl = (empty)
display = dpy-2
status = VISIBLE
type = SCREEN_ROOT_WINDOW
autonomous = 1
references = 1
window manager string =
pipeline id = 1
parent = (none)
children = (none)
window above = (none)
window below = (none)
alternate window = (none)
root window = (none)
shadow = (none)
reclip = 0
updates = 0
locked = 0
valid = 0x00000044
class = framebuffer
flags = WIN_FLAG_VISIBLE WIN_FLAG_FLOATING WIN_FLAG_FRAMEBUFFER
buffer size = 1280x720
format = SCREEN_FORMAT_RGBA8888
color space = SCREEN_COLOR_SPACE_UNCORRECTED
usage = SCREEN_USAGE_DISPLAY
order = 0
swap interval = 1
default = (none)
sessions = (none)
streams = str-1
holes = (none)
regions = (none)
flip = 0
mirror = 0
scale mode = (default)
source viewport = (0,0 1280x720)
source clip rectangle = (0,0;1280,720)
clipped source viewport = (0,0;1280,720 1280x720)
destination rectangle = (0,0 1280x720)
destination clip rectangle = (0,0;1280,720)
clipped destination rectangle = (0,0;1280,720 1280x720)
rotation = 0
clipped rotation = 0
transform = [[1 0 0],[0 1 0],[0 0 1]]
transparency = SCREEN_TRANSPARENCY_SOURCE_OVER
color = #ffcfcfcf
global alpha = 255 -> 255
brightness = 0 -> 0
contrast = 1 -> 1
hue = 0 -> 0
saturation = 0 -> 0
scale quality = 0
idle mode = normal
protection requested = (none)
protection enabled = (none)
cbabc mode = SCREEN_CBABC_MODE_NONE
metrics.dropped = 0
metrics.visible.partial = 0
metrics.visible.full = 0
metrics.updates.count = 0
metrics.updates.pixels = 289 Mpixels
metrics.updates.reads = 765 Mbytes
            

From the above example, the window (win-1) is for a framebuffer (class = framebuffer), and you can see the associated stream for this window by reading the file associated with the stream. For example:

# cat /dev/screen/0/str-1/str-1
str-1/ctx-0/0(screen)
=================================================
id = screen-str-1-0000000f-e0b082e90f32c96442c693d54d8636a2
id string =
permissions = rwx--x--x--x--x--x--x---
acl = (empty)
display = dpy-2
status = INVISIBLE
autonomous = 1
mode = (SCREEN_STREAM_MODE_MAILBOX)
buffer count = 3
flags = (none)
buffer size = 1280x720
format = SCREEN_FORMAT_RGBA8888
color space = SCREEN_COLOR_SPACE_UNCORRECTED
usage = SCREEN_USAGE_DISPLAY
swap interval = 1
protection requested = (none)
protection enabled = (none)
owner = win-1/ctx-0/0(screen)
refs = (self)
front = 1
back = 2 [ 0 ]
rcvids = (none)
buffers =
  str-1-1 gd=2 nbytes=4194304 usage=0x0001 flags=0x8240 paddr=0x00000000 vaddr=0x40c00000 cvaddr=0x00000000 dvaddr=0x00000003 wfd=0x0000005b cm=0x08893d50 egl=0x00000000 native=0x00000000
  str-1-2 gd=3 nbytes=4194304 usage=0x0001 flags=0x8240 paddr=0x00000000 vaddr=0x41000000 cvaddr=0x00000000 dvaddr=0x00000004 wfd=0x0000005c cm=0x08893e70 egl=0x00000000 native=0x00000000
  str-1-3 gd=4 nbytes=4194304 usage=0x0001 flags=0x8240 paddr=0x00000000 vaddr=0x41400000 cvaddr=0x00000000 dvaddr=0x00000005 wfd=0x0000005d cm=0x08893e90 egl=0x00000000 native=0x00000000
metrics.cpu = 0
metrics.gpu = 0
metrics.objcnt = 0
metrics.apicnt = 0
metrics.drawcnt = 0
metrics.tricnt = 0
metrics.vtxcnt = 0
metrics.teximg = 0
metrics.subdata = 0
metrics.blits.count = 0
metrics.blits.pixels = 0 pixels
metrics.blits.reads = 0 bytes
metrics.blits.writes = 0 bytes
metrics.posts.count = 6392
metrics.posts.pixels = 0 pixels
            

If you've verified that your configuration file, your display, and framebuffer configurations are what you want, then you'll need to look what things are happening when there are some graphics applications running.