Package Loop

Good Morning from my Robotics Lab! This is Shadow_8472, and today, I am aiming to rig Kerbal Space Program (KSP) to run across two Linux computers. Let’s get Started!

Intended Target

KSP is one of those games I find myself coming back to every so often. In case you’ve survived the past decade without hearing about KSP, it’s a game where you design rockets using an assortment of parts and fly your kerbals on them to explore their solar system. There are no goals except the ones you set for yourself. With the final major update now released, I’m going to give it another go at an interplanetary game.

But it would sure be nice if I weren’t tied to a single computer while playing. Steam offers a cloud save option, but I’d rather not be needlessly broadcasting my play time for a single-player or Local Area Network (LAN) experience. I picked up a little shell scripting for auto clicking in another game, so I figured I’d stretch the skill a little farther. For this project, I will be using Derpy Chips and my daily driver without a fancy name.

KSP updated nicely on my tower, but when I went to install the game on Derpy, Steam was nowhere to be found aside from a broken icon and a couple other Steam games I might try pulling this trick with in the future. My system was bugging me to update, so I went sudo aptitude update and sudo aptitude upgrade. It didn’t update correctly.

Running in Circles

I spent around three days trying different combinations I knew. Both Aptitude and Apt-get were stumped. The errors recommended I try running some more aggressive commands to fix installs, but I kept ending back at the same broken state.

Taking a closer look at the errors themselves, it appeared a whole host of locale packages were to be replaced with one inclusive one. Each and every one of them, as well as others appeared to reference some variant of libc6.

Not good.

Libc6 is a C language library. C is important as one of the first programming languages with a little abstraction for easier human readability while still being close enough to the hardware for amazing optimizations. You take out LibC, things start breaking fast.

I tried putting the upgrade off some more, but my package manager wasn’t having any of it. It insisted I fix the problem before installing or removing anything.

All this time, I was reaching out to the Engineer Man Discord. I got a few links on stuff to do, like a number of commands to do in sequence in case a particular log was getting in the way, but it always came back to my Libc6 version being wrong.

Progress and Repair

I of course was looking stuff up on my own, and I managed to find Libc6 was “half-installed.” My best guess is that a month or two ago, I had a partial upgrade. I didn’t think much of it at the time because I wasn’t relegated to an Xorg forsaken command line like all my other major system meltdowns normally worthy of a repair shop visit.

I made some progress when I used dpkg to uninstall a package I was otherwise interested in removing from the system anyway. According to localhost, the Discord user who solved my snafu (special thanks), I was caught in a dependency loop. Basically, when apt-get is either installing or trying to fix an install of package A , it wants to see package B or something like it before adding it to the list of satisfied packages, but if package B wants to see A or similar before it’s happy, there’s trouble. My trouble was that in order to fix the AB circle with apt-get or aptitude, I needed to first fix the AB cycle preventing me from solving it. Dpkg is too dumb to care about package dependencies, so it will happily ignore any logic bombs you’re setting (or defusing) for yourself.

Takeaway

I don’t understand the fix, sadly. I am still thankful Derpy is running again. I went ahead and installed KSP there, but the game file structure is so complicated, I’m just going to be copying the whole thing over to GoldenOakLibry, the network storage, using rsync. After going back and forth a few times to make sure everything is working as expected, I will write a set of scripts for further automation.

I will follow up if anything interesting happens on the implementation proper.

Final Question

Have you ever fudged a personal cloud?

Anatomy of the McKibben Artificial Muscle

Good Morning from my Robotics Lab! This is Shadow_8472, and today, I am ordering materials for the artificial muscle I’m going to be working with for a while. Let’s get started!

The McKibben Artificial Muscle

In my research this week, I learned the pneumatic muscle I’ve chosen to start prototyping with is in fact called a McKibben Muscle. An inner sleeve is typically made out of rubber. A fluid –usually air– is pumped in through an endcap. The sleeve expands radially, a woven outer casing translates that outwards expansion to a lengthwise contraction.

