OS: RaspberryPI Lite users you should create
dvandenbosch (sudoer)
gui (non sudoer)
install dotfiles (This is for Dan Van Den Bosch own sanity)
git clone https://github.com/danielleevandenbosch/dotfiles.git
cd dotfiles
bash install.sh
create this file as root /etc/systemd/system/[email protected]/autologin.conf with the following content:
[Service]
ExecStart=
ExecStart=-/sbin/agetty --autologin gui --noclear %I $TERM
then run this sudo systemctl daemon-reload
sudo apt-get update
sudo apt-get install xorg
sudo su - gui
create this file under the gui account ~/.bash_profile
With the following content: (I have not tested this using bash)
if [[ -z $DISPLAY ]] && [[ $(tty) = /dev/tty1 ]]; then
startx
fi
if you are using zsh,
create this file under the gui account ~/.zlogin
With the following content
if [[ -z $DISPLAY ]] && [[ $(tty) = /dev/tty1 ]]; then
startx
fi
run startx
run xrandr --output HDMI-1 --mode 1920x1080 --output HDMI-2 --mode 1920x1080 --same-as HDMI-1
apt install chromium-browser
create this file under the gui account ~/.xinitrc
This seemed to work from me after playing around with the settings.
xset s off -dpms &
unclutter -idle 300 &
xrandr --output "HDMI-1" --auto --output "HDMI-2" --same-as "HDMI-1" &
sleep 5
chromium-browser --start-fullscreen --disable-session-crashed-bubble --disable-infobars --incognito http://10.20.0.219/
You might need to delete the ~/.config/chromium
settings if it is not full screening.
I have had some luck with this method, but honestly the xrandr seems to work better... idk. feel free to try.
sudo vim /etc/X11/xorg.conf.d/10-monitor.conf
If the path does not exist, create it.
Section "Monitor"
Identifier "Monitor0"
EndSection
Section "Monitor"
Identifier "Monitor1"
Option "RightOf" "Monitor0"
EndSection
Section "Device"
Identifier "Device0"
Driver "modesetting"
Option "Monitor-HDMI-1" "Monitor0"
Option "Monitor-HDMI-2" "Monitor1"
EndSection
Section "Screen"
Identifier "Screen0"
Device "Device0"
Monitor "Monitor0"
DefaultDepth 24
SubSection "Display"
Depth 24
Modes "1920x1080"
Virtual 3840 1080
EndSubSection
EndSection
you might need to edit the following in boot:
sudo vim /boot/firmware/config.txt
or
sudo vim /boot/config.txt
disable_overscan=1
hdmi_force_hotplug=1