Jinglescript niet op bepaalde tijd
Re: Jinglescript niet op bepaalde tijd
Het script is wel traag dus wil dat wel weten om het zo goed mogelijk te hebben.
Re: Jinglescript niet op bepaalde tijd
Begin bovenaan:
Pas hele script aan zoals hieronder aangegeven :
En zet helemaal onderaan nog een keer :
Code: Selecteer alles
PAL.Loop := True;
PAL.LockExecution;
Code: Selecteer alles
while ((Now >= T['00:05:00']) and (Now <= T['00:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
Code: Selecteer alles
PAL.UnLockExecution;
Re: Jinglescript niet op bepaalde tijd
Ik ga het aanpassen. Bedankt voor de uitleg.
Re: Jinglescript niet op bepaalde tijd
Hierbij het nieuwe script.
Code: Selecteer alles
PAL.Loop := True;
PAL.LockExecution;
while ((Now >= T['00:05:00']) and (Now <= T['00:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['01:05:00']) and (Now <= T['01:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['02:05:00']) and (Now <= T['02:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['03:05:00']) and (Now <= T['03:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['04:05:00']) and (Now <= T['04:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['05:05:00']) and (Now <= T['05:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['06:05:00']) and (Now <= T['06:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['07:05:00']) and (Now <= T['07:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['08:05:00']) and (Now <= T['08:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['09:05:00']) and (Now <= T['09:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['10:05:00']) and (Now <= T['10:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['11:05:00']) and (Now <= T['11:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['12:05:00']) and (Now <= T['12:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['13:05:00']) and (Now <= T['13:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['14:05:00']) and (Now <= T['14:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['15:05:00']) and (Now <= T['15:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['16:05:00']) and (Now <= T['16:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['17:05:00']) and (Now <= T['17:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['18:05:00']) and (Now <= T['18:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['19:05:00']) and (Now <= T['19:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['20:05:00']) and (Now <= T['20:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['21:05:00']) and (Now <= T['21:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['22:05:00']) and (Now <= T['22:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['23:05:00']) and (Now <= T['23:55:00'])) do
Begin
PAL.LockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
PAL.LockExecution;
Re: Jinglescript niet op bepaalde tijd
Nee... dat gaat um niet worden zo....!
Let even goed op mijn berichtje van gisteren 19:37
(ik doe het even buiten de Code, want anders zie je niet de BOLD en underline
Boven aan : PAL.LockExecution
Dan in de 'uur'-segmenten :
while ((Now >= T['00:05:00']) and (Now <= T['00:55:00'])) do
Begin
PAL.UNLOCKExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LOCKExecution;
End;
En helemaal onderaan :
PAL.UNLOCKExecution;
Dus niet overal 'PAL.lockExecution'.... dat gaat niet werken...
Het 'Locken' betekend dat SAM het zeg maar niet regel voor regel gaat doen, maar in een miliseconde ofzo.
Na het locken, kan je niet weer opnieuw locken, alleen maar UNlocken.
Savvy?
Let even goed op mijn berichtje van gisteren 19:37
(ik doe het even buiten de Code, want anders zie je niet de BOLD en underline
Boven aan : PAL.LockExecution
Dan in de 'uur'-segmenten :
while ((Now >= T['00:05:00']) and (Now <= T['00:55:00'])) do
Begin
PAL.UNLOCKExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LOCKExecution;
End;
En helemaal onderaan :
PAL.UNLOCKExecution;
Dus niet overal 'PAL.lockExecution'.... dat gaat niet werken...
Het 'Locken' betekend dat SAM het zeg maar niet regel voor regel gaat doen, maar in een miliseconde ofzo.
Na het locken, kan je niet weer opnieuw locken, alleen maar UNlocken.
Savvy?
Re: Jinglescript niet op bepaalde tijd
Daarom is SAM nu gecrashed.
Ik ga het aanpassen
Ik ga het aanpassen
Re: Jinglescript niet op bepaalde tijd
Dat gaat SAM helemaal niet fijn vinden, als ie zo'n PALletje voor zijn kiezen krijgt....Radio Delta schreef:Daarom is SAM nu gecrashed.

Re: Jinglescript niet op bepaalde tijd
Hierbij het aangepaste script.
Code: Selecteer alles
PAL.Loop := True;
PAL.LockExecution;
while ((Now >= T['00:05:00']) and (Now <= T['00:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['01:05:00']) and (Now <= T['01:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['02:05:00']) and (Now <= T['02:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['03:05:00']) and (Now <= T['03:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['04:05:00']) and (Now <= T['04:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['05:05:00']) and (Now <= T['05:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['06:05:00']) and (Now <= T['06:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['07:05:00']) and (Now <= T['07:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['08:05:00']) and (Now <= T['08:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['09:05:00']) and (Now <= T['09:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['10:05:00']) and (Now <= T['10:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['11:05:00']) and (Now <= T['11:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['12:05:00']) and (Now <= T['12:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['13:05:00']) and (Now <= T['13:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['14:05:00']) and (Now <= T['14:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['15:05:00']) and (Now <= T['15:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['16:05:00']) and (Now <= T['16:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['17:05:00']) and (Now <= T['17:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['18:05:00']) and (Now <= T['18:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['19:05:00']) and (Now <= T['19:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['20:05:00']) and (Now <= T['20:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['21:05:00']) and (Now <= T['21:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['22:05:00']) and (Now <= T['22:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
while ((Now >= T['23:05:00']) and (Now <= T['23:55:00'])) do
Begin
PAL.UnLockExecution;
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
PAL.WaitForPlayCount(3);
PAL.LockExecution;
End;
PAL.UnLockExecution;
Re: Jinglescript niet op bepaalde tijd
Ik heb het script nu aangepast. SAM liep steeds vast om 5 minuten voor het uur tot 5 minuten na het uur.
Ik laat het weten als het werkt.
Ik laat het weten als het werkt.
Re: Jinglescript niet op bepaalde tijd
Het script werkt nu goed. Bedankt voor de uitleg
- Wout
- Beheerder
- Berichten: 3501
- Lid geworden op: 03 dec 2007, 14:17
- SAM-versie: 2019.3
- Database: MariaDB
- Windows: 11
- Locatie: West-Brabant
- Contacteer:
Re: Jinglescript niet op bepaalde tijd
Hoewel de bovenstaande oplossing ook zeker werkt.
Bemoei ik me toch een beetje ermee.
Omdat hij vaak hetzelfde moet doen kan je het ook verkort maken.
Er is niks mis mee met je code alleen is dit wat korter.
Bemoei ik me toch een beetje ermee.

Omdat hij vaak hetzelfde moet doen kan je het ook verkort maken.
Code: Selecteer alles
PAL.Loop := True ;
var uur : String ;
uur := FormatDateTime('hh', Now) ;
if (Now >= T[uur+':05:00']) and (Now <= T[uur+':55:00']) then
begin
CAT['Jingles (All)'].QueueBottom(smLemmingLogic, NoRules);
end
else
begin
WriteLn('Geen Jingle') ;
end ;
PAL.WaitForPlayCount(3) ;
// Wout Franken, Broadcasterforum.nl, 09-juni-2011
Re: Jinglescript niet op bepaalde tijd
Wout,
Bedankt voor je hele korte script.
Hier liep ik al naar te zoeken.... maar kon hem niet vinden...
Hier zal Radio Delta helemaal blij mee zijn !
Bedankt voor je hele korte script.
Hier liep ik al naar te zoeken.... maar kon hem niet vinden...
Hier zal Radio Delta helemaal blij mee zijn !
Re: Jinglescript niet op bepaalde tijd
Ik kon ook geen ander script vinden. Ga het nieuwe script testen.
Bedankt voor de reacties.
Bedankt voor de reacties.
Re: Jinglescript niet op bepaalde tijd
Ik heb het nieuwe script getest en werkt perfect.
Bedankt voor de reacties.
Bedankt voor de reacties.
-
- Vergelijkbare Onderwerpen
- Reacties
- Weergaves
- Laatste bericht
-
-
Nieuw bericht PAL script voor een bepaalde dag van de week en bepaalde tij
door remcortd » » in PAL» - 4 Reacties
- 4320 Weergaves
-
Laatste bericht door drOhimself
-
-
- 42 Reacties
- 18742 Weergaves
-
Laatste bericht door Adrie
-
- 13 Reacties
- 3154 Weergaves
-
Laatste bericht door Wout
-
- 11 Reacties
- 3051 Weergaves
-
Laatste bericht door qradio