How to record and stream your TV shows

In this blog post I will show you how easy simple it is to stream and record your TV shows. Also check out the new post that uses the same software but makes it compatible with VLC.

What you will need?

1x EasyCap USB Video capture device.

1x RCA to 3.5mm adaptor(I recommend using your soundcard’s line/mic port as the sound source, because the quality of EasyCap’s sound input will probably suck).

100GB or higher hard drive for recording shows is recommended,

You may need a VCR w/Remote Control, depending if the TV box doesn’t have a Composite video output. We will be using the VCR as a RF Demodulator (this is opposite of the famous RF Modulator)

If you have to use the VCR as you will need a TV Coax cable also before buying the VCR or TV Coax cable make sure your box has a RF output on it. Mediacom has the coax output but not Composite video output so the VCR is ideal for this project.

The software we will use is:

Step 1. Install EasyCap.

Install any drivers for EasyCap, i believe for windows 10 its plug and play

Step 2. Install Unreal Live Server

  1. Install Unreal LIve Server and open its control panel by opening “Live server configurator” from the Start Menu
  2. Right click “Live sources and click “Add new media source”
  3. Check “Add video source” and select “USB Video Device”
  4. Click next for the Media type
  5. You can click next again
  6. You can click next again
  7. Check “Add audio source” and choose the correct audio source that has is connected to the TV device(VCR/TV converter box).
  8. You can click next again
  9. You can test the audio or just click next
  10. You can leave the codecs and speeds alone and click next
  11. Enter a description like TV and then cick next
  12. Don’t click enable recording click finish, we will setup recording in the archival server.

Step 3. Install Unreal Media Server

  1. Download and install Unreal Media Server
  2. Open the “Media Server configurator” from the start menu.
  3. Click File then New Live Broadcast…
  4. Leave Static live broadcast selected and click OK
  5. Type in a alias for the stream and use the ID number from Live Server(usually 1)
  6. Type in the IP address or host name where the Live server is on you can set it to 127.0.0.1 if its on the same computer that the Media server is on
  7. If you don’t want to record shows then just skip to Step 6.

Step 4. Install Archival Server

  1. Before closing the media server control panel you must set up a password for the Archival Server, click File then properties in the media server control panel.
  2. Click the Set Password button
  3. Enter a password that will be used for the archival server to use.
  4. Note: we will install archival server and IIS on the same computer where the videos will be recorded
  5. Now install archival server.
  6. Open Archival server configurator from the start menu
  7. Check the “Enable periodic cleanup”, this will help save space on your hard drive by deleting the old videos
  8. Click file then add new media server
  9. Type in the IP address or hostname of the media server in the Media Server address text box, note this will be the constant LiveHost in the JavaScript code
  10. Type in the password you used for archival server in the media server control panel in the Server password field
  11. Click OK
  12. To setup the path where the videos are stored click the Storage Settings button, this will be where the website files will be stored
  13. You will now need to setup the schedule, since our JavaScript code is designed to load videos by the hour only it should have 24 different recording times. This means it should start at hh:00 and end at hh:59 for every hour, replace hh with the 2-digit hour.

Step 5. Install IIS

  1. Install IIS as shown in this tutorial
  2. Change the Default Web Directory by clicking Sites then right click “Default Web Site” then click Advanced Settings
  3. Set Physical Path to the path where archival server storage settings were set to.
  4. Open notepad and copy and paste the HTML code and save it as “index.html” in the root of the recording folder
<!DOCTYPE html>
<html>
<head>
<title>My TV Recordings</title>
<script type="text/javascript">
//If you used the same settings in my blog then you dont need to change the 2 constants
const LiveHost = "127.0.0.1";
const ArchivalAlias = "TV";
function gotoArchivalList(){
location.href ="./"+LiveHost+"/"+ArchivalAlias+"/"
}
function twoDigit(x){
if(x<10){
return "0"+x;
}return x;
}
function setVideo(videoMonth,videoHour,videoDay,videoYear){
document.getElementById("player").innerHTML="";
var videoPlayer = document.createElement("VIDEO");
var video = document.createElement("SOURCE");
video.src = "./"+LiveHost+"/"+escape(ArchivalAlias)+"/"+videoYear+"/"+videoMonth+"/"+videoDay+"/"+escape(ArchivalAlias+"_"+videoYear+"-"+videoMonth+"-"+videoDay+"_"+videoHour+"-00-01.mp4");
video.type = "video/mp4";
videoPlayer.controls = true;
videoPlayer.appendChild(video);
document.getElementById("player").appendChild(videoPlayer);
}
function playerForm(form){
var videoTime = new Date(form.date.value+" "+form.time.value+":00:00");
var videoMonth = twoDigit(videoTime.getMonth()+1);
var videoHour = twoDigit(videoTime.getHours());
var videoDay = twoDigit(videoTime.getDate());
var videoYear = videoTime.getFullYear();
setVideo(videoMonth,videoHour,videoDay,videoYear);
}
function startUp(){
var now = new Date();
var lastHour = new Date(now.getTime()-(60*60*1000));
document.getElementById("vDate").value = lastHour.toLocaleDateString();
var videoMonth = twoDigit(lastHour.getMonth()+1);
var videoHour = twoDigit(lastHour.getHours());
var videoDay = twoDigit(lastHour.getDate());
var videoYear = lastHour.getFullYear();
setVideo(videoMonth,videoHour,videoDay,videoYear);
}
</script>
</head>
<body onload="startUp()">
<form action="javascript:;">
<p id="player">

</p>
Chose a date:<input type="date" name="date" id="vDate"><br>
Choose a time:<select name="time">
<option value="00">12 AM</option>
<option value="01">1 AM</option>
<option value="02">2 AM</option>
<option value="03">3 AM</option>
<option value="04">4 AM</option>
<option value="05">5 AM</option>
<option value="06">6 AM</option>
<option value="07">7 AM</option>
<option value="08">8 AM</option>
<option value="09">9 AM</option>
<option value="10">10 AM</option>
<option value="11">11 AM</option>
<option value="12">12 PM</option>
<option value="13">1 PM</option>
<option value="14">2 PM</option>
<option value="15">3 PM</option>
<option value="16">4 PM</option>
<option value="17">5 PM</option>
<option value="18">6 PM</option>
<option value="19">7 PM</option>
<option value="20">8 PM</option>
<option value="21">9 PM</option>
<option value="22">10 PM</option>
<option value="23">11 PM</option>
</select><br>
<input type="button" value="Load Video" onclick="playerForm(this.form)">
</form>
<a href="javascript:gotoArchivalList()">Click here to see list of recorded video files.</a>
</body>
</html>

Step 6. Install Unreal Media Player

Finally install Unreal Media player and test its stream. For any device that is not windows you can use your HTML5 Web Browser to stream any recording upto an hour back(since the one that is being recording cannot be streamed until recording is done)

Published by Justin Roeder

I am an electronics engineer and computer programmer that has autism. I learned by myself

delphijustin Industries is an Autism Supported Business
Social Media Auto Publish Powered By : XYZScripts.com
All in one
Start
Microsoft Corporation AZ Phoenix
Your cart is empty.
Loading...