Tuesday, March 13, 2007

Today's achievements

Half an hour correcting dl.asp delivering 0 bytes to IE:
set fs=Server.CreateObject("Scripting.FileSystemObject")
set f=fs.GetFile(strFilePath)
strFileSize=f.Size

L bumped up the audio on AsiaStar, now it's fine.

Rest of the morning doing Bhajan processing.

Afternoon tracing schedule problem with DST: found probable locale change so that
if (date > #11/03/2007#) and (date < #04/11/2007#) then
has stopped working and now needs to be
if (date > #03/11/2007#) and (date < #11/04/2007#) then
So, changed it to locale independent
if (date > DateSerial(2007, 03, 11)) and (date < DateSerial(2007, 11, 04)) then
instead. We're not changing the changeover times because then the Latin Americans would have four changes to their regular programming every year - following US DST and their own DST.

And evening was spent on playlist generation.

Monday, March 12, 2007

newline in csv breaks database tables

A single bad newline in a description field had the schedule page down for the last half hour while we traced and corrected the problem... Caution needed when copy/pasting descriptions especially from text files / emails as in the case of Telugu programs!

bhajan processing

Starting slowly on Bhajan processing. Yield is roughly an hour's worth for a morning's work.

Sunday, March 11, 2007

changes to add PHP 5 compatibility

The forms in maillist were not PHP5 compatible: as noted by P, in PHP5, the posted variables are not automatically available, but requires the addition of lines like
$variablename=$_REQUEST["variablename"];
Did the necessary additions by searching for the name=parts and thus the required variablename in the forms. Partially implemented, so that most frequently used pages work.

changed Daylight savings times

Changed the code for daylight savings times for USA-Canada and Israel for 2007 checking out the info from http://timeanddate.com/time/dst2007.html

on-demand links on schedule page

An interim solution implemented, which will work only for single file items. Probably, multi-file items will need a rethinking along the lines of my previous post. Current implementation uses a single extra filename field in the remote database. And the logic to automatically add this is
if ( ($CATEGORYNAME=="Special") OR ($CATEGORYNAME=="Discourse")  )
{
if (Strncmp($NEXT_FILENAME,$FILENAME,7))
$DOWNLOAD_FILENAME=$FILENAME;

if (strcasecmp(trim($NEXT_DESCRIPTION),trim($DESCRIPTION)) )
$DOWNLOAD_FILENAME=$FILENAME;

}
with
 $DOWNLOAD_FILENAME="";
if the condition fails.

audio distortion at AsiaStar uplink

There seemed to be considerable distortion in low frequencies, and M wanted the jingle during the start and end of Moments of Oneness to be broadcast undistorted. The line in the playout scripts was
mpg123 -o alsa09 -g 70 -q -a $DSP_DEVICE   "$line"
But the gain factor of 70% was not being set - probably some permissions issue. After IM and emails, L found the audio card bad, since using another one seems to give clear audio. But currently the DBMax is byepassed, so audio levels are sometimes low. Next task is to get it thru the DBMax.

Saturday, March 10, 2007

play avi and wmv on MacOS X

Since we were mulling over the MirrorDome and such systems, just checking if DivX files play with QuickTime - this article links to some plugins to achieve this.

Windows media components for Quicktime is supposed to let you play Windows media files on Mac.

Friday, March 09, 2007

renewing postgres database from dump

My local copy of the SGH postgres database was out of date, so I picked up the dump from saiwaves
pg_dump sgh > /home/sgh/sghdbdump
Before loading onto my system, I had to remove the existing database with
dropdb sgh
then create it again with
createdb
and then run
psql -d sgh -f sghdbdump
Sirf kuch hi lamhon mein apka swadisht database tayyaar!

Wednesday, March 07, 2007

downloadable links on the schedule

For implementing downloadable links on the schedule page, we'll need some database changes at our end also - a "flag" saying allow/don't allow download - so that the appropriate data can be dumped into the csv file for import into remote database. Experimenting with adding a filename field to the AsiaStar schedule table...

Tuesday, March 06, 2007

new on-demand code

Quietly removed the embedded XSPF player from the on-demand pages, replacing it with the mp3player from http://www.jeroenwijering.com/?item=Flash_MP3_Player opening in a new window using a simple target="_blank" In replacing the old pages' code, learnt some regular expression syntax from KWrite's regular expression editor -
1. Reg Exps have to be only on a single line - end of line symbol $ terminates the regexp.
2. object.*$ means object followed by any characters till end of line.

Watch TV online

Got this link from Digg or Wired or somewhere:

http://www.onetipaday.com/2007/02/14/updated-list-of-places-to-watch-tv-for-free-online/

iPod repair

Saw a Wired article on "iPod mechanics" repairing broken iPods, and checked out www.NYCiPodDoctor.com But the cost of replacing a hard disk on the old broken 1st Gen iPod is greater than the cost of buying a new flash-based mp3 player....

used iMacs

Found some nice deals via a google ad for used iMacs at megamacs.com - Apple iMac 233MHz Bondi 96MB, 4GB, CD for $29.99! But unfortunately we can't get them by normal shipping methods - there's a $200 anti-dumping duty, it appears!
http://www.emergic.org/collections/tech_talk_letter_to_arun_shourie.html

http://www.ieport.com/Cus2004/Tariff/not30.htm

virus attack

Like almost any all-Windows shop, the PDS was hit in 2nd half of Feb by a virus/worm which was creating a fun.exe in all folders, and spreading to all machines via shared folders. Norton Enterprise antivirus was not catching it or maybe because it was already loaded into memory, it was recreating instances. P finally cleaned it with AVG free + using msconfig to stop it from loading on startup.

problems connecting to our playout server

In the first part of Feb, we had some trouble connecting to our playout server at Melbourne. The traceroute was taking too many hops. Now, for example, the traceroute reaches the server in around 22 hops. A little on the high side?
traceroute to <snip> , 30 hops max, 38 byte packets
<snip>
3 203.200.24.1.ill-bgl.static.vsnl.net.in (203.200.24.1) 6.730 ms 6.518 ms 6.491 ms
4 202.54.86.63.ill-bgl.static.vsnl.net.in (202.54.86.63) 7.045 ms 7.027 ms 7.012 ms
5 203.197.162.54.ill-bgl.static.vsnl.net.in (203.197.162.54) 8.562 ms 7.862 ms 8.308 ms
6 202.54.12.249.ill-bgl.static.vsnl.net.in (202.54.12.249) 10.766 ms 7.818 ms 7.894 ms
7 59.163.16.250.static.vsnl.net.in (59.163.16.250) 109.642 ms 105.444 ms 105.941 ms
8 59.163.16.250.static.vsnl.net.in (59.163.16.250) 106.086 ms 105.597 ms 114.480 ms
9 203.131.241.157 (203.131.241.157) 272.903 ms 273.216 ms 272.864 ms
10 ge-2-3-0.r00.newthk01.hk.bb.gin.ntt.net (203.131.240.205) 277.114 ms 277.567 ms 277.532 ms
11 p4-1-1-0.r00.tokyjp01.jp.bb.gin.ntt.net (129.250.4.50) 279.050 ms 279.150 ms 280.268 ms
12 p4-3-0-0.r00.sydnau01.au.bb.gin.ntt.net (129.250.4.162) 398.757 ms 446.588 ms 398.916 ms
13 ge-0-0-0.a02.sydnau01.au.ra.gin.ntt.net (202.68.64.222) 399.456 ms 400.323 ms 399.194 ms
14 202.68.65.18 (202.68.65.18) 354.208 ms 377.895 ms 355.543 ms
15 * connect1.sybr4.global-gateway.net.nz (203.96.120.122) 352.962 ms 359.593 ms
16 so-4-1-0.cre1.hay.connect.com.au (202.10.4.93) 367.183 ms 354.246 ms 372.219 ms
17 so-5-0-0.cre1.bur.connect.com.au (202.10.0.251) 368.156 ms 368.916 ms 376.512 ms
18 so-0-0-1.dst2.mel.connect.com.au (202.10.0.134) 370.836 ms 367.982 ms 375.395 ms
19 gigabitethernet0-1.cor6.mel.connect.com.au (203.63.170.183) 369.349 ms 388.766 ms 398.202 ms
20 AUS130611-3.gw.connect.com.au (203.63.104.101) 370.382 ms 378.105 ms 416.715 ms
21 worldspace-gw.ozonline.com.au (203.23.159.193) 375.345 ms 376.441 ms 409.865 ms
22 * * *

Force Refresh browser window

To force a refresh of cached content:

shift+reload in Mozilla-based products and control+refresh in Internet Explorer

remove from print queue

As root, to remove all print jobs from print queue
lprm - 

Monday, March 05, 2007

trying de-clipping tools

Trying de-clipping tools like Cool Edit Pro's built-in and Acoustica's built-in on bhajan recordings. No use. Since it is the singer mic alone which has the distortion, and since it is added to all the rest, the mixed signal can't be cleaned by these sw.

Tuesday, February 27, 2007

H2H virtual folder

Changed the H2H virtual folder journals into a physical folder with a single line asp page redirecting to media.radiosai.org/journals