====== Batocera ====== Batocera root user password is linux (z.B. ssh) ssh root@192.168.122.189 SMB: smb://BATOCERA.local/share ===== Emulationen ===== ==== VPinballX ==== Virtual Pinball X Sehr beschränkte Konfigurationsmöglichkeiten App: /usr/bin/vpinball/VPinballX_GL 2 Ini-Dateien (!): * /userdata/system/.vpinball/VPinballX.ini * /userdata/system/configs/vpinball/VPinballX.ini ====== Tricks zum Debbuggen ====== Änderungen in dmesg permanent anzeigen: dmesg -wH (-H: human) (wie: tail -F) Neustart der Oberfläche (ssh) batocera-es-swissknife --restart ===== Eigene Knöpfe für Sound oder andere Aktionen ===== Quelle((https://wiki.batocera.org/scripting_function_keys)) cp /etc/triggerhappy/triggers.d/multimedia_key.conf /userdata/system/configs/ ==== Identifying key names ==== Open a terminal and type the following command: evtest Then select your intended controller and press the button on your controller. The detected input will then be displayed like so: Event: time 1614795871.549381, type 1 (EV_KEY), code 99 (KEY_SYSRQ), value 0 Look for the key name in parenthesis and its value when depressed after the “code” number. In this example, the key name would be KEY_SYSRQ and its value would be 0. cat multimedia_keys.conf KEY_VOLUMEUP 1 batocera-audio setSystemVolume +5 KEY_VOLUMEUP 2 batocera-audio setSystemVolume +5 KEY_VOLUMEDOWN 1 batocera-audio setSystemVolume -5 KEY_VOLUMEDOWN 2 batocera-audio setSystemVolume -5 KEY_MUTE 1 batocera-audio setSystemVolume mute-toggle KEY_POWER 1 batocera-shutdown 1 KEY_POWER 0 batocera-shutdown 0 # display some information on X displays KEY_F2 1 /usr/bin/batocera-info --short | LANG=en_US HOME=/userdata/system XAUTHORITY=/var/lib/.Xauthority DISPLAY=:0.0 osd_cat -f -*-*-bold-*-*-*-38-120-*-*-*-*-*-* -cred -s 3 -d 4 KEY_F10+KEY_LEFTCTRL+KEY_LEFTALT 1 /etc/init.d/S31emulationstation stop KEY_F11+KEY_LEFTCTRL+KEY_LEFTALT 1 chvt 1 KEY_LEFTMETA 1 batocera-brightness cycle KEY_SYSRQ 1 batocera-screenshot BTN_PINKIE 1 batocera-audio setSystemVolume -5 BTN_TOP2 1 batocera-audio setSystemVolume +5 ===== Hardware ===== ==== Joystick ==== === Anlog Joystick on this cheap USB-encoder === Quelle((https://www.instructables.com/Zero-Delay-USB-Encoder-True-Analog-Joystick-Modifi/)) When I discovered these cheap CY-822A / USB Joystick X1 - Game Control Board USB Joystick Encoders on Ebay and Amazon I was puzzled by their description and construction. A lot of people like to make their own input devices and controllers and these are a cheap way to get started - but just switches are not always what you want. Despite the Analogue description its a very Digital device. {{::joystick-usb-analog.jpg?600|}} Bessere Möglichkeit mit dem gleichen CY-822A: Brücken, damit das Ding direkt in den Analogmodus bootet: [[https://beko.famkos.net/2022/03/17/cy-822a-with-analogue-input/]] ==== VPinball ==== Visual Pinball X - nimmt nur vpx-files. Problem: Batocera > v38_: rom MUSS in dem Verzeichnis sein (bzw. Unterverzeichnis rom/) in dem auch vpx ist. Das Editieren der /media/SHARE/system/configs/vpinball/VPinballX.ini bringt nicht, weil VPX bei jeden Start diese Datei wieder mit dem default überschreibt (warum?). Offenbar von einem r-Overlay. Lösung: Script schreibt in jedes Verzeichnis einen symlink zum rom hinein. create_symlinks.sh #!/bin/bash # Pfad zum zentralen ROM-Verzeichnis rom_source="/userdata/roms/vpinball/pinmame/roms" # Pfad zu den Tabellenverzeichnissen table_dirs="/userdata/roms/vpinball/" # Liste der Verzeichnisse, die ausgespart werden sollen exclude_dirs=("pinmame" "videos" "ini" "images" "manuals") # Schleife über alle Unterverzeichnisse im table_dirs-Pfad for dir in "$table_dirs"*/; do # Überprüfen, ob es sich um ein Verzeichnis handelt if [ -d "$dir" ]; then # Verzeichnisname extrahieren dir_name=$(basename "$dir") # Prüfen, ob das Verzeichnis in der Ausschlussliste enthalten ist if [[ " ${exclude_dirs[@]} " =~ " ${dir_name} " ]]; then echo "Verzeichnis $dir_name wird ausgelassen" continue fi # Symlink erstellen, wenn er nicht bereits existiert if [ ! -L "$dir/roms" ]; then ln -s "$rom_source" "$dir/roms" echo "Symlink erstellt: $dir/roms -> $rom_source" else echo "Symlink existiert bereits in $dir" fi fi done cat remove_symlinks.sh #!/bin/bash # Pfad zu den Tabellenverzeichnissen table_dirs="/userdata/roms/vpinball/" # Schleife über alle Unterverzeichnisse im table_dirs-Pfad for dir in "$table_dirs"*/; do # Überprüfen, ob es sich um ein Verzeichnis handelt und ob ein Symlink existiert if [ -d "$dir" ] && [ -L "$dir/roms" ]; then # Symlink entfernen rm "$dir/roms" echo "Symlink entfernt: $dir/roms" else echo "Kein Symlink vorhanden in $dir" fi done ==== Plunger ==== Bei Visual Pinball x gibt es ja die VPinballX.ini. Ich habe einen echten Plunger, den ich so programmiert habe, dass er sich wie die y-Achse der Maus verhaelt. Was muss ich in der VPinballX.ini einstellen, dass der Plunger funktioniert? ChatGPT: Da dein echter Plunger als Y-Achse der Maus fungiert, musst du in der VPinballX.ini sicherstellen, dass Visual Pinball X (VPX) die Maus als Eingabegerät für den Plunger erkennt und korrekt interpretiert. Schritte zur Anpassung der VPinballX.ini: Öffne die Datei VPinballX.ini Diese Datei befindet sich im Hauptverzeichnis von Visual Pinball X (z. B. C:\Visual Pinball\). Suche den Abschnitt [Joystick] Falls dieser nicht existiert, erstelle ihn am Ende der Datei. Ändere oder füge folgende Einstellungen hinzu: [Joystick] EnableLiveCentering=0 EnableVPJoystick=0 DeadZone=0 → Dies deaktiviert die Joystick-Unterstützung, falls VPX versehentlich einen Joystick anstelle der Maus verwendet. Suche den Abschnitt [Plunger] (Falls nicht vorhanden, erstelle ihn) [Plunger] Enabled=1 MousePlunger=1 Enabled=1 → Aktiviert den Plunger MousePlunger=1 → Setzt den Plunger-Eingang auf die Maus Speichern und VPX neu starten Testen in VPX: Starte Visual Pinball X Gehe zu den Einstellungen unter "Preferences → Keys, Nudge and DOF" Überprüfe unter "Plunger Settings", ob sich der Plunger bewegt, wenn du ihn betätigst Falls der Plunger falsch herum funktioniert, kannst du ihn umkehren: ReversePlungerAxis=1 Falls die Bewegung nicht flüssig genug ist, kannst du die Sensitivität anpassen: PlungerSpeed=5.0 (Werte zwischen 2.0 und 10.0 testen) Falls es nicht funktioniert, kannst du in VPX die Debug-Ansicht aktivieren: Drücke F11 in VPX während eines Spiels Beobachte die Plunger-Position Falls keine Bewegung sichtbar ist, könnte VPX die Maus nicht als Plunger erkennen. ==== Scraper ==== [[https://www.screenscraper.fr/]] gmx-h6³ ==== Mein selbstgebauter Spielautomat ==== 2024 * Lenovo ThinkCentre M715q * 2GB HD * 2 X 4GB 1Rx16 PC4-2666V Bootmenu: F12 === Conf === cat /boot/batocera-boot.conf ## Lines prefixed by double hashes (##) are comments. ## Lines prefixed by a single hash (#) are commented settings; remove the single hash to activate the setting. ## The device used to store the share data a.k.a. userdata. ## INTERNAL -> Use the same drive Batocera has been flashed to. See https://wiki.batocera.org/add_games_bios on how to add files to the internal storage. ## ANYEXTERNAL -> Use the first external storage detected. See https://wiki.batocera.org/store_games_on_a_second_usb_sata_drive ## Putting the name here of the drive instead will use that specific external storage. Use the menu in Batocera to see the available options. ## DEVICES -> Use external storage for individual folders. See https://wiki.batocera.org/store_games_on_a_second_usb_sata_drive#manual_configuration_with_batocera-bootconf_advanced ## DEV -> Manually define the GUID of the storage device requested. See https://wiki.batocera.org/store_games_on_a_second_usb_sata_drive#dev_mode ## NETWORK -> Use the network share, requires configuration first. See https://wiki.batocera.org/store_games_on_a_nas sharedevice=INTERNAL ## Add a wait time (in case the share device takes a while to come "online") in seconds. #sharewait=15 ## Automatically resize the userdata partition if unallocated space is present on the drive. Disables itself once completed successfully. #autoresize=true ### GPU's ### ## Manually override Nvidia driver selected. ## Leave this setting commented to have Batocera automatically select the correct driver. ## See https://wiki.batocera.org/supported_pc_hardware ## true -> Use the autodetection method. ## legacy470 -> Force using the legacy 470.xx driver. ## legacy390 -> Force using the legacy 390.xx driver. ## legacy340 -> Force using the legacy 340.xx driver. ## false -> Force using the open-source Nouveau drivers. ## Note: You DO NOT need to set this unless you want to select a particular compatible driver version. #nvidia-driver=true ## Use the amdgpu Mesa driver over the redeon driver if supported. set to false to disable this if needed. amdgpu=true ### Hybrid Laptops ### ## By default Batocera from v38 will detect laptops with multiple GPUs and set the appropriate prime value. ## You should not need to set the prime options below unless absolutely necessary. ## Set the boolean to false to disable accordingly. ## Helps with modern laptops (post-2018) with Nvidia hybrid graphics that default to using integrated graphics. #nvidia-prime=true ## Helps with modern laptops with AMD hybrid graphics that default to using integrated graphics #radeon-prime=true ## Disable the splash screen. #splash.screen.enabled=0 ## Maximum or specific machine resolution (get the full list for your display with "batocera-resolution listModes") ## See https://wiki.batocera.org/display_issues#force_any_specific_supported_resolution_in_es_instead_of_the_default_maximum_one #es.resolution=max-1920x1080 ### Below are copied values from batocera.conf to make them available in an early boot stage. ### ### Change them in batocera.conf or the menu, not here. ### wifi.enabled=1 wifi.ssid=PPP wifi.key=TT system.timezone=Europe/Berlin system.hostname=BATOCERA randomseed=xxx