Monday, December 31, 2018

Improving the Classics

I looked at some IBM assembler code from ~ 35+ years ago (support for some FORTRAN games ported from MUSIC to IBM VM/CMS). While it worked fine, it truly offended me. In particular, I felt driven to rewrote 32 lines into 9. (The 9 lines doesn't count the pair of simple FORTRAN programs I wrote to test the routines BEFORE I modified them. THAT's something I've learned to do since 1980 ....) Looking at the old code, I'm reminded of Cargo Cult Programming -- the old code did the right things, but it was redundant and did things by hand that macros could do for the past fifty years. It was all as if the coder didn't really grasp what they could do ... I'm sure I've seen and probably touched the code before, but I never wrote code this ugly -- I know, as I've got code samples from the era this was written, and I if nothing else I didn't code stuff by hand that macros existed for. I've also commented my code better since I was a freshman. (My old schoolmates would beg to differ about a help script I wrote for the Clarkson ROSCOE time sharing system. It was labeled as "Funky Subroutine #20", which none of us could decipher a few weeks later, wasn't deliberately obfuscated, but it was dense, like an APL one-liner -- write only code. Hey, it worked.)

Monday, November 5, 2018

Turnaucka’s Law (Automotive Edition)

In my previous post, I noted that Purr More the Aqua has updated electronics.  This is perhaps the biggest change between the model years, as it now has its own 4G cell service for enhanced traffic information, emergency calls, concierge service, telemetry, stolen vehicle tracking, and limited remote control.

It's all very cool. It also reminds me that I have said more than once that the 2016 MINI was one firmware upgrade away from being a charter member of Skynet. These changes are a serious upgrade, and now they can directly push more updates over the air.

Info Page of MINI Connected
(from the iPhone App)
The spooky thing is that it knows more than it explicitly publicizes. For instance, in the mock up of the car above from the companion iPhone application, it shows that the car is a convertible Cooper S, and all the customizations, including color, bonnet stripes, wheels, fog lights, headlight rims and even the mirror caps correctly.  It also has (if one scrolls down) our exact current mileage.

I didn't see any agreement that we were "serfs to global domination" in the Terms and Conditions. Katherine wonders if we should have read it more carefully before we agreed.

We do have Turnaucka’s Law:
The attention span of a computer is only as long as its electrical cord.
Where's the fuse panel on the 2019 MINI?

Sunday, November 4, 2018

It's Here! It's here! (Announcing Purr More the Aqua)

So once upon a time we replaced our 2006 rag top MINI with a 2016 rag top MINI . The plan was for it to have an equally a long, useful, and fun life.

It didn't work out that way. After about a year, the top, which only requires a single switch to raise and lower completely, didn't. It would fail every few months, Katherine would get out the Allen wrench to do the emergency close procedure, and then she would call Seattle MINI. They could see the problem code in the car's computer, but could never reproduce it. They tried (and I mean tried hard!), but modern integrated electronics are not something mortals can disassemble in the field.

To make a long story short, due to the top issues, we had the car declared a lemon. We ordered a 2019 replacement in late August, and we surrendered the 2016 MINI to MINI/BMW on September 14th. We were treated well by the dealer and MINI Corporate, and we've moved on.

This past Friday, our lovely 2019 MINI arrived. It's Caribbean Aqua in color, has more advanced electronics by three model years, an apparently working top, and otherwise feels very much like its now departed predecessor.

A friend of Katherine's hopped in it today and said "Did you get this painted?  I was sure this car was silver". That's an easy mistake to make. They are the same generation, and a guest won't notice subtle differences in the stereo or a repurposed switch or two.

Live Long and Motor, little MINI Cooper.

Presenting our 2019 MINI Cooper S Convertible, Purr More the Aqua.
(Click the picture for the full size edition)

Thursday, November 1, 2018

The Wayback Machine, Computer Languages Edition

A couple of days ago, I posted on Facebook:
FORTRAN is the first high language I learned. It's clearly also the first one I forgot...
which led to an amusing thread with friends who knew me back in college.

It turns out my command of FORTRAN isn't lost, it's just my brain hid it somewhere. This was no doubt a vain attempt to save my sanity. Now (with the occasional help of a few choice archival sites on the web) the FORTRAN is coming back ... with a vengeance.

To wit, I offer this gem from code I wrote in high school:
WEK DAY = MOD(WEK DAY - 1 + MONTH(B), 7) + 1
That is valid code, because FORTRAN doesn't tokenize on spaces. That is, WEKDAY could be spelled WEK DAY or W E K D A Y; they are all the same valid FORTRAN variable. (Tokens were something for subway turnstiles when FORTRAN was invented.)

At least I commented the program sometime in college. The first version from high school had minimal comments, as I originally wrote it on a 029 keypunch. (If you ever used a keypunch with its lack of an erasing backspace, you would understand.)

Shockingly enough, the program, written in 1978, was not Y2K ready. Let me see what I can do about that . . .

Note: My sanity is not lost, it's backed up on tape, somewhere.

Wednesday, June 27, 2018

And So Began The Descent Into Darkness ...

Pulling files from a software archive I created in the 1980s to load onto a computer built in the 1980s, I came across this gem:
My Access Request For UNIX While At Link FSD
I knew I was headed back to Clarkson University with its VM, VMS, Z-100 (MS-DOS) and UNIX systems. Clearly I wanted to be ready.

A random note is that the memo is old enough I was still using "Andrew" even though people tended to shorten it to the disdained "Andy". I switched to "Drew" when I went back to school that fall by changing my name in my sent email headers. That was enough to make it stick even though my account was $AHD (or ahd) on various school systems.

So began my descent into computers not made by IBM.

Monday, June 4, 2018

Marrying Within One's Species

Once upon a time, I needed a 30" monitor. I say "needed" because my second work portable, a MacBook Pro with an early Display Port, didn't play well with my original 30" monitor which required the notoriously flaky Apple Display Port to Dual DVI adapter. And I definitely wasn't in the mood to fight my monitor whenever the pager went off at 3:07 AM. It's sort of an odd (but honest) definition of need.

For those keeping score, this means I would have two 30" monitors. Many households would consider one 30" monitor excessive, especially since I also had a 24" loaner monitor from work. Thus, Spousal Approval Factor (SAF) was not a trivial consideration.

However, I married within my species. We were not even dating yet when when I asked to use Katherine's initials for kew.com, and, like a true MIT geek, she thought it was cool. Likewise, she was cool with the monitor, especially since she knew about my on-call duties.

(Apple later replaced the adapter free of charge, which tells you what they thought of the original revision. But this was months afterwards.)

It's nice to be understood as the years go by. But even with an inventory that includes eight Raspberry Pi computers, five networked stereos, four Macs, three Wifi access points and a nearly fully 24 port network switch in the pantry, I still try to have good manners. Trust but verify, as Ronald Reagan once said.

Which brings us to this weekend. A Raspberry Pi 2 provided network management at the Kitten Farm Pacific Northwest, and yesterday during routine updates it decided to scramble the SD card it used as its disk. This was not good, but not fatal -- there's a reason I backup each Raspberry Pi's configuration and other critical data nightly.

I twiddled the router to take on additional duties and get the house back on the Internet, and then I had to decide what do to about the dead machine:

  • Try fixing the current disk or
  • Bring a new (faster) machine online.
I chose the latter, and got things squared away enough by the evening to put the new machine online.

So, the replacement was online but still sitting on my desk. I then physically looked at the beast. The old unit had a dark opaque case which gave it low visibility; the new one was ... different. It dawned on me that the style conscious among us may feel a clear box with glowing LEDs and the general appearance of the incubator for a baby Terminator does not belong on the living room entertainment center. So I asked.

The Terminator Incubator

Katherine's reply: "That's fine. Entertainment Centers are often the geekiest part of a house. And anyone who walks into this house should know what to expect."

I definitely married within my species.

Update: A different, faster machine went downstairs. Thus the case ended up being a bright semi-transparent pink, not clear. Also spouse approved, of course.

p.s. She has bought me three smaller monitors for various purposes since I got the second 30" monitor. Is that love or what?

Wednesday, April 11, 2018

A Reading from The Book of Internet Security

Two-factor authentication (also known as 2FA) is a type (subset) of multi-factor authentication. It is a method of confirming a user's claimed identity by utilizing a combination of two different factors: 1) something they know, and 2) something they have.
-- Wikipedia
I have two factor authentication set up via Google Authenticator (Microsoft Authenticator works the same way) for:
  • Amazon
  • BitBucket
  • Facebook
  • GitHub
  • Google
  • LastPass
  • TunnelBroker.net
  • Microsoft, and
  • The Raspberry Pi downstairs sitting by my home Internet router.
I've also got two factor set via text message/email for Vanguard, Twitter, and others. These methods are not as secure as Google/Microsoft Authenticator (your phone number and/or email can be hijacked), but it's better than thinking no one will try to hack an account.

Actually, you or I personally won't be hacked, unless you ticked off the Russians or the Chinese -- our accounts are just a entry on a list, and someone is hacking the entire list. Your accounts are or will be a malware statistic. Mine won't, because I've got two factor on them.

So go through all your supported accounts (all, even the ones you never use) and put two factor on them today. Don't know where to start? Try here. As to when do it, the best answer is yesterday. So do it now.

p.s. Some of the sites I listed also support YubiKey -- it's also secure, and I use that when possible. But the point is, I do something for two factor whenever possible.

Tuesday, February 13, 2018

The Things I Do For Love (or, How Not to Spend Your Day)

grumble . . .

Ten years ago this spring, I ordered a monster Mac Pro:
  • Eight 3.2 Ghz processor cores, 
  • 8G of memory, 
  • Dual video cards (to drive up to 4 30" monitors)
  • 30" HP Monitor
  • Two 500 GB drives
  • Two Ethernet ports
  • WiFi
  • Bluetooth
The PC tower-sized case was all aluminum, and the beast weighed ~ 42 pounds. The primary internal upgrades to it over the years has been two SSD drives (160GB and 500GB) and a USB 3 card. Thus configured, it can compete with far more recent machines; it is worthy of its name "xena, the Warrior system".

It can even boot Windows 10 Pro 64-bit (the 160GB SSD was dedicated to that.)

Last spring, I switched to a new iMac for non-performance related reasons:
  • Parity with Katherine's Mac (replaced at the same time),
  • Lower power consumption, 
  • Support for newer MacOS operating systems. 
xena retired to the library, where I would wake it up every few weeks or months to update its software. When it has been awake, I have slowly purged various software and data off it (we *really* don't need a third copy of the ~8900 track music library or extra copies of various disk hogging virtual machines). The reduced space requirement meant I could move Windows 10 over to the 500GB SSD and use the 160GB SSD elsewhere, such as on one our proliferating Raspberry Pi systems.

Alas, I forgot I would be dealing with Microsoft licensing.

I had played Mr. Potato Head with xena when it moved and replaced the monitor, USB hubs, keyboard, & mouse, and pulled the 160 GB SSD drive. Internally, it was still the original internal configuration except for the missing SSD. But when I reinstalled Windows 10 on a second partition of the 500GB drive, Windows announced it could not be customized until it was activated, and it could not be activated because it wasn't the same system. It suggested that "please visit the Microsoft Store ...".

I
didn't think Theseus's paradox applied, but I'm not Microsoft.

So I plugged in most of the external peripherals I had on xena when it in was my office, reinstalled the SSD drive, and rebooted. Windows Pro 10 then said that it was installed on top of a previous version that had never been activated, and "please visit the Microsoft Store ...".

The primary factors that kept the xena from being thrown out the nearest window were a) that window does not open and b) the xena is not a petite machine.

I did the smart thing and went out to dinner.

Then I reinstalled again. First I put on Windows 7 64-bit, then activated it, and then upgraded to Windows 10 Pro. I then signed into my Hotmail (Microsoft account).

Voila!
I'm not quite sure what I did different, but Windows 10 Pro is happily fully functional. Now if I only knew what secret sauce I applied this time ...

. . . grumble