I’ve seen several tutorials on how to make these muscles online. The greatest design freedom is in the endcaps. They can be as simple as a clamp or complex enough to need a 3D printer. Their functions are to hold the inner sleeve and outer casing together, seal them off while still allowing air in and out within the greater pneumatic system, and provide mounting points to work on.

Materials Shopping

The most important part is the outer casing. I will be using cable management sleeving like what protects the cords coming off the power supply in my main computer tower. Squish them, and they expand: same principle in reverse of the muscle. I remember at least a couple sources saying to use nylon, but a little shopping yielded a selection of tubes made from polyethylene terephthalate (PET).

Tubing is almost as important as the casing. As long as it keeps air inside the muscle, it should work for all I know right now. I talked about it with my father while walking the dogs, and we figure longer-term durability will be best served by a rubber tube a bit thicker than a balloon, but not so thick it’s near difficult to inflate.

We’ve talked about an air source. Compressors are loud and bulky. Lower end models lack a tank for storing pressure, which I will need for anything resembling a decent response time. We also briefly considered getting a SCUBA tank, but those run more than a compressor and most certainly cost to refill. Whichever option we end up buying, this will be the most expensive part.

We’ve only baerly started brainstorming endcaps. My father proposed using a nut and a pipe clamp for one end, but I’m having trouble imagining how that will look while trying to attach a mount point. Perhaps some PVC piping will be involved after a trip to a hardware store. I can have a T pipe with a plug for a mount point across from the muscle and an adapter to the air supply coming off the tail.

Takeaway

The main consideration for buying parts at my stage is matching size. It won’t do to have an inner tube that barely fits in the expanded profile of the sleeve.

As noted above, it would seem everyone showing off their air-powered muscles has a slightly different design depending on his or her available tools. I don’t have access to a machine shop, so I won’t be modifying any metal parts. Neither is my 3D printer working right now: printed parts will need to wait.

I’m excited to start testing.

Final Question

What variables do you expect will affect the quality of my McKibben muscle design?

Removing Backgrounds With GIMP

Good Morning from my Robotics Lab! This is Shadow_8472, and today I am editing pictures for my church’s photo directory. Let’s get started!

My Background

I first learned the basics of photo manipulation in high school using Photoshop. Pictures can be split apart, remixed with other pictures or original (hand drawn) elements with a wide variety of tools, and sent back out for use elsewhere. The whole operation is organized in a series of layers with their won operations.

Photoshop is not a bad program, but ever since Adobe moved their product to a subscription model, service has have improved for people who use their products consistantly. But for people like me who only need it once every few years and at a moment’s notice, monthly or yearly payments are a terrible investment. I own an old copy of Photoshop, but even then the liscence is a pain to move from computer to computer — and if memory serves, it’I’m limited to the total number of computers it can ever rest on.

GIMP (GNU Image Manipulation Program) is a comparable, free and open source alternative. And in true Linux fashion, it focuses on a small core feature set to serve the vast majority of users’ needs while specialized functionality can be added with extensions. Contrast that with Photoshop loading every tool imaginable for everyone who won’t use but a quarter of them at most. In short: Photoshop has more polish, but GIMP is easier on system resources.

Selecting and Removing a Background

My church produces a photo directory every few years. Families grow, and pictures need updating. I was given a number of pictures and was expected to remove their backgrounds or else turn them white. Photoshop’s tool of choice would have been the quick select tool, but GIMP won’t have a perfect counterpart for this simple tool until GIMP 3.0. Instead, I taught myself the foreground select tool, which I would describe as resistant to learning by trial and error.

The foreground select tool has multiple phases. In GIMP 2.10 specifically, you start with a selection loop, overestimating your subject. You can use line segments or hand drawn boarders, whichever you deem most reasonable at the time. Endpoints are freely adjustable once you’ve closed the loop.

