Scripts to parse the sdrtrunk recording dir and move stuff around by date and talk group.
Major update to how this works...
- SDRTrunk: https://github.com/DSheirer/sdrtrunk
- ffmpeg (or other utility to merge mp3s in a dir...)
- PostgreSQL Database, any reasonably recent version should be fine.
- Create a postgresql database. SEE INSTRUCTIONS IN database/README.TXT
createdb -U postgres -h localhost -p 5432 psf
-
Load the database - see instructions in database/ README.TXT
-
Connect to the database and set paths to locations in the database pref table. You can use the setpref function.
SELECT setpref('current_path','/home/user/SDRTrunk/recordings');
-- This is the path that SDRTrunk writes recordings to.SELECT setpref('archive_path','/storage/path/archive');
-- This is where you want to move recordings into DATE/Talkgroup directoriesSELECT setpref('merged_path','/some/other/path/merged');
-- The is where you want merged talkgroup recordings to end up.
- Import info from RR for the talkgroups and sites.
- This data gets loaded into
trs_tg
. Sample talkgroup data is in thetrs_tg
table for my locality. - Site data too. see readme.txt
- Run setup.sh
- If not, troubleshoot.
- ` source psf_settings.ini && psql
- If you can connect, disconnect with
\q
and try to run psf.sh...
bash ./psf.sh
*/10 * * * * cd /home/pclark/sdrtrunk_recordings/script/psf && bash ./psf.sh