You are on page 1of 52

StreamCorder-SD4

4 Channel Video Streamer

Document version: A.17

USER MANUAL
Definitions
AMP and Advanced Micro Peripherals are the trading names for Advanced Micro Peripherals Inc. and Advanced Micro Peripherals Ltd.

Disclaimer
This document contains information on a new product. Specifications and information herein are subject to change without notice.
AMP reserves the right to make changes to any products herein to improve functioning and design. Although the information in this
document has been carefully reviewed and is believed to be reliable, AMP does not assume any liability arising out of the application
or use of any product or circuit described herein. Nothing in this document is to be taken as a license to operate under or a
recommendation to infringe any patents.
AMP does not recommend the use of any of its products in life support applications wherein a failure or malfunction of the product
may directly threaten life or injury. The user of AMP products in life support applications assumes all risk of such use and indemnifies
AMP against all damages. All information contained in this document is proprietary to AMP and may not be reproduced or disclosed
to any third parties without the written consent of AMP. The circuit design, EPLD programs and artworks are copyright AMP 2008.
The information contained in this document has been carefully checked and is believed to be reliable. However, Advanced Micro
Peripherals Ltd (AMP) makes no guarantee or warranty concerning the accuracy of said information and shall not be responsible for
any loss or damage of whatever nature resulting from the use of, or reliance upon, it. AMP does not guarantee that the use of any
information herein will not infringe upon the patent, trademark, copyright, or other rights of third parties, and no patent or other
license is implied hereby
AMP reserves the right to make changes in the products or specifications, or both, presented in this document at any time and
without notice.

Warranty
This product is supplied with a 1 year limited warranty. The product warranty covers failure of any AMP manufactured product
caused by manufacturing defects. AMP will make all reasonable effort to repair the product or replace it with an identical variant.
AMP reserves the right to replace the returned product with an alternative variant or an equivalent fit, form and functional product.

Trademarks
Tiny486, Tiny586DX, Tiny786LP, Mobile786EBX, Tiny886, Micro886, VAC104, VAC104plus , VAC2000, The Embedded Video Experts
are trademarks of Advanced Micro Peripherals.
All other trademarks recognized.

Advanced Micro Peripherals


operates a company-wide
quality management system,
which has been certified by
QMS International plc as
compliant with ISO9001:2008
Revision History

Document version Date Comments Approved

A.00 30th January 2014 Preliminary release AS

A.01 26th February 2014 Addition of screenshots from prototype unit SJC

A.02 14th March 2014 Addition of encoder and standard settings SJC

Now defaults to static IP

A.03 25th March 2014 Downscaling removed SJC

A.04 5th June 2014 Added details of serial interface AS

Added connector details

A.05 18th August 2014 Corrected RS485 usage SJC

A.06 26th June 2015 Added power consumption details AS

Updated board photography to Rev 1.00 board

Added K3 connector details

Added details of optional Wifi card.

A.07 17th November 2015 Clarification of quality setting SJC

Addition of RTSP commands

A.08 22nd January 2016 Addition of multicast and transport stream SJC
settings

Security pages updated

Password details updated

Correction to audio capture status

Removal of reboot from video settings

A.09 21st September 2016 Updated photos for Rev 1.01 PCB SJC

New recordings setup page

A.10 29th September 2016 Minor cosmetic changes

A.11 15th November 2016 Addition of MJPEG SJC

A.12 15th December 2016 RTSP commands for changing topology SJC

A.13 21st February 2017 SD card removal warning SJC

A.14 10th May 2017 Additional RS485 commands for 1.33 release SJC
A.15 30th May 2017 Further RS485 commands from 1.34 release SJC

Addition of status page for 1.34 release

A.16 17th April 2018 Updated US address AS

Updated Video Configuration

Updated SET_PARAMETER and GET_PARAMETER


to show Session: field is required

A.17 3rd May 2018 Updated Video and Network Configuration

Corrections to power figures

Removal of WiFi Options and standard


temperature
StreamCorder-SD4 User Manual

Contents
1: Introduction ............................................................................................. 6
Features........................................................................................................................................................... 7
At a glance ....................................................................................................................................................... 8
Technical specification ..................................................................................................................................... 9
Ordering information ...................................................................................................................................... 10

2: Installation ............................................................................................. 11
Jumpers and connectors................................................................................................................................ 12

3: User Configuration ................................................................................. 15


Web Interface................................................................................................................................................. 15
Serial Interface............................................................................................................................................... 31
RTSP Command Interface ............................................................................................................................. 45

A: Contacting AMP ...................................................................................... 52

© 2018 Advanced Micro Peripherals


Document version A.17 5
1:
Introduction

The StreamCorder-SD4 is an intelligent, stand-alone, H.264 Streaming solution


