Family Photo Chest Part 10: SANE Front Ends.

Good Morning from my Robotics Lab! This is Shadow_8472, and today, I’m trailblazing the next phase of this project. Let’s get Started!

Ten months now, I’ve trickled on with this project. All so I don’t burn out on it. And as always, just as I crest one peak, another valley of research to explore awaits me on the other side. Hopefully, I’ll get around to scanning the first photo before this project’s first birthday.

My goal for this project is preservation. I’m obsessed with not losing any details and getting the cleanest image possible, and even I don’t fully understand what that means yet. In theory, that could mean grabbing the best scanner on the market and cranking it up to max. That’s more or less what happens to old movies when they’re being digitally remastered for use on HD or 4K big screens. But once something has been digitized, the amount of captured information is locked (barring AI upscaling, but that’s a topic for another time), and I want this project to be able to stand up in a generation or two, even if all physical originals are lost.

Early Research

This week’s research focused on the one known missing link, the software. I would like to have a feature to keep front and back scans together, and that probably means either writing my own interface or modifying an existing program. I went to find the source for the scanner software for Linux I otherwise have a minutia of experience with, and I can’t find it. The closest I can find is an RPM package for Arch, and I read that that’s not a guarantee: such packages can contain precompiled machine code, and editing that would be a bit above my skill level.

I started thinking about the chain of software that accomplishes the task of getting anything scanned. Down at the bottom, just above the operating system, there’s the driver controlling the scanner. Higher up, there’s a middleware layer called SANE. On top of that is a front end in either a GUI or the terminal. If I am to write my own program from scratch, it would be tailored for only this one scanner and be feeding commands to the terminal front end.

I dug up a few alternate front ends for SANE with the intention to attempt modification. Options include XSANE, a program I gather works, but is a little generic, and SwingSane, a project that aims to unlock all options for any compatible scanner, but hasn’t been maintained in five years.

GIMP

I was a little surprised to hear that GIMP has a plugin for scanning pictures directly in for prompt, user-guided restoration works to correct scratches, dust, fading, or other problems without a potentially over-aggressive fully automatic algorithm giving you “scans that look worse than the original” (Link to citation). As an added bonus, a picture can believably be scanned in as multiple layers and easily saved to file as front and back with no extra modification needed. Same goes for if I want to scan a whole album.

Where Are the Bottlenecks?

Scratch that last detail. My whole robotics blog here has turned into being more about how I’m using Linux to keep aging computers out of the e-waste bin, often with a touch of Frankenstein thrown in. If I want to go preserving every little detail I can down to the grain, these pictures WILL be packing away the RAM, and chewing through any remaining swap space, probably crashing any machine I have to throw at it. I’m afraid a more modern machine will need to be specced out.

Such a machine would be built for the task, and intended to have a nice, long retirement as a regular gaming rig. I’d like this thing to still be in service ten years from now. As I understand it, we’re at the relative beginning of Intel’s LGA 1200 slot, so late-life, second hand upgrade isn’t out of the question, and M.2 is still fairly new in terms of how long PATA and SATA lasted. For all I know, I’ll be running out its final clock cycles in some kind of cluster or a cloud computing application twenty or thirty years from now.

Final Question

What is the longest project you’ve ever persevered at before any results started showing?

Miscellaneous Bits and Bobs

Good Morning from my Robotics Lab! This is Shadow_8472, and today, I only have a bunch of unfinished projects I’d like to write about, but not are really ready, so I’m picking one or two and expanding on them with a mini-update. Let’s get started!

NFS

In my last photo archive post, I talked about mounting a file share manually. This is fine and all, but my intention this week was to get it connecting automatically on boot. I had a bit of a bump when I tried connecting to a share called “Photo Trunk” or something like that. When mounting, I would properly escape the space in the file path with a backslash, but the file system table didn’t get the memo. Long story short, it needs “040” instead of an escaped space. I don’t know why, but it just does. Shortly thereafter, I ran into a permissions barrier I have yet to resolve.

Update:
In a random search I wasn’t expecting to go anywhere, I managed to find that I needed to replace the space with “\040” and not just “040”. I tested it with sudo mount -va. It’s working now.

Manjaro Shakedown

Arch has a reputation of being unstable, but so up to date that software any newer is yet to compile. Manjaro Linux aims to shift the balance around to be more friendly to people who don’t know a compiler from a package manager. I’m also being a tad dangerous –or so I hear– by running the KDE desktop environment on an NVIDIA card, especially with the proprietary drivers.

I’ve noticed several times while playing modded minecraft that my desktop environment decides, “You know what? We’re just going to crash and start over from the login screen, even if login on boot is disabled. Oh, and we’re going to make it look like it might be a power blink and spook Shadow each time it happens.” –Note: I now have login at boot. I’ve reached out for help across Discord, but nothing conclusive has shown up. I managed to capture a log file right after a crash, but nobody helping me found anything conclusive. The best guess was that because the traceback for some problem in the xorg logs was handled by a library to manage input, these crashes may be related to the random stutter my wireless keyboard is experiencing, though I’m skeptical.

