|
Hardware Support Discussions related to using various hardware setups with SageTV products. Anything relating to capture cards, remotes, infrared receivers/transmitters, system compatibility or other hardware related problems or suggestions should be posted here. |
|
Thread Tools | Search this Thread | Display Modes |
#1
|
||||
|
||||
Using the OpenDCT Generic Pipe Capture Device
You must have OpenDCT 0.5.21 or greater installed for this feature to be available and compatible with the latest directions.
Configuration:
Notes on Stopping Executable: While it is recommended to provide an executable to stop streaming, it is entirely optional. If you do not provide a executable to stop streaming or the one you have provided fails to stop the streaming within 15 seconds, the streaming executable will be forcibly terminated. In many cases this might be acceptable behavior, but in others it could leave you with an unusable recording or accumulating child processes that are not being terminated. It is also possible for a new stream to start while an old stream was not given sufficient time to stop. This should be a rare event, but if that could be a problem, you will need to build into your streaming executable a check to ensure the last execution was completely terminated before it starts a new stream. The channel is not appended as a final parameter since you are stopping a capture device, not a channel. If you are using one executable for multiple capture devices, I recommend that you provide your own parameter in the streaming_executable and stopping_executable that will allow them to know which capture device is being requested. e.g. Code:
sagetv.device.<unique_id>.streaming_executable=C:\Full\Path\To\Executable.exe --device 1 --tune=%c% sagetv.device.<unique_id>.stopping_executable=C:\Full\Path\To\Executable.exe --device 1 --stop sagetv.device.<unique_id>.streaming_executable=C:\Full\Path\To\Executable.exe --device 2 --tune=%c% sagetv.device.<unique_id>.stopping_executable=C:\Full\Path\To\Executable.exe --device 2 --stop If the streaming being provided is not an MPEG-TS container, you will need to change sagetv.device.<unique_id>.consumer=<default_consumer> to sagetv.device.<unique_id>.consumer=opendct.consumer.RawSageTVConsumerImpl. Without making this change it is very likely that best case nothing is streamed and worst case OpenDCT crashes. You may also need to change sagetv.device.<unique_id>.fast_network_encoder_switch=true to false and the corresponding value in Sage.properties, mmc/encoders/<unique_id>/fast_network_encoder_switch=true to false because seamless switching might not be reliable with unknown formats. Channel Detection: If you already have some specific channels in mind that you would like this capture device to return to SageTV as tunable, you can populate them in the sagetv.device.<unique_id>.custom_channels= property. The list is semicolon delimited. This can also be useful to create custom channels within SageTV. e.g. To return the channels 2000, 2002 and 2003 when doing a channel scan within SageTV, set the property as follows: Code:
sagetv.device.<unique_id>.custom_channels=2000;2002;2003 Non-Executable Tuning Alternative: If you want to tune in a manner that does not involve an executable, the latest versions of SageTV v9 will allow you to configure a tuning plugin for use with a network encoder which will allow you to use things such as the USB-UIRT to tune in a channel before calling OpenDCT to run your custom executable for stream capture. Other Notes: The standard pipe output is captured and streamed to SageTV. The error pipe output is captured and re-directed to the opendct.log file as a venue for troubleshooting. The standard input pipe is never used. The log will contain the entire executable path and parameters for troubleshooting, so if you are passing parameters such as plain text usernames and passwords, either wrap those into a script so they don't show up in the logs or make sure you scrub a copy of your logs and properties file before posting the copy. As of this time, this is an experimental feature, so it will likely have some issues that need to be worked out and new features will likely be added as required. %c% is now replaced with the requested channel.
__________________
SageTV v9 Server: ASRock Z97 Extreme4, Intel i7-4790K @ 4.4Ghz, 32GB RAM, 6x 3TB 7200rpm HD, 2x 5TB 7200rpm HD, 2x 6TB 7200rpm HD, 4x 256GB SSD, 4x 500GB SSD, unRAID Pro 6.7.2 (Dual Parity + SSD Cache). Capture: 1x Ceton InfiniTV 4 (ClearQAM), 2x Ceton InfiniTV 6, 1x BM1000-HDMI, 1x BM3500-HDMI. Clients: 1x HD300 (Living Room), 1x HD200 (Master Bedroom). Software: OpenDCT :: WMC Live TV Tuner :: Schedules Direct EPG Last edited by EnterNoEscape; 01-08-2017 at 03:47 PM. |
#2
|
||||
|
||||
This is very slick.
__________________
Sage Server: 8th gen Intel based system w/32GB RAM running Ubuntu Linux, HDHomeRun Prime with cable card for recording. Runs headless. Accessed via RD when necessary. Four HD-300 Extenders. |
#3
|
||||
|
||||
Thanks, it's fairly closely modeled after the Generic HTTP capture device; I was able to get this completely working in less than 3 days because of that. MythTV has something similar to this built in and when this was suggested, I thought it made a lot of sense for SageTV to have this option too. This also really opens the doors wide for anyone who wants to use the FFmpeg processing built into OpenDCT on a TS source, the SageTV media server remuxer on a TS source, the SageTV media server capabilities or just want something else to do all of the talking with SageTV.
__________________
SageTV v9 Server: ASRock Z97 Extreme4, Intel i7-4790K @ 4.4Ghz, 32GB RAM, 6x 3TB 7200rpm HD, 2x 5TB 7200rpm HD, 2x 6TB 7200rpm HD, 4x 256GB SSD, 4x 500GB SSD, unRAID Pro 6.7.2 (Dual Parity + SSD Cache). Capture: 1x Ceton InfiniTV 4 (ClearQAM), 2x Ceton InfiniTV 6, 1x BM1000-HDMI, 1x BM3500-HDMI. Clients: 1x HD300 (Living Room), 1x HD200 (Master Bedroom). Software: OpenDCT :: WMC Live TV Tuner :: Schedules Direct EPG |
#4
|
||||
|
||||
Quote:
__________________
Sage Server: 8th gen Intel based system w/32GB RAM running Ubuntu Linux, HDHomeRun Prime with cable card for recording. Runs headless. Accessed via RD when necessary. Four HD-300 Extenders. |
#5
|
||||
|
||||
Yes.
__________________
SageTV v9 Server: ASRock Z97 Extreme4, Intel i7-4790K @ 4.4Ghz, 32GB RAM, 6x 3TB 7200rpm HD, 2x 5TB 7200rpm HD, 2x 6TB 7200rpm HD, 4x 256GB SSD, 4x 500GB SSD, unRAID Pro 6.7.2 (Dual Parity + SSD Cache). Capture: 1x Ceton InfiniTV 4 (ClearQAM), 2x Ceton InfiniTV 6, 1x BM1000-HDMI, 1x BM3500-HDMI. Clients: 1x HD300 (Living Room), 1x HD200 (Master Bedroom). Software: OpenDCT :: WMC Live TV Tuner :: Schedules Direct EPG |
#6
|
||||
|
||||
I made a few changes that allowed me to be able to add Twitch channels using Livestreamer without needing to wrap it in a script. AGDQ just kicked off today and I thought it would be really cool to have it as a channel for the week. For anyone who's wondering what I did to get that streaming, I set the streaming executable to the following:
Windows: Code:
sagetv.device.<unique_id>.streaming_executable="C\:\\Program Files (x86)\\Livestreamer\\livestreamer.exe" --stdout --http-header Client-ID\=jzkbprff40iqj646a697cyrvl0zt2m6 https\://www.twitch.tv/gamesdonequick best Code:
sagetv.device.<unique_id>.streaming_executable=livestreamer --yes-run-as-root --stdout --http-header Client-ID=jzkbprff40iqj646a697cyrvl0zt2m6 https://www.twitch.tv/gamesdonequick best
__________________
SageTV v9 Server: ASRock Z97 Extreme4, Intel i7-4790K @ 4.4Ghz, 32GB RAM, 6x 3TB 7200rpm HD, 2x 5TB 7200rpm HD, 2x 6TB 7200rpm HD, 4x 256GB SSD, 4x 500GB SSD, unRAID Pro 6.7.2 (Dual Parity + SSD Cache). Capture: 1x Ceton InfiniTV 4 (ClearQAM), 2x Ceton InfiniTV 6, 1x BM1000-HDMI, 1x BM3500-HDMI. Clients: 1x HD300 (Living Room), 1x HD200 (Master Bedroom). Software: OpenDCT :: WMC Live TV Tuner :: Schedules Direct EPG |
#7
|
||||
|
||||
regarding the "sagetv.device.<unique_id>.custom_channels=2000;2002;2003" values, as enternoescape mentioned, there is more information that can be included here to return to sagetv, if you so desire. This information is what sage gets from openDCT when a channel scan is done in sage's channel lineup screen. One 'channel' is returned between each semi-colon. The simplest form is what the example shows, a single number is the minimum that must be returned, and sage will treat this as the 'physical' number. There are other options though:
[Physical#]-[Major#]-[Minor#]([CALLSIGN])[BroadcastType]; All values are optional except for the physical number. This information is used by SageTV to try to match the channel to an entry in the chosen EPG lineup (and I believe if it doesn't find a good match in the configured lineup, it will actually search through other configured lineups on the server for a match and add it to this lineup if found). And example might be: 43-2-1(KCBSDT)ATSC where logical channel 2-1 is broadcast on RF channel 43, with callsign KCBSDT. In the end, with the current implementation, I'm not sure how much utility most of these values have, as it may be easier to simply configure these things manually in SageTV, as opposed to manually creating this string in the opendct.properties, and letting sage import it. I believe it is the Physical number that sage will send back to opendct when requesting to tune a channel, so that is the value that OpenDCT should be passing to the executable in the %c% value.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer) unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers. Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA. Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S Other Clients: Mi Box in Master Bedroom, HD-200 in kids room Last edited by Fuzzy; 01-09-2017 at 04:20 AM. |
#8
|
|||
|
|||
Would this allow you to capture video from an IP camera and make it available to Sage as a tuner?
For example, here is a page listing the URLs that Foscam IP cameras used. Could you redirect one of those URLs into this DCT Generic pipe?
__________________
New Server - Sage9 on unRAID 2xHD-PVR, HDHR for OTA Old Server - Sage7 on Win7Pro-i660CPU with 4.6TB, HD-PVR, HDHR OTA, HVR-1850 OTA Clients - 2xHD-300, 8xHD-200 Extenders, Client+2xPlaceshifter and a WHS which acts as a backup Sage server |
#9
|
||||
|
||||
Yes, that would be possible. It would likely be wise to use ffmpeg as the executable and have it transcode it to MPEG4 in an MPEG2 Transport Stream container, however. The Foscam IP cameras output MJPEG, which, while simple to compress, which is why the small footprint cameras have that built in, is NOT a good video codec by todays standards, and more importatnly, is not necessarily well supported by sagetv.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer) unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers. Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA. Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S Other Clients: Mi Box in Master Bedroom, HD-200 in kids room |
#10
|
|||
|
|||
I was just using Foscam as an example, but I do have some of their cameras, as well as Trendnet which also appear to use MJPEG.
If I was getting a new camera then I guess I would look for something that could output MPEG-4? Sorry, I didn't paste the URL before - it is from the ispy project. Here ios trendnet info https://www.ispyconnect.com/man.aspx?n=Trend+Net and here is foscam https://www.ispyconnect.com/man.aspx?n=foscam FYI - on some of my cameras I can see a video from a URL of http://192.168.1.31/video.cgi. Would livestreamer work with this? If not how about VLC? I have tried VLC in the past for similar stuff, like michaelcdfox's webfeedencoder and it was very hit and miss.
__________________
New Server - Sage9 on unRAID 2xHD-PVR, HDHR for OTA Old Server - Sage7 on Win7Pro-i660CPU with 4.6TB, HD-PVR, HDHR OTA, HVR-1850 OTA Clients - 2xHD-300, 8xHD-200 Extenders, Client+2xPlaceshifter and a WHS which acts as a backup Sage server Last edited by wayner; 01-09-2017 at 12:17 PM. |
#11
|
||||
|
||||
OpenDCT also has a HTTP capture device that is very similar to the PIPE capture device - and may work for you as well. I only think using the PIPE would be better because ffmpeg CAN do the transcoding for you. I don't see a reason to try to use something else for that task if you've already got MJPEG cameras. fmpeg should be able to pull in the MJPEG direct from the URL, and output the converted MP4 m2ts to the PIPE that OpenDCT would then send to sage.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer) unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers. Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA. Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S Other Clients: Mi Box in Master Bedroom, HD-200 in kids room |
#12
|
|||
|
|||
Ok thanks, I will check that out. Being in Canada I hadn't paid much attention to OpenDCT since DCTs aren't useful in Canada as cable companies won't give you a CableCARD and almst all cable cos encrypt all channels. But I know see that it is moving beyond the DCT.
__________________
New Server - Sage9 on unRAID 2xHD-PVR, HDHR for OTA Old Server - Sage7 on Win7Pro-i660CPU with 4.6TB, HD-PVR, HDHR OTA, HVR-1850 OTA Clients - 2xHD-300, 8xHD-200 Extenders, Client+2xPlaceshifter and a WHS which acts as a backup Sage server |
#13
|
||||
|
||||
Quote:
__________________
SageTV v9 Server: ASRock Z97 Extreme4, Intel i7-4790K @ 4.4Ghz, 32GB RAM, 6x 3TB 7200rpm HD, 2x 5TB 7200rpm HD, 2x 6TB 7200rpm HD, 4x 256GB SSD, 4x 500GB SSD, unRAID Pro 6.7.2 (Dual Parity + SSD Cache). Capture: 1x Ceton InfiniTV 4 (ClearQAM), 2x Ceton InfiniTV 6, 1x BM1000-HDMI, 1x BM3500-HDMI. Clients: 1x HD300 (Living Room), 1x HD200 (Master Bedroom). Software: OpenDCT :: WMC Live TV Tuner :: Schedules Direct EPG |
#14
|
||||
|
||||
Quote:
Wayner. Check out this you can hook it up to your Sat receiver or Cable box to output an un-encrypted stream to OPENDCT. There is some review threads below. http://www.unisheen.cn/pro.asp?ClassID=2 https://forums.sagetv.com/forums/showthread.php?t=63177
__________________
SageTV V9.xx 2 x HD300's, 2 x Nvidia Shields Running Mini Client |
#15
|
|||
|
|||
I have seen those threads. Currently I am have three HD-PVRs that I have been using for many years so I won't need these boxes until I have to switch to HDMI only cable boxes. For now it is nice to continue to get the DD5.1 sound.
__________________
New Server - Sage9 on unRAID 2xHD-PVR, HDHR for OTA Old Server - Sage7 on Win7Pro-i660CPU with 4.6TB, HD-PVR, HDHR OTA, HVR-1850 OTA Clients - 2xHD-300, 8xHD-200 Extenders, Client+2xPlaceshifter and a WHS which acts as a backup Sage server |
#16
|
||||
|
||||
Quote:
Can you help me format the executable with ffmpeg? Im using windows and im not that familiar with using the PIPE My IP Camera is rtsp://192.168.0.25:554/live that works in VLC Its 264 - MPEG-4 AVC (part 10) (h264) I have "ffmpeg -i rtsp://192.168.0.25:554/live ???????" Thanks Chris
__________________
SageTV V9.xx 2 x HD300's, 2 x Nvidia Shields Running Mini Client |
#17
|
||||
|
||||
Quote:
Code:
ffmpeg -i rtsp://182.168.0.25:554/live -f mpegts pipe:1
__________________
Buy Fuzzy a beer! (Fuzzy likes beer) unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers. Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA. Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S Other Clients: Mi Box in Master Bedroom, HD-200 in kids room |
#18
|
||||
|
||||
Quote:
I might do this slight modification or I think FFmpeg will transcode the video by default Code:
ffmpeg -i rtsp://182.168.0.25:554/live -c:v copy -f mpegts pipe:1
__________________
SageTV v9 Server: ASRock Z97 Extreme4, Intel i7-4790K @ 4.4Ghz, 32GB RAM, 6x 3TB 7200rpm HD, 2x 5TB 7200rpm HD, 2x 6TB 7200rpm HD, 4x 256GB SSD, 4x 500GB SSD, unRAID Pro 6.7.2 (Dual Parity + SSD Cache). Capture: 1x Ceton InfiniTV 4 (ClearQAM), 2x Ceton InfiniTV 6, 1x BM1000-HDMI, 1x BM3500-HDMI. Clients: 1x HD300 (Living Room), 1x HD200 (Master Bedroom). Software: OpenDCT :: WMC Live TV Tuner :: Schedules Direct EPG |
#19
|
||||
|
||||
Yes, definitely this.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer) unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers. Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA. Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S Other Clients: Mi Box in Master Bedroom, HD-200 in kids room |
#20
|
||||
|
||||
And we may find that it might be best to have ffmpeg add a silent audio track to these security camera feeds, so it is easier for sage and other players to see what they expect.
Code:
ffmpeg -i rtsp://182.168.0.25:554/live -c:v copy -i anullsrc=cl=1 -shortest -c:a aac -f mpegts pipe:1
__________________
Buy Fuzzy a beer! (Fuzzy likes beer) unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers. Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA. Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S Other Clients: Mi Box in Master Bedroom, HD-200 in kids room Last edited by Fuzzy; 01-14-2017 at 11:35 AM. |
Tags |
executable, script, streaming |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
USB Capture Device? | Skybolt | Hardware Support | 5 | 05-07-2013 07:00 PM |
HVR-1600 Capture Device? | m0ng00se30 | Hardware Support | 10 | 04-28-2007 10:24 AM |
Using Motorola Tuner device for capture device | cyberfreak | Hardware Support | 4 | 02-22-2007 02:47 PM |
No AV Capture Device | jaelanicu | SageTV Recorder Software | 5 | 08-03-2006 02:02 AM |
Video Capture Device - Not Available | crashdude | Hardware Support | 2 | 03-15-2004 12:14 PM |