Hi all,

We're integrating a new tool FileScheduler [0] with LiquidSoap.

To make short, FileScheduler can choose in a directory the "next"
content to be played (by LiquidSoap in this case). This part works fine
(with a simple request.dynamic/request.create).

FileScheduler can also manage contents with a "forced time". For
example, to start at exactly 14h00 a given file. This "forced" content
must skip the current content in LiquidSoap.

The FileScheduler usage is very simple :

file-scheduler <directory> next : returns the next file
file-scheduler <directory> forced_next : returns nothing or the "forced"
file

This small LiquidSoap script integrates FileScheduler :
https://gist.github.com/1577924

This "forced_next" part is more difficult to integrate. We're using a
fallback.skip with an "conditional" switch. But I have some difficulties
to make an efficient forced_change predicate
(https://gist.github.com/1577924#L10) [1].

As the switch checks several times per second the predicate, the "if 0s
then" condition isn't enough strict and the external check is performed
several times in the same second. It's very expensive (mainly because
we're using this script on our small PlayBoxes).

I tried to save the last gettimeofday in variable/list/... to skip
checks in the same second ... but I didn't found a way to "store" this
value with LiquidSoap language/API.

There are other solutions to make a single forced_next at each 0s like
using a more complex switch, etc. But I prefer to have feedback from
real LiquidSoap users :)

Regards,

0. http://wiki.tryphon.eu/filescheduler/start
1. The current forced_change precidate ignores the filename returns by
FileScheduler.
-- 
Alban Peignier - [email protected]

Tryphon : Radio, Web et Logiciels Libres
http://www.tryphon.eu

------------------------------------------------------------------------------
Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex
infrastructure or vast IT resources to deliver seamless, secure access to
virtual desktops. With this all-in-one solution, easily deploy virtual 
desktops for less than the cost of PCs and save 60% on VDI infrastructure 
costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users

Reply via email to