Hi-Res Audio Software – Part 3 : CAO

A short follow-up on the last post.

I mentioned that all my software scripts were now fully updated and capable of working with hi-res audio files... except that CAO, whilst perfectly happy merging per-track hi-res FLACs into single composition-at-once hi-res FLACs was unable to reverse the process (whereas, for standard CD-audio resolution FLACs, the processes are completely reversible in either direction). [...] 

Continue Reading

Hi-Res Audio Software - Part 2

To re-cap: I'm not a fan of hi-res audio (i.e., anything with sampling rates and bit-depth greater than standard CD audio) myself, but I recognise that other people are, and for them my music management/playing software tools could usefully be modified to work with hi-res FLAC files. Accordingly, I have added the ability to play hi-res FLACs to AMP (version 1.19 and above). Additionally, I adjusted AUAC (version 2.05 and above) so that it could convert an SACD ISO to a hi-res FLAC, or convert a hi-res FLAC to a standard-res one.

Today, I bring the equivalent hi-res functionality to all my other tools. [...] 

Continue Reading

Hi-Res Audio

Let's begin by defining what 'hi-res audio' is, and then I'll explain why it's marketing baloney and no-one should touch it with a barge-pole... and why I've just enhanced my various software offerings to work with it anyway!

So, to begin at the beginning: there's a thing called the Nyquist-Shannon Sampling Theorem. It says that a continuous wave-form can be perfectly reproduced as a set of fixed, discrete samples if the waveform being sampled has a finite bandwidth, and your sampling rate is twice the maximum signal frequency. That is, so long as you can say 'this audio signal has a fixed upper-limit of (say) 20KHz', then it is mathematically provable that a sampling rate of 40KHz can capture that wave form perfectly. When the Sony and Philps engineers were developing the Compact Disc audio format in the 1970s, they relied on this theory to determine the characteristics of CD audio. Since the best human ear can really only hear up to 20KHz (and even then, you've got to be young and genetically-blessed to hear that high), we can record an orchestra and chop off any part of the audio signal above 20KHz and no-one will be any the wiser: we're disposing of frequencies no-one of mortal woman born can hear anyway. Then, once we have a continuous audio signal with a firm upper cut-off of 20KHz, we can digitise that by sampling the signal at 40KHz and be mathematically sure of being able to perfectly re-create the original analogue audio signal. Being clever people of the 1970s, however, the Philps and Sony engineers also realised that cut-off filters aren't linearly perfect. Tell them to cut off at 20KHz, and they'll maybe kick in a bit early and chop some sub-20KHz signal off, too; they'll alternatively knock-off a bit early and leave some 20KHz+ signal behind that ought to have been removed. Frequency filters being imperfect, therefore, the CD developers decided to cut a little slack for the filtering process and thus decided to cut off the audio signal at 22.05KHz, rather than at precisely 20KHz. The extra 2005Hz were there to deal with the electronic filtering imperfections of the time. The consequence of that is that for Nyquist-Shannon to remain applicable, the sampling rate had to be twice this higher 'highest frequency' - and that's why CDs have a sampling rate of 44,100 Hertz. [...] 

Continue Reading

Health Report…

Anyone paying attention to my listing of music I've been playing at home will have noticed that after playing at least half a dozen pieces a day (and often double that), I suddenly played nothing at all on 20th March and only managed a single play on 21st March, quite late in the evening.

I'm blaming Covid-19! Specifically, I was fortunate enough to receive my first dose of the Oxford-AstraZeneca vaccine on the Friday 19th March. The jab happened around 3.30pm, so quite late in the day, and afterwards everything was fine... until I woke up at around 1.30am that night/next morning with a dead left arm, shoulder to wrist; shivering, headache and feeling, essentially, dreadful. These are known side-effects of the vaccine and, unlike the Euro-invented blood-clotting ones, are real and can be quite nasty. It probably felt like the worst 'flu I've had in years, and in consequence I dosed myself up on paracetamol and aspirin, went to bed and stayed there. I felt really bad throughout Saturday 20th (hence the non-playing of music), and felt intermittently bad on the Sunday 21st (and hence the solitary play of something quite late in the day on that date, too). [...] 

Continue Reading

A Locking Problem

I have been aware for quite some time that, occasionally, plays of music made by AMP would not get recorded in the PLAYS table as they should. It's difficult to know precisely why: when you're developing the code and saving changes to the script as it's playing something, it could well be that your editing has caused the 'record in PLAYS' bit of code to get skipped.

Or it could be a locking issue. Putting it at its simplest, databases cannot have one person modifying data whilst simultaneously allowing a second person to read that data. If I am in the process of withdrawing £5000 from my bank account just as a credit check is being performed, do we let the credit agency see the £5000 in the account? Or do we see it missing the £5000, even though I might be about to type 'Cancel' at the ATM? To resolve these data concurrency issues, all databases implement a form of 'locking': if I am going to withdraw money from my account, we lock the data until my withdrawal is complete, so that no-one can see it, either with or without the £5000, then when I'm finished at the ATM, we unlock and people can read the definite results. [...] 