Hitting Enter will put you in phase 2. Here, the whole picture takes on a blue tint (The color is adjustable, but I didn’t learn how). The goal here is to paint in your clear foreground, heavily tinted background, and a lightly tinted buffer between them called “unknown” or “unknown pixels.” Tool options let you switch between what zone you’re painting.

Here, more than anywhere else, it’s particularly picky about keeping on task. I lost about two hours total because I did something just a little too unrelated and the foreground select tool sent me back to phase 1 with no way to undo. It is best to save other tasks in the workflow for later, like adding an alpha (transparency color) channel or duplicating/hiding the original picture layer for quick reference.

Phase 3 will “[calculate] the alpha value of unknown pixels” referring to your boarder zone. It provides a preview of exactly what you’re selecting and lets you make further adjustments, but it will recalculate everything each paintbrush stroke you make. I recommend finding the small dialogue box that lets you disable the preview, effectively reverting to the more economical phase 2. By going back and forth between these two phases, you can tell where the algorithm understands your selection and where it needs more help. Hitting one enter while in phase 3 will finalize your selection.

Training Family

One of the more rewarding parts of this experience was teaching my father this tool, though there were unique challenges. At one point, he was having frustrations getting the tool to cooperate. I had worked with this tool using two or three computers, but his description of what was happening sounded alien to my experiences.

I took a look at his workflow, and GIMP was skipping straight from what I’m calling phase 1 to phase 3, forcing him to use long strokes or face tons of extra recalculation time. Long story short, while I was trying to make his tool icons larger, I found he was on GIMP 2.8, the latest available in the Linux Mint repositories. The GIMP download page directed me to a GIMP 2.10 flatpack installer. The system still prefers GIMP 2.8 when unspecified, but he figured out how to proceed, so that’s a tech support topic for another day.

Color to Black and White

Later on, the software for the directory was making some pictures way too dark. Photoshop has a layer filter for this exact use case with six sliders to adjust different color ranges. GIMP doesn’t include any layer filters, but I was able to make a crude approximation of this tool. Just know there may be a better way to do this and I don’t know it — plugin or otherwise.

To make the perfect black and white version of a color picture, I would start by adding a white background and merging layers if necessary. Next, I menued over to an option to decompose the color channels to a new document. With each layer in grayscale, I added another white background and used Color to Alpha on the red, green, and blue color channel layers. I then adjusted the opacity of each layer until I had a result I was happy with.

Each picture was its own challenge. Most times, I would have one layer carrying most of the data while reducing the other two dramatically. Too little color data, and the picture would fade. Too much, and it would go dark. I targeted a mix where the picture would pop and my eye would relax a little while looking at it.

Takeaway

Both GIMP and Photoshop are wonderful pieces of software in their own rights. I’ve had a class on Photoshop, so of course I’m going to find it easier to navigate that program, even if it’s been years. Despite my slim requirements of advanced photo editing, GIMP’s slim feature set slimmed out a feature or two I miss.

Final Question

Have you taught yourself both Photoshop and GIMP? Which is harder to learn?

The Economy of Scale in Robotics

Good Morning from my Robotics Lab! This is Shadow_8472, and today, I am following up on last week’s post, covering my brief corrispondance with Artimus Robotics. Let’s get started!

I first approached Artimus through their site’s Contact Us page [1], where I provided some details about my project – a quadrupedal robot system aimed at hobbyists.

Sticker Shock

The next day, I received an email from Andrew Morton representing Artimus. “Our actuators start at $2,995 and it is another $1,995 for the rest of the kit (kit total starts at $4,990) [2].” He then directed me to the Application Assistant where I could provide more details about my application.

Ouch. I thought HASEL actuators were supposed to be made from relatively low-cost materials. But yeah, I understand: they have the research to pay for, they’re making everything to order, and it’s going to be more durable than something I assemble at home; and that’s just the costs I know about.