that accepts 4x NTSC/PAL/RS-170 composite video sources and records and
streams them over 100/1000Mbit Ethernet. The single board solution is ideal for
rapid deployment in demanding applications in Military, Communications,
Transportation, Mining and Energy industries.
The StreamCorder-SD4 features a dedicated hardware compression engine
capable of recording all 4 video channels at full size and full frame-rate. The
flexible streaming engine can then stream each channel direct from the on-board
Ethernet port as well as save direct to locally attached storage (SD Card) for later
retrieval. The StreamCorder-SD4 also supports 4 channels of audio that can be
captured and streamed with the video channels.
Especially for mobile, UAS and Vetronix applications, the StreamCorder-SD4 has
optional on-board features, including Controller Area Network (CAN), 3-Axis
Accelerometer, High sensitivity GPS receiver, Altimeter, and a 3-Axis Digital
Magnetometer (e-compass). These can integrate with other vehicle systems and
data from these sources can be used as meta data embedded within the video
and streamed to clients or saved for later analysis.
The StreamCorder-SD4 is an intelligent stand-alone device with its own on-board
CPU and does not require a host CPU or any driver or OS software. For
mechanical convenience the module can be mounted on a PCI/104 stack without
consuming host CPU resources.

© 2017 Advanced Micro Peripherals


Document version A.17 6
1: Introduction StreamCorder-SD4 User Manual

Features
▪ 4 channels of live video inputs (PAL/NTSC/RS-170).

▪ Real time MPEG-4 Part 10 (H.264) video compression at full frame rate

▪ 4 channels of audio encoding

▪ Single board capture, encode, stream and record solution

▪ 100/1000Mbit Ethernet connection

▪ Low power operation for long endurance

▪ Stand-alone operation

▪ SD Card for local storage of recorded data.

▪ Optional CAN, GPS, Altimeter, Accelerometer, Compass

▪ Standard PCIe104 mechanical form factor

© 2018 Advanced Micro Peripherals


Document version A.17 7
1: Introduction StreamCorder-SD4 User Manual

At a glance

Power Ethernet
(+5V)

0V

Audio
inputs NTSC
/ PAL
Video
inputs

GPS
Antenna
(optional)

© 2018 Advanced Micro Peripherals


Document version A.17 8
1: Introduction StreamCorder-SD4 User Manual

Technical specification
Analog Video Input
Up to 4 concurrent PAL / NTSC / RS-170 composite video inputs
Four 10bit Analog-to-Digital converters
Anti-aliasing filter on inputs

Audio Input
4x mono input
Provides Audio/Video synchronization

H.264 Video Encoding


ITU-T H.264 (ISO/IEC 14496-10), supported profiles:
Baseline profile,
Main profile (I, P frame coding only)
High profile (I, P frame coding only) at level 4.1
4x D1 encode @ full frame rate
CAVLC and CABAC coding
Supports Variable Bit Rate (VBR)
Supports Constant Bit Rate (CBR)

JPEG Encoder
JPEG (ISO/IEC 10918-1)
Baseline JPEG with JFIF support

Network Interface
100/1000MBit Ethernet

Other Interfaces
RS-485 - For simple control of recording using proprietary commands
USB2.0 OTG - For external storage
SD-Card slot - On-board storage

Vetronix Features
CAN2.0B port - For vehicle networks (option)
High-sensitivity GPS (option)
3-axis Digital Magnetometer for eCompass (option)
3-axis Accelerometer (option)
High sensitivity altimeter (option)

© 2018 Advanced Micro Peripherals


Document version A.17 9
1: Introduction StreamCorder-SD4 User Manual

Mechanical
Intelligent stand-alone module, does not require host computer
Standard 3.6 x 3.8in PCIe104 form factor
Mechanical mounting for PCIe104 stack
Single +5V supply @ 800mA Max (4W)
Operating temp –40˚C to +85˚C

Ordering information
The following part number(s) can be used when ordering:
StreamCorder-SD4-Ext H.264 Video Streamer
(-40 to +85degC)
StreamCorder-SD4-VX-Ext H.264 Video Streamer + WiFi + sensors
(-40 to +85degC)

Anti-static handling
The board(s) supplied contain electrostatic components that are susceptible to
permanent damage from electrostatic discharge (static electricity). To prevent
electrostatic discharge, the boards are supplied in anti-static packaging.
When handling a board, observe the following anti-static precautions to alleviate
risk of damage:

▪ Remove the board(s) from the packaging only when you are working on an
anti-static, earthed surface and wearing an anti-static wrist strap.

▪ Retain the anti-static packaging that the board(s) were supplied in. If you
remove a board from a system, store it in this packaging.

© 2018 Advanced Micro Peripherals


Document version A.17 10
2:
Installation

© 2017 Advanced Micro Peripherals


Document version A.17 11
2: Installation StreamCorder-SD4 User Manual

Jumpers and connectors

K3

Power Ethernet
(+5V)

0V

VIN1
AUDIO

VIN2
SDCard
(Bottom side)
VIN3

J13
VIN4

USB
RFin
(GPS option)

CX1, CX2, CX3, CX4 PAL / NTSC Video input


75Ω MCX right angle connector for connecting composite video sources

