Hi,
I'd like to use my Sat-TV recordings with Plex. Unfortunately my Dreambox receiver saves the recordings in a strange way: 20121119 0116 - RTL2 HD - V wie Vendetta.ts
The first numbers are sort of a time code followed by the channel name any by the movie name. The built-in Plex Movie Scanner recognizes the .ts files and loads them but unfortunately the correct movie name is not extracted. As a result, no corresponding metadata is found.
Is there already a scanner for Dreambox enigma2 recordings or could anybody help me in getting started programming such a scanner?
Thanks in advance!
As far as I know .ts files can not have any metadata embedded so Dreambox must be storing metadata for the recordings ( like Programme description, Title, Sub-Title, Time of recording, genre etc ... ) some place else.
If this information is easily accessible ( maybe there's an xml file with the same name as .ts on Dreambox ? ) then you'll be able to write an scanner/agent combo to get the recordings show up in Plex. If is not, then you wont get any further then name of the file (Maybe if you set up your regex right, title and date of recording but that's it.)
I'm also using Dreambox to record Sky UK channels but I'm using Windows MCE7 & DVBlink Dreambox plugin ( so Dreambox is actually used only as a tuner and card decrypter while MCE7 does recording to the HTPC )
Then I have MCEBuddy to automatically convert/rename those recordings (wtv files ) into Plex friendly format along with all metadata that's available from EPG.
This way I have EXACTLY same programmes in MCE7 and in Plex ( usually delayed by 30 - 60 minutes , depending on runtime of the show ) Also MCEBuddy keeps tab on location of the files, so whenever I delete anything in MCE7, MCEBuddy will remove it from Plex. ( you can disable this feature )
Here is what the Recorded TV episodes look like in Plex ( i put the recording date in-between the wildcards, because thats how my kids remember their shows ):

I have just added my Vu+ Duo/Enigma2 based recording location as a directory on my NAS on which PMS runs and added it to the PMS. Meta data from recordings is present in the .eit files that go with each recordings. I tried to find a file format for it, but it's mainly a header of some sort along with a description of the recording.
Now I've only just started to look at this, but I am correct in saying that an Agent is all that is needed for it, right?
Ok, so I know a bit more now, and an Agent is not what we need (not until we want to add the meta data), but a scanner... so I took a copy of the Plex Movie Scanner.py file and put it into the /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Scanners directory and named it Enigma2.py
I then started to tweak and debug it and although I am not a python developer, I know enough of development to find the point that mattered and added the following
# Enigma2 files look like: YYYYMMDD HHMM - Channel - Programmename.ts
qfile = os.path.splitext(file)[0]
(qdatetime,qchannel,qprogramme) = qfile.split(' - ',2)
(qdate,qtime) = qdatetime.split(' ')
# Construct as: Programmename (Channel) DD/MM/YYYY HH:MM
name = qprogramme+" ("+qchannel+") "+qdate[6:8]+"/"+qdate[4:6]+"/"+qdate[0:4]+" "+qtime[0:2]+":"+qtime[2:4]
print "Name =", name
year = qdate[0:4]
and commented out the part that would normally get the 'clean' filename
#(name, year) = VideoFiles.CleanName(os.path.splitext(file)[0])
Then set your scanner to 'Enigma2', your Agent to 'Personal Media' and that should be it :)
*edit 30/05/2013 - .zip file removed, see further down*
Sorry to butt in! Total python non expert here, so I can't assisst with zany programming etc... but I have tested this out.
This is awesome, however the each recording title is now given as "YYYYMMDD Name" with the other file name data stripped.
I've tried it in the following sections
Movies
Series
Home Movies
All using enigma2 as teh scanner
It'd be awesome if this worked for me like your screen shot. A I being daft?
Many thanks, so glad I stumbled across this little beaut! Fingers crossed I can get it to work OK.
Hi DogBoy,
Can you do an list of the actual filename that your recordings have? Mine look exactly like the one christianrodesh posted:
YYYYMMDD HHMM - Channel - Programme name.ts
quinten@hp:/mnt/vu/movie/Movies$ ls -la *.ts
-rw-r--r-- 1 root root 7392845824 Mar 20 22:15 20130320 1933 - RTL7 HD - The Fifth Element.ts
-rw-r--r-- 1 root root 5977882624 Apr 7 21:08 20130407 1856 - RTL7 HD - Alex Rider - Operation Stormbreaker.ts
-rw-r--r-- 1 root root 6531162300 May 19 21:29 20130519 1901 - RTL7 HD - The Siege.ts
-rw-r--r-- 1 root root 7292354560 May 19 23:48 20130519 2111 - RTL7 HD - Lucky Number Slevin.ts
Q.
Heres the paste:
Nicks-iMac:VUplus nickdiacre$ ls -la *.ts
Seems just the same no?


what do you reckon the problem is?
Thanks for looking at it, much appreciated!
It looks like you haven't cleaned your section as that is the normal naming convention given to items parsed through the Plex Video Scanner. Or maybe you need a deep scan, instead of Turbo?
I tried the old deep scan, how would I clean the section?
I'm surprised the deep scan didn't work, but with cleaning the section I meant to delete and re-add it. Or maybe try it on a new section with a small set of files first? I double checked the .zip file above and it definitely contains my amendment, so if this does not work, I am at a loss...
My bad, I had been fiddling with the naming system, so a couple of the files were in the "long" format and a couple in the "short" format... this obviously stopped the scanner working entirely for the files that were named correctly.
So to fix... I went through and made up the missing, but in the correct format, and it worked a-ok!
Thanks for your help, fab scanner, I hope more enigma2 users find this!
Pfew, glad you got it working now. When I got some more time again I will also investigate the Agent option to see if we can get the programme descriptions out of the .eit files.
Thanks, still ran into a few teething problems, it looked OK last night, but by the time it finished the scan it had reverted to the old format. I deleted the section and cleaned/optimised and then re-added under a new name and it worked a little better.
Is there a way of making plex group the recordings by program name? Much like in the TV series sections? That'd make browsing the recordings easier...
This solution is brilliant, my enigma box [Vu+ Solo2] was unable to share .TS content with any of my TVs over DLNA, nor stream recordings using the XBMC PVR backend on ATV2 [fine on SD files but not HD files, a known problem] so using Plex as a transcoder really helps...
Is there a way of making plex group the recordings by program name? Much like in the TV series sections? That'd make browsing the recordings easier...
Well, there may be a way, but I have not looked into it at all. I agree that it would be nice to do so, so I may have a peek and a poke later and see how that works.
that's be amazing, wish I could offer some support, but I don't know much about python [I know nothing in fact]
If you need me to test stuff, however :)
Not finished yet, but first signs are promising ;) To be continued
Version 2 :)
This time you have the choice between a Movie scanner or a Series scanner. The Movie scanner has been tidied up a bit but is largely the same as before in the sense that you can not group shows. The Series scanner will group shows by using the Programme name and puts them in a season (year) and arranges them by episode (the absolute day number within the season year).
Next on the list will be the meta-data agent... I have already got bits for the .eit structure reading, just need to investigate the Agent methods
Enjoy!
edit 04/06/2013 - .zip file removed, see further down
wowsers, fast work... I'll check it out now! Do I need to redo the section as "Series"?
Nick
Yes, but maybe do a small (new) section first? I have two sections, both using the same directory, one for the Movie scanner and one for the TV scanner... that will give you a good idea which one you'll prefer in the long run
all working pretty well... only tried the series scanner though... exactly what I needed. GF-friendly and all...
Part of the problem here is that [at least my] enigma2 box uses tags for organising recordings, rather than folders.
Separating into folders is a bit laborious, but it'd be good to be able to auto split movies and tv-shows, that way you could apply a different scanner to each folder - disco!
However, everyone seems happy with the tag system, so it's not a priority I think [I use ViX]. I'll have another sniff round the forums and see if anyone has a view on it...
Another suggestion, can you copy the code from the existing Plex agent for TV-series enigma2 scanner so it scrapes the TV show artwork [and music?] for the folders on your TV-scanner? I'm probably being basic, but would the same code not work? Or create an enigma2 agent using similar code. Might need to adjust the "Title" for the episodes as it shows the channel and time at the moment...
You'll have to excuse me, I really have no idea what I am talking about, so it's probably way more complex than that... I should learn python really.