feat: add config overlay for auto-login, mounts, X11, and RetroArch

- Add autologin config for getty@tty1.service to auto-login as emulation user
- Add udev rule for auto-detecting second SD card (mmcblk1p1)
- Add systemd mount units for /roms (primary SD) and /roms2 (second SD)
- Add .bash_profile to auto-start X on tty1
- Add .xinitrc to configure X11 and launch EmulationStation-DE
- Add retroarch.cfg with H700 optimized settings

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
cloudwithax 2026-02-17 17:54:12 -05:00
parent 599b4df508
commit c90240d423
7 changed files with 62 additions and 0 deletions

View File

@ -0,0 +1,3 @@
[Service]
ExecStart=
ExecStart=-/sbin/agetty --autologin emulation --noclear %I $TERM

View File

@ -0,0 +1,12 @@
[Unit]
Description=ROM Storage (Primary SD)
After=local-fs.target
[Mount]
What=/dev/mmcblk0p5
Where=/roms
Type=auto
Options=defaults,noatime
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1,11 @@
[Unit]
Description=ROM Storage (Second SD Card)
[Mount]
What=/dev/mmcblk1p1
Where=/roms2
Type=auto
Options=defaults,noatime,nofail
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1,2 @@
# Auto-detect second SD card (mmcblk1p1) and trigger mount
ACTION=="add", KERNEL=="mmcblk1p1", TAG+="systemd", ENV{SYSTEMD_WANTS}="roms2.mount"

View File

@ -0,0 +1,4 @@
# Auto-start X on tty1
if [ -z "$DISPLAY" ] && [ "$(tty)" = "/dev/tty1" ]; then
exec startx
fi

View File

@ -0,0 +1,22 @@
# RetroArch configuration for H700
video_driver = "gl"
video_fullscreen = "true"
video_vsync = "true"
# Input
input_autodetect_enable = "true"
input_joypad_driver = "udev"
# Directories
system_directory = "/roms/bios"
savefile_directory = "/roms/saves"
savestate_directory = "/roms/saves"
screenshot_directory = "/roms/screenshots"
libretro_directory = "/home/emulation/.config/retroarch/cores"
libretro_info_path = "/usr/share/libretro/info"
# Audio
audio_driver = "alsa"
# Menu
menu_driver = "ozone"

View File

@ -0,0 +1,8 @@
#!/bin/bash
# Disable screen blanking
xset s off
xset -dpms
xset s noblank
# Launch EmulationStation-DE
exec /usr/local/bin/EmulationStation-DE.AppImage --no-sandbox