MCX Signal
CX1 Channel 1 video input (VIN1)

CX2 Channel 2 video input (VIN2)

CX3 Channel 3 video input (VIN3)

CX4 Channel 4 video input (VIN4)

© 2018 Advanced Micro Peripherals


Document version A.17 12
2: Installation StreamCorder-SD4 User Manual

AUDIO Audio, Serial and CAN


20way right angle 2mm connector. (Molex:87833-2020)

Pin Signal Pin Signal


1 AIN1 2 AGND

3 AIN2 4 AGND

5 AIN3 6 AGND

7 AIN4 8 AGND

9 Reserved 10 Reserved

11 RS485+ 12 RS485-

13 Reserved 14 GND

15 Reserved 16 GND

17 CANH(1) 18 GND

19 CANL(1) 20 GND
Note 1: Requires CAN option.

PWR1 Power
Pin Signal
1 +5V

2 +5V

3 Reserved

4 0V

USB1 USB
USB 2.0 port for connection of an external mass storage device.

RFIN GPS Antenna


MCX connector for GPS Antenna (requires GPS option)

JP1, JP2, J8
Reserved for factory use

© 2018 Advanced Micro Peripherals


Document version A.17 13
2: Installation StreamCorder-SD4 User Manual

J13
Reserved for factory use

K3 Ethernet
K3 is provided to allow remote mounting of RJ45 connector.
For best results, when using K3, the local RJ45 is not normally fitted.

Pin Signal RJ45 pin Pin Signal RJ45 pin


1 MD_B+ 3 2 MD_B- 6

3 MD_C+ 4 4 MD_C- 5

5 MD_A+ 1 6 MD_A- 2

7 MD_D+ 7 8 MD_D- 8

9 GND Shield 10 GND Shield

SDCard SD Card Socket


This socket is used to host the SD card used for local storage or recordings. AMP
has tested and validated particular SD card models. Use of other models is not
supported.
The SD card MUST NOT be removed while the board is powered.

© 2018 Advanced Micro Peripherals


Document version A.17 14
3: User Configuration StreamCorder-SD4 User Manual

3:
User
Configuration

Web Interface
The StreamCorder-SD4 includes a number of standard HTML configuration
screens which may be accessed via the default IP address http://192.168.1.123/.

By default, the web front-end is not password protected. It is recommended to


set a password during the commissioning process for the purposes of security.

Two usernames are provided, allowing for two levels of authentication. The
admin account has access to the entire web front-end and settings, whereas the
user account has access only to the recording control.

Both usernames can also be used to restrict access to the RTSP stream. Both can
access the streamed video but certain RTSP commands require the admin login.

© 2018 Advanced Micro Peripherals


Document version A.17 15
3: User Configuration StreamCorder-SD4 User Manual

After completing the sign-on, the system will display the web front end where the
StreamCorder-SD4 can be configured.

© 2018 Advanced Micro Peripherals


Document version A.17 16
3: User Configuration StreamCorder-SD4 User Manual

Status
The status page provides information about the currently connected inputs and
the available storage media.

The channel information gives the recording and streaming status for each
input as well as providing diagnostic information about the connection.

© 2018 Advanced Micro Peripherals


Document version A.17 17
3: User Configuration StreamCorder-SD4 User Manual

Field Description
URL This can be copied and pasted into a streaming client such
as VLC. If WiFi is present, a second URL will be displayed
with the relevant IP address.

Status This can be one of the following:

Value Meaning

Running Streaming but not recording

Recording Streaming and recording

Format Recording format (avi for AVI or ts for Transport Stream)

Input If the input is connected and stable, this will display the
input resolution.
If the input is invalid, a series of error flags will be displayed

Value Meaning

loss No video detected

vlock Vertical lock failed

hlock Horizontal lock failed

slock Standard lock failed

© 2018 Advanced Micro Peripherals


Document version A.17 18
3: User Configuration StreamCorder-SD4 User Manual

Recording Control
The StreamCorder-SD4 supports stopping and starting recording on each channel.

Each channel is represented as a check box. If the box is checked, the recording
will run. When the box is unchecked, the recording will terminate.
The recording produces AVI files with a configurable maximum length. After this
time, a new file will be generated and the current file saved.
The recording medium menu allows the user to select the destination for video
clips between the internal storage and an external USB device (if fitted).
The StreamCorder supports the USB mass storage class (as used by most USB
hard drives and memory keys). It expects a single partition formatted to the FAT
filesystem.
When USB storage is present, a button will be displayed to allow the ejection of
the device. Note that this will work only when the device is not being written to;
if the user attempts to eject a device either when it is selected as the active
medium or during a flush operation, an error will be returned. If it is safe to
remove the USB device, a message will flash up informing the user. The device
should be removed before acknowledging the message in order to avoid
inadvertently remounting the filesystem.
The delete buttons are provided to reduce clutter on the internal storage. Press
the delete file for a particular channel to remove all files associated with that
channel. Note that it is not recommended to perform this on a channel that is
currently recording.

