203 lines
14 KiB
HTML
Executable File
203 lines
14 KiB
HTML
Executable File
<!DOCTYPE html>
|
||
<html>
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<meta name="generator" content="pandoc">
|
||
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">
|
||
<meta name="author" content="Dave Morriss">
|
||
<title>How I manage podcast listening (HPR Show 3161)</title>
|
||
<style type="text/css">code{white-space: pre;}</style>
|
||
<!--[if lt IE 9]>
|
||
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
|
||
<![endif]-->
|
||
<link rel="stylesheet" href="http://hackerpublicradio.org/css/hpr.css">
|
||
</head>
|
||
|
||
<body id="home">
|
||
<div id="container" class="shadow">
|
||
<header>
|
||
<h1 class="title">How I manage podcast listening (HPR Show 3161)</h1>
|
||
<h2 class="subtitle">Another reply to MrX’s episode on how he listens to podcasts</h2>
|
||
<h2 class="author">Dave Morriss</h2>
|
||
<hr/>
|
||
</header>
|
||
|
||
<main id="maincontent">
|
||
<article>
|
||
<header>
|
||
<h1>Table of Contents</h1>
|
||
<nav id="TOC">
|
||
<ul>
|
||
<li><a href="#introduction">Introduction</a></li>
|
||
<li><a href="#playing-podcasts">Playing podcasts</a>
|
||
<ul>
|
||
<li><a href="#overview">Overview</a></li>
|
||
<li><a href="#uploading-feed-contents-to-a-player">Uploading feed contents to a player</a></li>
|
||
<li><a href="#managing-episodes">Managing episodes</a></li>
|
||
<li><a href="#managing-id3-and-similar-tags-on-episodes">Managing ID3 and similar tags on episodes</a></li>
|
||
</ul></li>
|
||
<li><a href="#links">Links</a></li>
|
||
</ul>
|
||
</nav>
|
||
</header>
|
||
<h2 id="introduction">Introduction</h2>
|
||
<p>I have spoken in the past about the <a href="https://hackerpublicradio.org/eps/hpr2211" title="My podcast workflow">podcast management system</a> I have created, but have never gone into much detail about how I manage the playing of episodes.</p>
|
||
<p>Prompted by <a href="http://hackerpublicradio.org/correspondents.php?hostid=201">MrX’s</a> <a href="https://hackerpublicradio.org/eps/hpr3132" title="Keeping track of where I am">HPR episode hpr3132, “Keeping track of where I am”</a> I will describe it now.</p>
|
||
<h2 id="playing-podcasts">Playing podcasts</h2>
|
||
<h3 id="overview">Overview</h3>
|
||
<ul>
|
||
<li>Details of all my podcasts are in a database which runs on my desktop PC
|
||
<ul>
|
||
<li>I keep details from the feed for each episode</li>
|
||
<li>If I currently hold a relating to an episode file then the database knows the path to it</li>
|
||
<li>Since I’m a <em>hoarder</em>, I keep episode details in the database for episodes I have already listened to.</li>
|
||
</ul></li>
|
||
</ul>
|
||
<ul>
|
||
<li>Every podcast feed is assigned to a group. I have groups such as <em>music</em>, <em>science</em>, <em>documentary</em> and <em>technical</em>.</li>
|
||
</ul>
|
||
<ul>
|
||
<li>I interface to the database on my desktop PC using command-line scripts and through Pdmenu menus.</li>
|
||
<li>The episodes are on a Raspberry Pi which runs all the time and has an SSD attached, and I mount the podcast directory on my desktop using NFS</li>
|
||
<li>I download podcast episodes overnight on the RPi using a locally hacked version of the venerable <code>Bashpodder</code>, which I have talked about in the past.</li>
|
||
</ul>
|
||
<ul>
|
||
<li>I have several MP3 players with Rockbox installed</li>
|
||
<li>I usually load my players using a script that is aware of the feed groupings that I have defined. It makes a playlist in the database and writes a copy on the player. The database playlist table holds the alias of the player so I can have a playlist per player in it.</li>
|
||
<li>I have another script which can upload the contents of a feed for when that is convenient.</li>
|
||
</ul>
|
||
<ul>
|
||
<li>As I play an episode I run a script that marks that episode in the database as being played.</li>
|
||
<li>It’s Rockbox that tracks which episode I’m listening to and where I am in the audio on the player</li>
|
||
</ul>
|
||
<ul>
|
||
<li>After playing an episode I run a script that lists episodes marked <em>playing</em> and allows me to delete them from my PC and from the database</li>
|
||
<li>I don’t actually delete anything from the player until I next upload to it</li>
|
||
</ul>
|
||
<ul>
|
||
<li>There is an issue with the size of a group and the space on a player. This has worsened recently because I don’t seem to be able to listen to podcasts fast enough and most of my players don’t have a huge amount of space on them.</li>
|
||
<li>Since I don’t delete files on the player until I upload new ones I don’t always know how much space there will be. I have to find a solution to this!</li>
|
||
<li>I have a script that shows numbers of files and total sizes for the groups, both for files copied to players and those pending. I plan to use these sizes to make decisions about what gets uploaded.</li>
|
||
<li>In the worst case I can write episodes to a player selected by feed name if there are capacity issues.</li>
|
||
</ul>
|
||
<h3 id="uploading-feed-contents-to-a-player">Uploading feed contents to a player</h3>
|
||
<p>The player being used in this example is a Sansa Clip with an alias of <code>'Clip'</code>. This player (as with most of my players) runs Rockbox. It gets mounted on <code>/media/usb2</code>. The commands that are run (by the alias <code>player_mount</code>) look on the player for a file called <code>PlayerName</code> and display it using <code>figlet</code>:</p>
|
||
<pre><code>$ player_mount
|
||
____ _ _
|
||
/ ___| (_)_ __
|
||
| | | | | '_ \
|
||
| |___| | | |_) |
|
||
\____|_|_| .__/
|
||
|_|</code></pre>
|
||
<p>Next, the script <code>copy_episodes</code> performs the upload of episodes from a particular feed. The <code>-c C</code> option says to remove any media found in the <code>PODCASTS</code> directory on the player. Using <code>-c N</code> allows further feeds to be appended to what’s already on the player. The feed name is a regular expression, so <code>'Hacker'</code> maps to <em>Hacker Public Radio</em>. The script generates a playlist on the player in the <code>Playlists</code> directory for use by Rockbox, it’s called <code>podcasts.m3u</code> and contains paths to the episodes which are relative to the player.</p>
|
||
<pre><code>$ ./copy_episodes -m /media/usb2 -p Clip -c C -f Hacker
|
||
Warning: There are already files on the player
|
||
Deleting media files
|
||
Copying files from feed 'Hacker' to the Clip player
|
||
1: /home/cendjm/Bashpodder/Podcasts/2020-08-14/hpr3140.ogg
|
||
2: /home/cendjm/Bashpodder/Podcasts/2020-08-17/hpr3141.ogg
|
||
3: /home/cendjm/Bashpodder/Podcasts/2020-08-18/hpr3142.ogg
|
||
4: /home/cendjm/Bashpodder/Podcasts/2020-08-19/hpr3143.ogg
|
||
5: /home/cendjm/Bashpodder/Podcasts/2020-08-20/hpr3144.ogg
|
||
6: /home/cendjm/Bashpodder/Podcasts/2020-08-21/hpr3145.ogg
|
||
7: /home/cendjm/Bashpodder/Podcasts/2020-08-24/hpr3146.ogg
|
||
Created playlist
|
||
COPY 7
|
||
NOTICE: Rows changed = 7
|
||
$ player_umount</code></pre>
|
||
<p>There is a backup of the playlist on the PC and the <code>playlists</code> table in the database is also updated. The messages <code>'COPY 7'</code> and <code>'NOTICE: Rows changed = 7'</code> are generated by the database for debugging purposes.</p>
|
||
<p>I use an alternative script (<code>copy_group</code>) when uploading episodes to a player by group.</p>
|
||
<p>The alias <code>player_umount</code> unmounts the player.</p>
|
||
<p>The playlist is used on the player by navigating to the <code>'Playlist Catalogue'</code> entry in the main menu. Clicking the central button on the Sansa Clip shows the list with the name <code>'podcasts'</code>. Clicking on that shows a numbered list of episodes. Clicking on the first entry starts the playing of the playlist.</p>
|
||
<p>My Rockbox players are set to write a bookmark for the currently playing episode when the player is turned off. They are also set to auto-resume after stopping, so I can stop and turn off during the playback of an episode and the player will resume where I left off when I turn it on again. If for any reason I navigate away from the playlist I can get back to where I was with the <code>'Resume Playback'</code> item on the main menu, or I could look in <code>'Recent Bookmarks'</code> to find the bookmark for what was being played before.</p>
|
||
<p>My Rockbox player collection:</p>
|
||
<pre><code> alias | manufacturer | model | gigs
|
||
---------+--------------+----------------+------
|
||
Fuze | SanDisk | Sansa Fuze V2 | 16GB
|
||
Clip | SanDisk | Sansa Clip+ | 8GB
|
||
H10 | iRiver | H10 | 5GB
|
||
Clip3 | SanDisk | Sansa Clip+ | 4GB
|
||
Mini | Apple | iPod Mini | 4GB
|
||
H10-6GB | iRiver | H10 | 6GB
|
||
Fuze2 | SanDisk | Sansa Fuze V1 | 2GB
|
||
Clip2 | SanDisk | Sansa Clip+ | 8GB
|
||
Fuze3 | SanDisk | Sansa Fuze | 6GB
|
||
Fuze4 | SanDisk | Sansa Fuze V1 | 4GB
|
||
Zip1 | SanDisk | Sansa Clip Zip | 4GB
|
||
Zip2 | SanDisk | Sansa Clip Zip | 4GB</code></pre>
|
||
<h3 id="managing-episodes">Managing episodes</h3>
|
||
<p>I run several scripts to mark episodes as being played and to delete those I have listened to. The following is an edited transcript.</p>
|
||
<p>The first section shows what’s active on any players known to the database. The <code>'Clip'</code> player has the HPR episodes added above, none of which have yet been played. I’m up to podcast episode 38 on the playlist for the <code>'Zip2'</code> player.</p>
|
||
<pre><code> 1 [Clip,01] HPR: GIMP: Selection Tools
|
||
2 [Clip,02] HPR: Lessons learnt from Magic the Gathering game design
|
||
3 [Clip,03] HPR: tcsh
|
||
4 [Clip,04] HPR: LibreOffice 7.0 Released!
|
||
5 [Clip,05] HPR: Pentesting: Insecure Object Reference
|
||
6 [Clip,06] HPR: A light bulb moment, part 1
|
||
7 [Clip,07] HPR: Help Me Help you with HPR eps!
|
||
|
||
8 [Zip2,38] mintCast 338 - Two Oh Snap
|
||
9 [Zip2,39] mintCast 338.5 - The Ripple Effect
|
||
10 [Zip2,40] mintCast 339 - OLTs? More Like OLGeez
|
||
11 [Zip2,41] mintCast 339.5 - ZFS Butter Recognize
|
||
12 [Zip2,42] mintCast 340 - Unit of Measurement
|
||
13 [Zip2,43] mintCast 340.5 - Will It Blend?
|
||
.
|
||
.
|
||
.
|
||
Select number(s): 8
|
||
Marking:
|
||
8: mintCast 338 - Two Oh Snap
|
||
Made 1 change(s)
|
||
01: [Zip2 ] mintCast 337.5 - Managing the Managers
|
||
02: [Zip2 ] mintCast 338 - Two Oh Snap
|
||
Select numbers: 1
|
||
Deleting:
|
||
1: mintCast 337.5 - Managing the Managers</code></pre>
|
||
<p>I truncated the complete list on <code>'Zip2'</code>. The prompt <code>'Select number(s):'</code> is asking which of these episodes I’m next going to listen to. I select 8, which is a <em>mintCast</em> episode on the <code>'Zip2'</code> player.</p>
|
||
<p>The next prompt <code>'Select numbers:'</code> follows a list of episodes currently marked as being played. I select number 1, the previous <em>mintCast</em> episode I just finished. This is then deleted and the database updated.</p>
|
||
<p>The listing then shows how many podcast files still exist, with their cumulative size. This is followed by a (truncated) list of durations of the remaining episodes. I currently have 1 week, 1 day, 47 minutes and 58 seconds of continuous listening to catch up with my 10GB of podcasts!</p>
|
||
<pre><code>Total = 262 (83 directories)
|
||
10G Podcasts/
|
||
|
||
[2020-08-24 09:00:53] 01 weeks, 1 days, 01 hours, 57 minutes, 02 seconds
|
||
[2020-08-24 11:02:42] 01 weeks, 1 days, 00 hours, 47 minutes, 58 seconds
|
||
--------------------------------------------------------------------------------
|
||
Player: Zip2
|
||
Album: MP3 - mintCast
|
||
Artist: mintCast
|
||
Title: mintCast 338 - Two Oh Snap
|
||
Length: 01:13:31
|
||
Genre: Podcast
|
||
Track: 338
|
||
Year: 2020
|
||
Comment: The podcast by the Linux Mint community for all users of Linux.
|
||
Path: /home/cendjm/Bashpodder/Podcasts/2020-07-02/ep338.mp3
|
||
--------------------------------------------------------------------------------</code></pre>
|
||
<p>Finally a display script is run against all episodes marked as <em>playing</em> to show a summary of what is being listened to on my players.</p>
|
||
<p>I usually only have a maximum of three players active at any time. That way, I can change to another player when the one I’m listening to needs its battery recharged.</p>
|
||
<h3 id="managing-id3-and-similar-tags-on-episodes">Managing ID3 and similar tags on episodes</h3>
|
||
<p>As I process the day’s batch of incoming podcasts I manipulate the audio metadata (<em>tags</em>). I have a Perl script I wrote which uses a rules file for each feed and performs checks and actions on the episodes it finds.</p>
|
||
<p>In general I try to ensure that podcast episodes have a valid title that can be seen in the lists shown above. Sometimes the audio does not contain tags, so my script can access the fields from the RSS or Atom feed and use these to fill in the audio tags.</p>
|
||
<p>Some feeds place the feed name in the title (as with the <em>mintCast</em> example above), but if not, I use rules to add something meaningful. In the case of HPR the title usually makes no reference to HPR itself, so I add the characters <code>'HPR: '</code> to the front of the title for my convenience.</p>
|
||
<p>I find it surprising how many feeds produce episodes which have no metadata at all. I used to write to feed owners and ask for these to be filled in but this was largely a waste of time, so I evolved my <code>tag_manager</code> script to make decisions about what should be in the metadata fields.</p>
|
||
<h2 id="links">Links</h2>
|
||
<ul>
|
||
<li><a href="http://www.rockbox.org/">Rockbox - an alternative operating system for certain music players</a></li>
|
||
<li><a href="http://www.figlet.org/">figlet - a program for making large letters out of ordinary text</a></li>
|
||
</ul>
|
||
<ul>
|
||
<li>HPR links:
|
||
<ul>
|
||
<li><a href="https://hackerpublicradio.org/eps/hpr1656">hpr1656 :: My audio player collection</a></li>
|
||
<li><a href="https://hackerpublicradio.org/eps/hpr1992">hpr1992 :: How I’m handling my podcast-subscriptions and -listening</a></li>
|
||
<li><a href="https://hackerpublicradio.org/eps/hpr2211">hpr2211 :: My podcast workflow</a></li>
|
||
<li><a href="https://hackerpublicradio.org/eps/hpr3132">hpr3132 :: Keeping track of where I am</a></li>
|
||
</ul></li>
|
||
</ul>
|
||
</article>
|
||
</main>
|
||
</div>
|
||
</body>
|
||
</html>
|