URL command for DCS-5220, DCS

URL command for DCS-5220, DCS
URL command for DCS-5220,
DCS-2120
Version 1.0B
2007/6/6
www.D-Link.com
URL commands of the Network Camera
For some customers who already have their own web site or web control application, the
Network Camera can be easily integrated through convenient URLs. This section lists
the commands in URL format corresponding to the basic functions of the erase Network
Camera.
Get server parameter values
Note: This request require administrator access
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/admin/getparam.cgi?[<parameter>]
[&<parameter>…]
where the <parameter> should be <group>[_<name>] or <group>[.<name>] If you
do not specify the any parameters, all the parameters on the server will be returned. If
you specify only <group>, the parameters of related group will be returned.
When query parameter values, the current parameter value are returned.
Successful control requests returns parameter pairs as follows.
Return:
HTTP/1.0 200 OK\r\n
Content-Type: text/html\r\n
Context-Length: <length>\r\n
\r\n
<parameter pair>
where <parameter pair> is
<parameter>=<value>\r\n
[<parameter pair>]
<length> is the actual length of content.
Example: request IP address and it’s response
Request:
http://192.168.0.123/cgi-bin/admin/getparam.cgi?network_ipaddress
Response:
HTTP/1.0 200 OK\r\n
Content-Type: text/html\r\n
Context-Length: 33\r\n
\r\n
network.ipaddress=192.168.0.123\r\n
Set server parameter values
Note: This request require administrator access
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/admin/setparam.cgi?
[nosync=<value>&]<parameter>=<value>
[&<parameter>=<value>…][&return=<return page>]
parameter
value
description
<group>_<name>. value to assigned Assign <value> to the parameter
<group>_<name>..
return
<return page>
Redirect to the page <return page> after the
parameter is assigned. The <return page> can be a
full URL path or relative path according the the current
path. If you omit this parameter, it will redirect to an
empty page.
(note: The return page can be a general HTML
file(.htm, .html) or a D-Link server script executable
(.vspx) file. It can not be a CGI command. It can not
have any extra parameters. This parameter must be
put at end of parameter list)
Return:
HTTP/1.0 200 OK\r\n
Content-Type: text/html\r\n
Context-Length: <length>\r\n
\r\n
<parameter pair>
where <parameter pair> is
<parameter>=<value>\r\n
[<parameter pair>]
Only the parameters that you set and readable will be returned.
Example: Set the IP address of server to 192.168.0.123
Request:
http://myserver/cgi-bin/admin/setparam.cgi?Network_IPAddress=192.168.0.123
Response:
HTTP/1.0 200 OK\r\n
Content-Type: text/html\r\n
Context-Length: 33\r\n
\r\n
network.ipaddress=192.168.0.123\r\n
Available parameters on the server
NOTE: The bold characters in table are the default value of each parameter.
Group: System
NAME
VALUE
DESCRIPTION
hostname
<text string shorter
host name of server
(r/w)
than 40 characters>
<<Wireless>Network Camera >
ledoff
0
Do not turn off the led indicator
(r/w)
1
Turn off the led indicator
date
<yyyy/mm/dd>
year, month and date separated by slash.
(r/w)
<keep>
keep date unchanged
<auto>
Using NTP to sync date/time automatically
time
<hh:mm:ss>
hour, minute and second separated by colon.
(r/w)
<keep>
keep date unchanged
<auto>
Using NTP to sync date/time automatically
ntp
<domain name or IP
NTP server
(r/w)
address>
<skip to invoke default server>
timezone
-12 ~ 12
time zone, 8 means GMT +8:00
(r/w)
<8>
updateinterval
0 ~ 2592000
0 to Disable automatic time adjustment,
(r/w)
otherwise, it means the seconds between
NTP automatic update interval.
<0>
serialnumber
<mac address>
12 characters mac address without hyphen
(r)
connected
firmwareversion
<text string shorter
The version of firmware, including model,
(r)
than 39 characters>
company, and version number
restore
0
Restore the system parameters to default
(w)
value.
Positive integer
Restore the system parameters to default
value and restart the server after <value>
seconds.
reset
0 ~ 65535
Restart the server after <value> seconds.
-1
Not restart the server.
viewmode
0
Using the profile of viewing by computer
(r/w)
1
Using the profile of viewing by mobile phone
dinormalstatus
0
Define DI normal status as “Low”
(r/w)
1
Define DI normal status as “High”
dinormalstatus
0
Define DO normal status as “Grounded”
(r/w)
1
Define DO normal status as “Open”
resetdo
0
Disable the function of resetting DO
(r/w)
1
Enable the function of resetting DO
resetdo
Positive integer
Reset DO to normal status after <value>
(w)
(r/w)
di<1~4>
seconds.
L
Normal status
H
Triggering status
L
Normal status
H
Triggering status
(r)
do<1~4>
(r)
Group: Security
NAME
VALUE
DESCRIPTION
username_<1~20 <text string shorter change user name.
>
than 16 characters> <blank>
(r/w)
userpass_<0~20> <text string shorter change user’s password.
than 14 characters> The UserPass_0 is root’s password.
(r/w)
<blank>
userattr_<1~20> [conf]
show user’s privilege. The privilege can be
(r)
<blank> - only permit to view live media
conf – Permit to change server’s configuration
<blank>
usercount
1 ~ 21
(r)
The current account number on the server
including root.<1>
Group: Network
NAME
VALUE
DESCRIPTION
type
0
LAN
(r/w)
1
PPPoE
pppoeuser
<text string shorter than PPPoE account user name
(r/w)
80 characters>
pppoepass
<text string shorter than PPPoE account password
(r/w)
15 characters>
<blank>
resetip
1
enable to get ipaddress, subnet, router, dns1,
(r/w)(restart)
<blank>
dns2 from DHCP server at next reboot
0
Using preset ipaddress, subnet, router, dns1,
dns2
ipaddress
<IP address>
(r/w) (restart)
subnet
<192.168.0.99>
<IP address>
(r/w) (restart)
router
<IP address>
default gateway
<blank>
<IP address>
(r/w) (restart)
dns2
subnet mask
<255.255.255.0>
(r/w) (restart)
dns1
IP address of server
primary DNS server
<blank>
<IP address>
(r/w) (restart)
secondary DNS server
<blank>
smtp1
<domain name or IP
primary SMTP server
(r/w)
address, string shorter
<blank>
than 40 characters>
mailto1
<string shorter than 80 mail recipient address
(r/w)
characters>
mailuser1
<text string shorter than User name of primary smtp server
(r/w)
63 characters>
mailpass1
<text string shorter than Password of primary smtp server
(r/w)
15 characters>
<blank>
smtp2
<domain name or IP
secondary SMTP server
(r/w)
address, string shorter
<blank>
<blank>
<blank>
than 40 characters>
mailto2
<text string shorter than mail recipient address
(r/w)
80 characters>
mailuser2
<text string shorter than User name of secondary smtp server
(r/w)
63 characters>
mailpass2
<text string shorter than Password of secondary smtp server
(r/w)
15 characters>
returnemail
<text string shorter than return email address
(r/w)
80 characters>
<blank>
localftpport
<positive number less
FTP port
(r/w)
than 65535>
<21>
ftp1
<domain name or IP
primary FTP server
(r/w)
address, string shorter
<blank>
<blank>
<blank>
<blank>
than 40 characters >
ftpport1
<positive number less
primary FTP port
(r/w)
than 65535>
<21>
ftpuser1
<text string shorter than user name for primary FTP server
(r/w)
63 characters>
ftppass1
<text string shorter than password for primary FTP server
(r/w)
15 characters>
ftpfolder1
<text string shorter than upload folder in primary FTP server
(r/w)
40 characters>
<blank>
<blank>
<blank>
ftppasvmode1 1
Enable passive mode of primary FTP server
(r/w)
0
Disable passive mode of primary FTP server
ftp2
<domain name or IP
secondary FTP server
(r/w)
address, string shorter
than 40 characters >
ftpport2
<positive number less
secondary FTP port
(r/w)
than 65535>
<21>
ftpuser2
<text string shorter than user name for secondary FTP server
(r/w)
63 characters>
<blank>
ftppass2
<text string shorter than password for secondary FTP server
(r/w)
15 characters>
ftpfolder2
<text string shorter than upload folder in secondary FTP server
(r/w)
40 characters>
<blank>
<blank>
ftppasvmode2 1
Enable passive mode of primary FTP server
(r/w)
0
Disable passive mode of primary FTP server
httpport
<positive number less
HTTP port
(r/w) (restart) than 65535>
<80>
rtspport
RTSP port
<positive number less
(r/w) (restart) than 65535>
<554>
videoport
<positive number less
video Channel port for RTP
(r)
than 65535>
<5558>
audioport
<positive number less
audio Channel port for RTP
(r)
than 65535>
<5556>
accessname
<text string shorter than RTSP access name
(r/w)
20 characters>
<live.sdp>
Group: Wireless (restart)
ssid
<text string shorter than SSID for wireless lan settings
(r/w)
32 characters>
<default>
wlmode
0
Infrastructure mode
(r/w)
1
Adhoc mode
txrate
"NONE", "1M", "2M",
Transmit rate in Mbps
(r/w)
"5.5M", "11M", "22M"
<Auto>
for 802.11b+
"NONE", "1M", "2M",
"5.5M", "11M", "6M",
"9M", "12M", "18M",
"24M", "36M", "48M",
"54M", "Auto" for
802.11g
encrypt
0
None data encryption
(r/w)
1
WEP data encryption
2
WPA-PSK data encryption
authmode
Open
Open mode
(r/w)
Shared
Shared mode
keylength
(64, 128) for 802.11g
(r/w)
Key length in bits
<64>
keyformat
HEX
Key1 ~ Key4 will be represented in HEX format
(r/w)
ASCII
Key1 ~ Key4 will be represented in ASCII format
keyselect
1~4
Default key number
(r/w)
<1>
key1
<text string shorter than WEP key1 for encryption
(r/w)
58 characters> (depends <0000000000>
on keyformat &
keylength)
key2
<text string shorter than WEP key2 for encryption
(r/w)
58 characters> (depends <0000000000>
on keyformat &
keylength)
key3
<text string shorter than WEP key3 for encryption
(r/w)
58 characters> (depends <0000000000>
on keyformat &
keylength)
key4
<text string shorter than WEP key4 for encryption
(r/w)
58 characters> (depends <0000000000>
on keyformat &
keylength)
algorithm
TKIP
TKIP data encryption algorithm for WPA-PSK
(r/w)
AES
AES data encryption algorithm for WPA-PSK
presharedkey <text string shorter than WPA-PSK key for encryption
(r/w)
58 characters>
<00000000>
Group: IPFilter
NAME
VALUE
DESCRIPTION
allowstart_<0~9> 1.0.0.0 ~
Allowed starting RTSP connection IP address
(r/w)
<1.0.0.0>
255.255.255.255
allowend_<0~9> 1.0.0.0 ~
Allowed ending RTSP connection IP address
(r/w)
<255.255.255.255>
255.255.255.255
denystart_<0~9> 1.0.0.0 ~
Denied starting RTSP connection IP address
(r/w)
<blank>
255.255.255.255
denyend_<0~9> 1.0.0.0 ~
Denied ending RTSP connection IP address
(r/w)
<blank>
255.255.255.255
Group: Video
NAME
VALUE
DESCRIPTION
text
<text string shorter
enclosed caption
(r/w)
than 14 characters>
<blank>
codectype
0
MPEG4
(r/w)
1
MJPEG
keyinterval
1, 3, 5, 10, 30, 60, 90, Key frame interval
(r/w)
120
<60>
size
1
half
(r)
2
half x 2
3
normal
4
normal x 2
5
double
256
This field is obsolete (use resolution)
resolution
176x144 (for mobile)
Video resolution 176 x 144
(r/w)
160x120
Video resolution 160 x 120
320x240
Video resolution 320 x 240
640x480 (for computer) Video resolution 640 x 480
color
0
monochrome
(r/w)
1
color
quality
0
fix bit rate
(r/w)
1
fix quantization
quant
1
lowest quality of video
(r/w)
2
lower quality of video
3
normal quality of video
4
higher quality of video
5
highest quality of video
bitrate
20000
set bit rate to 20K bps
(r/w)
30000
set bit rate to 30K bps
40000
set bit rate to 40K bps
50000
set bit rate to 50K bps
64000
set bit rate to 64K bps
128000
set bit rate to 128K bps
256000
set bit rate to 256K bps
512000
set bit rate to 512K bps
768000
set bit rate to 768K bps
1000000
set bit rate to 1000K bps
1500000
set bit rate to 1500K bps
2000000
set bit rate to 2000K bps
3000000
set bit rate to 3000K bps
4000000
set bit rate to 4000K bps
maxframe
1
set maximum frame rate to 1 fps
(r/w)
2
set maximum frame rate to 2 fps
3
set maximum frame rate to 3 fps
5
set maximum frame rate to 5 fps
10
set maximum frame rate to 10 fps
15
set maximum frame rate to 15 fps
20
set maximum frame rate to 20 fps
25
set maximum frame rate to 25 fps
30 (for 60Hz only)
set maximum frame rate to 30 fps
mode
50
synchronize with 50Hz utility
(r/w) (in CMOS
60
synchronize with 60Hz utility
whitebalance
0
auto white balance
(r/w) (in CMOS
1
fixed indoor(3200K)
version only)
2
fixed fluorescent (5500K)
3
fixed outdoor( > 5500K)
flip
1
flip image
(r/w)
0
normal image
mirror
1
mirror image
(r/w)
0
normal image
version only)
imprinttimestam 1
Overlay time stamp on video
p
Do not overlay time stamp on video
0
(r/w)
Group: Audio
NAME
VALUE
DESCRIPTION
type
AAC4 (for computer)
set codec to AAC
(r/w)
GAMR (for mobile)
set codec to GSM-AMR
aacbitrate
16000
set AAC bitrate to 32K bps
(r/w)
32000
set AAC bitrate to 32K bps
48000
set AAC bitrate to 32K bps
64000
set AAC bitrate to 32K bps
96000
set AAC bitrate to 32K bps
128000
set AAC bitrate to 32K bps
amrbitrate
4750
set AMR bitrate to 4.75K bps
(r/w)
5150
set AMR bitrate to 5.15K bps
5900
set AMR bitrate to 5.9K bps
6700
set AMR bitrate to 6.7K bps
7400
set AMR bitrate to 7.4K bps
7950
set AMR bitrate to 7.95K bps
10200
set AMR bitrate to 10.2K bps
12200
set AMR bitrate to 12.2K bps
source
0
Use line input
(r/w)
1
Use external microphone input
boostmic
0, 1
Enable microphone boost
0~31
Gain of input
0, 1
Enable audio mute
(r/w)
inputgain
(r/w)
mute
(r/w)
Group: Image
NAME
VALUE
DESCRIPTION
brightness
<-5 ~ 5>
Adjust brightness of image according to mode
(r/w)
saturation
settings. <0>
<-5 ~ 5>
settings. <0>
(r/w)
contrast
<-5 ~ 5>
(r/w)
hue
Adjust saturation of image according to mode
Adjust contrast of image according to mode
settings. <0>
<-5 ~ 5>
(r/w)
Adjust hue of image according to mode
settings. <0>
Group: Motion
NAME
VALUE
DESCRIPTION
enabled
0
disable motion detection
(r/w)
1
enable motion detection
winenabled_<0~2> 0
disable motion window #1
(r/w)
1
enable motion window #1
winname_<0~2>
<text string shorter
name of motion window #1
(r/w)
than 14 characters >
<blank>
winleft_<0~2>
0 ~ 320
(r/w)
Left coordinate of window position.
<0>
wintop_<0~2>
0 ~ 240
(r/w)
Top coordinate of window position.
<0>
winwidth_<0~2>
0 ~ 320
(r/w)
Width of motion detection window.
<0>
winheight_<0~2>
0 ~ 240
(r/w)
Height of motion detection window.
<0>
winobjsize_<0~2>
0 ~ 100
Percent of motion detection window
(r/w)
<0>
winsensitivity_<0~2 0 ~ 100
Sensitivity of motion detection window
>
<0>
(r/w)
update
1
Update the above motion detection settings
to take effect
(w)
Group: DDNS
NAME
VALUE
DESCRIPTION
enable
0, 1
Enable or disable the dynamic dns.
(r/w)
provider
<0>
1~6
(r/w)
dyndns.org (dynamic)
dyndns.org (custom)
tzo.com
dhs.org
safe100.net
dyn-interfree.it
<1>
hostname
Text string shorter than
Your dynamic hostname.
(r/w)
127 characters.
<blank>
usernameemail Text string shorter than 63 Your user or email to login ddns service
(r/w)
characters.
provider
<blank>
passwordkey
Text string shorter than 20 Your password or key to login ddns service
(r/w)
characters.
provider
<blank>
update
(w)
0, 1
Update the above ddns settings to take
effect
Group: UPNP
NAME
VALUE
DESCRIPTION
enable
0, 1
Enable or disable the UPNP presentation
(r/w)
service.
<1>
Group: UPNPfor
NAME
VALUE
DESCRIPTION
enable
0, 1
Enable or disable the UPNP port forwarding
(r/w)
service.
<0>
Group: App
NAME
VALUE
DESCRIPTION
scriptname
<text string shorter than File name of script
(r)
255 characters>
<script.vssx>
enablescript
0
Disable script
(r/w)
1
Enable script
Group: Syslog
NAME
VALUE
DESCRIPTION
enableremotelog
0
disable remote log
(r/w)
1
enable remote log
serverip
<IP address>
Log server IP address
<514>
Server port used for log
(r/w)
serverport
(r/w)
Group: CAMCTRL (For DCS-5220 series only)
NAME
VALUE
DESCRIPTION
panspeed
-5 ~ 5
Pan speed
(r/w)
tiltspeed
<0>
-5 ~ 5
(r/w)
zoomspeed
<0>
-5 ~ 5
(r/w)
autospeed
(r/w)
Tilt speed
Zoom speed
<0>
-5 ~ 5
Auto pan speed
<0>
dwelling
0 ~ 9999
(r/w)
Time to dwelling when patrol
<0>
presetname_<0~9> Text string shorter than The name of preset location
(r/w)
40 characters.
<blank>
presetpan_<0~9>
-1024 ~ 1024
The pan coordinates of preset location.
(r/w)
presettilt_<0~9>
<0>
-56 ~ 144
(r/w)
The tilt coordinates of preset location.
<0>
patrolname_<0~19> Text string shorter than The name of patrol location
(r/w)
40 characters.
<blank>
Application page CGI command
Note: This request requires administrator privilege.
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/admin/gen-eventd-conf.cgi?[ snapshot_enable=<value>]
[&weekday=<value>][&time_method=<value>][&begin_time=<value>]
[&end_time=<value>]
[&ss_prefix=<value>][&trigger_type=<value>]
[&md_prenum=<value>][&md_postnum=<value>][&md_delay=<value>]
[&sq_interval=<value>]
[&send_method=<value][&ftp_suffix=<value>]
Return:
HTTP/1.0 200 OK\r\n
Content-Type: text/plain\r\n
Content-Length: <length>\r\n
\r\n
<depends on method value>
If(method == get || method == set)
{
tue=<value>\r\n
wed=<value>\r\n
…
}
Else if(method == normal)
{
Application page contents
}
parameter
Value
snapshot_enable 0
description
Enable snapshot application
1
Disable snapshot application
weekday
0,1,2,3,4,5,6
The array indicate weekly schedule
time_method
always
24 hours full day
interval
Select begin time and end time
begin_time
hh:mm
Begin time of weekly schedule
end_time
hh:mm
End time of weekly schedule
ss_prefix
<text string
Snapshot file name prefix for both event and
shorter than 60
sequential operation
characters>
trigger_type
motion
Set trigger by motion detect
sequential
Snapshot sequentially
md_win
0,1,2
The array indicate which motion windows are used
md_prenum
1~5
The numbers of snapshot before event
md_postnum
1~5
The numbers of snapshot after event
md_delay
1~999
The delay seconds for detecting next motion event
sq_interval
1~999
The interval seconds of sequential snapshot
send_method
mail
Send snapshot by mail
ftp
Send snapshot by ftp
0/1
Enable/Disable file name prefix
ftp_suffix
Capture single snapshot
Note: This request require normal user privilege
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/video.jpg
Server will return the most up-to-date snapshot in JPEG format. The size and quality of
image will be set according to the video settings on the server.
Return:
HTTP/1.0 200 OK\r\n
Content-Type: image/jpeg\r\n
[Content-Length: <image size>\r\n]
<binary JPEG image data>
Account management
Note: This request requires administrator privilege
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/admin/editaccount.cgi?
method=<value>&username=<name>[&userpass=<value>][&privilege=<value>]
[&privilege=<value>][…][&return=<return page>]
parameter
value
Description
method
add
Add an account to server. When using this method,
“username” field is necessary. It will use default value
of other fields if not specified.
delete
Remove an account from server. When using this
method, “username” field is necessary, and others are
ignored.
edit
Modify the account password and privilege. When
using this method, “username” field is necessary, and
other fields are optional. If not specified, it will keep
original settings.
username
<name>
The name of user to add, delete or edit
userpass
<value>
The password of new user to add or that of old user to
modify. The default value is an empty string.
privilege
<value>
The privilege of user to add or to modify. The privilege
can be the addition of the following values. Ex: A user
with configure access can be assigned privilege as
privilege=conf.
return
conf
configuration privilege
<return page>
Redirect to the page <return page> after the
parameter is assigned. The <return page> can be a
full URL path or relative path according the the current
path. If you omit this parameter, it will redirect to an
empty page.
System logs
Note: This request require administrator privilege
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/admin/syslog.cgi
Server will return the up-to-date system log.
Return:
HTTP/1.0 200 OK\r\n
Content-Type: text/plain\r\n
Content-Length: <syslog length>\r\n
\r\n
<system log information>\r\n
Configuration file
Note: This request requires administrator privilege
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/admin/configfile.cgi
Server will return the up-to-date configuration file.
Return:
HTTP/1.0 200 OK\r\n
Content-Type: text/plain\r\n
Content-Length: <configuration file length>\r\n
\r\n
<configuration data>\r\n
Upgrade firmware
Note: This request requires administrator privilege
Method: POST
Syntax:
http://<servername>/cgi-bin/admin/upgrade.cgi
Post data:
fimage=<file name>[&return=<return page>]\r\n
\r\n
<multipart encoded form data>
Server will accept the upload file named <file name> to be upgraded the firmware and
return with <return page> if indicated.
Camera Control (For DCS-5220 series only)
Note: This request requires camera control access privilege
Method: GET/POST
Syntax:
http://<servername>/cgi-bin/camctrl.cgi? [move=<value>][&focus=<value>]
[&iris=<value>][&speedpan=<value>][&speedtilt=<value>][&speedzoom=<value>]
[&speedapp=<value>][&auto=<value>][&zoom=<value>][&return=<return page>]
parameter
value
description
move
home
Move to camera to home position
up
Move camera up
down
Move camera down
left
Move camera left
right
Move camera right
speedpan
-5 ~ 5
Set the pan speed
speedtilt
-5 ~ 5
Set the tilt speed
speedzoom
-5 ~ 5
Set the zoom speed
speedapp
-5 ~ 5
Set the auto pan/patrol speed
auto
pan
Auto pan
patrol
Auto patrol
stop
Stop camera
wide
To zoom for larger view with current speed
tele
To zoom for farer view with current speed
auto
To do auto focus
far
To focus on farer distance
stop
To focus on nearer distance
auto
Let the Network Camera control iris size
open
Manually control the iris for bigger size
stop
Manually control the iris for smaller size
<return page>
Redirect to the page <return page> after the
zoom
focus
iris
return
parameter is assigned. The <return page> can be
a full URL path or relative path according to the
current path. If you omit this parameter, it will
redirect to an empty page.
Recall (For DCS-5220 series only)
Note: This request requires camera control access privilege
Method: GET
Syntax:
http://<servername>/cgi-bin/recall.cgi?
recall=<value>[&return=<return page>]
parameter
value
description
recall
Text string less
One of the present positions to recall.
than 30 characters
return
<return page>
Redirect to the page <return page> after the
parameter is assigned. The <return page> can be
a full URL path or relative path according to the
current path. If you omit this parameter, it will
redirect to an empty page.
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Download PDF

advertisement