© 2018 Advanced Micro Peripherals


Document version A.17 19
3: User Configuration StreamCorder-SD4 User Manual

System Settings
The system settings page can be used to configure the time and date as well as
the hostname.

Field Description
Host name The name by which the StreamCorder-SD4 is known on the
network.

Time zone Local time zone.

NTP server When Automatic is set, the StreamCorder-SD4 will query this
server to obtain the system time. This can be an internet
server or a server on the local network.

Update The NTP server will be queried at the specified interval to


interval compensate for clock drift.

© 2018 Advanced Micro Peripherals


Document version A.17 20
3: User Configuration StreamCorder-SD4 User Manual

Security
The Security page can be used to set a password. It is recommended that this is
done before deployment.

The system provides two logins: admin and user.

The user login has limited access to the web front-end ie. the ability to start and
stop recordings and to download recorded files. It can also view the live RTSP
stream and run certain commands.

The admin login has the same abilities as the user as well as access to the
configuration pages on the web front-end and full RTSP command access.

Authentication for RTSP and HTTP can be toggled independently. If


authentication is disabled, the server can be accessed without requiring a login.

© 2018 Advanced Micro Peripherals


Document version A.17 21
3: User Configuration StreamCorder-SD4 User Manual

Network Settings

© 2018 Advanced Micro Peripherals


Document version A.17 22
3: User Configuration StreamCorder-SD4 User Manual

© 2018 Advanced Micro Peripherals


Document version A.17 23
3: User Configuration StreamCorder-SD4 User Manual

Note that there are multiple Save buttons on the page. Each section has its own
Save button.

Field Description
DHCP DHCP uses an IP address assigned by the local DHCP server.
Static IP uses the IP address defined by IP Address.
Default mode is Static IP

IP Address The IP address should be entered as an IPv4 dot-decimal


notation.
Default IP address is 192.168.1.123

SubNet Mask The SubNet Mask defined the logical address in dot-decimal
notation for the local branch of the network.
Default subnet mask is 255.255.0.0

Default Router The Gateway address defines the node address for router to
other networks.
Default Gateway address is 192.168.1.1

Primary DNS IPv4 Address for primary DNS server

Secondary DNS IPv4 Address for secondary DNS server

The HTTP settings configure the web front-end:

Field Description
HTTP Port The transport layer port number used for the web front-end.
The default port is 80.

Note: When setting the HTTP port to a value other than 80, it will need to be
specified in the URL eg. for a port of 8080, the web front-end would be accessed
as follows:

http://192.168.1.123:8080/

The RTSP settings are configured in the final section.

Field Description
RTSP Port The transport layer port number used for RTSP commands.
The default port is 554.

© 2018 Advanced Micro Peripherals


Document version A.17 24
3: User Configuration StreamCorder-SD4 User Manual

Multicast Group When multicast is enabled, the video will be streamed to this
Address address.

Multicast Port The starting port for multicast streaming.

Multicast TTL Time to live

Access name The access name for each stream is appended to the end of
the RTSP URL

Use transport The video, audio and metadata will be multiplexed into a
stream transport stream.

Always The data will be continuously streamed to the multicast


multicast address and ports listed above.

Stream Audio Audio data will be streamed. Only used when not doing
transport stream. When streaming transport stream the
setting from the Recording page is used

Multicast These are automatically derived from the Multicast Port field
Audio/Video/ above and specify the individual port for each stream on
Metadata port each channel.

All other fields are reserved for future use and should not be changed.

To access the RTSP video stream for a given channel would be:

rtsp://192.168.1.123:554/live0-1.sdp

Channel number (0 to 3)

Access to each channel is defined by the following stream addresses:

Channel RTSP Stream address


1 rtsp://192.168.1.123:554/live0-1.sdp

2 rtsp://192.168.1.123:554/live1-1.sdp

3 rtsp://192.168.1.123:554/live2-1.sdp

4 rtsp://192.168.1.123:554/live3-1.sdp

Note: The IP address may be different to the examples shown.


Important: Transport stream is currently not reliable over multicast.

© 2018 Advanced Micro Peripherals


Document version A.17 25
3: User Configuration StreamCorder-SD4 User Manual

Video
This is used to set the size and quality of each of the four channels. Note that
only the first two are shown below.
The settings will not be stored until the Save button has been pressed.

© 2018 Advanced Micro Peripherals


Document version A.17 26
3: User Configuration StreamCorder-SD4 User Manual

General settings
Field Description
Maximum The capture size. This must be set to the same standard as
Visible Size the video source.

Horizontal Number of pixels from start of horizontal sync to start of


Start active video

Vertical Start Number of lines from start of vertical sync to start of active
video

Mode Select the encoding method for compression. Options are


H264 and MJPEG.
Note that MJPEG cannot be used with transport stream.

Frame Size The frames will be downscaled to the given resolution before
encoding.

