Common Display configurations for all Platforms¶
Setting the HDMI or the DP Screen Resolution¶
The screen resolution can be modified using the xrandr utility or RandR protocol.
To change the default HDMI/DP screen resolution¶
Export the
DISPLAY
variable:$ export DISPLAY=:0
Obtain the applicable resolutions list:
$ xrandr
The resulting output shows a list of the connected HDMI/DP settings.
Switch the resolution to the display resolution that you want:
$ xrandr --output HDMI-0 --mode <res> $ xrandr --output DP-0 --mode <res>
Where
<res>
is the desired resolution, for example,640x480
.The highest rate supported for the specified mode is automatically chosen.
Select a refresh rate:
$ xrandr --output HDMI-0 --mode <res> --rate <refresh_rate>
Where
<refresh_rate>
is the refresh rate you want, for example,60
.Use
xrandr
to display all supported refresh rates for a mode.
Mirroring or Extending Displays¶
When multiple displays are connected, you can choose the relative position of each monitor (HDMI or DP).
To choose the relative position of each monitor¶
Execute the following command to mirror the DP monitor on the HDMI monitor:
$ xrandr --output DP-0 --same-as HDMI-0
Execute the following command to extend the display environment by placing the DP monitor to the left of the HDMI monitor:
$ xrandr --output DP-0 --left-of HDMI-0
Execute the following command to place the DP monitor to the right of the HDMI monitor:
$ xrandr --output DP-0 --right-of HDMI-0