Академический Документы
Профессиональный Документы
Культура Документы
Orders
Document History .................................................................................................................. 5 1. Overview ............................................................................................................................. 6 1-1. Description for PNP2 (Probe Network Protocol second version) ............................... 6 1-2. Connection to the PNP2 device (Camera) ...................................................................... 7 1-3. Protocol Structure ........................................................................................................... 8 1-3-1. Term definition used in Protocol Message ................................................................. 8 1-3-2. Protocol Structures ...................................................................................................... 9 2-1. Connection Command .................................................................................................. 11 2-1-1. [CNS] .......................................................................................................................... 11 2-1-2. [LGN],[LGS],[LGW]..................................................................................................... 11 2-1-4. [STA] ........................................................................................................................... 12 2-2. Common Command ...................................................................................................... 13 2-2-1. [RSU] .......................................................................................................................... 13 2-2-2. [RUC] .......................................................................................................................... 13 2-2-3. [RSD] .......................................................................................................................... 13 2-2-4. [NVS] .......................................................................................................................... 15 2-2-5. [SDM, RSM] ................................................................................................................ 16 2-2-6. [RMT] .......................................................................................................................... 17 2-2-7. [PTZ], [SCF] ................................................................................................................ 18 2-2-8. [FSR] ........................................................................................................................... 28 2-2-9. [FSP] ........................................................................................................................... 29 2-2-10. [ AGN ] ...................................................................................................................... 30 2-3. Firmware Upload ........................................................................................................... 31 2-3-1 [FUP, FUR] ................................................................................................................... 31 2-3-2 [FUS] ............................................................................................................................ 32 2-4. Usage Reference ........................................................................................................... 35 2-4-1. Relay setting setup .................................................................................................... 35 2-4-2. Alarm Input Setting .................................................................................................... 35 3. Video Server Protocol ...................................................................................................... 35 3-1. Connection Command .................................................................................................. 36 3-1-1. [CNS] .......................................................................................................................... 36 3-1-2. [LGN] .......................................................................................................................... 36 3-1-3. [LGS], [LGW] .............................................................................................................. 37
nd
3-1-4. [STA] ......................................................................................................................................................................... 3-2. Transmitting Stream Data .............................................................................................................................. 4. Audio Receive Server Protocol (Audio from Microphone in Client) .................................... 4-1. Connection Command .................................................................................................................................... 4-1-1. [CNS] ...................................................................................................................................................................... 4-1-2. [LGN] ...................................................................................................................................................................... 4-1-3. [LGS], [LGW] ..................................................................................................................................................... 4-1-4. [STA] ....................................................................................................................................................................... 4-2. Transmitting Stream Data ............................................................................................................................. 5. Audio Transmit Server Protocol (Audio from MIC in PNP2/Camera) .................................. 5-1. Connection Command ................................................................................................................................... 5-1-1. [CNS] ..................................................................................................................................................................... 5-1-2. [LGN] ...................................................................................................................................................................... 5-1-3. [LGS], [LGW] .................................................................................................................................................... 5-2. Receiving Stream Data....................................................................................................................................
37 38 40 40 40 40 41 41 42 44 44 44 44 45 45
Document History
Date 2010-09-14 2010-10-09 2010-10-11 2010-10-16 2010-11-1 2010-11-18 2010-11-19 2010-11-23 -Initial Version -Updated with FPS ( Encoder Setup) Command - Updated with RSD Command Structure -Updated with FSR, FPS commands. -Updated the Resolution Byte of RSD command - Added the speed setting in PTZ direction key -Updated with FSP Parameter -Updated with FUP, FUR,FUS Parameter -Updated with LGS, LGW 2010-11-30 2011-01-13 2011-01-17 2011-01-31 2011-02-01 - Added with FUP Status ( 610~690 ) -Updated the figure in 2.3 Firmware Upload & Update 2 -Added the semi-auto in PTZ Focus Mode -Updated in the connection flow -Described the use of Motion Area Map -Resolution Value correction 2011-03-11 -Remove unused command
( RST, STM, SDC, SDS, RSS )
Note
Author
Lee Sang Min Kim Myeong
Revision
1.0.0
1.0.1 Seong Lee Sang Min Lee Sang Min Lee Sang Min Lee Sang Min Lee Sang Min Lee Sang Min 1.0.2 1.0.3 1.0.4 1.0.5
1.0.6 1.0.7
Lee Sang Min Lee Sang Min Lee Sang Min Lee Sang Min Lee Sang Min
1.1.4
-Update in Audio (Receive, Transmit) -Add the interval check time in STA -Add AGN Command -Update FSR. 2011-03-14 2011-04-25 2011-05-30 -Remove all unused command and setting -Add the additional function of PTZ -Add new Op code of PTZ (Advanced Zoom)
since firmware version 0.9.23_20110530 (PTI-H2100) since firmware version 0.9.67_20110530 (PMI-H2000/PMI-H2000s) Alex Oh Lee Jung Min Lee Jung Min
2011-07-05 2011-08-04
1.1.8 1.1.9
nd
1. Overview
1-1. Description for PNP2 (PRISMA Network Protocol second version)
1-1-1. PNP2 To receive the video and audio stream, the Viewer application needs to connect to the Edge device equipped with PNP2. PNP2 is 2nd generation of PRISMA-designed protocol and all IP-product in PRISMA follows this protocol specification. PNP2 In this manual, TCP/IP based streaming protocol will be explained even though there are more streaming protocol such as UDP, RTP and etc. Device Connection (TCP) Edge Device (PNP2)
Stream Data (TCP or UDP (Unicast/ Multicast))
*PNP2: Interoperability protocol newly defined by PRISMA camera(version of H.264) : Based-platform: TI DM365 *PNP1: Previous Interoperability protocol defined and used by PRISMACamera: Based-Platform: PENTA MICRO *Viewer Application: External Software or Application connected to P R I S M A camera. It can be CMS (Central Management Software) or VMS (Video Management Software) or NVR (Network Video Recording) SW.
Viewer Application
1-1-2. the sort of Product line Fundamentally, one PRISMA SDK can be applicable all the IP products but there are small difference in the group of products with different parameter setting. To make it be clear with clarification. Below we are listing the group of sort according to the models which should be checked during the integration. Group of Model Product Model
PMI-H2000 PMI-H2000s PTI-H2100
Description
High-definition PTZ
HD-1
SD-1 SD-2
*Note: this definition of Group of Model will be referred in following section to differentiated setting respectively.
A Windows application doesnt need to use the Web server among 5 servers. Accordingly, 4 servers (control, video, audio transmit and audio receive) are used in our SDK. A random number (authorization
number assigned by Servers) is obtained after connecting each server. This authorization number is used as key for further connections such as user
Control Server (Port) can be connected only if the connection request is succeed with LGS (=Authentication
nd
success). ? ? Video and Audio Server (Port) can be connected only if respond will be LGS (=Authentication success) Audio Receive Port(Microphone use from SW Client) case is same flow with Audio Transmit Port
? Connection status between servers in camera (PNP2) and Viewer (=External Application) can be checked by the STA message every 5sec.
? If detected any disconnection from any servers in Camera, it is highly recommended to disconnect all severs and restart the connection from the beginning to get the key.
Term
SC PS
Size(Byte)
5 4
Description
Packet Starting code (STRT) Size in byte (CTR+CMD +PARAM DATA) Determine: Stream and Control Data
Control Byte
CTR
Command Parameters
4 Var.
Var. 5
SC
PS
CTR
STREAM DATA
EC
SC
-
PS
CTR
CMD
PARAM DATA
EC
SC
PS
CTR
STREAM DATA
EC
When data transfer from Server to Client, a control byte (CTR) is added to determine
whether data is Stream or Control.
SC
PS
CTR
CMD
PARAM DATA
EC
SC
-
PS
CTR
CMD
PARAM DATA
EC
SC
PS
CTR
STREAM DATA
EC
SC -
PS
CTR
CMD
PARAM DATA
EC
SC
PS
CTR
STREAM DATA
EC
10
nd
SC ? Usage
PS
CTR
CMD
PARAM DATA
EC
2. In the case when PACKET SIZE includes CRT bit, then it represents the size from CTR-CMS-PARAM DATA, otherwise it does for the size of CMD-PARAM DATA only. ? Clarification Response in the Command/Message: Response can be initialized by Server (=PNP2) even there is no Request from external viewer. This case is when there is the first connection request from viewer during login process. Server sends the defined responding once login is authorized. This is reason why there is command/message which is defined with only Response from chapter 2 below. Notify in the Command/Message: Notify stands for the periodic update from Server (PNP2) even there is no certain request from viewer side. It can be kind of information like Time or connection status.
10
11
Request ( Client -> Server ) to connect to the server Response ( Server -> Client) for the Connection Request
STRT P.S CNS RANDOM CONST _END
CNS message is required before User Authentication Sample Code ( Unit : Byte )
S _
T E
R N
T D
0 0
2-1-2. [LGN],[LGS],[LGW]
Command Definition: User Authentication (Request)
Request
STRT P.S LGN RANDOM CONST USER ID + PW _END
11
12
nd
ID ( 20byte ) _ E N D 0
Password ( 20byte )
Response
STRT P.S LGS NULL _END
T
STRT
T
P.S
L
NULL
_
_END
LGW
Notify
Notify Response
2-1-4. [STA]
Command Definition: Connection status (check) message.
Request
Check message for the connection status ( every 5 seconds) Sample Code ( Unit : Byte )
Notify Response
STRT PS STA NULL _END
12
13
Request
Administrator(1), Guest(2)
S _
T E Notify
R N
T D
0 0
Param ( 1Byte )
2-2-2. [RUC]
Command Definition: Number of user connected now
Request
S _
T E Notify
R N
T D
0 0
Param ( 1Byte )
2-2-3. [RSD]
Command Definition : Stream Channel Setup
13
14
nd
Request
STRT P.S RSD PARAM _END
S _
T E
R N
T D
0 0
Channel(1Byte)
Response
STRT P.S RSD PARAM _END
S _
T E
R N
T D
0 0
Param ( 46Byte )
1 A MSB
1 B
2 C
1 D
1 E
1 F
1 G
1 H
1 I
1 J
1 K
16 L
18 M LSB
Para
A B C D Video type(2bit) Streaming Channel Video Type (0:NTSC, 1:PAL) CBR value
Description
Range
0~4 0/1
- Video Type ( 1:NTSC, 2:PAL ) -Resolution 8 9 10 11 12 13 14 15 16 17 1080p (1920 x 1080) 720P(1280X720) D1_PAL(720X576) D1_NTSC(720X480) HALF_D1_PAL(720X288) HALF_D1_NTSC(720X240) 4CIF_PAL(704X576) 4CIF_NTSC(704X480) HALF_4CIF_PAL(704X288) HALF_4CIF_NTSC(704X240) Resolution (8~24)
14
15
18 19 20 21 22 23 24 E F G Quality
VGA(640X480) CIF_PAL(352X288) CIF_NTSC(352X240) QVGA(320x240) QCIF_PAL(176X144) QCIF_NTSC(176X120) QQVGA(160X120) 1~10 0/1 0~4
Encode mode (0: CBR, 1: VBR) Compress mode (0: MJPEG (PNP1), 1: MPEG4 (PNP2) 2: MPEG4 (PNP2), 3: H264 (PNP2), 4: MJPEG (PNP2))
H I J K L M
Frame rate Camera Mount type (0 : normal, 1: flip ) PTZ direction (0: normal, 1: reverse) image control ( 0 : play, 1 : stop ) String Camera Name String Camera Mac Address
16chr 18chr
Notify
2-2-4. [NVS]
Command Definition: Server sends the notification whenever its status is changed.
Request
is not used in this command Notify .STRT P.S NVS PARAM _END
Motion Tracking & Detect Status & Video Format & Focus Mode & IRIS Mode & Flip On/Off Sample Code ( Unit : Byte )
S _
T E
R N
T D
0 0
Param ( 8Byte )
15
16
nd
Structure of Parameter ( Unit: byte ) 1 Focus Mode 1 IRIS Mode 1 Flip On/Off 2 Reserved 1 Video Format 1 Motion Tracking 1 Motion Detect
MSB
- Focus : 0(AUTO), 1(MANUAL, SEMIAUTO) - IRIS : 0(AUTO,SHUTTER,BRIGHT), 1(IRIS, MANUAL)
LSB
Notify Response
S _
T E
R N
T D
0 0
Param ( 2Byte )
Response
STRT P.S RSM P RAM _END
S _
T E
R N
T D
0 0
Param ( 2Byte )
OP CODE
0x40
Data
0 : Off, 1 : Detect On, 2 : Tracking On
Size Of Data
Motion Detect/Tracking On/Off(1)
0 ~ 255 0~7 1 ~ 63 1 ~ 127 1 ~ 255 1 ~ 255 0 : normal, 1 : skip 0 : none, 1 : Sensor out,
Detect area map(54) : PENTA Sensitivity(1) Pixel difference threshold(1) Different pixel count threshold(1) Motion MB count threshold(1) Motionless frame count threshold(1) Motionless record mode(1) Motion detect Action(1)
16
17
Parameter
Sensitivity Pixel Difference threshold Different Pixel Count threshold Motion MB Count threshold Motionless Frame Count threshold
Higher
1 8 4 1 5
High
2 12 12 1 5
Normal
3 16 20 2 5
Low
4 20 28 3 5
Lower
5 24 36 4 5
Notify
2-2-6. [RMT]
Command Definition: Video Setup information (Response)
Request
17
18
nd
S _
T E
R N
T D
0 0
Param ( 26Byte )
MSB
Structure of Parameter ( Unit: byte ) Para a b c Notify Horizon Width Vertical Height Reserved Description Range
Structure of Parameter is depending on OP code for PTZ, IO, Function Operation Pan/Tilt *Tilt Up *Tilt Down *Pan Left *Pan Right *Pan Right, Tilt Up *Pan Right, Tilt Down *Pan Left, Tilt Down *Pan Left, Tilt Up 20 21 22 23 33 34 35 36 Iris Open Iris Close Function *Preset Save 74 Focus Far Focus Near Focus Stop Iris 28 29 Code Operation Focus 26 27 47 Code Operation PTZ Position *Set Pan Position *Set Tilt Position *Set Zoom Position *Set PTZ Position Get Pan Position Get Tilt Position Get Zoom Position Get PTZ Position 125 126 127 37 100 101 128 130 Code
18
19
Pan/Tilt Stop *Set Pan/Tilt Speed Zoom Zoom In (Tele) Zoom Out (Wide) Zoom Stop
41 105
104 75 71 79 80
Alarm I/O *Set Output Get Input Status Get Output Status OSD Menu OSD Menu On/Off 108 106 102 103
24 25 45
Additional Function for HD-1 *Pattern Save *Scan Save *Group Save 70 67 82 *Pattern Delete *Scan Delete *Group Delete 72 68 83 Load All Pattern Load All Scan Load All Group Load All Preset *Set Zoom Advanced *Set PTZ Advanced 120 122 Get Zoom Advanced Get PTZ Advanced 121 123 73 69 84 76
* marked Operations in the table needs to refer the following Parameter definition Parameter Format: LSB(1Byte) + MSB(1Byte) Number of Alarm In/Out and Preset, Pattern, Scan, Group is depending on Edge device model.
HD-1 MAX_PRESET MAX_PATTERN MAX_SCAN MAX_GROUP ALARM INPUT ALARM OUTPUT 1024 128 128 128 2 1
SD-1 255 4 8 8 2 1
SD-2 255 4 8 8 8 4
in the case of PROBE model of HD-1, it can request the current setting(=saved) of Preset, Pattern,
Scan and Group using the Load Function(Op code 76, 73, 69, 84) and respective request can be responded from each Save Command.
Advanced Zoom Command (OP code 120, 121, 122, 123) works from firmware version v0.9.23_20110530(PTI-H2100), v0.9.67_20110530(PMI-H2000, PMI-H2000s).
OP Code
20
19
20
nd
Tilt Down Pan Left Pan Right Pan Right, Tilt Up Pan Right, Tilt
21 22 23 33 34
SPEED 1 ~ 1000
Down Pan Left, Tilt Down Pan Left, Tilt Up Set Pan/Tilt Speed Preset Save Preset Run Preset Delete 35 36 105 74 75 104
INDEX(2)
INDEX 1 ~ MAX_PRESET
(HD-1 Only)
SUB_POINTs
and
its
starting
point
will
be
SUB_POINT_1. The number of created SUB_POINT cannot exceed more than 55.
20
21
//pattern number,1 ~ MAX_PATTERN SUB_POINT_NUM //total number of created SUB_POINT_n in one pattern ( n ) SUB_POINT_n_PAN //PAN location of SUB_POINT_n, 0 ~ 36000 SUB_POINT_n_TILT //TILT location of SUB_POINT_n 0 ~ 9000 SUB_POINT_n_ZOOM //Zoom ratio of SUB_POINT_n, 1 ~ MAX ZOOM SUB_POINT_n_SPEED //Moving speed to SUB_POINT_n 3 : Very Slow 7 : Slow 11 : Middle 15 : Fast 300 : Skip SUB_POINT_n_DIR .//moving direction of SUB_POINT_n 0 : shortest path, 1 : clock-wise, 2 : anti-clockwise LABEL //name of Pattern created
71 72
INDEX(2)
INDEX 1 ~ MAX_PATTERN
Scan Save
67
79 68
INDEX(2)
INDEX 1 ~ MAX_SCAN
(HD-1 Only) One Group can be consisted with maximum 10 Sub Index.
INDEX(2)+SUB_1_ACTIOIN(1)+SUB_1_ACTION_IDX(2)+
Group Save 82
SUB_1_DWELL(2)+SUB_1_OPT(2)+SUB_2_ACTION(1)+ +SUB_20_OPT(2)+LABEL(10)
INDEX //Group number, 1 ~ MAX_GROUP SUB_n_ACTION ( n = 1 ~ 20 ) // Sub Index Action (Nth)
21
22
nd
//0 : None, 1 : Preset, 2 : Pattern, 3 : Scan SUB_n_ACTION_IDX ( n = 1 ~ 20 ) //Function Index of Sub Index(Nth),1 ~ MAX_FUNCTION SUB_n_DWELL ( n = 1 ~ 20 ) //Waiting time for Sub Index(Nth),3 sec ~ 240 sec SUB_n_OPT ( n = 1 ~ 20 ) //Sub Index Option(Nth), Moving speed or repeat count //if required Action is Preset, then this parameter stands for moving speed //if required Action is Pattern or Scan, then it stands for repeat count. 1 ~ 360 LABEL //Group Name
INDEX(2)
Group Run 80 INDEX 1 ~ MAX_GROUP
PAN_POS(2)
Set Pan Position 125 PAN_POS 0 ~ 36000
TILT_POS(2)
Set Tilt Posi ion 126 TILT_POS 0 ~ 9000, when model is PMI-H2000 0 ~ 18000
ZOOM_POS(2)
Set Zoom Position 127 ZOOM_POS 1 ~ MAX_ZOOM
PAN_POS(2)+TILT_POS(2)+ZOOM_POS(2)
PAN_POS 0 ~ 36000 TILT_POS 0 ~ 18000 0 ~ 9000, when model is PMI-H2000 ZOOM_POS 1 ~ MAX_ZOOM
37
INDEX(1)+ STATUS(1)
Set Output 106 INDEX (BitMask) 1 : Output-1, 2 : Output-2, 4 : Output-3, 8 : Output-4 STATUS 0 : off, 1 : On
(HD-1 Only)
Set Zoom 120 Advanced
ZOOM_POS(2)
ZOOM_POS 100 ~ MAX_ZOOM*100
122
22
23
PAN_POS 0 ~ 36000 TILT_POS 0 ~ 18000 0 ~ 9000, when model is PMI-H2000 ZOOM_POS 100 ~ MAX_ZOOM*100
OP Code MODE(1)
151
Parameters (bytes)
MODE 1:Auto, 2:Indoor, 3:Outdoor, 4:One-Push, 5:Manual
MODE(1)+VALUE(1)
R-Gain 153 MODE 2:Up, 3:Down, 4:Direct VALUE 0 ~ 255, when Mode is Direct.
MODE(1)+VALUE(1)
B-Gain 154 MODE 2:Up, 3:Down, 4:Direct VALUE 0 ~ 255, when Mode is Direct.
MODE(1)
AE Mode 157 MODE 1:Full Auto, 2:Manual, 3:Shutter Priority, 4:Iris Priority, 5:Bright, 6:Spotlight
MODE(1)+VALUE(1)
Shutter 160 MODE 2:Up, 3:Down, 4:Direct VALUE 1 ~ 21, when Mode is Direct.
23
24
nd
MODE(1)+VALUE(1)
Iris 161 MODE 2:Up, 3:Down, 4:Direct VALUE 0 ~ 17, when Mode is Direct.
MODE(1)+VALUE(1)
Gain 162 MODE 2:Up, 3:Down, 4:Direct VALUE 0 ~ 7, when Mode is Direct.
MODE(1)+VALUE(1)
Bright 163 MODE 2:Up, 3:Down, 4:Direct VALUE 0 ~ 23, when Mode is Direct.
MODE(1)
Day & Night Mode 170 MODE 1:Day, 2:Night, 3:Auto
MODE(1)
Focus Mode 172 MODE 1:Auto, 2:Manual, 3:Semi- Auto
MODE(1)
Backlight 155 MODE 1:On, 2:Off
MODE(1)
Digital Zoom 150 MODE 1:On, 2:Off
Response
STRT P.S SCF OP CODE PARAM _END
Parameters (bytes)
Preset Save
74
( HD-1 Only )
Preset Delete 104
INDEX(2)
INDEX 1 ~ MAX_PRESET
Pattern Save
70
( HD-1 Only) This is operation for HD-1 type of camera to the respond to
24
25
( HD-1 Only )
Patter Delete 72
INDEX(2)
INDEX //1 ~ MAX_PATTERN
( HD-1 Only ) Responding to Scan Save / Load All Scan INDEX(2)+1 _POS(2)+2 _POS_NUM(2)+SPEED(2)+ LABEL(10)
Scan Save 67 INDEX //1 ~ MAX_SCAN 1ST_POS //1st Preset Number ,1 ~ MAX_PRESET 2ND_POS //2nd Preset Number,1 ~ MAX_PRESET SPEED //Moving speed between 1st 2nd Preset 1 ~ 360 SCAN_LABEL
ST ND
25
26
nd
Scan Name
( HD-1 Only )
Scan Delete 68
INDEX(2)
INDEX 1 ~ MAX_SCAN
Group Save
82
( HD-1 Only )
Group Delete 83
INDEX(2)
// INDEX,1 ~ MAX_GROUP
PAN_POS(2)
Get Pan Position 100 PAN_POS 0 ~ 36000
TILT_POS(2)
Get Tilt Position 10 TILT_POS 0 ~ 18000
ZOOM_POS(2)
Get Zoom Position 128 ZOOM_POS 1 ~ MAX_ZOOM
PAN_POS(2)+TILT_POS(2)+ZOOM_POS(2)
Get PTZ Position 130 PAN_POS 0 ~ 36000 TILT_POS 0 ~ 18000 ZOOM_POS 1 ~ MAX_ZOOM
102
INPUT_NUM(2)
INPUT_NUM
26
27
1 : Input-1, 2 : Input-2, 4 : Input-3, 8 : Input-4 (Reference) 1. When Alarm Input generated, the command of Get Input Status will be delivered periodically, Once the alarm input will be off(event off), then no more command will be delivered 2. If both off Input one and Input two are generated at the same time, each and respective command will be delivered
OUTPUT_NUM(2)
Get Output Staus Get Zoom 121 Advanced 103 OUTPUT_NUM (BitMask) 1 : Output-1, 2 : Output-2, 4 : Output-3, 8 : Output-4
ZOOM_POS(2)
ZOOM_POS 100 ~ MAX_ZOOM*100
PAN_POS(2)+TILT_POS(2)+ZOOM_POS(2)
Get PTZ Advanced 123 PAN_POS 0 ~ 36000 TILT_POS 0 ~ 18000 ZOOM_POS 100 ~ MAX_ZOOM*100
OP Code
181 183 184 187
GAIN(1)
0 ~ 255 GAIN(1) 0 ~ 255
MODE(1)
1:Full Auto, 2:Manual, 3:Shutter Priority, 4:Iris Priority, 5:Bright, 6:Spotlight
Shutter Iris Gain Bright Day & Night Mode Focus Mode Backlight Digital Zoom
VALUE(1) 1 ~ 21
VALUE(1)
0 ~ 17 VALUE(1) 0~7
VALUE(1)
0 ~ 23 MODE(1) 1:Day, 2:Night. 3:Auto
MODE(1)
1:Auto, 2:Manual, 3:Semi-Auto MODE(1) 1:On, 2:Off
MODE(1)
27
28
nd
1:On, 2:Off
Notify
2-2-8. [FSR]
Command Definition: Encoder Setup
Request
STRT P.S FSR PARAM _END
S _
T E
R N
T D
0 0
Param ( 1Byte)
Response
STRT P.S FSR PARAM _END
S _
T E
R N
T D
0 0
Param ( 137Byte )
1 a
4 b
4 c
4 d
4 e
4 F
4 g
4 h
4 i
4 j
4 k
32 l
32 m
32 n
MSB
LSB
Para
a b Setup Channel Number
Description
Range
0~4 0~3
1~25 1~30
d e
30/25 0/1
28
29
f g h i j k l m n
Bit Rate(1~5Mbps) Quality(1:best ~ 5:worst) Resolution(0:1080i, 1:720p, 2:D1,4CIF, 3:CIF, 4:QCIF) Gop Interval(1~30, default:15) Priority(Not yet) Quantizer(Not yet) Video Name Codec Name Reserved
Notify
2-2-9. [FSP]
Command Definition: Encoder Setup
Request
STRT P.S FSP PARAM _END
S _
T E
R N
T D
0 0
Param ( 137Byte )
1 a
4 b
4 c
4 d
4 e
4 F
4 g
4 h
4 i
4 j
4 k
32 l
32 m
32 n
MSB Para
a b
LSB Description
Setup Channel Number Codec Type(0:None, 1:H264, 2:MPEG4, 3:MJPEG) ch1/ch2 ch3/ch4/ch5 : Fixed : Variable 1~25 1~30
Range
0~4 0~3
30/25
29
30
nd
e f g h
Bit Rate Mode(0:VBR, 1:CBR) Bit Rate(1~5Mbps) Quality(1:best ~ 5:worst) Resolution (0:1080i, 1:720p, 2:D1,4CIF, 3:CIF, 4:QCIF)
i j k l m n
Gop Interval(1~30, default:15) Priority(Not yet) Quantizer(Not yet) Video Name Codec Name Reserved
Response
STRT P.S FSP PARAM _END
S _
T E Notify
R N
T D
0 0
Param ( 5Byte )
2-2-10. [ AGN ]
Command Definition : Get Alarm I/O Number Command
Request
STRT P.S AGN PARAM _END
Response
STRT P.S AGN PARAM _END
30
31
Structure of Parameter ( Unit: byte ) 1 a MSB 1 b LSB Description Alarm In Number Alarm Out Number Range 0~255 0~255
Para a b
Notify
Request
STRT P.S FUP PARAM _END
S _
T E
R N
T D
0 0
Param ( 1400Byte )
4 a
4 b
4 c
2 d
2 e
4 f
size g LSB
Description
MSB
Para
Range
31
32
nd
a b c d e f G
File Type (Not yet). Total size CRC for the file to be upgraded Slice Number (starting from 0) Slice Size Slice CRC Slice Data At least same with 1400 (A+B+C+D+E+F) or less.
Response
STRT P.S FUR PARAM _END
S _
T E
R N
T D
0 0
Param ( 13Byte )
Para a
Range
b c Notify
2-3-2 [FUS]
Command Definition: Upload Status Command
Request
is not used in this command
32
33
Response
is not used in this command
Notify
STRT P.S FUS PARAM _END
S _
T E
R N
T D
0 0
Param ( 8Byte )
a MSB
Para A
b LSB
Description Result Code // Boot Status 110 ~ 190 110: complete. Upgrade Complete 120: error. Upgrade Error 130: ready. Upgrade Ready 140: progress. Upgrade in Progress 150: start. Verify & Loading. Range
// Kernel Status 210 ~ 290 210: complete. 220: error. 230: ready. 240: progress. 250: start.
33
34
nd
// Root2 Status 410 ~ 490 410: complete. 420: error. 430: ready. 440: progress. 450: start.
// Config Status 510 ~ 590 510: complete. 520: error. 530: ready. 540: progress. 550: start.
// Internal Analog(Micom) Status 710 ~790 710: complete. 720: error.(Upgrade Fail) 730: ready. 740: progress. 750: start. 760: Different File (detecting the incorrect file in updating) 770: Old(=previous) file is not exited after Upgrade fail. 780: Old((=Previsous) file is fall-backed successfully after Upgrade fail. 790: Fall-back failure after upgrade fail B Result Param Code [progress] -> percentage of progress
Notify Response
34
35
Client
Relay Event generated by Client manually to turn on/off of Relay. Relay On (OP_CODE:106, Param1:1, Param2:1 ) Relay (#1) becomes ON Relay Off (OP_CODE:106, Param1:1, Param2:0) Relay (#1) becomes OFF Relay On / Off OP_CODE 106 PARAM 1 Relay No (Bit Mask) Out1 : 1 Out2 : 2 Out3 : 4 Out4 : 8 On/Off On : 1 Off : 0 PARAM 2
Setup the type of alarm input. Available to setup for alarm sensor type (dont use sensor event / normal open type/ normal close type)
Set up the Activation Time ( Check it always / Check it only scheduled day/time)
Action ( Alarm Output / Output Duration / Alarm Image Transfer / Camera Action )
Generating alarm output (when alarm happened) as following the configured duration for alarm output If Alarm Image Transfer is ON, then stored image from alarm will be sent via configured Transfer mode (FTP or Email).however Image cannot be sent without setting of Alarm Image Transfer set On Available to set up the motion of Camera when alarm generate. Admin in FTP and SMTP even though
35
36
nd
Request ( Client -> Server ) to connect to the server Response ( Server -> Client) for the Connection Request
STRT P.S CNS RANDOM CONST _END
S _
T E
R N
T D
0 0
3-1-2. [LGN]
Command Definition: User Authentication (Request)
Request
STRT P.S LGN RANDOM CONST USER ID + PW _END
ID ( 20byte )
Password ( 20byte )
36
37
Response
is not used in this command. Notify Response is not used in this command
T
STRT
T
P.S
L
NULL
_
_END
LGW
T Notify
3-1-4. [STA]
Command Definition: Connection status (check) message.
Request
37
38
nd
Notify Response
STRT P.S STA N LL _END
STREAM DATA
Type
unsigned char unsigned char unsigned char unsigned char unsigned long unsigned long unsigned short unsigned short unsigned char unsigned char
Name
start_code[5] packetsize[4] isStream isCompMode frame_num frame_size slice_num slice_size channel_info mountType, resolution 1 1 1
Description
Start Code (STRT) Packet size Packet Type Compression Mode frame number frame size Slice Number of Current Packet Slice Size of Current Packet Channel Index
Resolution (LSB)
Value 00 01 10
38
39
Description 1920*1080 1280*720 720*576 720*480 720*288 720*240 704*576 704*480 704*288 704*240 640*480 352*288 352*240 320*240 176*144 176*128 160*120 unsigned long unsigned short unsigned short unsigned char unsigned char frame_gop frame_gop_num frame_type frame_data[1400] end_code[5] Payload (Stream Data) Ending Code (_END) gop gop number
Value 01000 01001 01010 01011 01100 01101 01110 01111 10000 10001 10010 10011 10100 10101 10110 10111 11000
39
40
nd
Request ( Client -> Server ) to connect to the server Response ( Server -> Client) for the Connection Request
STRT P.S CNS RANDOM CONST _END
S _
T E
R N
T D
0 0
4-1-2. [LGN]
Command Definition: User Authentication (Request) . Request
TRT ID: 20byte, P.S LGN RANDOM CONST USER ID + PW _END
40
41
ID ( 20byte ) _ E N D 0
Password ( 20byte )
Response
Request
T
STRT
T
P.S
L
NULL
_
_END
LGW
T Notify
4-1-4. [STA]
Command Definition: Connection status (check) message.
Request
41
42
nd
Check message for the connection status ( every 10 seconds) Sample Code ( Unit : Byte ) S T R T 0 0 0 0 4 S T A 0 _ E N D 0
Notify Response
STRT P.S STA NULL _END
Type
unsigned char unsigned char unsigned char unsigned char unsigned long unsigned long *unsigned short *unsigned short *unsigned char *unsigned char
Name
start_code[5] packetsize[4] isStream isCompMode frame_num frame_size slice_num slice_size channel_info mountType, resolution 1 1 1
Description
Start Code (STRT) Packet size Packet Type Compression Mode frame number frame size Slice Number of Current Packet Slice Size of Current Packet Channel Index
Resolution (LSB)
Value 00 01 10
42
43
bit5 ~ 0 Description 1920*1080 1280*720 720*576 720*480 720*288 720*240 704*576 704*480 704*288 704*240 640*480 352*288 352*240 320*240 176*144 176*128 160*120 *unsigned long *unsigned short *unsigned short unsigned char unsigned char frame_gop frame_gop_num frame_type frame_data[1400] end_code[5] Payload (Stream Data) Ending Code (_END) gop gop number Value 01000 01001 01010 01011 01100 01101 01110 01111 10000 10001 10010 10011 10100 10101 10110 10111 11000
43
44
nd
Request ( Client -> Server ) to connect to the server Response ( Server -> Client) for the Connection Request
STRT P.S CNS RANDOM CONST _END
S _
T E
R N
T D 0
5-1-2. [LGN]
Command Definition: User Authentication (Request)
Request
STRT P.S LGN RANDOM CONST USER ID + PW _END
44
45
ID ( 20byte ) _ E N D 0
Password ( 20byte )
Response
Request
T
STRT
T
P.S
L
NULL
_
_END
LGW
T Notify
is not used in this command Notify Response is not used in this command
45
46
nd
unsigned char unsigned char unsigned long unsigned long unsigned char unsigned char
Packet Type Compression Mode frame number frame size Payload (Stream Data) Ending Code (_END)
End of Documentation-
46