• This repository has been archived on 25/Jun/2024
  • Stars
    star
    527
  • Rank 84,091 (Top 2 %)
  • Language
    Shell
  • License
    MIT License
  • Created about 5 years ago
  • Updated almost 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Create virtual display / monitor on linux OS for extended display via teamviewer or vnc server without any real Monitor is Plugged In.

Virtual Display Linux (VDL Monitor)

Just a simple bash script that create some virtual display / monitor on linux OS for extended display via TeamViewer or VNC server

Yes, you can add fake display monitor without real monitor attached!

⚠️⚠️⚠️⚠️ DISCLAIMER: Do with your own risk! ⚠️⚠️⚠️⚠️

Virtual Monitor Linux

Virtual Display Linux (VDL Monitor)

I'm using this simple script for extend my desktop pc to "2 external monitor" via teamviewer.

Device support

Curently this VDL Monitor only work for intel CPUs with integrated graphics only, sorry 😞

If you are using an Nvidia GPU, you can follow this instruction.

Or if you already made a mistake when trying this script on a device without an integrated intelhd gpu, which makes your device stuck on a black screen with blinking cursor, this instruction might be useful for you to fix this problem.

If you encounter a similar problem, you just need to delete /usr/share/X11/xorg.conf.d/20-intel.conf created by vdl-monitor to get your device booted normally again.

Quick Setup

  1. Install teamviewer on both devices. (You also can use VNC to)
  2. cd ~
  3. git clone https://github.com/dianariyanto/virtual-display-linux.git
  4. cd virtual-display-linux
  5. sudo chmod +x vdl-monitor
  6. Change your own resolution setup vdl-monitor.conf
  7. ./vdl-monitor
  8. For first running, you will prompt to reboot or relogin current session
  9. cd ~/virtual-display-linux/
  10. ./vdl-monitor
  11. Done.
dianariyanto@lenovo:~$ cd virtual-display-linux/
dianariyanto@lenovo:~/virtual-display-linux$ ./vdl-monitor 
Start configuration
add resolution 1368x768
start display VIRTUAL1 to 1368x768
Screen 0: minimum 8 x 8, current 2968 x 900, maximum 32767 x 32767
LVDS1 connected primary 1600x900+1368+0 (normal left inverted right x axis y axis) 310mm x 170mm
   1600x900      60.00*+  59.82  
   1400x900      59.88  
   1368x768      60.00    59.88    59.85  
   1360x768      59.80    59.96  
   1280x800      59.81    59.91  
   1152x864      60.00  
   1280x720      59.86    60.00    59.74  
   1024x768      60.00  
   1024x576      60.00    59.90    59.82  
   960x540       60.00    59.63    59.82  
   800x600       60.32    56.25  
   864x486       60.00    59.92    59.57  
   800x450       60.00  
   640x480       59.94  
   720x405       59.51    60.00    58.99  
   640x360       59.84    59.32    60.00  
DP1 disconnected (normal left inverted right x axis y axis)
DP2 disconnected (normal left inverted right x axis y axis)
DP3 disconnected (normal left inverted right x axis y axis)
HDMI1 disconnected (normal left inverted right x axis y axis)
HDMI2 disconnected (normal left inverted right x axis y axis)
HDMI3 disconnected (normal left inverted right x axis y axis)
VGA1 disconnected (normal left inverted right x axis y axis)
VIRTUAL1 connected 1368x768+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
   1368x768      60.00* 
VIRTUAL2 disconnected (normal left inverted right x axis y axis)

Done, Check your VDL Monitor on System Setting > Display
dianariyanto@lenovo:~/virtual-display-linux$ 

Check teamviewer client and select your virtual display act as external monitor.

You now success Add Fake Display with No Monitor is Plugged In!

VNC + Android Setup

Dependencies :

On the linux machine :
  • x11vnc
  • android-tools
  • libnotify
On the android phone/tablet :
  • VNCviewer, or any other vnc viewer for android

Installation steps :

  1. Enable developer mode on the android phone/tablet by entering int settings -> info and tapping on the release number 5 times
  2. Enable USB-debugging in developer settings on the android device
  3. Plug an USB cable between your two devices
  4. b) Depending on the android version you may need to go to your notifications, and look for a notification about the USB connection to allow debugging.
  5. Run adb shell on your Linux machine and approve the request on your android device
  6. Configure the variables in the script, internal is your computer monitor, you should get it with xrandr. screen1 and virtual1 are the resolutions of the screens
  7. start the script
  8. open the VNC app on your android device
  9. connect to http://127.0.0.1:5900

Confirmed

  • Elementary OS 5.0 Juno based on Ubuntu 18.04 with Teamviewer v.14.7.19.65
  • Pop OS! 20.04 Default Share Screen with Remmina Desktop Client
  • Armbian 5.0 xrdp with Realvnc Client
  • Fedora 34 - Gnome 40 on Xorg with Deskreen
  • Debian 11 - KDE Plazma with Deskreen
  • Manjaro Rolling - Gnome 40 on Xorg with x11vnc (server) realvnc (client) adb (for better fluidity)
  • Waiting your report here.

Remote Client

Useful links