datalars

  • Home
  • About
  • RSS Feed
  • Archive
  • Log in

September 2023

  • "Retrocorder" -…

    Persistent nostalgia The past few months, I've spent some time to set up a room in my house to be a pretty sweet space dedicated to retro-gaming. This includes a vintage PC, a CRT TV, and a multitude of classic games consoles hooked up to four RCA/AV switches. This works well, and to play the console we want, one can just flip a couple of switches instead of having to unplug and shuffle around literally 8 different sets of RCA cables. Thing is, when you're playing games, especially during couch coop, things tend to happen. Some of these things, depending on the types of games you play, can be utterly hilarious, and worth saving for posterity. With the two last generations of consoles I own, PS5, PS4 and the Nintendo Switch, you can just press a single button on the controller to save recent gameplay as a file to the system storage, which is awesome. When you also enjoy playing on 20-30 year old game consoles as well, this part becomes a bit trickier. Emergent technologies Enter: The…

    Permanent link to “"Retrocorder" - Using a spare PC to make a fully automated retro-gaming recording solution”
  • How to make a…

    Acquisition I bought a new TV a year and a half ago. Much to my dismay, I discovered that while the picture quality is great, the audio quality is not, unlike my previous TV. My daily driver Linux PC is connected to my TV, and is my main entertainment hub for TV shows, movies and video games, and also general PC usage, so I figured I had to get an external speaker or sound bar. My dad had a spare speaker which he had replaced with a newer unit, so I inherited the spare - a "Geneva Sound System Model S DAB". It came with a small caveat: the speaker will not turn on using the remote control. Mind you, it will turn off just fine with the same exact button, and every other button on the remote works as advertised - it just will not turn on using the remote. I figured that this was no big deal, and accepted the speaker with thanks. I get the speaker situated and hooked up, and the audio quality is great - a big upgrade from the built-in TV audio. Great for music, great for…

    Permanent link to “How to make a partially defective speaker stay powered on (or: The Five Stages of Annoyance)”

August 2023

  • Quickie: Using…

    The PS2 homebrew scene is an absolute mess, and whenever I try to find any information on any operation about it online, I find the following: A truckload of conflicting information A myriad of different guides spanning back 20 years A bushel of different software tools, none of which are usually available on Linux And a partridge in a pear tree This time, all I needed to do was to figure out how to get my ISO and BIN/CUE PS2 backups onto an internal HDD for playing through Open PS2 Loader (OPL). All of the above points of note came into play, but after digging and sorting through it all for a bit, I found a reasonable way to do this without having to involve a Windows computer: HDL Dump Helper GUI includes a Linux x86 build of hdldump. Grab it from PSX-Place. Extract the rar, move hdld_2_3/files/hdl_dump_090 to /usr/bin/hdldump chmod +x /usr/bin/hdldump You now have hdldump for Linux CLI, hooray! Every guide I looked at said that one of the downsides of hdldump is that it doesn't do…

    Permanent link to “Quickie: Using hdldump to transfer PS2 HDD games under Linux”

July 2023

  • Using a Mac Mini as…

    Issues in the bedroom I have a wall-mounted TV in my bedroom. This TV has a PS4 and a PC hooked up to it. I use the PS4 to remote play my PS5 (which is situated in the living room), and in the past, have used the PC for Kodi/Jellyfin and YouTube in bed, using a USB remote control with support for moving the mouse cursor. Unfortunately, it doesn't do that very well, as the Wi-Fi adapter I have for it keeps presenting issues under Linux. No matter how much I re-compile and reenable the drivers, it just won't work properly, and will randomly cut out after a while. This also happens with several different adapters, so I've kinda just left it there, and used the PS4 to access the web UI of Jellyfin. This is not ideal, and I don't want to spend any more hours fighting with it. Free fruit I don't usually use Apple products, but I had a Mac Mini lying around as surplus after having replaced all Macs at my place of work with Windows computers. It's a shame to let it just lie around, collecting…

    Permanent link to “Using a Mac Mini as a bedroom PC for Kodi, Moonlight and YouTube”