Maximum This is the encoding frame rate. It should not be set above
Frame Rate the frame rate of the input source e.g. if using a PAL source,
setting 30FPS could have unexpected results.
Note that MJPEG recordings may have a lower framerate for
higher quality values.

H264 settings
Field Description
Intra frame Defines the I-Frame interval, i.e. the number of frames
Period between each I frame for standard encoding. The value range
is from 0 to 255. Default I-Interval count is 30.

Rate control Select the rate control method. Can be one of the following:
Mode VQCB - The video quality and the frame rate will be varied to
meet the requested bitrate.
CQCB – The video is encoded with the selected quality factor
if the requested bitrate is not exceeded. When the requested
bit-rate is exceeded, the video quality and the frame rate will
be reduced to meet the requested bitrate.
CVBR – The video is encoded with the provided quality factor
if the requested bit-rate is not exceeded. When the bit-rate is
exceeded, the video quality will be reduced to meet the
desired bit-rate.

© 2018 Advanced Micro Peripherals


Document version A.17 27
3: User Configuration StreamCorder-SD4 User Manual

Bit Rate Desired bitrate

Quality Desired quality. Higher values result in higher compression,


giving a lower bitrate and less visual clarity. The value range
is from 0 to 51.

MJPEG settings
Field Description
Quality This can be set to Medium, Standard, Good, Detailed or
Excellent.
Please note that the quality may need to be reduced when
recording multiple channels to internal storage.

© 2018 Advanced Micro Peripherals


Document version A.17 28
3: User Configuration StreamCorder-SD4 User Manual

Recording
This is used to set the duration and format of the video clips.

Field Description
Recording This may be either AVI or transport stream.
format Note that only the transport stream format supports metadata
generated by the sensors and GPS (options). However, it
cannot be used for MJPEG encoding.

Duration This is the maximum clip length in minutes before the next
clip is started when continuously recording.

© 2018 Advanced Micro Peripherals


Document version A.17 29
3: User Configuration StreamCorder-SD4 User Manual

Video Clips
This page provides a means of accessing the files recorded by the Streamcorder-
SD4.

To download a file, simply click on the link. These are organized according to the
date and time at which the recording was started.
Note that only complete video clips are shown here; if the StreamCorder-SD4 is
currently recording a file, that file will not appear on this list until the recording
has terminated.

© 2018 Advanced Micro Peripherals


Document version A.17 30
3: User Configuration StreamCorder-SD4 User Manual

Serial Interface
The StreamCorder has a simple serial control interface that runs over the RS-485
port. The serial interface is configured for 38400bps, 8N1. The interface consists
of simple command and response messages.
Commands are terminated with a carriage return <CR> character.

Start Recording
Start saving files for the specified channel
Command
$RECORD,<channel>

Where <channel> selects the channel:-


-1 for all,
0,1,2,3 for individual channels.
Response
+OK if successful

+FAIL if unsuccessful
Example
Start all channels recording:
$RECORD,-1
Start channel 1 recording:
$RECORD,0

© 2018 Advanced Micro Peripherals


Document version A.17 31
3: User Configuration StreamCorder-SD4 User Manual

Stop Recording
Stop saving files for the specified channel.
Command
$STOP,<channel>

Where <channel> selects the channel,

-1 for all,
0,1,2,3 for individual channels.
Response
+OK if successful

+FAIL if unsuccessful

Example
Stop all channels recording:
$STOP,-1

Erase Files
Erase the files for the specified channel.
Command
$ERASE,<channel>

Where <channel> selects the channel,

-1 for all,
0,1,2,3 for individual channels.
Response
+OK if successful

+FAIL if unsuccessful
Example
Erase all clips for all channels:
$ERASE,-1

© 2018 Advanced Micro Peripherals


Document version A.17 32
3: User Configuration StreamCorder-SD4 User Manual

Configure Quality
Change the bitrate for the specified channel.
Command
$QUALITY,<channel>,<quality>

Where <channel> selects the channel

0,1,2,3 for individual channels.


<quality> specifies the new quality factor (0-51)

Response
+OK if successful

+FAIL if unsuccessful
Example
Set quality for channel 0 to 20
$QUALITY,0,20
With response:
+OK

© 2018 Advanced Micro Peripherals


Document version A.17 33
3: User Configuration StreamCorder-SD4 User Manual

Retrieve Quality
Get the bitrate for the specified channel.
Command
$GETQUALITY,<channel>

Where <channel> selects the channel

0,1,2,3 for individual channels.


Response
+OK if successful

+FAIL if unsuccessful
Example
Get quality for channel 0
$GETQUALITY,0
With response:
+OK,20

© 2018 Advanced Micro Peripherals


Document version A.17 34
3: User Configuration StreamCorder-SD4 User Manual

Configure Encoding Mode


Change the bitrate for the specified channel.
Command
$ENCODINGMODE,<channel>,<mode>

Where <channel> selects the channel

0,1,2,3 for individual channels.


<mode> specifies one of VQCB, CQCB, CVBR, VQCBSTRICT

Response
+OK if successful

