#!/usr/bin/perl/ require 'dvrcommands.pl'; &config(); my $pid = fork(); if($pid){ exit; } $DVR{'recordstring'} =~ s/\%CHANNEL\%/$ARGV[0]/g; $DVR{'recordstring'} =~ s/\%FILE\%/$ARGV[1]/g; $DVR{'record'} =~ s/[\n\r]//g; $DVR{'recordstring'} =~ s/[\n\r]//g; # Set sound properties e.g. volume $cmmd = $DVR{'sound'}; system ($cmmd); # Start recording $cmmd = $DVR{'record'}." ".$DVR{'recordstring'}; system ($cmmd);