From: yomguy <> Date: Fri, 25 Jul 2008 00:07:21 +0000 (+0000) Subject: * Creates raw_dir X-Git-Tag: 0.9~319 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=0a338e2c8e196f5709e59a62bc637e10bae78cf1;p=telecaster-client.git * Creates raw_dir * Clean CGI --- diff --git a/etc/pre-barreau_conferences.xml b/etc/pre-barreau_conferences.xml index fdc4955..3753025 100644 --- a/etc/pre-barreau_conferences.xml +++ b/etc/pre-barreau_conferences.xml @@ -1,5 +1,5 @@ - http://192.168.7.202 + http://localhost Pre-Barreau - ICP 8000 mp3 diff --git a/etc/telecaster_mp3.cfg b/etc/telecaster_mp3.cfg index ed72e65..9aac5d7 100644 --- a/etc/telecaster_mp3.cfg +++ b/etc/telecaster_mp3.cfg @@ -1,7 +1,7 @@ Server=localhost Port=8000 ServerPassword=source2parisson -ServerMountpoint=/Pre-Barreau_-_ICP_-_CRFPA_-_Droit_administratif_Corrections.mp3 +ServerMountpoint=/Pre-Barreau_-_ICP_-_ENM_-_undefined.mp3 ServerPublic=0 AutomaticReconnectSecs=10 Encode=MP3 Lame @@ -13,8 +13,8 @@ ServerType=Icecast2 ExternalFile=/tmp/test #YP Settings ServerStreamURL=http://www.pre-barreau.com -ServerName=Pre-Barreau_-_ICP_-_CRFPA_-_Droit_administratif_Corrections -ServerDescription=Pre-Barreau_-_ICP_-_CRFPA_-_Droit_administratif_Corrections_-_2_-_MARINHO_A._-_1er_cours +ServerName=Pre-Barreau_-_ICP_-_ENM_-_undefined +ServerDescription=Pre-Barreau_-_ICP_-_ENM_-_undefined_-_4_-_GIUSTINIANI_G._-_2e_cours ServerGenre=Teaching #Advanced Settings LogLevel=1 diff --git a/telecaster.py b/telecaster.py index d4b1c23..9e268ad 100755 --- a/telecaster.py +++ b/telecaster.py @@ -122,6 +122,7 @@ class Station(Conference): oddconf.close() def start_oddcast(self): + os.makedirs(self.raw_dir) command = 'oddcastv3 -n "'+clean_string(self.conference)[0:16]+'" -c '+self.odd_conf_file+ \ ' alsa_pcm:capture_1 > /dev/null &' os.system(command) @@ -144,7 +145,7 @@ class Station(Conference): command = 'streamripper ' + self.url + self.mount_point + \ ' -d '+self.output_dir+' -D "%S" -s -t --quiet > /dev/null &' os.system(command) - time.sleep(3) + time.sleep(1) def stop_oddcast(self): if len(self.odd_pid) != 0: @@ -340,8 +341,7 @@ class WebView: print "
"+message+"
" print "
Attention, il est important de remplir tous les champs, y compris le commentaire !
" print "" - print "" - + print "" print "" print "" print "
Titre :"+self.title+"
Département :" - print "" print "" print "" print "" @@ -433,6 +432,7 @@ class WebView: "."+self.format+".m3u\">Cliquez ici pour écouter cette formation en direct" print "" print "
" + print "" print "" print "" print "" @@ -485,13 +485,11 @@ class TeleCaster: s = Station(self.conf_file, self.conference_dict, self.lock_file) s.start() - time.sleep(4) if get_pid('^oddcastv3 -n [^LIVE]', self.uid) != []: casting = True if get_pid('streamripper ', self.uid) == []: writing = False - ws = WebView(self.school_file) - ws.stop_form(self.conference_dict, writing, casting) + w.stop_form(self.conference_dict, writing, casting) exit() elif odd_pid != [] and os.path.exists(self.lock_file) and not form.has_key("action"):
Titre :"+self.title+"
Département :"+department+"
Conference :"+conference+"