Skip to Content
It is currently September 15th, 2019, 12:41 am

All times are UTC - 6 hours [ DST ]




Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: April 28th, 2015, 10:47 am 
Offline
New User
New User

Joined: November 17th, 2012, 3:39 am
Posts: 12
I am using this PAL Script to relay a syndicated show on my station and it works fine as in relaying. The problem I am having is the Artist and Song title show up in the deck on SAM, but when I go to my players on the web it only shows the IP/Stream, no artist or song title. I am a novice with Pal, is there a way to fix this to where Artist and Song title show up or is there a better Pal Script out there that I should be using instead?

Code:
{ Here is an example script that can be used to relay a remote show or URL
About:
This script will play a remote show inside SAM
The show starts at a specified time, and then ends at
another specified time.

The script also contains some error-correction code
that will attempt to connect to the stream up to 20 times
in case it goes down. We schedule one song between each attempt.

Usage:
a) Compile configuration below and start PAL script.
b) If this show is only in certain days you will need to modify the script to
only queue the show up during these days.
See the DayOfWeek function.
}
{ CONFIGURATION }
{==================================================}
const ShowURL = 'http://66.85.154.211:8074/stream';
const StartTime = '05:59:30';
const EndTime = '09:01:00';

{ IMPLEMENTATION }
{--------------------------------------------------}
var T : Integer;
PAL.Loop := True;

{Wait for the show to start}
PAL.WaitForTime(StartTime);

{Add show to queue}
Queue.Clear;
Queue.AddURL(ShowURL,ipTop);

{Fade to show}
ActivePlayer.FadeToNext;

{Precautions - if there is a brief disconnect or server problem,
then we would want to retry a few times to get back to the show.
To do this we place the URL quite a few times in the queue, followed
by some normal programming. That way we will try and reconnect until
the end of the show}

T := 0;
while T < 20 do
begin
Queue.AddURL(ShowURL,ipBottom);
CAT['Heavy rotation'].QueueBottom(smLRP,EnforceRules);
T := T + 1;
end;

{Wait for show to end}
PAL.WaitForTime(EndTime);

{Clear queue}
Queue.Clear;

{Fade to normal programming}
ActivePlayer.FadeToNext;

{--------------------------------------------------}


Last edited by sirg2424 on April 28th, 2015, 2:09 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
PostPosted: April 28th, 2015, 12:17 pm 
Offline
SVS Member
SVS Member

Joined: May 5th, 2008, 4:53 pm
Posts: 300
Hello,

One idea is to send the current title by http query.
You can check the active deck title every X seconds and if it changed do a http request.

Command for update the title for shoutcast:
Quote:
http://<shoutcastDNS>:<port>/admin.cgi?pass=<password>&mode=updinfo&song=<active deck title>

_________________
Ivan Radolović - Spacial Volunteer Support (SVS)


Top
 Profile  
Reply with quote  
PostPosted: April 28th, 2015, 7:34 pm 
Offline
SVS Member
SVS Member

Joined: December 6th, 2004, 9:00 am
Posts: 7872
Location: Aachen (Germany)
You could try this snippet for relaying a Shoutcast v1 stream:
http://support.spacialaudio.com/wiki/Ch ... ream_Title

For shoutcast v2 I can't guarantee this works. (Does shoutcast v2 still have the 7.html interface?)

For Icecast 2 streams, you might have luck or not. Icecast by default comes with a xslt file that simulates the 7.html from shoutcast, but I don't remember whether it's enabled by default or if you need to configure that by hand.

_________________
Benedikt Bauer - SVS (Spacial Volunteer Support)

We're offering custom PAL / PHP code and general SAM assistance at palscripts.com

My Project:
Send "Now Playing" from SAM to Twitter and/or Facebook | Sourcecode


Top
 Profile  
Reply with quote  
PostPosted: April 28th, 2015, 10:56 pm 
Offline
SVS Member
SVS Member

Joined: October 15th, 2003, 11:59 pm
Posts: 4732
Location: Los Angeles - A Little West Of Nashville
Mastacheata wrote:
(Does shoutcast v2 still have the 7.html interface?)
Yes, it does.

_________________
- DJ Dee
- Spacial Volunteer Support (SVS)
- Custom PAL services: www.palscripts.com
- http://www.AlternativeHD.com
- http://www.lahotcountry.com


Top
 Profile  
Reply with quote  
PostPosted: April 29th, 2015, 1:39 am 
Offline
New User
New User

Joined: November 17th, 2012, 3:39 am
Posts: 12
Mastacheata wrote:
For Icecast 2 streams, you might have luck or not. Icecast by default comes with a xslt file that simulates the 7.html from shoutcast, but I don't remember whether it's enabled by default or if you need to configure that by hand.


Unfortunately its coming from a Icecast 2 server. I tried http://66.85.154.211:8074/7.html and got this message "The file you requested could not be found" so I changed it to http://66.85.154.211:8074/7.xslt and got this message "Could not parse XSLT file".

I am not sure where to go from here, I do appreciate the help that has been offered so far. I am thinking it would be easier to contact www.palscripts.com and get a cost on how much to have a script built for my needs.


Top
 Profile  
Reply with quote  
PostPosted: April 29th, 2015, 6:00 pm 
Offline
New User
New User

Joined: April 21st, 2012, 10:52 am
Posts: 10
I had the same problem as you relaying an Icecast v2 server. The only true solution I found came from http://custompalscript.com/. The PAL script they wrote for me works great. I am very happy with their work.


Top
 Profile  
Reply with quote  
PostPosted: April 30th, 2015, 3:19 pm 
Offline
New User
New User

Joined: November 17th, 2012, 3:39 am
Posts: 12
redearthradio wrote:
I had the same problem as you relaying an Icecast v2 server. The only true solution I found came from http://custompalscript.com/. The PAL script they wrote for me works great. I am very happy with their work.


I will check them out, thanks for the lead!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC - 6 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group