+FAIL if unsuccessful
Example
Set quality for channel 0 to CVBR
$ENCODINGMODE,0,CVBR
With response:
+OK

© 2018 Advanced Micro Peripherals


Document version A.17 35
3: User Configuration StreamCorder-SD4 User Manual

Retrieve Encoding Mode


Get the bitrate for the specified channel.
Command
$ENCODINGMODE,<channel>

Where <channel> selects the channel

0,1,2,3 for individual channels.


Response
+OK if successful

+FAIL if unsuccessful
Example
Get quality for channel 0
$GETENCODINGMODE,0
With response:
+OK,CVBR

© 2018 Advanced Micro Peripherals


Document version A.17 36
3: User Configuration StreamCorder-SD4 User Manual

Configure Framerate
Change the framerate for the specified channel.
Command
$FRAMERATE,<channel>,<rate>

Where <channel> selects the channel,

0,1,2,3 for individual channels.


<rate> specifies the new framerate in frames per second

Response
+OK if successful

+FAIL if unsuccessful
Example
Set framerate for channel 0 to 15 frames per second
$FRAMERATE,0,15
With response:
+OK

© 2018 Advanced Micro Peripherals


Document version A.17 37
3: User Configuration StreamCorder-SD4 User Manual

Retrieve Framerate
Get the framerate for the specified channel.
Command
$GETFRAMERATE,<channel>

Where <channel> selects the channel

0,1,2,3 for individual channels.


Response
+OK if successful

+FAIL if unsuccessful
Example
Get framerate for channel 0
$GETFRAMERATE,0
With response:
+OK,15

© 2018 Advanced Micro Peripherals


Document version A.17 38
3: User Configuration StreamCorder-SD4 User Manual

Configure network settings


Change the network settings for the specified adapter
Command
$NETWORK,<adapter>,<mode>,<ipaddr>,<subnet>,<gateway>

Where <adapter> selects the adapter number. This is 0 for the on-board
Ethernet.
<mode> specifies the network mode,
STATIC for static IP
DHCP for dhcp assigned
<ipaddr> specifies the IP address for static mode in dotted string format. Not
required for DHCP
<subnet> specifies the subnet mask for static mode in dotted string format. Not
required for DHCP
<gateway> specifies the gateway address for static mode in dotted string
format. Not required for DHCP
Response
+OK if successful

+FAIL if unsuccessful
Example
Set network to DHCP
$NETWORK,0,DHCP

With response:
+OK

Set network to static IP with address 192.168.1.123, subnet 255.255.255.0 and


gateway 192.168.1.1
$NETWORK,0,STATIC,192.168.1.123,255.255.255.0,192.168.1.1
With response:
+OK

© 2018 Advanced Micro Peripherals


Document version A.17 39
3: User Configuration StreamCorder-SD4 User Manual

Retrieve network settings


Get the network settings for the specified adapter.
Command
$GETNETWORK,<adapter>

Where <adapter> selects the adapter. This is 0 for the on-board Ethernet.

Response
+OK,<mode>,<ipaddr>,<subnet>,<gateway> if successful

Where:

Field Description
<mode> STATIC for static IP
DHCP for dhcp assigned

<ipaddr> Current IP address in dotted string format.


<subnet> Current subnet address in dotted string format.
<gateway> Current gateway address in dotted string format.

+FAIL if unsuccessful
Example
Get network settings
$GETNETWORK,0
With response:
+OK, STATIC,192.168.1.123,255.255.255.0,192.168.1.1

© 2018 Advanced Micro Peripherals


Document version A.17 40
3: User Configuration StreamCorder-SD4 User Manual

Get System Status


Returns the status of the StreamCorder and its channels
Command
$SYSSTATUS

Response
+SYSSTATUS,<systemstatus>,<numchannels>,<channelstatus0>,<ch
annelstatus1>,<channelstatus2>,<channelstatus3>

Where:

Field Description
<systemstatus> The overall system status. Can be one of the following values.
ready – system is ready for use and accepting commands
busy – system is currently unable to accept commands
<numchannels> The number of channels supported on the StreamCorder.
This will be 4 for the StreamCorder-SD4, and 1 for the
StreamCorder-HD.
<channelstatus> The status of each individual channel. There is a
<channelstatus> field for each of the number of channels
indicated in <numchannels>. The status can be one of the
following:
0 – not recording
recording – channel is currently recording

Example
Only the first channel of the StreamCorder-SD4 is currently recording.
$SYSSTATUS
+SYSSTATUS,ready,4,recording,0,0,0
Comments
The system status message is also sent unsolicited once per minute to serve as a
general heartbeat that the system is alive. The format in this case is:
*SYSSTATUS,<systemstatus>,<numchannels>,<channelstatus0>,<ch
annelstatus1>,<channelstatus2>,<channelstatus3>

© 2018 Advanced Micro Peripherals


Document version A.17 41
3: User Configuration StreamCorder-SD4 User Manual

