Project

General

Profile

Feature suggestion - timeshifting a mux

Added by Harri Huttunen over 11 years ago

I'm thinking of using Tvheadend as a backend for XBMC to get a tv for projector. I currently have a linux-box that functions as dvr and it would be nice if its functions could be integrated to a new system.

My current system is a one mans project and I'm not the one that developed it so I can't get new features for it. I have used it for couple of years and have been very happy with it.

It's quite simple system, you dedicate a disk (or partition) for a mux and first use tzap to tune adapter for a mux and then record the mux to dedicated disk with dvbstream splitting it couple minutes long pieces. A disk and adapter per mux. There are scripts for deleting oldest files from mux, updating epg and storing favorites automatically to disk. User interface runs on browser with apache.

System works so that when you "record" something it copies the data from the files in the mux and doesn't actually use the adapter. The reason why I like it is that when I put something for automatic recording and there is long running sporting event or something else that screws programming schedule I won't miss the ending but just get it from the buffer. Also couple of times there have been for example talk at work next day of program that I didn't watch but sounded interesting when people talked of it. Instead of wondering if it comes again I opened the browser when I got home and got it from the buffer.

It should propably be quite easy to add such functionality to Tvheadend? This doesn't do live recording or timeshifting, programs are available after they have ended, but they could be done with Tvheadends own functions.


Replies (3)

RE: Feature suggestion - timeshifting a mux - Added by Dave Chapman over 11 years ago

Hi,

Before I joined the tvheadend team, I wrote a small app which I called dvbarchive - this takes the tuning parameters for a mux, and a list of service IDs, and will then continuously record those services, naming and splitting the recordings based on the EIT present/following information. However, I haven't got around to publically releasing this yet. If this is something you would be interested in using, let me know and I'll try and put it on github sooner rather than later.

To do the same thing in tvheadend today, I think you could simply configure auto-recordings with a very general search string (e.g. the regular expression ".*" would match any title). However, I'm not sure how reliable that would be in the case of last-minute EPG changes.

As you probably know, tvheadend currently has a timeshift feature, but this is "subscription-based". i.e. every instance of live streaming creates its own timeshift buffer, and this is deleted when that live streaming is stopped.

The intention is that in the future, timeshift will be service-based - i.e. the buffer will relate to the service, and multiple subscriptions will share the same timeshift buffer.

An idea that's been proposed is to then introduce the concept of a "null" subscription, which the user can enable on a service-by-service basis. This will keep a permanent timeshift buffer for that service, meaning that a user can then view or record anything from that buffer at any time.

RE: Feature suggestion - timeshifting a mux - Added by Harri Huttunen over 11 years ago

Dave Chapman wrote:

Hi,

Before I joined the tvheadend team, I wrote a small app which I called dvbarchive - this takes the tuning parameters for a mux, and a list of service IDs, and will then continuously record those services, naming and splitting the recordings based on the EIT present/following information. However, I haven't got around to publically releasing this yet. If this is something you would be interested in using, let me know and I'll try and put it on github sooner rather than later.

If it's easy to use I could be interested of it. Can you easily select what you record from mux? For example, there are radio channels and other unneccesary data in mux that I don't want to record. Do I Understand correctly that it records "ready to watch" programs, doesn't put mux to the disk but individual channels split by the starting and ending times of programs? If that's the case how do you get a movie to one file if it starts so late (because of an long running sporting event) that it's split into two files in the disk? (With my current system I can choose start and end times if the program isn't on time.)

The intention is that in the future, timeshift will be service-based - i.e. the buffer will relate to the service, and multiple subscriptions will share the same timeshift buffer.

An idea that's been proposed is to then introduce the concept of a "null" subscription, which the user can enable on a service-by-service basis. This will keep a permanent timeshift buffer for that service, meaning that a user can then view or record anything from that buffer at any time.

That sounds like the system that I would want but could that your app be integrated to tvheadend until this system is working?

RE: Feature suggestion - timeshifting a mux - Added by Dave Chapman over 11 years ago

Harri Huttunen wrote:

If it's easy to use I could be interested of it. Can you easily select what you record from mux? For example, there are radio channels and other unneccesary data in mux that I don't want to record. Do I Understand correctly that it records "ready to watch" programs, doesn't put mux to the disk but individual channels split by the starting and ending times of programs? If that's the case how do you get a movie to one file if it starts so late (because of an long running sporting event) that it's split into two files in the disk? (With my current system I can choose start and end times if the program isn't on time.)

Yes, you just pass a list of service IDs to dvbarchive to say which services (TV/Radio channels) you want to archive.

It never drops any data, so in effect it is recording each channel 24/7. It only uses the "current event" information in the EIT to determine when to split files. If this is wrong, you can fix it by simply concatenating multiple TS files (i.e "cat file1.ts file2.ts > combined.ts). But normally if a sporting event runs late, the broadcaster will send the updated info in the EIT, so the splitting will still be accurate.

That sounds like the system that I would want but could that your app be integrated to tvheadend until this system is working?

No, this is something completely independent of tvheadend - you would run it instead of tvheadend.

I'll try and find some time to release it and you can have a play if you want to.

    (1-3/3)