April 2023

  • ntfy: Send…

    I've recently started using ntfy to send notifications to my phone from some scripts I'm running on my home NAS. This works great, but when I'm on my PC, I'd rather get notifications there instead of on the phone. There doesn't seem to be a desktop app for ntfy, but luckily the API is extremely simple. I've also recently started picking up Python, so I decided to whip together a simple ntfy notification delivery system for the Linux desktop. To use this, you need notify-send (provided by the libnotify package), and python3. ntfy-listener.py: from sys import argv import requests import json import subprocess # Sends desktop notifications to a subscribed ntfy topic through libnotify/notify-send # Usage: python3 ntfy-listener.py topic-name if len(argv) > 1: try: resp = requests.get(f"https://ntfy.sh/{argv[1]}/json", stream=True) for line in resp.iter_lines(): if line: ntfyData = json.loads(line) if ntfyData["event"] == "message": ntfyTitle =…

    Permanent link to “ntfy: Send notifications through libnotify to Linux desktop”

March 2023

  • KDE Shenanigans:…

    Dolphin, the KDE file manager, is great, and has grown to become my favorite file manager of all time. It's super customizable, and a joy to use, which is more than I can say for the Windows equivalent. I do a fair amount of file management, so having a good tool for this is important, and when it's extensible like Dolphin, that's when it really starts to shine. I recently got the idea to make a script that will play a random video file from a given directory tree. Some possible use cases for this is to play a random episode of a TV show, or a random home recording stored on your computer. Making the script itself was fairly straight-forward, but I don't want to open up the terminal to launch my script every time I want to use it, and I have enough keyboard shortcuts for things already (the most important one being Meta+Z, which plays a rimshot sound effect, much to the amusement of everyone I know). Naturally, I started looking into integrating this into Dolphin. Initially, I wanted…

    Permanent link to “KDE Shenanigans: Playing a random video from Dolphin”

January 2023

  • Sending arbitrary…

    The task Automation is great. There's just something inherently beautiful about the process of stringing together a bunch of software, services, or tools to attain a simple goal, and finding a solid solution that just works™. One automation task I've been tinkering with lately is how to send an arbitrary file directly from my browser to my phone, with as little fuss as possible. I often browse reddit or just the web in general and find a funny video or image I want to keep on my phone to send to someone, or just to easily refer to back later. If I can just click a button and nearly immediately have a copy of the resource in question available on my phone, that would be really swell. Luckily, the world of open source software provides a multitude of ways to accomplish this task; here's how I did it. The requirements To follow along at home, you'll need: A Linux-based computer An Android-based smartphone Firefox on your PC The Open With addon for Firefox yt-dlp (or youtube-dl or any of…

    Permanent link to “Sending arbitrary files directly from Firefox to your phone”
  • qBittorrent v4.5.0:…

    The story so far: In the beginning, qBittorrent was created. Then they released v4.5.0. This has made a lot of people very angry and been widely regarded as a bad move. (If you just want the theme file with completely white text colors, you can download that here. Place it somewhere safe, then open qBT, and go to Tools > Preferences > Behaviour and check the checkbox for "Use custom UI theme". Then browse to the theme file, click OK, and restart qBT) Update 2023-03-22: ZippyShare is shutting down, so the link now points to MultiUp, which uploads to multiple services. The problem The very bad move in this case, was hard-coding foreground colours, while simultaneously not hard-coding background colours. Most, if not all, operating systems in use today will let you choose a theme for your apps, so you can probably see how this quickly becomes a problem. If your app's hard-coded foreground colour has poor contrast with the user's chosen background colour, the user is gonna…

    Permanent link to “qBittorrent v4.5.0: The Hitchhiker's Guide to Legible Text”
  • Bash script:…

    Continuing on the theme of file management from my last post: This script takes a folder of files and randomizes all filenames, whilst keeping the filename extension. This is useful if you're sorting by name, and want to have the files presented in a random order. Some possible use cases are a folder of pictures you intend to post to a blog, do further processing on, and the order and names of the files aren't important. Usage: cd to the directory that contains the files you wish to randomize the filenames of, then run the script. randomize_filenames.sh: #!/bin/bash # Randomize file names in current working directory, keeping the filename extension # Modified from: https://unix.stackexchange.com/a/6553 # Ignores dotfiles and subdirectories find . -type f -not -path '*/.*' | while read -r name; do ext=${name##*/} case $ext in *.*) ext=.${ext##*.};; *) ext=;; esac newName=`mktemp --dry-run XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX` mv "$name" "$newName$ext" done

    Permanent link to “Bash script: Randomize filenames in a directory”
2022