Continue Reading

Scarlatti In Bulk

Thanks to another recent video by David Hurwitz, I was finally persuaded to bite the bullet and splash out on the complete Domenico Scarlatti keyboard sonatas as performed by Scott Ross (the album artwork of which appears off to the left). It's a 34-CD collection, available for purchase from Presto Classical at only around £2.50 a box, which seems reasonable value to me.

Curiously, this collection of works has previously been discussed by me in comments on this blog piece, where I was asked by 'DACO' how I would go about tagging the multiple Chopin Nocturnes or the even more multitudinous Scarlatti keyboard sonatas. I had to answer DACO in that exchange in the abstract, since I didn't at that point actually own the Scarlatti. The general principle I advanced, however, was: group lots of little pieces together in whatever way makes them accessible and attractive to play. Thus, I could speak from experience: a CD of Britten arrangements of folksongs would be ripped and catalogued as a single collection of folksongs, rather than 21 short pieces of (usually) less than 3 minutes' duration. Similarly, I had only just completed a re-rip of the complete works of Percy Grainger, where because of the quantity of music involved, and its overall great similarity, I found it more expedient to essentially rip entire CDs as 'Grainger Compilations' than try to separate out each individual composition as its own 'album'. [...] 

Continue Reading

Colour Perception and Sorting

This is yet another story about AMP (my ever-evolving music player) being updated. This one, however, has a subtle twist that most of you probably won't care about, let alone make use of.

It's all to do with colour. In all my software, I try to use just four colours in a consistent way: (1) Terminal Default Foreground; (2) Bright Red; (3) Bright Yellow; and (4) Bright Blue. The terminal default will depend on what colour scheme you've configured your terminal to use. Commonly, as in the screenshot on the left, it's bright green for me and my desktops. It's used to display fairly 'static informational' text: things like the program name, the data labels and so on. Bright Red is used to display error or out-of-condition messages or alerts to program behaviours. Bright yellow is used to display user-input or fairly static information derived from user input (such as the folder path/name from which you're currently playing music). Finally, Bright Blue is used to display fairly dynamic text derived from user input (the name of the database you're using, for example, or any override switches you've specified that affects what music will be selected for play). I may not always be entirely consistent with the way I use my colours, but that's the general scheme I try to use and stick to, anyway! [...] 

Continue Reading

Cute Cat

For no particular reason, other than wanting to post something that didn't involve a new update to some software script or other, I would like to take this opportunity to share with you all the latest picture of Harper, my cat. He was a rescue cat -though the pound wouldn't tell us why and what he was rescued from. He did have an aversion to feet for a long time, though, so we figured he might have been the victim of some injudicious kicks in his time. I called him Harper because of the lines in 'To Kill a Mockingbird': "Remember it's a sin to kill a mockingbird. Mockingbirds don't do one thing but make music for us to enjoy…but sing their hearts out for us. That's why it's a sin to kill a mockingbird." It's a sin to kick a cat, too.

Anyway, he wouldn't have anything to do with me for the first year he was at home (in Australia). Literally: he wouldn't come to me for anything, wouldn't jump on my lap, nothing. A no-contact order was clearly in place. [...] 

Continue Reading

Tweaks and Twiddles

Another round of software tweaks and twiddles -mostly minor, some a little more significant.

First, AMP has been bumped a couple of notches to 1.16. It's mostly to do with a few colour tweaks, but also an annoying bug dealing with distros that don't have the 'bc' utility installed by default.  Those should all now work fine (so that's OpenSuse, Endeavour OS, Debian, Arch and Raspbian). [...] 

Continue Reading

SACD ISO: Knifing a Fork!

The world of open source software can sometimes be confusing, because if someone likes your code, they can take it and 'fork' it -that is, essentially, copy it and declare it to be a new piece of software altogether. As a mere user, it can then be difficult to know if you're supposed to use the original, or the copy (which, potentially, might be better than the original).

This is precisely what has happened to me and the utility needed to unpack/convert SACD ISO music files. [...] 

Continue Reading

Roller-coaster Ride

Today has been fun, in an up-and-down and terrifying sort of way!

First the good news: I finally managed to build a pure Arch-based virtual machine with no slip-ups, mistakes or catastrophes. Installing Arch is never for the faint-hearted and I've done it lots of times in the past... but never done it 'quite right', with always something missing or not-quite-working! I accordingly long ago gave up hope of ever achieving something that seemed stable and functional. But that run of ducks was broken today! Hurrah. (And I've written up how I did it here). [...] 

Continue Reading

Pi-faced!

A correspondent from the west coast of the USA recently got in touch to say that whilst he enjoyed using some of my music-related software, he regretted having to point out that the code didn't run properly on his Raspberry Pi running the Raspbian Linux distro ...but that he'd hacked a way to get it to work anyway.

A couple of thoughts came to mind when I read that. First, the grumpy-me thought that it was no wonder that the software didn't work on Raspbian, because I go to the effort of listing the distros I've actually tested my stuff on... and Raspbian isn't listed there! [...] 

Continue Reading