Files

147 lines
9.2 KiB
Plaintext
Raw Permalink Normal View History

Episode: 375
Title: HPR0375: SAP - the Simple Audio Player
Source: https://hub.hackerpublicradio.org/ccdn.php?filename=/eps/hpr0375/hpr0375.mp3
Transcribed: 2025-10-07 19:19:21
---
music
music
music
music
music
music
music
music
music
I don't know, I don't know, I don't know
I don't know, I don't know
I don't know
I don't know
I don't know
I don't know
I don't know
I don't know
I don't know
Hello, this is Lost in Bronx
Today I want to talk to you about SAP, the simple audio player
This is a command line application for, as you can imagine, playing audio files
It's written by a fine BeWhiskard fellow named Jezra, who can be found at Jezra.net
SAP itself is at Jezra.net slash projects slash SAP
I'll have an easy link in the show notes
SAP uses the G-streamer library and can play any format that G-streamer can
and it's as simple to use as its name promises
I installed versions 0.4.1, but the current version, as of this recording, is 0.4.3
Either way, it's very early in its development and that development is active
and while there are features and capabilities I'd like to see implemented in the future, which I'll get to in a bit
I don't think there's much more that can be done without turning it into something that it's not intended to be
So what is it intended to be?
Well, the name says it all
Here's an example
You open your shell and type in SAP, SAP, then space, and then the path name to an audio file, enter
It will begin to play
The controls for the app are as follows
You use the arrow keys with the up being volume up, down being volume down, left being seek backward, right being seek forward,
space bar is pause, and Q quits the application
There are also some VIM-like controls that do the same thing for those of you who are fans of that, which I'm not
So I don't remember what they are and could care less, actually
But I mention it in case you do
When the file is done playing or when you hit Q, it exits back to a prompt
And that's it, nothing fancy
Will it compile on a Mac?
No clue
Will it compile on Windows?
No clue, but I'd say probably not
It certainly compiles and runs on Linux though, and for me, that's plenty
So yes, it's very nice, but it ain't perfect
The biggest issue I have with it is how difficult such a simple application is to install
Now, let me preface this piece of criticism with the confession that I really don't know what I'm doing
I'm a lot more comfortable in the command line than I was in days past, but that doesn't make me a geek
I'm just trying to get by
So far, there are no binary packages for SAP, which only leaves compiling from source
Now for some, that's the preferred method, right?
But for others, like me, it's a mighty challenge
If something goes along in the compile, the errors are meaningless to me
And in fact, there was no if about that
My first attempt failed with mighty fury
Luckily, Jezre walked me through it, and I was finally able to get it compiled
Unfortunately, I was on a machine that turned out to have a sound card issue
So while I'm reasonably sure that the compilation went well, I can't confirm it for that machine
But I was not done trying
Oh no, on Jezre's say so, I was able to take that binary
Which I'd compiled on an i386 machine, copy it onto a thumb drive, and install it on a triple EPC 701 surf
Running eBunt2 1.0, which is essentially hardy heron
I put it into slash user, slash local, slash bin, so it was in my path
And then I typed SAP in the name of an audiophile, and I was listening to music
Okay, the pros, first
Well, it sure was nice to use it on the triple EPC without having to compile it again
Got to give it thumbs up there for effort saved
Next, it's little
I like my apps, small and fast like a bullet, and SAP qualifies
It does one job, and does it well, sweet and unicy
Next, it can play remote audiophiles via HTTP
You just type in a web address instead of a local file address, and it'll play
If you have a decent enough connection, therefore, you can listen to your music or podcasts
As if they were live streams, instead of waiting for them to download
Kind of cool, I think, for a tiny application
And next, just reset up a page for it at launchpad
So it has the proper repository, version control, and bug tracking tools that any well-maintained project ought to have
In other words, he takes it seriously, small though it is
Now that's at HTTPS colon slash slash launchpad.net slash SAP plus sign
You know, it's got one of those little plus sign thingies at the end
Anyway
The cons, in no particular order
First, SAP clears the command line, which gets rid of my previous file listings on the screen
No big deal, but it would be nice if it just depended itself to the end of the printout instead of clearing the screen
And then leaving it cleared when the file closes
I tend to use the command line itself as my file manager of choice
After SAP finishes playing a file, the return from my previous LS command, which I almost certainly had up to find the file that played, is gone
And I have to enter it again
Yes, yes, it's simplicity itself to do, just tap the up arrow twice and then enter and it's back again
But that's extra keystrokes, which if SAP left the screen up instead of clearing it wouldn't be needed
Like I said, it's a little thing, but little applications should excel at little things, I believe
Okay, next, ease of use and simplicity, notwithstanding, I'd very much like it if it could play an entire folder, which is a poor man's playlist
You know, one file after another in a folder, it tries to, but it can't
I'd like to be able to type in the path to a folder of music and let her rip
0.4.3, which is the current version I'm launch pad as of this recording, is stated to now have playlists support
So I guess my frown could turn upside down if I installed the latest version
Except that I don't like playlists, I like directories, you know, folders
Next, fast forward and fast backward go by at 5% at a time, that is each increment of the fast forward or fast backward keys
Right and left arrows is worth 5% of the file that's playing
I would like more fine grain control over this, longer files can skip several minutes at a time, at 5% per
Next, SAP can play remote audio files, as I said, but it does not do actual live audio streams
It would be awesome if it did, but you put in a stream address, it acts like it's buffering or something, but it never plays
Next, a successful compilation spits out the following warning, or something similar for you
Slash home, slash lost in Bronx, in my case, slash SAP, slash audio player, dot-bara, dot-c, colon 269, colon space, warning, colon passing argument 2 of double quote, GST, blah blah blah
I'll put it in the show notes
The gist is that this is just a warning, not an error, and the application compiles just fine despite it
It's weird to see, though, and, thusly, worthy of a bug report which has been made, not by me, because I don't know how to do that
Unless you count crabbing at Jezura about it, because if you do, like I do, then I did
And, next, and finally, probably the most serious issue for people like myself
Serious enough that I repeat it now is that, as of this recording, SAP has no pre-built binary packages available for it
As I assume you've gathered by now, compiling isn't my strength
I was able to get the binary I had successfully compiled to run easily on the triple EPC, as I said
But that same binary would not run on our 64-bit machine, also running a bunch too hardy
It seemed to be a library issue, which I couldn't resolve, despite Jezura's valiant attempt at help
I tried to compile it on this machine as well, but I got into dependency hell almost immediately
Once built, SAP is only about 45 kilobytes, but I had to install much more than that in dependencies and compiling tools and libraries
I mean, I told you I don't do much compiling, so this box was not ready for any of it
Even then, after putting on what I thought were the right tools, it was still a no-go
Understand, this is all about my lack of skill, and not about SAP being badly written or anything
But then, that's why it'd be really nice to have a way of installing it that didn't require skill
This episode of HPR is about a piece of software, and not about the obvious merits of me learning how to compile a piece of software
So, on that point alone, packages would be nice
Currently, Jezura is the only developer, he can only do what he can do
If others want to get involved with it, maybe my idiot install might come about, which I'd very much like
And that amounts to all the problems for me
I guess I had a lot to say about what I didn't like, but a pound of it don't weigh in-outs as my poor old broken-down mother would say
None of what I'd like to see put into SAP sometime in the far-off, misty future takes away from what it already does well and simply
Which is play audio from the command line
So, if you're in the market for a very lightweight command line interface audio player
And you're better at compiling from source than I am, which pretty much everyone is, then take a look at SAP
It's small, it's cool, it's GPLV3, and it just might scratch you where you which
This has been Lost in Bronx, take care
Thank you for listening to Hack with Public Radio
HPR is sponsored by Carol.net, so head on over to C-A-R-O.N-C for all of her team
You