Active Topics

 


Reply
Thread Tools
Posts: 102 | Thanked: 22 times | Joined on Oct 2009
#1
Ok so I installed gstreamer-tools and after a bit of messing I managed to get the N900 to stream to my ubuntu desktop using the following:

-- Server (N900) --
gst-launch v4l2src device=/dev/video0 ! videoscale! video/x-raw-yuv,width=320,height=240 ! ffmpegcolorspace ! jpegenc ! multipartmux ! tcpserversink host=192.168.0.3 port=5000

-- Client (PC) --
gst-launch tcpclientsrc host=192.168.0.5 port=5000 ! multipartdemux ! jpegdec ! autovideosink

It works but I am now trying to get it to play nice with VLC.
I have had a look at :
1
and
2

But the encoder used, hantro4200enc, I do not have. Does any one know of a possible solution to stream to VLC?
 

The Following 2 Users Say Thank You to shadow12 For This Useful Post:
Posts: 102 | Thanked: 22 times | Joined on Oct 2009
#2
Nevermind found this:

Streaming N900 VLC
 

The Following User Says Thank You to shadow12 For This Useful Post:
Posts: 4 | Thanked: 9 times | Joined on Jan 2010 @ Buenos Aires, Argentina
#3
Hello every body.

I made to short scripts on bash in order to make the streaming easyer:

First on the N900 with root privileges

touch /usr/local/bin/stream-gst
chmod +x /usr/local/stream-gst
vi /usr/local/bin/stream-gst

and there write (remeber to press "i" to edit and when you finish press ESC and then "x:" + ENTER ):

Code:
Code:
#!/bin/sh

gst-launch v4l2src device=/dev/video$1 ! videoscale! video/x-raw-yuv,width=320,height=240,framerate=30/1 ! ffmpegcolorspace ! jpegenc ! tcpserversink host=$2 port=5000
After that run the script:

stream-gst 1 192.168.1.101

In this example you are transmiting from the /dev/video1 (Front Camera) to the computer 192.168.1.101
or
You can also steam from the back camera to all the computers on your network by:

stream-gst 0 192.168.1.255


Then on the PC (with linux and root privileges)

touch /usr/local/bin/get-gst
chmod +x /usr/local/get-gst
vi /usr/local/bin/get-gs

and there write (remeber to press "i" to edit and when you finish press ESC and then "x:" + ENTER ):

Code:
Code:
#!/bin/sh

gst-launch tcpclientsrc host=$1 port=5000 ! jpegdec ! autovideosink
And the runing the script specifiing the IP of your N900

get-gst 192.168.1.102

It also work on the other way and direction. To see the web cam on yor PC form your N900.

See you!

Patricio
Pd: Sorry for my english
 

The Following 6 Users Say Thank You to pgv1982 For This Useful Post:
danx's Avatar
Posts: 304 | Thanked: 20 times | Joined on Jan 2010 @ irvine
#4
CAN YOU PACKAGE THAT .lol
 
Posts: 2 | Thanked: 1 time | Joined on Apr 2010
#5
If anyone has problems with the front camera not working, the front camera didn't work for me until I removed the ',framerate=30/1' part.
 
Posts: 489 | Thanked: 404 times | Joined on Dec 2009
#6
Hi everyone,

could any very gentle person out there explain me how to stream this damn camera to my PC? It seems that none of the procedure explained here works for me.

Why the hell it says "no element "multipartmux""??? Where can I find that one?

I'm a very noob in these kind of things, so please be patient with me.

Thanks for reading, I really need that thing (for my job) so any help would be appreciated.
 
Posts: 992 | Thanked: 738 times | Joined on Jun 2010 @ Low Earth Orbit
#7
Originally Posted by torpedo48 View Post
Why the hell it says "no element "multipartmux""??? Where can I find that one?
Here, sort of. You need to install it via your distro app management thingy. If in doubt install all the gstreamer plugins.
 

The Following User Says Thank You to kureyon For This Useful Post:
Posts: 86 | Thanked: 28 times | Joined on Jan 2010 @ That beer and prezels country in Europe -_-
#8
@torpedo48:

This will work and is tested with VLC:

On your N900 execute the following command:
Code:
gst-launch-0.10 v4l2src device=/dev/video1 ! dsph264enc ! rtph264pay ! udpsink host=xxx.xxx.xxx.xxx port=5434
(where xxx.xxx.xxx.xxx is the IP address of your computer and /dev/video1 is the front camera; video0 is back camera)

Note that this is v4l2src with an lowercase L, NOT 412

On your computer create the following .txt file:
Code:
v=0
m=video 5434 RTP/AVP 96
c=IN IP4 xxx.xxx.xxx.xxx
a=rtpmap:96 H264/90000
(where xxx.xxx.xxx is the IP address of your N900)

Rename the file to some_cool_name_for_streaming.sdp and open it with VideoLAN player for greater justice.

Try looking for the other posts to add additional parameters to gstreamer. This is video only, additional audio is also available, but not used by me so I can't say anything to that.

Best regards,
/me

PS: Your N900 could get heated up and will drain battery somewhat fast, so if you intend to use this longer, please attach the charger.

Last edited by Renkon; 2010-09-17 at 09:22.
 

The Following 3 Users Say Thank You to Renkon For This Useful Post:
Posts: 22 | Thanked: 1 time | Joined on Sep 2009 @ Belgium
#9
Originally Posted by Renkon View Post
@torpedo48:

This will work and is tested with VLC:

On your N900 execute the following command:
Code:
gst-launch-0.10 v4l2src device=/dev/video1 ! dsph264enc ! rtph264pay ! udpsink host=xxx.xxx.xxx.xxx port=5434
(where xxx.xxx.xxx.xxx is the IP address of your computer and /dev/video1 is the front camera; video0 is back camera)

Note that this is v4l2src with an lowercase L, NOT 412

On your computer create the following .txt file:
Code:
v=0
m=video 5434 RTP/AVP 96
c=IN IP4 xxx.xxx.xxx.xxx
a=rtpmap:96 H264/90000
(where xxx.xxx.xxx is the IP address of your N900)

Rename the file to some_cool_name_for_streaming.sdp and open it with VideoLAN player for greater justice.

Try looking for the other posts to add additional parameters to gstreamer. This is video only, additional audio is also available, but not used by me so I can't say anything to that.

Best regards,
/me

PS: Your N900 could get heated up and will drain battery somewhat fast, so if you intend to use this longer, please attach the charger.
I'm getting some errors while following your tutorial though

Code:
Nokia-N900:~# gst-launch-0.10 v4l2src device=/dev/video0 ! dsph264enc ! rtph264pay ! udpsink host=78.21.100.x port=5434
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
create_node: dsp node create failed
sink_setcaps: dsp node creation failed
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Internal data flow error.
Additional debug info:
gstbasesrc.c(2378): gst_base_src_loop (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
streaming task paused, reason not-negotiated (-4)
Execution ended after 558532714 ns.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...
Nokia-N900:~#
 
joshv06's Avatar
Posts: 346 | Thanked: 139 times | Joined on Jan 2008 @ Houston Texas
#10
^ I have the same problem.
__________________
Nokia N900
joshuavidana@gmail.com
 
Reply


 
Forum Jump


All times are GMT. The time now is 04:39.