Wednesday 10 June 2020

MacOSx version from the command line

I have some old disks lying around and in "These Uncertain Times" (TM) was going through them to catalog with Neofinder (stunningly good application for cataloging all sorts of things and especially for offline disks/CDs etc.  Check it out at: https://www.cdfinder.de - unpaid promotion)

One of my disks looks to have a Carbon Copy Cloner backup of an old version of the OS.  I wanted to know which release it was, but realised I didn't know how to under MacOS. The normal Unix-y things of /etc/motd /etc/red-hat-release, etc don't exists as such,  After a few minutes looking around I found the following:

  • The command sw_vers is a command to print out the version of the running OS.
  • The man page for sw_vers refers to /System/Library/CoreServices/SystemVersion.plist
I could just dump the file, but after a few minutes looking at the file, I worked out the following:

  • /usr/libexec/PlistBuddy -c "Print:ProductName" -c "Print:ProductVersion"  -c "Print:ProductBuildVersion" /System/Library/CoreServices/SystemVersion.plist
and by extension:
  • /usr/libexec/PlistBuddy -c "Print:ProductName" -c "Print:ProductVersion"  -c "Print:ProductBuildVersion" /Volumes/Unknown-disk/System/Library/CoreServices/SystemVersion.plist
printed the MacOS version of the disk image in question.

Friday 5 June 2020

Recording Old LP's using Macintosh only software


The Old Records

I recovered some old records in the attic of my parents house that I'd not seen for a long time and wanted to digitise then to be able to listen to them again.  Unfortunately these had been stored in a plastic box underneath a leaky roof which had filled up with water, and the records were basically sitting in half a pool of water, and had been for at least 3-4 years.

The covers had stuck to the inner sleeves which had also stuck to the records.  Not a pretty sight:



Cleaning the Records

Wash

The first part of recovering these was to remove as much of the cardboard and paper that had stuck to the record as possible. This was done by soaking each on in a bath of hot soapy water and leaving them overnight.  Then gently removing as much of the paper as possible.  For some of the residue that was left, some isopropyl alcohol, cotton buds, and gentle rubbing was used to remove the glue.


However, this didn't get the dirt etc that had been engrained inside the grooves out.  So on to google and part 2.

PVA Glue

Some research showed that PVA glue may be able to help.   I bought some wood PVA glue from my local hardwire store an covered one side of the record with a layer of the glue.  This was all over the vinyl.  I left this to dry for a couple of days until it was 100% clear.  I used a Stanley knife to make a small cut on the lead in track of the record to get my fingernail under the glue and slowly, moved it would until I managed to get a reasonable portion loose.  I then lifted it off radially, and slowly.  It all came of slowly, and in one piece and removed about 99% of the dirt that was in the record.  Success.

Before:

Step 1 after applying the PVA glue:

Step 2 after 2 days drying:

Step 3 starting to remove the glue:

Result:


Recording Hardware

I wanted to use my latest iMac to record, but it doesn't have a line in socket.  My new MacBook pro doesn't either, so I had to go back to an old machine running Lion but it had the correct ports. Enter my first MacBook, the....

MacBook Pro 2006

My old workhorse with 2G of RAM and a 32bit Intel Core 2 duo processor had the correct hardware to be able to record.  The battery doesn't work, so it needs to be powered on the whole time, but it does still work.

Line in, connected from my Record Deck into the MacBook, and a simple grab of the file with QuickTime to save the audio worked. In the end I actually used used Audio Hijack to save to an AIFF file. Sorted.

UCA222 USB Sound

I was trying to find one of these USB sticks to record on my iMac, but they are as rare a hen's teeth at the time of writing, so I couldn't manage this.  Be wary of cheaper USB line in solutions, as 90% of them are Mono only, which won't work well for recording.  They focus on the Stereo output for headphones in the advertising, so look carefully.


Recording Software


CD Spin Doctor

I had an old version to Toast Titanium 10 which included CD Spin Doctor which had the click, pop and hiss reduction along with various other capturing tools.  I was wanting to run this, but it has been discontinued and, according to the Roxio website, only worked well on OSx 10.6.  I can confirm this as I'm running 10.7 on my MacBook, and its doesn't work on that.  Toast Crashes just after startup. Ah well, I thought, I have a VM and so I can fire up an old instance of OSx and run it in there, and also benefit for faster CPU speeds.


VM Fusion

I pulled out an old DVD copy of Snow Leopard (Since I received my first Mac in 2006, I've saved all of the install DVD's and downloaded images "just in case") and copied this to an iso image for Fusion.

Bad news, it seems that Fusion only goes back to 10.7, and I know for running 10.7 on my MacBook, that Toast doesn't work well on it.  A glimmer of hope though, Fusion does support OSX 10.6 server and I did have a valid copy of that with a serial number (Server releases came with registration keys)


Snow Leopard Server

Fire up Fusion, install Snow Leopard server and get it running.  I had to update to the latest patches after installing and install VMware tools.  However, it seems that Fusion running virtual hardware version 9 (or above, I assume) is too recent for Snow Leopard to identify a sound card, so it won't work.


Additional Changes to allow Sound Card

There are 2 ways to get around this.
  1. Shutdown the server, downgrade the virtual hardware on the server instance to 7 and reboot.
  2. Change the audio card setting in the vmx file.
I chose the latter option.  Closed the VM down and then edit the vmx file:
  • I changed sound.virtualDev = "hdaudio" to "es1371".
  • Since the VM didn't have a sound card, I needed to go into the settings for the VM and add a device, and then select 'Sound Card"
  • Another reboot.
One more thing.  I need to install a driver for this sound card, so that it actually works.  Fortunately, the VMware discussion boards came up with a solution: Sound with Snow Leopard Server on Snow Leopard in Fusion 4

I downloaded the package in the VM and ran it.

Sound was appearing and working.  Success.


Transfer of files into and out of VM and processing the audio

The normal way to transfer files in and out with a Fusion VM would be to drag and drop.  For some reason this appeared to work, and then didn't.  In the end I fell back to opening a terminal session and using scp to copy the files into the VM, worked on them with CD Spin Doctor, and then used scp to copy the resultant files back out to my main machine.

Problems with CD Spin Doctor

The main reason to use CD Spin Doctor was the de-click and de-hiss options for the filters.  A secondary use was to split the files into tracks and save them for importing into iTunes later.  Unfortunately, the latter of these features didn't seem to work at all.  Every active track saved was save with the correct meta information, the correct duration, but they all started at the start of the recording, and not where they were supposed to.

Rather than try to work out why this was the case, I just used the CD Spin Doctor filters on the whole audio file and then copied it bak to the main Mac for splitting up with either Fission or Audacity.

After processing them as AIFF format, I then use "MediaHuman Audio Converter" to convert to m4a before tagging and adding to iTunes.