I’ve had this kind of keyboard for years, and I’ve always had stuttering problems, regardless of OS. Nevertheless, whenever we looked, it was the only wireless, ergonomic keyboard on the market that we could find. I’ve even experienced these frustrating stutters while writing here, now, yet I’ve put up with this particular keyboard til I’ve worn the matte finish on many keys until they’re mirror smooth.My N and Numpad_2 keys are totally missing their decals, and several other keys are already unrecognizable.

It’s possible my keyboard is crashing the desktop environment. Every time I’ve had the crash, I’ve been actively playing, and at least two of those times, I was fighting keyboard/mouse lag at the time. I’ve had another small glitch where a small, almost square rectangle of pixels along the bottom of my screen goes black for everything but my cursor. Unplugging my monitor and plugging it back in didn’t help, but the issue was gone after a reboot.

The more I use Manjaro, the more feels familiar. Really, the biggest difference from Debian I know about is the repositories inherited from Arch. The terminal acts a little differently in a way I don’t like, but I know that if I spent the time to bother changing it, I could. On the whole, I’m familiarizing myself with both a distribution and a desktop environment. A far future project may be to assemble my own experience from elements of everything I’ve seen.

Modded Minecraft Update

This one would never get a post to itself, but I’m after filler. Just tonight, I added a couple mods we were talking about, one to make the ender dragon leave an egg each time, and another to prevent endermen from making off with your grass, dirt, TNT, or other blocks they list as portable. The hardcore modding culture hasn’t moved past 1.12.2 yet, and it was 1.13 that introduced datapacks that really opened up lightly modified gameplay to otherwise strictly vanilla servers. The built-in function involving mob griefing is great, but nerfs creepers and ghasts — two otherwise harmless mobs when totally ignored. To ambitious players, endermen’s abilities to move blocks are more annoying than fun.

The Importance of Help

I’ve been chugging along regularly for three years now, and I only remember being late on a post by a single day once. I have proven to at least myself that I can write regularly. Along the way, I’ve found communities to solicit help from. At some point, I’d like to get a little more serious about my presentation because a default WordPress theme and a weekly wall of text wouldn’t insight confidence in me if I were looking at a tech blog. I know I chose this platform because I could get access to the low-level code, but I’ve only glanced at it once or twice. I don’t know any web design, and I can’t get excited about learning it. I’m not even sure I have the comments section working correctly!

Final Question

I decided to include the extra formatting this post on a whim to better separate the discrete partial projects, but I think I might use it in the future. What do you think of it?

Modding Minecraft Mods: Balance, Bugs, and Textures

Good Morning from my Robotics Lab! This is Shadow_8472, and today, I would like to share a couple bits about how I tweaked my family’s private Minecraft modpack. Let’s get started!

If running a curated modpack were bad for finding help, a custom modpack is even worse. It’s the sort of thing you just don’t do when you don’t get –or keep– working unless you have someone who knows what he or she is doing, or has the patience to figure it out; you won’t know everything — nobody will. That is why why I cannot stress enough the importance of knowing where you can ask for help after you’ve made an effort.

It took me a few Discord servers, but I landed on one for modded Minecraft in general. Minecraft Forge, a popular modding platform, refuses to support anything they’ve made but the couple most recent Minecraft versions, 1.15 and 1.16, but the modding scene has of this writing has not yet moved on from Minecraft 1.12.2 for stability concerns in the base game. This Discord server I found is full of people from this scene. Some of them are even developers of popular mods.

My family’s custom modpack is fairly lightweight because we have a lower-power computer or two to consider. As such, once my sister, Tzarina8472, had all the gameplay elements she wanted, new mods were always carefully considered. One of our mods involved using a rare crafting ingredient from woodland mansions, and we wanted a renewable source of them.

I turned to an old favorite: Soul Shards: Respawn by TheNut (there have been several versions, each by another developer). The basic idea is that you go out, collect mob souls with a shard, then use the shard in a cage. My problem was that the default recipe for a shard was way too cheap. Our seed has four witch huts, and if we are just going to spam a few high tier sould shard cages, then why bother? I’ve done that and ended up losing interest in the world, and I don’t want that this time.

Taz and I went through the config files and rebalanced things for using some more expensive, modded metals from what I like to call the Thermal Expansion suite, while keeping to the general design principles that appeared to have gone into the original mod. We ended up using two alloys: enderium and lumium.

Trouble: the way the mod is coded, those two metals are “block states” of the same base block called thermalfoundation:storage_alloy. I spent hours across multiple days trying everything I could think of to properly configure the mod. Suffice it to say anything I tried either didn’t work at all, or accepted any storage_alloy, even the much cheaper steel.

Special shout out to Watersfall, a mod developer on that Discord server I found. He looked at the publicly available source code on GitHub for Soul Shards and found a bug where it doesn’t accept block states in the config file. He even created a fork with a patch and used a pull request to petition that it be merged back into the main branch. He even talked me through how to clone his branch — and how to make sure I had the correct base version.