Count files
Returns the number of files associated with a particular channel
Command
$COUNTFILES,<channel>

Response
+OK,<number of files>

+FAIL if unsuccessful

Example
Channel 1 has 3 files associated with it
$COUNTFILES,1
+OK,3

Query file
Returns the name of the specified index of a particular channel
Command
$QUERYFILE,<channel>,<file index>
Response
+OK,<filename> if successful

+FAIL if unsuccessful
Example
Read name of file 0 on channel 0
$QUERYFILE,0,0
With response:
+OK,videoclips_s/video0-20170504-135256.avi
Comment

© 2018 Advanced Micro Peripherals


Document version A.17 42
3: User Configuration StreamCorder-SD4 User Manual

Get Input Status


Returns the status of the StreamCorder inputs
Command
$INPUTSTATUS,<channel>

Where <channel> selects the channel

0,1,2,3 for individual channels.


Response
+INPUTSTATUS,<channel>,<status>,<value>
Where:

Field Description
<count> Number of channels (normally 1)

<channel> Selected channel


<status> 0 for error
1 for active
<value> If active, gives input resolution

Value Standard

720x480 NTSC

720x576 PAL

If error, gives flags in a semi colon-separated list

Flag Meaning

hlock Horizontal sync is not locked

slock Sub-carrier is not locked

vlock Vertical sync is not locked

loss Video is not present

Example
First channel is connected to a PAL source.
$INPUTSTATUS,0

© 2018 Advanced Micro Peripherals


Document version A.17 43
3: User Configuration StreamCorder-SD4 User Manual

+INPUTSTATUS,1,0,1,720x576
Second channel is not connected.
$INPUTSTATUS,1
+INPUTSTATUS,1,1,0,hlock;vlock;slock;loss

Comments
The input status message is also sent unsolicited once per minute if an error is
detected on one or more of the inputs. The format in this case is:
*INPUTSTATUS,<numchannels>,0,<status0>,<value0>,1,<status1>,
<value1>,2,<status2>,<value2>,3,<status3>,<value3>
eg. for PAL on the first three channels and no input on the last:
*INPUTSTATUS,4,0,1,720x576,1,1,720x576,2,1,720x576,3,0,hlock
;vlock;slock;loss

© 2018 Advanced Micro Peripherals


Document version A.17 44
3: User Configuration StreamCorder-SD4 User Manual

RTSP Command Interface


The StreamCorder has a RTSP command interface for controlling the channel. For
further information on RTSP commands please see “Real Time Streaming Protocol
– RFC 2326” http://www.faqs.org/rfcs/rfc2326.html.
The RTSP URL is rtsp://<StreamCorder IP>/live1.sdp
Commands are available with authentication disabled or with user level
authentication unless otherwise indicated.
Commands requiring admin level authentication cannot be run with RTSP
authentication disabled.

SET_PARAMETER
The basic form of the SET_PARAMETER message sent by the client is as below:
SET_PARAMETER rtsp://<StreamCorderIP>/live1.sdp RTSP/1.0
CSeq: <sequence>
Content-length: <length>
Session: <session ID>

<param>: <value>

On a successful SET_PARAMETER the return status response value will be 200.


The StreamCorder supports the following parameters on SET_PARAMETER. Note
that the list of supported parameters can be got by issuing a GET_PARAMETER
with LISTCOMMANDS.

BITRATE
Sets the desired bitrate (in bps) for the stream.
<param> BITRATE
<value> 30000-20000000
e.g.
BITRATE: 2000000

© 2018 Advanced Micro Peripherals


Document version A.17 45
3: User Configuration StreamCorder-SD4 User Manual

QUALITY
Set the desired quality level.
<param> QUALITY
<value> 0-51
e.g.
QUALITY: 20

ENCODINGMODE (VQCB, CQCB, CVBR, VQCBSTRICT)


Set the encoding mode.
<param> ENCODINGMODE
<value> One of VQCB, CQCB, CVBR, VQCBSTRICT
e.g.
ENCODINGMODE: CQCB

RECORD
Enable recording of channel data to StreamCorder storage
<param> RECORD
<value> n/a
e.g.
RECORD:

STOPRECORD
Disable recording
<param> STOPRECORD
<value> n/a
e.g.
STOPRECORD:

© 2018 Advanced Micro Peripherals


Document version A.17 46
3: User Configuration StreamCorder-SD4 User Manual

FRAMERATE
Set the frame rate of the channel.
Note: This must not exceed the frame rate of the input signal.
<param> FRAMERATE
<value> 1 - 60
e.g.
FRAMERATE: 30

KEYINTERVAL
Set the key frame interval. There will be a key frame every n frames.
<param> KEYINTERVAL
<value> 1 – 300
e.g.
KEYINTERVAL: 60

STREAMUNICAST
Enable unicast streaming. This will disable multicast streaming.
<param> STREAMUNICAST
<value> 1 to enable
e.g.
STREAMUNICAST: 1

