Monday, November 04, 2013

Podcast Sync

I listen to audio books and podcasts using a SanDisk Sansa, I prefer this over using my mobile phone for a few reasons. The main ones are:

  • battery life; the sansa lasts weeks with out a recharge

  • it clips onto my collar and I use a very short set of headphones

I use the Juice podcast receiver application to download and manage my podcast subscriptions. I have it rigged up to download new podcasts every day and delete any file over 14 days old (for some podcasts I set up a longer purge time).

I then have a batch file which calls xxcopy to sync the mp3 files from the podcast download folder on my laptop onto the sansa. Here is the batch file:

[code]@echo off
set SN=19088743
set "extDrive="

for /f %%D in ('wmic volume get driveLetter^, serialNumber ^| find "%sn%"') do set extDrive=%%D

if not defined extDrive echo Error finding external drive & pause & exit /b

xxcopy C:\Users\fuzzy\Podcasts "%extDrive%\PODCASTS" /KS/H/E/R/Q/BB/ZE/oD0/ZY/YY/EXC:\Users\fuzzy\Utils\podcast-exclude.txt[/code]

Now there are a couple of things which you'd have to edit if you were going to make use of this:

  • plug in your mp3 player

  • check what drive letter has been assigned to it

  • open a cmd window (start -> run -> cmd)

  • execute the following: wmic volume get driveLetter, serialNumber

  • copy the serial number listed next to the drive letter of your mp3 player

  • edit this number into the line in the batch file to replace my serial number: set SN=19088743

You'll also need to edit the paths to your podcast directory on your PC and the output directory.

The C:\Users\fuzzy\Utils\podcast-exclude.txt part is the location of a text file which contains a list of any folders which I don't want to include in the sync.