Compilation was another matter. Since the patch was written for the Minecraft 1.12.2 version of the mod, I needed to compile it with Java 8, or some equivalent. I don’t remember who, but someone talked me through making a shell script to compile the new version using the proper versions.

The other, smaller story I want to tell started when we noticed we didn’t have a way to remove enchantments. Taz had an expensive drill or saw from Thermal Expansion, and needed a way to remove it. One mod called Futurecraft backports select items from newer game versions, but because we need to use an older version of Forge, we would have needed to use an older version of Futurecraft that didn’t have the grindstone, the block we were after.

We tried using a small, one-block mod to add a disenchanting table, but of all the things it let us disenchant, it refused to allow Taz to remove her one enchantment. Enchanting Plus looked like a good option, except for the fact that it also lets you selectively apply enchantments. Let’s just say I feel strongly against that feature, and Taz doesn’t see a problem and leave it at that. There were miscommunications, I balanced the config to make it free to remove enchantments, but prohibitively expensive to add them so as to not devalue our planned villager trading hall.

I also -could – not – stand- the default texture for the enhanced enchanting table Enchanting Plus adds. I find it to be way too busy, even though a close look shows that it’s the same 16×16 resolution as the rest of the game. Going by the crafting recipe, you’re adding an ender pearl and either some gold foiling or gold chains down the sides. I used Taz’s computer to unzip the .jar file for the mod and find its textures. Taz then used an editor to design replacement textures based more on the original artwork. I put the result in a resource pack, and I had to make sure it was the correct format version.

Final Question: I’ve had to prune several details that didn’t fit with the overall narrative. What are some details you’ve really wanted to include, but didn’t quite fit?

New OS Smell: Manjaro Linux

Good Morning from my Robotics Lab! This is Shadow_8472, and today, I’m starting my first expedition into another branch of the Linux family. Let’s get started!

Moving away from Windows involved one of the larger culture shocks I’ve ever experienced without leaving home. The concept of software package managers was something I had only seen on phones. The file system left me wondering where my secondary drive was. And the downright alien sense of open-ended desktop environment customization options almost sent me reeling with decision fatigue. But the mindset surrounding Linux lends itself to self-guided study, an element that is sorely absent from a number of other mainstream operating systems.

The switch to Manjaro has brought back some of that sense of culture shock, but the similarities are already surfacing. Of note, I am also finally trying out this fancy KDE desktop environment, now that I’m on something with a discrete graphics card, so I won’t be totally sure what change comes from where all of the time. The file system has some subtle differences, such as /run/.local, a directory I am otherwise used to finding in ~/.local. Software installation comes from either an official repository, or else code can be downloaded and compiled from AUR (Arch User Repository — similar to Ubuntu’s PPA, but it’s supposed to be safer to use). Furthermore, Arch-based distros have a rolling release schedule for their software, delivering the “bleeding edge” experience.

Installation was typical from what I have come to expect from distros meant for a desktop experience. I downloaded an ISO to “restore” to a thumb drive, and installed the intended install drive. I was sure to physically detach any other drives that I wanted intact before booting to a live session with a few essential programs and an installer application. It did offer a choice between a couple Office suites, which was nice.

Of note, I did have to install some proprietary drivers to get my NVIDIA graphics card to run Minecraft, or at least a custom mod pack. I hear it’s a bit of a gamble with KDE and that there are workarounds that tend to break with updates. I was cautioned to enable SSH before flipping the proverbial switch, but fortunately I was lucky and didn’t have to do some extensive repair.

I gave the system a few days to ease in before getting my father to rustle up my old PCI Wi-Fi card from somewhere in the garage. Long ago, we got this card when the machine was relatively new. I was in a dorm setting, and my wireless printer was particular about having only serving computers connected to the same wireless network. When I upgraded from Windows 7 to 10, was having the hardest time getting the upgrade to take. I even reached out to tech support some scammers who showed me to a network log or something and said, “These errors are what is keeping your computer from –what was it your problem was?– upgrading to Windows 10.” (aside paraphrased, the rest is as close as I remember) My parents were ready to pay these guys a reasonable-sounding fee, but the whole thing smelled off, and I backed out. Our own, internal diagnostics pointed to the Wi-Fi card, and I had to give it up.

My Wi-Fi card has had one of its detachable twin antennas smashed and trashed. In the meantime, I had need for my desktop to go wireless again. We bought a USB3 based antenna that served me well until the day I decided to use it with Linux. Since then, I’ve been using my Raspberry Pi 4 as a reverse Wi-Fi hotspot, and I’m quite proud of it.

Today, I decided to install the old card back into its slot and lo and behold, it worked straight away. I tried to run some speed tests to find if the newer Pi 4 was outpacing the older, more direct PCI card. But it was during peak usage in my area, so I’ll need to run something across my local network. Whatever the case, my father had the idea to stick the double-length antenna from the new Wi-Fi adapter onto the vacant attachment point on the old card.

Final Question: Have you ever reinstated anything you thought was hopelessly obsolete?