STREAMMULTICAST
Enable multicast streaming. This will disable unicast streaming.
<param> STREAMMULTICAST
<value> 0 to disable, 1 to enable
e.g.
STREAMMULTICAST: 1

© 2018 Advanced Micro Peripherals


Document version A.17 47
3: User Configuration StreamCorder-SD4 User Manual

STREAMUNICASTTS
Enable unicast transport stream. This will disable multicast streaming.
<param> STREAMUNICASTTS
<value> 0 to disable, 1 to enable
e.g.
STREAMUNICASTTS: 1

SYSTEM
Run system command (requires admin level authentication)
<param> SYSTEM
<palue> One of RESET, REBOOT
RESET will perform a factory reset of the StreamCorder
REBOOT will reboot the StreamCorder
e.g.
SYSTEM: REBOOT

© 2018 Advanced Micro Peripherals


Document version A.17 48
3: User Configuration StreamCorder-SD4 User Manual

GET_PARAMETER
The basic form of the GET_PARAMETER message sent by the client is as below:
GET_PARAMETER rtsp://<StreamCorderIP>/live1.sdp RTSP/1.0
CSeq: <sequence>
Content-length: <length>
Session: <session ID>

<param>

On a successful GET_PARAMETER the return status response value will be 200


and the response body will contain the actual response.
The StreamCorder supports the following parameters on GET_PARAMETER.

LISTCOMMANDS
Return a list of COMMAND supported by the StreamCorder.
<param> LISTCOMMANDS
Example response:
LISTCOMMANDS:BITRATE,QUALITY,ENCODINGMODE,RECORD,STOPRECORD,
FRAMERATE,BITRATERANGE,KEYINTERVAL,QUALITYRANGE,ENCODINGMODE
VALUES,FRAMERATERANGE

BITRATE
Returns the current bitrate setting
<param> BITRATE
Example Response:
BITRATE: 8000000

QUALITY
Returns the current quality setting
<param> QUALITY
Example Response:
QUALITY: 30

© 2018 Advanced Micro Peripherals


Document version A.17 49
3: User Configuration StreamCorder-SD4 User Manual

ENCODINGMODE
Returns the current encoding mode
<param> ENCODINGMODE
Example Response:
ENCODINGMODE: CVBR

KEYINTERVAL
Returns the current keyframe interval
<param> KEYINTERVAL
Example Response:
KEYINTERVAL: 30

RECORD
Returns the current recording state.
<param> RECORD
The response will be of the form:
RECORD: n
Where n=0 means not recording and n=1 means recording.

BITRATERANGE
Returns the acceptable bitrate range.
<param> BITRATERANGE
Example Response:
BITRATERANGE: 30000-20000000

QUALITYRANGE
Returns the acceptable quality range.
<param> QUALITYRANGE
Example response:
QUALITYRANGE: 0-51

© 2018 Advanced Micro Peripherals


Document version A.17 50
3: User Configuration StreamCorder-SD4 User Manual

ENCODINGMODEVALUES
Returns the acceptable encoding mode values.
<param> ENCODINGMODEVALUES
Example Response:
ENCODINGMODEVALUES: VQCB,CQCB,VQCBSTRICT,CVBR

FRAMERATERANGE
Returns the acceptable framerate value range
<param> FRAMERATERANGE
Example response:
FRAMERATERANGE: 1-60

STREAMUNICAST
Returns whether a unicast stream is available
<param> STREAMUNICAST
Example response:
STREAMUNICAST: 1

STREAMMULTICAST
Returns whether a multicast stream is available
<param> STREAMMULTICAST
Example response:
STREAMMULTICAST: 1

STREAMUNICASTTS
Returns whether a unicast transport stream is available
<param> STREAMUNICASTTS
Example response:
STREAMUNICASTTS: 1

© 2018 Advanced Micro Peripherals


Document version A.17 51
A: Contacting AMP StreamCorder-SD4 User Manual

A:
Contacting AMP

Sales
AMP’s sales team is always available to assist you in choosing the board that best
meets your requirements. Contact your local sales office or hotline.

Sales office US Sales office UK


Advanced Micro Peripherals Inc. Advanced Micro Peripherals Ltd.
Suite 808 1 Harrier House, Sedgeway Business Park
100 Church Street Witchford, Cambridge,
New York, NY CB6 2HY
USA 10007 United Kingdom

Tel: +1 212 951 7205 Tel: 01353 659500


Fax: +1 212 658 9073 Fax: 01353 659600
E-mail: sales@amp-usa.com E-mail: sales@ampltd.com
Web: www.amp-usa.com Web: www.ampltd.com

Technical support
Comprehensive technical information is available on our websites (see above).
If you can’t find the information or solution you require, AMP has a team of
technical support engineers / embedded video experts available to provide a
quick and free response to your technical queries.
Please submit your technical support query to the appropriate email address:

Technical support US Technical support UK


E-mail: support@amp-usa.com E-mail: support@ampltd.com

© 2018 Advanced Micro Peripherals


Document version A.17 52

You might also like