Send Motion-user mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.sourceforge.net/lists/listinfo/motion-user
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Motion-user digest..."
Today's Topics:
1. Trying to use Milestone Universal Driver to access Motion web
stream (John C Edens)
----------------------------------------------------------------------
Message: 1
Date: Mon, 05 Feb 2018 23:01:22 +0000
From: John C Edens <[email protected]>
To: "[email protected]"
<[email protected]>
Subject: [Motion-user] Trying to use Milestone Universal Driver to
access Motion web stream
Message-ID: <[email protected]>
Content-Type: text/plain; charset="us-ascii"
I am trying to use the stream from Motion's built in webcam server as a video
input source to a Milestone XProtect video management system.
I can access the stream from other computers on the network using Firefox and
VLC media player by simply entering the address:
http://server_address:8081
into the browser URL bar or into VLC's "Open Network Stream" entry field
However, when I try to configure Milestone's selections, the stream is not
properly accessed.
The Milestone reference page for their Universal Driver can be found here:
https://force.milestonesys.com/support/articles/en_US/How_To/Use-and-configure-the-Universal-Driver?retURL=%2Fsupport%2Fapex%2FMccKnowledgeBase&popup=false
but I'll extract the relevant parts below...
Summary
The Universal Driver was introduced to expand the number of devices which could
be used with XProtect(r) software. Many devices use the RTP/RTSP streaming
protocols, and the Universal Driver is designed to work with these. However,
because not all manufacturers implement standards in the same way, not all
RTP/RTSP devices will work using this driver. Due to the vast number of devices
in the market, we cannot provide support for the Universal Driver beyond the
content of this article.
This looks a little worrisome since only RTP/RTSP is referenced, but HTTP is
mentioned further on as an option...
Any codec and streaming mode can be combined, provided standard RTP and HTTP
protocols are used. Here is an explanation on the available fields:
Codec
Select among three supported video formats: MJPEG, MPEG4 and H.264.
>From the "Stream and Webcontrol section of Motion's documentations, we find:
"The webserver generates a stream in "multipart jpeg" format (mjpeg)." - so I
choose MJPEG
Back on Milestone, we see:
Streaming Mode
* RTP - this mode uses the RTSP protocol to initiate the connection,
while RTP (over UDP) is used for data transmission.
* RTP over RTSP - this mode uses the RTSP protocol to initiate the
connection, and data is transmitted over a TCP connection.
* HTTP - this mode uses an HTTP GET request to initiate the connection
and continues to use TCP for data transmission.
So I select "HTTP"
Also in Milestone:
Delivery Mode (available only when streaming mode is HTTP)
* Multipart Stream - the data is streamed using multipart packaging
(i.e. a stream with boundaries, with or without content length specified.)(See
example 1 below).
* Non-Multipart Stream - the data is streamed as "back to back",
meaning the images have only the relevant tags and that the start of the next
image is delivered right after the end tag of the previous image (See example 2
below).
Based on the previous information from the Motion documentation, I choose
"Multipart Stream"
This next from Milestone puzzles me a bit:
Mode (only available when you select JPEG codec
* Streaming - this mode specifies that the images are retrieved by
opening a connection and keeping it open.
* Snapshot - this mode specifies that the images are retrieved one at a
time by connecting, getting an image, and then disconnecting.
There was no JPEG codec listed as an option, but there was an MJPEG, which I
have selected. I suspect "Streaming" is what I want, but I try both with no
success.
And the final option of interest is Connection URI:
Connection URI
You must enter the video stream connection string for your device in this
field. Use the device API documentation or a tool like Wireshark to discover
the correct URI (See example 3 below).
Example 3 - Connection URI
The following is a connection URI example from an Axis VAPIX3 device:
"axis-media/media.amp?videocodec=h264"
Note that the field can actually be empty as some devices do not require more
information other than an open connection.
Based on this from the Motion docs:
It may also be possible to view the stream via regular stream players such as
VLC, mplayer, ffplay, avplay, etc. by specifying the network stream as
http://localhost:myportnumber/stream.mjpg
I've tried both leaving that field blank and trying "stream.mjpg" and field
entries. No results in either case.
I tried using Wireshark and if I'm looking at the right things, this is what
the packets from a Firefox browser looks like:
GET /stream.mjpg HTTP/1.1
Host: IP-address:8081
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:58.0) Gecko/20100101
Firefox/58.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate
Connection: keep-alive
Upgrade-Insecure-Requests: 1
HTTP/1.0 200 OK
Server: Motion/4.0
Connection: close
Max-Age: 0
Expires: 0
Cache-Control: no-cache, private
Pragma: no-cache
Content-Type: multipart/x-mixed-replace; boundary=BoundaryString
--BoundaryString
Content-type: image/jpeg
Content-Length: 33948
If I omit the /stream.jpg from the url and just enter http://IP-address:8081,
then the first line of the header reads:
GET / HTTP/1.1
Any suggestions would be appreciated.
John Edens
-------------- next part --------------
An HTML attachment was scrubbed...
------------------------------
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
------------------------------
Subject: Digest Footer
_______________________________________________
Motion-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/motion-user
------------------------------
End of Motion-user Digest, Vol 140, Issue 17
********************************************