User avatar
ScottBouch
Posts: 146
Joined: Wed Jun 06, 2012 12:32 pm
Location: Midlands, UK
Contact: Website

Composite (or Component) Video INPUT!?

Thu Jun 07, 2012 1:36 pm

Hi all.... I have a nice old CCTV camera. It has a composite output.

I want (eventually) to make my Raspi and the camera into an IP camera.
Is there a way of bringing composite video into my Pi without using dodgy USB adaptors?

Can I make a curcuit to digitize the signal and utilise the GPIO header?

But then where do I go with coding for it!?

Cheers, Scott
http://www.scottbouch.com

http://www.youtube.com/user/sbscottmonkey - - - YouTube Channel

User avatar
thekeywordgeek
Posts: 105
Joined: Fri May 18, 2012 1:48 pm
Contact: Website

Re: Composite (or Component) Video INPUT!?

Thu Jun 07, 2012 3:41 pm

Something that I also have a slight interest in, though I'll be looking at a USB solution if indeed I ever get round to it.

I did have a read around though and found a couple of pages that might be of use.

http://www.techmind.org/vd/mk1/vdescrpt.html
http://www.techmind.org/vd/vidmk2.html
I make and sell radio kits for the Raspberry Pi and more.
http://shop.languagespy.com/

User avatar
Burngate
Posts: 6225
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: Composite (or Component) Video INPUT!?

Thu Jun 07, 2012 5:15 pm

OK you've got an old camera. Its output will probably be analogue, maybe colour, either PAL or NTSC.
To get that into the Pi (or any digital device) you're going to need a D-A device, and it's going to have to be running in sync with the analogue picture, and fairly fast. For PAL you're going to need at least 8 bits, and 13.5 MHz sample rate to keep up with the colour subcarrier (can't remember the NTSC color sbcarrier!)
Then you're going to need to lock that to the picture, which means separating out the syncs and feeding those into a vco
Alternatively you could decode the picture down to RGB - you'll need the sync separator for that as well, but now you only need three slower A_Ds.
Having got the digital data, you're then going to have to get it in to the Pi, in a timely fashion - writing that code for the GPIOs could be difficult, as Linux ain't good for realtime stuff, we're told.
A USB dongle does all that for you. Saves a lot of hassle

User avatar
Grumpy Mike
Posts: 931
Joined: Sat Sep 10, 2011 7:49 pm
Location: Manchester (England England)
Contact: Website

Re: Composite (or Component) Video INPUT!?

Sat Jun 09, 2012 5:06 pm

I made a lot of these sort of devices in the 70's. You need what is called a flash A/D to handle the speed. In essence you need to monitor a pin for a line sync pulse and when you see one gather something like 512 samples from the A/D. It is a simple matter to keep count of the lines and reset it when you see a frame sync pulse.

The problem with getting the data into the Pi is that the Linux operating system steals slices of time up to 10mS from any running code. Mainly you don't notice this but when you are trying to do a frame grab then you do.

Therefore you would have to have some sort of input buffer which adds to the complexity of the circuit.
Your best bet would be to use one of these video input converters you get for digitising your old video tapes and then trying to find or write a driver for them.

User avatar
ScottBouch
Posts: 146
Joined: Wed Jun 06, 2012 12:32 pm
Location: Midlands, UK
Contact: Website

Re: Composite (or Component) Video INPUT!?

Tue Jun 12, 2012 7:18 pm

Great responses guys, thank you.

I'll have a look at USB devices, as like you say, 10ms is quite a long time, relatively.

It would be great to get stuck into some proper electronics again, but this seems like a bit too much of a project!

Thanks for the responses! Scott
http://www.scottbouch.com

http://www.youtube.com/user/sbscottmonkey - - - YouTube Channel

zachgheaja
Posts: 1
Joined: Thu Jul 26, 2012 5:28 am

Re: Composite (or Component) Video INPUT!?

Thu Jul 26, 2012 5:29 am

http://www.amazon.com/EasyCAP-DC60-Crea ... ity+camera

Easy Cap usb 2.0 to rca yadda yadda jacks.

im working on the same project. this seems like it could do the job.

rvinoth39
Posts: 37
Joined: Mon Jan 07, 2013 8:42 am

Re: Composite (or Component) Video INPUT!?

Fri Jan 11, 2013 12:15 pm

does anyone got easycap successfully working????
i've installed firmware successfully but when i run sudo somagic-capture with mplayer its showing error like unexpected block and repeats

User avatar
davidstory
Posts: 15
Joined: Sat Feb 09, 2013 5:32 am
Location: San Diego, CA

Re: Composite (or Component) Video INPUT!?

Thu Feb 21, 2013 4:45 am

I too, am searching for a UVC compliant composite video capture device to use with my Raspberry Pi. I have a GearHead web cam that is UVC compliant, and it works great (with mjpg_streamer), but, I want to use a security camera with night vision that outputs composite video.

camera --(composite video)--> UVC capture device --(usb)--> Raspberry Pi

User avatar
davidstory
Posts: 15
Joined: Sat Feb 09, 2013 5:32 am
Location: San Diego, CA

Re: Composite (or Component) Video INPUT!?

Mon Mar 11, 2013 11:31 pm