Lower Speccs

HASEL actuators reportedly compare relatively well to human skeletal muscle on several metrics [3]. I don’t need that level of performance. I’m also looking at potentially several dozen tiny muscles that only need a few pounds of pulling force. While it would be nice to see my robot galloping, jumping, and dancing, I’ll settle for standing up and walking around obsticles. Getting up and down stairs will be a luxury to strive for.

In all reality, I won’t need my eventual full strength actuators (I’m just going to call them muscles or artificial muscles for the remainder of this post) the moment I have my first fully assembled prototype – certanly not until I have the kinematics worked out. On the other hand, it’s not a bad idea to buy what you’ll need near the end with the idea that you’re not blowing money on as much intermediary equipment.

I went ahead and went through the Application Assistant. The form asked several important questions. What motion does my proposed actuator make? How much, hard, and fast does it move? How long should it last? What kind of space will it be installed in? How presicely controlled does it need to be? Will it need to be self-sensing? What are the most important characteristics you’re controlling for [1]? I answered as best I could, but I found myself leaving the form mostly blank or full of “TBD.”

I came to the last page where it asks for an overall description. I will also take this moment to note that I did not retain a copy of my exact wording, and none was ever echoed back to me. (If there’s one complaint I have with my experience, that would be it). I found myself weaving in most of the information I had put in different note fields, so I compiled it here and tidyed up on the other pages. I also expressed my concern at the up front cost, asking if they offered something like a junior developer’s kit for small scale projects.

Important Questions Without Answers

Hi [Shadow],

Thank you for providing the application details. Do you have a force or stroke specification for the actuators? These are the primary specs used to size an actuator. No problem if you don't have those yet as you're welcome to purchase a standard actuator development kit for preliminary testing to better understand the technology and your needs. I think that is the best path given the complexity of your project. 

We don't have any lower-budget actuators, just our standard actuators that start at $2995 or $4990 for the development kit. Please let me know if you would like a formal quote.

Thank you,

Andrew Morton [1]

At this point, I was coming to terms with the realization that Artimus will be out of my price range until I’m much deeper into prototyping. Even then, I may have a tough time keeping my unnofficial $5,000 goal unless the price comes down.

My reply ballparked my figures: a 20 inch robot, muscles ranging 1-4 inches long, 5-10 pounds of pulling force each, and the whole unit anywhere between 5-20 pounds [4]. Total guesswork on my part. But the focus was more on how my pockets weren’t that deep. I thanked Andrew for his time.

I still hope to work with Artimus in the future, even if it’s for my scaled up version.

Andrew got back to me in a third and final email, probably saving face as much as I was. As I suspected, they’re oriented around industrial clients right now, and smaller clients will be served well once economy of scale kicks in [1].

Takeaway

Going forward, it looks like homemade muscles will dominate my development process until I’m ready for something professionally assembled; my first prototypes may very well end up being powered by pneumatics. They won’t be untethered, but at least I can find the figures I need and get back in touch with Artimus when I’m ready.

Final Question

What artificial muscle technology would you recommend as an analogue for HASEL?

Works Cited

[1] Artimus Robotics. Accessed: June 29, 2021. Available: https://www.artimusrobotics.com.

[2] A. Morton. “Artimus Robotics Actuators” Personal emails (June 30-July 2, 2021).

[3] P. Rothemund, N. Kellaris, S. Mitchell, E. Acome, and C. Keplinger “HASEL Artificial Muscles for a New Generation of Lifelike Robots—Recent Progress and Future Opportunities” Nov. 2020 Advanced Materials vol. 33, issue 19, May 13, 2021 Available: https://onlinelibrary.wiley.com/doi/10.1002/adma.202003375. [Accessed: June 6, 2021]

[4] S. 8472. “Re: Artimus Robotics Actuators” Personal email (July 1, 2021)