I purchased a UVC compatible video capture device that works great with the Raspberry Pi.
I'm able to plug in my composite video source (camera) into it, then plug it into the USB port, and capture and stream the video using mjpg_streamer. Works great!

$70 USD for FEBON 100 UVC video grabber
from Andy Tzeng of Sunriase Co., LTD
[email protected]
http://www.sunriase.com/

balajiv
Posts: 33
Joined: Mon May 06, 2013 6:08 am

Re: Composite (or Component) Video INPUT!?

Wed Aug 07, 2013 11:46 am

davidstory wrote:I purchased a UVC compatible video capture device that works great with the Raspberry Pi.
I'm able to plug in my composite video source (camera) into it, then plug it into the USB port, and capture and stream the video using mjpg_streamer. Works great!

$70 USD for FEBON 100 UVC video grabber
from Andy Tzeng of Sunriase Co., LTD
[email protected]
http://www.sunriase.com/
David,

I have a query:

1) This UVC card captures video as well as audio. Can we give the audio input to the RPi using USB Jack ?

2) If yes, is it possible for me to get the audio remotely ? Like, I can see the video using mjpg streamer's web URL. Will I be able to get the audio as well ?

Your responses are appreciated.

Thanks.

balajiv
Posts: 33
Joined: Mon May 06, 2013 6:08 am

Re: Composite (or Component) Video INPUT!?

Wed Aug 07, 2013 11:48 am

David, this is related to a query posted on the thread: http://www.raspberrypi.org/phpBB3/viewt ... 86#p375586

User avatar
davidstory
Posts: 15
Joined: Sat Feb 09, 2013 5:32 am
Location: San Diego, CA

Re: Composite (or Component) Video INPUT!?

Wed Aug 07, 2013 4:00 pm

I was not attempting to capture audio at the time (backup camera).
I don't recall if mjpg_streamer was sending audio or not.

PiGraham
Posts: 3778
Joined: Fri Jun 07, 2013 12:37 pm
Location: Waterlooville

Re: Composite (or Component) Video INPUT!?

Wed Aug 07, 2013 5:18 pm

rvinoth39 wrote:does anyone got easycap successfully working????
i've installed firmware successfully but when i run sudo somagic-capture with mplayer its showing error like unexpected block and repeats
Yes, just tried out a device I've had in a draw for ages.
"EasyCap" written above a green LED on the top of the case.

Code: Select all

lsusb
Bus 001 Device 010: ID 05e1:0408 Syntek Semiconductor Co., Ltd STK1160 Video Capture Device

Code: Select all

dmesg
[27833.336139] usb 1-1.3.5: new high-speed USB device number 14 using dwc_otg
[27833.437416] usb 1-1.3.5: New USB device found, idVendor=05e1, idProduct=0408
[27833.437449] usb 1-1.3.5: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[27833.437467] usb 1-1.3.5: Product: USB 2.0 Video Capture Controller
[27833.437481] usb 1-1.3.5: Manufacturer: Syntek Semiconductor
It captures from a PAL output CCTV camera to frame buffer at approx. 2-3 frames per second.

[edit]
Trying again it looks more like 8 - 10 fps now.

Code: Select all

 mplayer tv:// -tv driver=v4l2:device=/dev/video0
Last edited by PiGraham on Fri Aug 09, 2013 7:40 pm, edited 1 time in total.

PiGraham
Posts: 3778
Joined: Fri Jun 07, 2013 12:37 pm
Location: Waterlooville

Re: Composite (or Component) Video INPUT!?

Fri Aug 09, 2013 7:16 pm

I can't get the EasyCap to record audio. arecord recognises it and produces an output file but there is only a faint hint of signal to it.
alsamixer detects it with mic input but will not allow level adjustment.

Aspvr
Posts: 1
Joined: Wed Feb 19, 2014 8:17 pm

Re: Composite (or Component) Video INPUT!?

Wed Feb 19, 2014 8:20 pm

Sorry for resurecting this old post.


But is there any new updates on video grabbing with raspberry Pi?

Does the FEBON100 UVC Grabber Card mentioned here works out of the box?


Thx

BerryPicker
Posts: 177
Joined: Tue Oct 16, 2012 3:03 pm
Location: The East of England

Re: Composite (or Component) Video INPUT!?

Thu Feb 27, 2014 3:57 pm

Aspvr wrote: ... any new updates on video grabbing with raspberry Pi
I've found that em28xx devices now work at 25fps with 320x288 resolution. I've had success with "DVD maker USB 2.0" devices branded by VSTREAM and KWORLD.
The full frame rate and reduced resolution of these devices makes them ideal for use with the hyperion-v4l2.

hups
Posts: 11
Joined: Fri Mar 07, 2014 10:12 am

Re: Composite (or Component) Video INPUT!?

Mon Mar 17, 2014 7:02 am

hey dear,,

i am having Easycap DC60 device but i dont have its drivers for linux ..
so can u please provide the driver and procedure to install it over a linux OS

please rply soon....

ctslick
Posts: 2
Joined: Thu Apr 03, 2014 9:11 pm

Re: Composite (or Component) Video INPUT!?

Thu Apr 03, 2014 9:14 pm

According to the page, this USB converter works directly with the Raspberry Pi:

http://febon.blogspot.com/2012/02/1.html

Return to “Graphics, sound and multimedia”