联咏平台
1 Command
Catalog | Name | Command | Parameter Type | |
---|---|---|---|---|
Photo | WIFIAPP_CMD_CAPTURE | 1001 | Null | |
Photo | WIFIAPP_CMD_CAPTURESIZE | 1002 | Enumeration | |
Photo | WIFIAPP_CMD_FREE_PIC_NUM | 1003 | Null | |
Photo | Movie | WIFIAPP_CMD_RECORD | 2001 | Start/stop |
Photo | WIFIAPP_CMD_MOVIE_REC_SIZE | 2002 | Enumeration | |
Photo | WIFIAPP_CMD_CYCLIC_REC | 2003 | On/off | |
Photo | WIFIAPP_CMD_MOVIE_HDR | 2004 | On/off | |
Photo | WIFIAPP_CMD_MOVIE_EV | 2005 | Enumeration | |
Photo | WIFIAPP_CMD_MOTION_DET | 2006 | On/off | |
Photo | WIFIAPP_CMD_MOVIE_AUDIO | 2007 | On/off | |
Photo | WIFIAPP_CMD_DATEIMPRINT | 2008 | On/off | |
Photo | WIFIAPP_CMD_MAX_RECORD_TIME | 2009 | Null | |
Photo | WIFIAPP_CMD_MOVIE_LIVEVIEW_SIZE | 2010 | Enumeration | |
Photo | WIFIAPP_CMD_MOVIE_GSENSOR_SENS | 2011 | On/off | |
Photo | WIFIAPP_CMD_SET_AUTO_RECORDING | 2012 | On/off | |
Photo | WIFIAPP_CMD_MOVIE_REC_BITRATE | 2013 | Bit rate string | |
Photo | WIFIAPP_CMD_MOVIE_LIVEVIEW_BITRATE | 2014 | Bit rate string | |
Photo | WIFIAPP_CMD_MOVIE_LIVEVIEW_START | 2015 | Start/stop | |
Photo | WIFIAPP_CMD_MOVIE_RECORDING_TIME | 2016 | Null | |
Photo | WIFIAPP_CMD_MOVIE_REC_TRIGGER_RAWENC | 2017 | Null | |
Photo | WIFIAPP_CMD_MOVIE_GET_RAWENC_JPG | 2018 | Null | |
Photo | WIFIAPP_CMD_MOVE_GET_LIVESTREAM | 2019 | Null | |
Setup | WIFIAPP_CMD_MODECHANGE | 3001 | Enumeration | |
Setup | WIFIAPP_CMD_QUERY | 3002 | Null | |
Setup | WIFIAPP_CMD_SET_SSID | 3003 | string of SSD | |
Setup | WIFIAPP_CMD_SET_PASSPHRASE | 3004 | string ofpassphrase | |
Setup | WIFIAPP_CMD_SET_DATE | 3005 | YY-MM-DDstring | |
Setup | WIFIAPP_CMD_SET_TIME | 3006 | HH-MM-SSstring | |
Setup | WIFIAPP_CMD_POWEROFF | 3007 | Enumeration | |
Setup | WIFIAPP_CMD_LANGUAGE | 3008 | Enumeration | |
Setup | WIFIAPP_CMD_TVFORMAT | 3009 | Enumeration | |
Setup | WIFIAPP_CMD_FORMAT | 3010 | Enumeration | |
Setup | WIFIAPP_CMD_SYSRESET | 3011 | Null | |
Setup | WIFIAPP_CMD_VERSION | 3012 | Null | |
Setup | WIFIAPP_CMD_FWUPDATE | 3013 | Null | |
Setup | WIFIAPP_CMD_QUERY_CUR_STATUS | 3014 | Null | |
Setup | WIFIAPP_CMD_FILELIST | 3015 | Null | |
Setup | WIFIAPP_CMD_HEARTBEAT | 3016 | Null | |
Setup | WIFIAPP_CMD_DISK_FREE_SPACE | 3017 | Null | |
Setup | WIFIAPP_CMD_RECONNECT_WIFI | 3018 | Null | |
Setup | WIFIAPP_CMD_GET_BATTERY | 3019 | Null | |
Setup | WIFIAPP_CMD_NOTIFY_STATUS | 3020 | Null | |
Setup | WIFIAPP_CMD_SAVE_MENUINFO | 3021 | Null | |
Setup | WIFIAPP_CMD_GET_HW_CAP | 3022 | Null | |
Setup | WIFIAPP_CMD_REMOVE_USER | 3023 | Null | |
Setup | WIFIAPP_CMD_GET_CARD_STATUS | 3024 | Null | |
Setup | WIFIAPP_CMD_GET_DOWNLOAD_URL | 3025 | Null | |
Setup | WIFIAPP_CMD_GET_UPDATEFW_PATH | 3026 | Null | |
Setup | WIFIAPP_CMD_UPLOAD_FILE | 3027 | Null | |
Setup | WIFIAPP_CMD_SET_PIP_STYLE | 3028 | Enumeration | |
Setup | WIFIAPP_CMD_GET_SSID_PASSPHRASE | 3029 | Null | |
Setup | WIFIAPP_CMD_QUERY_MOVIE_SIZE | 3030 | Null | |
Setup | WIFIAPP_CMD_QUERY_MENUITEM | 3031 | Null | |
Setup | WIFIAPP_CMD_SEND_SSID_PASSPHRASE | 3032 | SSID:Passphrase string | |
Setup | WIFIAPP_CMD_SET_WIFI_CONNECT_MODE | 3033 | Enumeration | |
Setup | WIFIAPP_CMD_FILELIST_PARTITION | 3034 | index num | |
Playback | WIFIAPP_CMD_THUMB | 4001 | File path string | |
Playback | WIFIAPP_CMD_SCREEN | 4002 | File path string | |
Playback | WIFIAPP_CMD_DELETE_ONE | 4003 | File path string | |
Playback | WIFIAPP_CMD_DELETE_ALL | 4004 | File path string | |
Playback | WIFIAPP_CMD_MOVIE_FILE_INFO | 4005 | File path string | |
Playback | WIFIAPP_CMD_UPLOAD | 5001 | File path string |
2 用法
2.1 拍照模式
2.1.1 Capture
Start capture.
Command: http://192.168.1.254/?custom=1&cmd=1001
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>1001</Cmd>
<Status>0</Status>
<File>
<NAME>2000_0101_002223_001.JPG</NAME>
<FPATH>A:\Novatek\Photo\2000_0101_002223_001.JPG</FPATH>
</File>
<FREEPICNUM>317</FREEPICNUM>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_FILE_ERROR | (-5) |
WIFIAPP_RET_STORAGE_FULL | (-11) |
WIFIAPP_RET_FOLDER_FULL | (-12) |
Note:
This command is only executed in photo mode. If system is not in photo mode, please change to photo mode by WIFIAPP_CMD_MODECHANGE first.
Before capture, please check free picture number by WIFIAPP_CMD_FREE_PIC_NUM.
(1) This command would return captured file and file path. It also returns free picture after capture.
2.1.2 Capture Size
capture size.
command: http://192.168.1.254/?custom=1&cmd=1002&par=0
parameter: Depend on project capture size enumeration; current value as below
Reference Parameter
| --- |
| _PHOTO_SIZE
HOTO_SIZE_12M,
HOTO_SIZE_10M,
HOTO_SIZE_8M,
HOTO_SIZE_5M,
HOTO_SIZE_3M,
HOTO_SIZE_VGA,
HOTO_SIZE_ID_MAX, |
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>10012</Cmd>
<Status>0</Status>
</Function>
Note:
This command can execute in photo and movie mode.
User should check WIFIAPP_CMD_FREE_PIC_NUM if change capture size.
2.1.3 Free capture number
Get free capture number of current storage. This command would depend on different
capture size to estimate the free picture numbers
Command: http://192.168.1.254/?custom=1&cmd=1003
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>1003</Cmd>
<Status>0</Status>
<Value>378</Value>
</Function>
Note:
- Free picture number value 0 means there is on
2.2 录像模式
2.2.1 Movie record
Start and stop movie record.
Command: http://192.168.1.254/?custom=1&cmd=2001&par=1
Parameter: 1 means start record
0 means stop record
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2001</Cmd>
<Status>0</Status>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_MOVIE_FULL | (-7) |
WIFIAPP_RET_MOVIE_WR_ERROR | (-8) |
WIFIAPP_RET_MOVIE_SLOW | (-9) |
2.2.2 Movie record size
Set movie record size.
Command: http://192.168.1.254/?custom=1&cmd=2002&par=1
Parameter: Depend on project movie size enumeration; user should get movie size
capacity by command 4.3.30 Get movie size capacity
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2002</Cmd>
<Status>0</Status>
</Function>
Note:
- User should check WIFIAPP_CMD_MAX_RECORD_TIME, if change movie record size.
2.2.3 Cyclic record
Set cyclic record value.
Command : http://192.168.1.254/?custom=1&cmd=2003&par=1
Parameter: depend on project movie cyclic record enumeration; current value as below
Reference Parameter
enum _MOVIE_CYCLICREC
{
MOVIE_CYCLICREC_OFF,
MOVIE_CYCLICREC_3MIN,
MOVIE_CYCLICREC_5MIN,
MOVIE_CYCLICREC_10MIN,
MOVIE_CYCLICREC_ID_MAX
};
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2003</Cmd>
<Status>0</Status>
</Function>
2.2.4 Movie HDR
Enable/Disable movie HDR.
Command: http://192.168.1.254/?custom=1&cmd=2004&par=0
Parameter: 1 means on
0 means off
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2004</Cmd>
<Status>0</Status>
</Function>
2.2.5 Movie EV
Set Movie EV value.
Command: http://192.168.1.254/?custom=1&cmd=2005&par=6
Parameter: depend on project movie EV enumeration; current value as below
Reference Parameter
enum _EXPOSURE
{
EV_P20,
EV_P16,
EV_P13,
EV_P10,
EV_P06,
EV_P03,
EV_00,
EV_N03,
EV_N06,
EV_N10,
EV_N13,
EV_N16,
EV_N20,
EV_SETTING_MAX,
};
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2005</Cmd>
<Status>0</Status>
</Function>
Note:
- This command should stop live view before setting and then start live view, the value would become effective
2.2.6 Motion detection
Enable/Disable movie motion detection. While motion detection on, device detected
moving object, it would notify user record started (WIFIAPP_RET_RECORD_STARTED)
by socket. If no moving object more than 10 sec, it would notify user record stopped
(WIFIAPP_RET_RECORD_STOPPED) by socket.
Command: http://192.168.1.254/?custom=1&cmd=2006&par=1
Parameter: 1 means on 0 means off
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2006</Cmd>
<Status>0</Status>
</Function>
Notify status | value |
---|---|
WIFIAPP_RET_RECORD_STARTED | 1 |
WIFIAPP_RET_RECORD_STOPPED | 2 |
Note:
- This command would become effective while user start record by WIFIAPP_CMD_RECORD. In other words, users must start recording when users enable motion detection, this function will work.
2.2.7 Movie audio
Enable/Disable audio while recording.
Command: http://192.168.1.254/?custom=1&cmd=2007&par=1
Parameter: 1 means on 0 means off
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2007</Cmd>
<Status>0</Status>
</Function>
2.2.8 Movie date in print
Enable/Disable movie date in print.
Command: http://192.168.1.254/?custom=1&cmd=2008&par=1
Parameter: 1 means on 0 means off
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2008</Cmd>
<Status>0</Status>
</Function>
2.2.9 Movie max record time
Get movie max recording time depend on current bitrate. This command would get free
space of current storage to calculate the max recording time. The unit is second.
Command: http://192.168.1.254/?custom=1&cmd=2009
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2009</Cmd>
<Status>0</Status>
<Value>471</Value>
</Function>
2.2.10 Movie G-Sensor sensitivity
Enable/Disable movie G-Sensor sensitivity.
Command: http://192.168.1.254/?custom=1&cmd=2011&par=2
Parameter: depend on project G-sensor enumeration; current value as below
Reference Parameter
enum _GSENSOR
{
GSENSOR_OFF = 0,
GSENSOR_LOW,
GSENSOR_MED,
GSENSOR_HIGH,
GSENSOR_ID_MAX,
};
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2011</Cmd>
<Status>0</Status>
</Function>
2.2.11 Set auto-recording
Enable/Disable auto-recording. If enable, the system would auto-record while power-on or first time Wi-Fi on would auto-record. Command: http://192.168.1.254/?custom=1&cmd=2012&par=1 Parameter: 1 means on 0 means off
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2012</Cmd>
<Status>0</Status>
</Function>
2.2.12 Movie record bitrate
Set movie record bitrate.
Command: http://192.168.1.254/?custom=1&cmd=2013&str=400
Parameter: record bitrate value. The unit is K byte/sec
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2013</Cmd>
<Status>0</Status>
</Function>
Note:
- User should care about movie record size and bitrate relationship. If bitrate is too sma
and movie size it too large; H264 cannot scale down to target bitrate.
- The suggestion setting is as below
Movie size | Bitrate |
---|---|
1080p (1920*1080) | 1450 K Byte/sec |
720p | 800 K Byte/sec |
WVGA | 400 K Byte/sec |
VGA | 400 K Byte/sec |
1080p(1440*1080) | 1450 K Byte/sec |
2.2.13 Movie live view bitrate
Set movie live view bitrate.
Command: http://192.168.1.254/?custom=1&cmd=2014&str=300
Parameter: movie live view bitrate value
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2014</Cmd>
<Status>0</Status>
</Function>
Note:
- User should care about movie live view size and bitrate relationship. If bitrate is too
small and movie size it too large; H264 cannot scale down to target bitrate.
- The suggestion setting is as below
Movie size | Bitrate |
---|---|
720p | 800 K Byte/sec |
WVGA | 400 K Byte/sec |
VGA | 400 K Byte/sec |
360p | 400 K Byte/sec |
QVGA | 300 K Byte/sec |
2.2.14 Movie live view start
Start and stop movie live view.
Command: http://192.168.1.254/?custom=1&cmd=2015&par=1
Parameter: 1 means start live view
0 means stop live view
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2015</Cmd>
<Status>0</Status>
</Function>
Note:
- All movie menu setting should stop movie live view and then set. After setting usershould start live view again.
- While stop movie live view, RTSP client should also stop and start RTSP client until movie live view start OK.
2.2.15 Movie recording time
Get movie recording time. The unit is second.
command: http://192.168.1.254/?custom=1&cmd=2016
parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2016</Cmd>
<Status>0</Status>
</Function>
Note: The value 0 means is not recording If cyclic record on, the recording time would reset depend on cyclic period.
2.2.16 Trigger RAW encode
Trigger RAW encode to save a JPEG frame in a DRAM buffer rather than a file.
Command: http://192.168.1.254/?custom=1&cmd=2017
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2017</Cmd>
<Status>0</Status>
</Function>
Note:
- If the status returned 0, command WIFIAPP_CMD_MOVIE_GET_RAWENC_JPG can be sent to grab back the JPEG frame which is just taken.
- This command must be send while movie recording.
2.2.17 Get RAW encode JPEG
Grab back the JPEG frame which is just taken by command WIFIAPP_CMD_MOVIE_REC_TRIGGER_RAWENC.
Command: http://192.168.1.254/?custom=1&cmd=2018
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2018</Cmd>
<Status>0</Status>
</Function>
If error, the device would return error status by a XML
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2018</Cmd>
<Status>-1</Status>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_NOFILE | (-1) |
2.2.18 Get live stream url
WIFIAPP_CMD_MOVE_GET_LIVESTREAM
Command: http://192.168.1.254/?custom=1&cmd=2019
Parameter: null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>2019</Cmd>
<Status>0</Status>
<MovieLiveViewLink>rtsp://192.168.1.254/</MovieLiveViewLink>
<PhotoLiveViewLink>http://192.168.1.254:8192</PhotoLiveViewLink>
</Function>
Note:
If not support this command(2019), MovieLiveViewLink default rtsp://192.168.1.254,PhotoLiveViewLink default http://192.168.1.254:8192
2.3 设置命令
2.3.1 Mode change
Change system mode.
Command: http://192.168.1.254/?custom=1&cmd=3001&par=2
Parameter: Depend on project Wi-Fi mode enumeration; current value as below
Reference Parameter
typedef enum
{
WIFI_APP_MODE_PHOTO = 0,
WIFI_APP_MODE_MOVIE,
WIFI_APP_MODE_PLAYBACK,
ENUM_DUMMY4WORD(WIFI_APP_MODE_CMD)
} WIFI_APP_MODE_CMD;
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3001</Cmd>
<Status>0</Status>
</Function>
Note:
- In Wi-Fi on photo mode, the system would start HTTP protocol and send motion JPG stream.
- In Wi-Fi on movie mode, the system would start RTSP protocol and send H264 stream.
- In Wi-Fi on playback mode, user can send command to play movie files by RTSP protocol.
2.3.2 Query status
Query current support command. Command: http://192.168.1.254/?custom=1&cmd=3002
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>1001</Cmd>
<Cmd>1002</Cmd>
<Cmd>1003</Cmd>
<Cmd>2016</Cmd>
<Cmd>2001</Cmd>
<Cmd>2002</Cmd>
<Cmd>2003</Cmd>
<Cmd>2004</Cmd>
<Cmd>2005</Cmd>
<Cmd>2006</Cmd>
<Cmd>2007</Cmd>
<Cmd>2008</Cmd>
<Cmd>2009</Cmd>
<Cmd>2010</Cmd>
<Cmd>2011</Cmd>
<Cmd>2012</Cmd>
<Cmd>2013</Cmd>
<Cmd>2014</Cmd>
<Cmd>2015</Cmd>
<Cmd>3001</Cmd>
<Cmd>3002</Cmd>
<Cmd>3003</Cmd>
<Cmd>3004</Cmd>
<Cmd>3005</Cmd>
<Cmd>3006</Cmd>
<Cmd>3007</Cmd>
<Cmd>3008</Cmd>
<Cmd>3009</Cmd>
<Cmd>3010</Cmd>
<Cmd>3011</Cmd>
<Cmd>3012</Cmd>
<Cmd>3013</Cmd>
<Cmd>3014</Cmd>
<Cmd>3015</Cmd>
<Cmd>3016</Cmd>
<Cmd>3017</Cmd>
<Cmd>3018</Cmd>
<Cmd>3019</Cmd>
<Cmd>4001</Cmd>
<Cmd>4002</Cmd>
<Cmd>4003</Cmd>
<Cmd>4004</Cmd>
</Function>
2.3.3 Set SSID
Set Wi-Fi SSID. This command would become effective while reconnect Wi-Fi. After set SSID, user would reconnect Wi-Fi by WIFIAPP_CMD_RECONNECT_WIFI. The SSID would be kept in flash if device power off correctly.
Command: http://192.168.1.254/?custom=1&cmd=3003&str=ABCDE
Parameter: string of SSID name; max length is 32 bytes of number and characters mix
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3003</Cmd>
<Status>0</Status>
</Function>
2.3.4 Set passphrase
Set Wi-Fi passphrase. This command would become effective while reconnect Wi-Fi. After
set passphrase, user would reconnect Wi-Fi by WIFIAPP_CMD_RECONNECT_WIFI. The
passphrase would be kept in flash if device power off correctly.
Command: http://192.168.1.254/?custom=1&cmd=3004&str=87654321
Parameter: string of passphrase ;max length is 26 bytes of number and characters mix
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3004</Cmd>
<Status>0</Status>
</Function>
2.3.5 Set date
Set device system date.
Command: http://192.168.1.254/?custom=1&cmd=3005&str=2014-03-21
Parameter: string of date ; format would be yyyy-mm-dd
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3005</Cmd>
<Status>0</Status>
</Function>
2.3.6 Set time
Set device system time.
Command: http://192.168.1.254/?custom=1&cmd=3006&str=17:10:30
Parameter: string of time ; format would be hh:mm:ss
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3006</Cmd>
<Status>0</Status>
</Function>
2.3.7 Power off
Set system auto power off time.
Command: http://192.168.1.254/?custom=1&cmd=3007&par=1
Parameter: the enumeration of power off setting in project; current value as below:
Reference Parameter
typedef enum
{
POWER_ON = 0,
POWER_1MIN,
POWER_2MIN,
POWER_3MIN,
POWER_5MIN,
POWER_10MIN,
POWEROFF_SETTING_MAX
}POWEROFF_SETTING;
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3007</Cmd>
<Status>0</Status>
</Function>
2.3.8 Language
Select device language.
Command: http://192.168.1.254/?custom=1&cmd=3008&par=1
Parameter: the enumeration of language setting in project; current value as below:
Reference Parameter
enum _LANGUAGE
{
LANG_EN,
LANG_FR,
LANG_ES,
LANG_PO,
LANG_DE,
LANG_IT,
LANG_SC,
LANG_TC,
LANG_RU,
LANG_JP,
LANG_ID_MAX,
};
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3008</Cmd>
<Status>0</Status>
</Function>
2.3.9 TV format
Set TV format while device output to TV.
Command: http://192.168.1.254/?custom=1&cmd=3009&par=1
Parameter: the enumeration of TV mode setting in project; current value as below:
Reference Parameter
enum _TV_MODE
{
TV_MODE_NTSC,
TV_MODE_PAL,
TV_MODE_ID_MAX
};
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3009</Cmd>
<Status>0</Status>
</Function>
2.3.10 Format
This command would format storage (SD card or flash memory) on device.
Command: http://192.168.1.254/?custom=1&cmd=3010&par=0
Parameter: 1 means format card 0 means format nand/spi flash
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3010</Cmd>
<Status>0</Status>
</Function>
2.3.11 System reset
Reset all setting to default. The system default value would be decided by project. The reset result would be the same as executing menu default setting.
Command: http://192.168.1.254/?custom=1&cmd=3011
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3011</Cmd>
<Status>0</Status>
</Function>
2.3.12 Get version
Get project version.
Command: http://192.168.1.254/?custom=1&cmd=3012
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3012</Cmd>
<Status>0</Status>
<String>ECOSDEMO00010027</String>
</Function>
2.3.13 Firmware update
Start to update firmware. Firmware path would be defined by project. Before update ,user should upload FW file to device. If there is no firmware, it would return error
Command: http://192.168.1.254/?custom=1&cmd=3013
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3013</Cmd>
<Status>0</Status>
<String>ECOSDEMO00010027</String>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_FW_WRITE_CHK_ERR | (-14) |
WIFIAPP_RET_FW_READ2_ERR | (-15) |
WIFIAPP_RET_FW_WRITE_ERR | (-16) |
WIFIAPP_RET_FW_READ_CHK_ERR | (-17) |
WIFIAPP_RET_FW_READ_ERR | (-18) |
WIFIAPP_RET_FW_INVALID_STG | (-19) |
Note:
Before update firmware should check battery level. Prevent shutdown suddenly while updating. After firmware update successfully, the system would auto power off. User should do system reset when power on next time.
User can refer to "6 FW update flow"
2.3.14 Query current status
Query all setting command status. This command is for user to synchronous device menu setting. The value would be the same as command parameter.
Command: http://192.168.1.254/?custom=1&cmd=3014
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>1002</Cmd>
<Status>1</Status>
<Cmd>2016</Cmd>
<Status>0</Status>
<Cmd>2002</Cmd>
<Status>1</Status>
<Cmd>2003</Cmd>
<Status>1</Status>
<Cmd>2004</Cmd>
<Status>0</Status>
<Cmd>2005</Cmd>
<Status>6</Status>
<Cmd>2006</Cmd>
<Status>0</Status>
<Cmd>2007</Cmd>
<Status>1</Status>
<Cmd>2008</Cmd>
<Status>1</Status>
<Cmd>2009</Cmd>
<Status>1</Status>
<Cmd>2010</Cmd>
<Status>3</Status>
<Cmd>2011</Cmd>
<Status>2</Status>
<Cmd>2012</Cmd>
<Status>1</Status>
<Cmd>3007</Cmd>
<Status>0</Status>
<Cmd>3008</Cmd>
<Status>0</Status>
<Cmd>3009</Cmd>
<Status>1</Status>
</Function>
2.3.15 File list
List all files sorting by file creating time. This command only is executed in playback mode only.
Command: http://192.168.1.254/?custom=1&cmd=3015
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<LIST>
<ALLFile>
<File>
<NAME>2000_0101_002223_001.JPG</NAME>
<FPATH>A:\NOVATEK\PHOTO\2000_0101_002223_001.JPG</FPATH>
<SIZE>2794693</SIZE>
<TIMECODE>673252044</TIMECODE>
<TIME>2000/01/01 00:22:24</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_093302_001.JPG</NAME>
<FPATH>A:\NOVATEK\PHOTO\2014_0516_093302_001.JPG</FPATH>
<SIZE>3068293</SIZE>
<TIMECODE>1152404513</TIMECODE>
<TIME>2014/05/16 09:33:02</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_115639_041.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_115639_041.MOV</FPATH>
<SIZE>295976740</SIZE>
<TIMECODE>1152409459</TIMECODE>
<TIME>2014/05/16 11:59:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_120239_043.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_120239_043.MOV</FPATH>
<SIZE>295911204</SIZE>
<TIMECODE>1152409779</TIMECODE>
<TIME>2014/05/16 12:05:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_120539_044.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_120539_044.MOV</FPATH>
<SIZE>296107812</SIZE>
<TIMECODE>1152409875</TIMECODE>
<TIME>2014/05/16 12:08:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_120839_044.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_120839_044.MOV</FPATH>
<SIZE>296075044</SIZE>
<TIMECODE>1152409971</TIMECODE>
<TIME>2014/05/16 12:11:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
</LIST>
Note:
This command needs one file handle and temp buffer. Current device support 4 file handle max, if user need operate files at the same time. This command would occupy one file handle until command finish.
\
is file attribute. The value is the same as FAT file system file entry. The definition is as below.
ex: \
name | value | comment |
---|---|---|
FS_ATTRIB_READ | 0x01 | Bit 0, indicates the file is read only. |
FS_ATTRIB_HIDDEN | 0x02 | Bit 1, indicates the file should not be shown innormal directory listings. |
FS_ATTRIB_SYSTEM | 0x04 | Bit 2, indicates the file is an operating system file. |
FS_ATTRIB_VOLUME | 0x08 | 3, indicates the entry is the label for the volume. |
FS_ATTRIB_DIRECTORY | 0x10 | bit 4, indicates it is a directory |
FS_ATTRIB_ACHIEVE | 0x20 | bit 5, indicates the file has been created ormodified since the attribute was clear |
2.3.16 Heartbeat
This command is for smartphone to check device if exist. If it is alive would return result, otherwise it would not return.
Command: http://192.168.1.254/?custom=1&cmd=3016
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3016</Cmd>
<Status>0</Status>
</Function>
2.3.17 Get disk free space
Get free space of file system mounting storage (nand/spi flash or SD card, usually card).The unit is byte.
Command: http://192.168.1.254/?custom=1&cmd=3017
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3017</Cmd>
<Status>0</Status>
<Value>5159288832</Value>
</Function>
Note:
- Free space would be 64 bit digital number.
2.3.18 Reconnect Wi-Fi
Disconnect Wi-Fi and connect Wi-Fi again.
Command: http://192.168.1.254/?custom=1&cmd=3018
Parameter: Null
XML Return No device would be in wait to connect screen
Note:
- Some commands (SSID and passphrase setting ) need to reconnect Wi-Fi. The setting value would become effective.
2.3.19 Get battery level
Get battery level. If Device charged, it would return charged.
Command: http://192.168.1.254/?custom=1&cmd=3019
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3019</Cmd>
<Status>0</Status>
<Value>5</Value>
</Function>
Return value : depend on project battery status enumeration; current value as below
Reference return value
typedef enum
{
BATTERY_FULL = 0,
BATTERY_MED,
BATTERY_LOW,
BATTERY_EMPTY,
BATTERY_EXHAUSTED,
BATTERY_CHARGE,
BATTERY_STATUS_TOTAL_NUM
} BATTERY_STATUS;
2.3.20 Notify status
This is a command Device initiate to client. It is not a HTTP protocol based command.
User need to create socket to connect to server. Port number is 3333. The socket needs to
connect while smartphone application connects to Wi-Fi. The Device would notify app by user socket while there are system error.
ex: battery low, card full while recording, card error while recording and slow card while recording.
The data format which the socket received is as bellow.
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3020</Cmd>
<Status>-10</Status>
</Function>
Note:
- User can refer to "8 list" to know all status value.
2.3.21 Save menu information
Save all menu setting to flash memory
Command: http://192.168.1.254/?custom=1&cmd=3021
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3021</Cmd>
<Status>0</Status>
</Function>
2.3.22 Get hardware capacity
Get Device hardware capacity. App can get the current Device hardware components.
The component list is defined by project.
Command: http://192.168.1.254/?custom=1&cmd=3022
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3022</Cmd>
<Status>0</Status>
<Value>3</Value>
</Function>
2.3.23 Remove last user
There is only one user can connect to Device at the same time. This command provide new connect to kick off last connection. Device would notify last connection would be disconnected (WIFIAPP_RET_REMOVE_BY_USER) by socket.
Command: http://192.168.1.254/?custom=1&cmd=3023
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3023</Cmd>
<Status>0</Status>
</Function>
Notify status | value |
---|---|
WIFIAPP_RET_DISCONNECT | (7) |
2.3.24 Get card status
Get SD card status. If SD card unplug, movie recording or capture would fail, but user sti can live view.
Command: http://192.168.1.254/?custom=1&cmd=3024
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3023</Cmd>
<Status>0</Status>
</Function>
Return value: depend on project card status enumeration; current value as below
Reference return value
typedef enum
{
CARD_REMOVED = 0,
CARD_INSERTED,
CARD_LOCKED
} CARD_STATUS;
// If card error occurred, return below error code plus 3024. For Example, if rereturn value is 3025,
that means FS_UNKNOWN_FORMAT (3024 + 1).
typedef enum
{
FS_DISK_ERROR = 0,
FS_UNKNOWN_FORMAT,
FS_UNFORMATTED,
FS_NOT_INIT,
FS_INIT_OK,
FS_NUM_FULL
} FS_STATUS;
Note:
- User should check WIFIAPP_CMD_GET_CARD_STATUS before start record or live view.
2.3.25 Get download URL
Get download URL. The URL is usually manufacture proprietary website. The web site would keep new version information. The app should analysis the document of version information, and then check the Device FW version to decide if need to update. There are download link, and the FW authentication method in the document.
Command: http://192.168.1.254/?custom=1&cmd=3025
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3025</Cmd>
<Status>0</Status>
<String>http://114.29.201.46:8020/download/filedesc.xml</String>
</Function>
Example of filedesc.xml:
XML description
<?xml version="1.0" encoding="UTF-8" ?>
<DownloadDesc>
<FilePath>http://114.29.201.46:8020/download/FW96655A.bin</FilePath>
<Version>CDV.001.001.001</Version>
<CheckMethord>none</CheckMethord>
<CheckValue>0</CheckValue>
</DownloadDesc>
Note:
- User can refer to "6 FW update flow"
2.3.26 Get update FW path
Get update FW path. The Device would read new version FW in this path to update.
Therefore app would upload new FW to the assigned path according this command.
Command: http://192.168.1.254/?custom=1&cmd=3026
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3026</Cmd>
<Status>0</Status>
<String>http://192.168.1.254/FW96655A.bin</String>
</Function>
Note:
- User can refer to "6 FW update flow"
2.3.27 Result of HFS upload file
This is only a command ID for HFS upload file result. After app uploaded file, Device would return xml format result. 3027 is only update command ID in xml.
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3027</Cmd>
<Status>0</Status>
</Function>
Return status | value | comment |
---|---|---|
CYG_HFS_UPLOAD_OK | (0) | upload file ok |
CYG_HFS_UPLOAD_FAIL_FILE_EXIST | (-1) | upload file fail because of file exist |
CYG_HFS_UPLOAD_FAIL_RECEIVE_ERROR | (-2) | receive data has some error |
CYG_HFS_UPLOAD_FAIL_WRITE_ERROR | (-3) | write file has some error |
CYG_HFS_UPLOAD_FAIL_FILENAME_EMPTY | (-4) | file name is empty |
2.3.28 Setup PIP Style
Set PIP (Picture in Picture) style for live view streaming.
Command: http://192.168.1.254/?custom=1&cmd=3028&par=1
Parameter: the enumeration of PIP_STYLE setting in project; current value is as below:(Returning supported items from 3031)
Reference Parameter
enum _DUALCAM_SETTING
{
DUALCAM_FRONT,
DUALCAM_BEHIND,
DUALCAM_BOTH, //FRONT is major
DUALCAM_BOTH2, //BEHIND is major
DUALCAM_SETTING_MAX,
DUALCAM_LEFT,
DUALCAM_RIGHT
}; //PIP Styoe setting
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3028</Cmd>
<Status>0</Status>
</Function>
2.3.29 Get SSID and passphrase
If Wi-Fi AP mode is enable. User can get SSID and passphrase via this command.
Command: http://192.168.1.254/?custom=1&cmd=3029
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<List>
<SSID>NVT_CARDV_xxxxxx</SSID>
<PASSPHRASE>12345678</PASSPHRASE>
</List>
2.3.30 Get movie size capacity
List all supported movie record size. Different model might support different size, app should query movie size list first. If type is MOVIE_REC_TYPE_FRONT means this size is support only record file, no RTSP streaming. The resolution or frame rate is much bigger,therefore system could not support 2 path output. Command: http://192.168.1.254/?custom=1&cmd=3030
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<LIST>
<Item>
<Name>UHD P24</Name>
<Index>0</Index>
<Size>2880*2160</Size>
<FrameRate>24</FrameRate>
<Type>1</Type>
</Item>
<Item>
<Name>QHD P30</Name>
<Index>1</Index>
<Size>2560*1440</Size>
<FrameRate>30</FrameRate>
<Type>4</Type>
</Item>
<Item>
<Name>FHD P60</Name>
<Index>4</Index>
<Size>1920*1080</Size>
<FrameRate>60</FrameRate>
<Type>4</Type>
</Item>
<Item>
<Name>FHD P30</Name>
<Index>5</Index>
<Size>1920*1080</Size>
<FrameRate>30</FrameRate>
<Type>4</Type>
</Item>
<Item>
<Name>HD P120</Name>
<Index>6</Index>
<Size>1280*720</Size>
<FrameRate>120</FrameRate>
<Type>1</Type>
</Item>
<Item>
<Name>HD P60</Name>
<Index>7</Index>
<Size>1280*720</Size>
<FrameRate>60</FrameRate>
<Type>1</Type>
</Item>
<Item>
<Name>HD P30</Name>
<Index>8</Index>
<Size>1280*720</Size>
<FrameRate>30</FrameRate>
<Type>4</Type>
</Item>
<Item>
<Name>WVGA P30</Name>
<Index>9</Index>
<Size>848*480</Size>
<FrameRate>30</FrameRate>
<Type>4</Type>
</Item>
<Item>
<Name>VGA P240</Name>
<Index>10</Index>
<Size>640*480</Size>
<FrameRate>240</FrameRate>
<Type>1</Type>
</Item>
<Item>
<Name>VGA P30</Name>
<Index>11</Index>
<Size>640*480</Size>
<FrameRate>30</FrameRate>
<Type>4</Type>
</Item>
</LIST>
Type is movie record type, emulation is below:
Reference record type
typedef enum _MOVIE_REC_TYPE{
MOVIE_REC_TYPE_UNKNOWN,
MOVIE_REC_TYPE_FRONT,
MOVIE_REC_TYPE_BEHIND,
MOVIE_REC_TYPE_DUAL,
MOVIE_REC_TYPE_CLONE,
}MOVIE_REC_TYPE;
2.3.31 Query menu item
List all supported menu item except movie size. Different model might support differen menu item, app should query menu itme and movie size list first.
Command: http://192.168.1.254/?custom=1&cmd=3031&str=all
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<LIST>
<Item>
<Cmd>1002</Cmd>
<Name>PHOTO_SIZE</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>12M</Id>
</Option>
<Option>
<Index>1</Index>
<Id>10M</Id>
</Option>
<Option>
<Index>2</Index>
<Id>8M</Id>
</Option>
<Option>
<Index>3</Index>
<Id>5M</Id>
</Option>
<Option>
<Index>4</Index>
<Id>3M</Id>
</Option>
<Option>
<Index>5</Index>
<Id>VGA</Id>
</Option>
</MenuList>
</Item>
<Item>
<Cmd>2003</Cmd>
<Name>MOVIE_CYCLIC_REC</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>3MIN</Id>
</Option>
<Option>
<Index>2</Index>
<Id>5MIN</Id>
</Option>
<Option>
<Index>3</Index>
<Id>10MIN</Id>
</Option>
</MenuList>
</Item>
<Item>
<Cmd>2004</Cmd>
<Name>MOVIE_WDR</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
<Item>
<Cmd>2005</Cmd>
<Name>EV</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>+2.0</Id>
</Option>
<Option>
<Index>1</Index>
<Id>+1.6</Id>
</Option>
<Option>
<Index>2</Index>
<Id>+1.3</Id>
</Option>
<Option>
<Index>3</Index>
<Id>+1.0</Id>
</Option>
<Option>
<Index>4</Index>
<Id>+0.6</Id>
</Option>
<Option>
<Index>5</Index>
<Id>+0.3</Id>
</Option>
<Option>
<Index>6</Index>
<Id>0.0</Id>
</Option>
<Option>
<Index>7</Index>
<Id>-0.3</Id>
</Option>
<Option>
<Index>8</Index>
<Id>-0.6</Id>
</Option>
<Option>
<Index>9</Index>
<Id>-1.0</Id>
</Option>
<Option>
<Index>10</Index>
<Id>-1.3</Id>
</Option>
<Option>
<Index>11</Index>
<Id>-1.6</Id>
</Option>
<Option>
<Index>12</Index>
<Id>-2.0</Id>
</Option>
</MenuList>
</Item>
<Item>
<Cmd>2006</Cmd>
<Name>MOVIE_MOTION_DET</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
<Item>
<Cmd>2007</Cmd>
<Name>MOVIE_AUDIO</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
<item>
<cmd>2018</cmd>
<Name>MOVIE_DATEIMPRINT</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
<Item>
<Cmd>2011</Cmd>
<Name>GSENSOR</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>LOW</Id>
</Option>
<Option>
<Index>2</Index>
<Id>MED</Id>
</Option>
<Option>
<Index>3</Index>
<Id>HIGH</Id>
<Id>SC</Id>
</Option>
<Option>
<Index>7</Index>
<Id>TC</Id>
</Option>
<Option>
<Index>8</Index>
<Id>RU</Id>
</Option>
<Option>
<Index>9</Index>
<Id>JP</Id>
</Option>
</MenuList>
</Item>
<Item>
<Cmd>3009</Cmd>
<Name>TV_MODE</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>NTSC</Id>
</Option>
<Option>
<Index>1</Index>
<Id>PAL</Id>
</Option>
</MenuList>
</Item>
<CHK>A6B7</CHK>
</LIST>
2.3.32 Send SSID and passphrase
APP can issue this command to send SSID and passphrase to deivce. APP should also issue command (3033) to notify device to switch to station mode thereafter.
Command : http://192.168.1.254/?custom=1&cmd=3032&str=SSID:passphrase
Parameter : string of SSID and passphrase
Return :
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3032</Cmd>
<Status>0</Status>
</Function>
2.3.33 Set Wi-Fi connection mode
Select Wi-Fi mode. After given SSID and passphrase by issuing command 3032. APP can switch device to station mode by this command. Then issue command 3018 to do re-conncetion.
Command: http://192.168.1.254/?custom=1&cmd=3033&par=1
Parameter : the enumeration of mode setting in project; current value as below:
typedef enum
{
NETWORK_AP_MODE = 0,
NETWORK_STATION_MODE,
}NETWORK_MODE_SETTING;
Return :
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>3033</Cmd>
<Status>0</Status>
</Function>
2.3.34Get file list partition
List all files sorting by file creating time. This command only is executed in playback mode only.
Command: http://192.168.1.254/?custom=1&cmd=3034&index=1&num=50
Parameter: index: the file start position
num: number of the file
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<LIST>
<ALLFile>
<File>
<NAME>2000_0101_002223_001.JPG</NAME>
<FPATH>A:\NOVATEK\PHOTO\2000_0101_002223_001.JPG</FPATH>
<SIZE>2794693</SIZE>
<TIMECODE>673252044</TIMECODE>
<TIME>2000/01/01 00:22:24</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_093302_001.JPG</NAME>
<FPATH>A:\NOVATEK\PHOTO\2014_0516_093302_001.JPG</FPATH>
<SIZE>3068293</SIZE>
<TIMECODE>1152404513</TIMECODE>
<TIME>2014/05/16 09:33:02</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_115639_041.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_115639_041.MOV</FPATH>
<SIZE>295976740</SIZE>
<TIMECODE>1152409459</TIMECODE>
<TIME>2014/05/16 11:59:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_120239_043.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_120239_043.MOV</FPATH>
<SIZE>295911204</SIZE>
<TIMECODE>1152409779</TIMECODE>
<TIME>2014/05/16 12:05:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_120539_044.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_120539_044.MOV</FPATH>
<SIZE>296107812</SIZE>
<TIMECODE>1152409875</TIMECODE>
<TIME>2014/05/16 12:08:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
<ALLFile>
<File>
<NAME>2014_0516_120839_044.MOV</NAME>
<FPATH>A:\NOVATEK\MOVIE\2014_0516_120839_044.MOV</FPATH>
<SIZE>296075044</SIZE>
<TIMECODE>1152409971</TIMECODE>
<TIME>2014/05/16 12:11:38</TIME>
<ATTR>32</ATTR>
</File>
</ALLFile>
</LIST>
Note:need return by 3002 if supported
This command needs one file handle and temp buffer. Current device support 4 file handle max, if user need operate files at the same time. This command would occupy one file handle until command finish.
\
is file attribute. The value is the same as FAT file system file entry. The definition is as below.
ex: \
name | value | comment |
---|---|---|
FS_ATTRIB_READ | 0x01 | Bit 0, indicates the file is read only. |
FS_ATTRIB_HIDDEN | 0x02 | Bit 1, indicates the file should not be shown innormal directory listings. |
FS_ATTRIB_SYSTEM | 0x04 | Bit 2, indicates the file is an operating system file. |
FS_ATTRIB_VOLUME | 0x08 | 3, indicates the entry is the label for the volume. |
FS_ATTRIB_DIRECTORY | 0x10 | bit 4, indicates it is a directory |
FS_ATTRIB_ACHIEVE | 0x20 | bit 5, indicates the file has been created ormodified since the attribute was clear |
2.4 回放模式
All playback mode command needs to change to playback mode first; otherwise there would be not enough free memory.
2.4.1 Get thumbnail
Get photo or movie file thumbnail. Movie thumbnail would be first frame of the movie file.
Command: http://192.168.1.254/NOVATEK/MOVIE/2014_0321_011922_002.MOV?custom=1&cmd=4001
Return The thumbnails data. There would be JPG data.
If error, the device would return error status by xml
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>4001</Cmd>
<Status>-1</Status>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_NOFILE | (-1) |
WIFIAPP_RET_EXIF_ERR | (-2) |
WIFIAPP_RET_NOBUF | (-3) |
2.4.2 Get screennail
Get photo or movie file screennail. Movie screennail would be first frame of the movie file.
Command : http://192.168.1.254/NOVATEK/MOVIE/2014_0321_011922_002.MOV?custom=1&cmd=4002
Return The screennails data. There would be JPG data.
If error, the device would return error status by xml
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>4002</Cmd>
<Status>-1</Status>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_NOFILE | (-1) |
WIFIAPP_RET_EXIF_ERR | (-2) |
WIFIAPP_RET_NOBUF | (-3) |
2.4.3 Delete one file
Delete the specific file in device
Command: Http://192.168.1.254/?custom=1&cmd=4003&str=A:\CARDV\PHOTO\2014_0506_000000.0001.JPG
Parameter: string format would be the same as file path
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>4003</Cmd>
<Status>0</Status>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_FILE_LOCKED | (-4) |
WIFIAPP_RET_FILE_ERROR | (-5) |
WIFIAPP_RET_DELETE_FAILED | (-6) |
2.4.4 Delete all
Delete the all photo and movie files in device
Command: http://192.168.1.254/?custom=1&cmd=4004
Parameter: Null
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>4004</Cmd>
<Status>0</Status>
</Function>
2.4.5 Get Movie file information
Get movie file information which included width, height and length.
Command: http://192.168.1.254/NOVATEK/MOVIE/2014_0321_011922_002.MOV??custom=1&cmd=4005
Return width, height and length by a XML.
XML Return
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>4005</Cmd>
<Status>0</Status>
<String>Width:1920, Height:1080, Length:51 sec</String>
</Function>
If error, the device would return error status by a XML
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>4005</Cmd>
<Status>-1</Status>
</Function>
Error status | value |
---|---|
WIFIAPP_RET_NOFILE | (-1) |
WIFIAPP_RET_EXIF_ERR | (-2) |
WIFIAPP_RET_NOBUF | (-3) |
WIFIAPP_RET_PAR_ERR | (-21) |
3 错误码列表
Error status | value | comments |
---|---|---|
WIFIAPP_RET_OK | 0 | Execute successful |
WIFIAPP_RET_RECORD_STARTED | 1 | Record is started |
WIFIAPP_RET_RECORD_STOPPED | 2 | Record is stop |
WIFIAPP_RET_DISCONNECT | 3 | Wi-Fi would be disconnect |
WIFIAPP_RET_MIC_ON | 4 | Notify app device is microphone on |
WIFIAPP_RET_MIC_OFF | 5 | Notify app device is microphone off |
WIFIAPP_RET_POWER_OFF | 6 | Notify app device power off |
WIFIAPP_RET_REMOVE_BY_USER | 7 | Notify app is disconnected, because newuser connected to device |
WIFIAPP_RET_NOFILE | -1 | No file |
WIFIAPP_RET_EXIF_ERR | -2 | File EXIF error |
WIFIAPP_RET_NOBUF | -3 | No buffer |
WIFIAPP_RET_FILE_LOCKED | -4 | File is read only |
WIFIAPP_RET_FILE_ERROR | -5 | File delete error |
WIFIAPP_RET_DELETE_FAILED | -6 | Delete fail |
WIFIAPP_RET_MOVIE_FULL | -7 | Storage full while recording |
WIFIAPP_RET_MOVIE_WR_ERROR | -8 | Write storage error while recording |
WIFIAPP_RET_MOVIE_SLOW | -9 | Slow card while recording |
WIFIAPP_RET_BATTERY_LOW | -10 | Battery low |
WIFIAPP_RET_STORAGE_FULL | -11 | Storage full |
WIFIAPP_RET_FOLDER_FULL | -12 | Folder full |
WIFIAPP_RET_FAIL | -13 | Execute error |
WIFIAPP_RET_FW_WRITE_CHK_ERR | -14 | Write FW checksum failed |
WIFIAPP_RET_FW_READ2_ERR | -15 | Read FW from NAND failed (for writechecking) |
WIFIAPP_RET_FW_WRITE_ERR | -16 | Write FW to NAND error |
WIFIAPP_RET_FW_READ_CHK_ERR | -17 | Read FW checksum failed |
WIFIAPP_RET_FW_READ_ERR | -18 | FW doesn't exist or read error |
WIFIAPP_RET_FW_INVALID_STG | -19 | Invalid source storage |
WIFIAPP_RET_FW_OFFSET | -20 | Firmware update error code offset |
WIFIAPP_RET_PAR_ERR | -21 | Command parameter error |
WIFIAPP_RET_CMD_NOTFOUND | -256 | Command not found |
4 扩展指令
4.1 时间戳开关
define WIFIAPP_CMD_DATE_STAMP 1101
FL_DATE_STAMP
enum _DATE_STAMP
{
DATE_STAMP_OFF,
DATE_STAMP_DATE,
DATE_STAMP_DATE_TIME,
DATE_STAMP_ID_MAX
};
4.2 延时开关
define WIFIAPP_CMD_TIME_LPASE 2101
FL_TIME_LPASE
enum _TIMELPASE
{
TIME_LPASE_OFF,
TIME_LPASE_1S,
TIME_LPASE_2S,
TIME_LPASE_5S,
TIME_LPASE_10S,
TIME_LPASE_30S,
TIME_LPASE_1MIN,
TIME_LPASE_ID_MAX
};
4.3 慢动作
#define WIFIAPP_CMD_ SLOW_MOTION 2102
FL_ SLOW_MOTION
enum _SLOW_MOTION
{
SLOW_MOTION_OFF,
SLOW_MOTION_ON_720P_120fps,
SLOW_MOTION_ON_VGA_P240,
SLOW_MOTION_ID_MAX
};
4.4 停车监控
修改目的:在该命令中添加两条参数,当在样机端打开或关闭停车守卫时发送3020告知App。
添加参数:
#define WIFIAPP_RET_PARKING_GUARD_ON 20 //通知app停车监控已经打开
#define WIFIAPP_RET_PARKING_GUARD_OFF 21 //通知app停车监控已经关闭
#define WIFIAPP_CMD_MOVIE_PARKING_GUARD 3101//8020 万汇
FL_MOVIE_PARKING_GUARD
enum _MOVIE_PARKING_GUARD
{
MOVIE_PARKING_GUARD_OFF,
MOVIE_PARKING_GUARD_ON,
MOVIE_PARKING_GUARD_ID_MAX,
};
4.5 防抖
#define WIFIAPP_CMD_ANTISHAKE 3102
FL_ANTISHAKE
enum _ANTISHAKING
{
ANTISHAKE_OFF,
ANTISHAKE_ON,
ANTISHAKE_ID_MAX
};
4.6 光源频率
#define WIFIAPP_CMD_FREQUENCY 3103
FL_FREQUENCY
enum _WIFI_FREQUENCY_
{
WIFI_50HZ,
WIFI_60HZ,
WIFI_FREQUENCY_MAX,
};
4.7 开车模式
#define WIFIAPP_CMD_CARMODE 3104
FL_CARMODE
enum _CARMODE
{
CARMODE_OFF,
CARMODE_ON,
CARMODE_ID_MAX
};
4.8 Sensor旋转
#define WIFIAPP_CMD_SENSOR_ROTATE 9984
enum _SENSOR_ROTATE_MODE
{
SEN_ROTATE_OFF,
SEN_ROTATE_ON,
SEN_ROTATE_MAX
};
4.9 锐度设置
#define WIFIAPP_CMD_SHARPNESS 9985
enum _SHARPNESS
{
SHARPNESS_SHARP,
SHARPNESS_NORMAL,
SHARPNESS_SOFT,
SHARPNESS_ID_MAX
};
4.10 图像色彩
#define WIFIAPP_CMD_PHOTO_COLOR 9986
FL_ PHOTO_COLOR
enum _PHOTO_COLOR
{
COLOR_EFFECT_STANDARD,
COLOR_EFFECT_MONOCHROME,
COLOR_EFFECT_SEPIA,
COLOR_EFFECT_ID_MAX,
COLOR_EFFECT_VIVID
};
4.11 图像质量
#define WIFIAPP_CMD_PHOTO_QUALITY 9987
FL_ PHOTO_QUALITY
enum _QUALITY
{
QUALITY_FINE,
QUALITY_NORMAL,
QUALITY_ECONOMY,
QUALITY_ID_MAX
};
4.12 连拍设置
#define WIFIAPP_CMD_CONTINUE_SHOT 9988
FL_ CONTINUE_SHOT
enum
{
CONTINUE_SHOT_OFF,
CONTINUE_SHOT_3,
CONTINUE_SHOT_SETTING_MAX
}
4.13 倒计时拍照
#define WIFIAPP_CMD_SELFTIMER 9989
FL_ SELFTIMER
enum _SELFTIMER
{
SELFTIMER_OFF,
SELFTIMER_2SEC,
SELFTIMER_5SEC,
SELFTIMER_10SEC,
SELFTIMER_20SEC,
SELFTIMER_ID_MAX
};
4.14 ISO设置
#define WIFIAPP_CMD_SETISO 9990
FL_ISO
enum _ISO
{
ISO_AUTO,
ISO_100,
ISO_200,
ISO_400,
ISO_ID_MAX,// The following are for compiling issue
ISO_800,
ISO_1600,
ISO_3200
};
4.15 白平衡
#define WIFIAPP_CMD_SETWB 9991
FL_WB
enum _WB_MODE
{
WB_AUTO,
WB_DAYLIGHT,
WB_CLOUDY,
WB_TUNGSTEN,
WB_FLUORESCENT,
WB_ID_MAX,
// The following are for compiling issue
WB_FLUORESCENT1,
WB_FLUORESCENT2,
WB_INCAND,
WB_MANUAL
};
4.16 背光开关
#define WIFIAPP_CMD_MOVIE_BACKLIGHT 9992
FL_LCD_BACKLIGHT
enum _LCD_BACKLIGHT
{
LCD_BACKLIGHT_OFF,
LCD_BACKLIGHT_1MIN,
LCD_BACKLIGHT_3MIN,
LCD_BACKLIGHT_5MIN,
LCD_BACKLIGHT_ID_MAX
};
4.17 文件保护
#define WIFIAPP_CMD_FILE_PROTECT 9993
enum _SENSOR_PROTECT_MODE
{
SEN_ PROTECT _OFF,
SEN_ PROTECT _ON,
SEN_ PROTECT _MAX
};
4.18 状态通知
#define WIFIAPP_CMD_NOTIFY_STATUS 3020
#define WIFIAPP_RET_CMD_FILE_PROTECT_OFF (-254)
#define WIFIAPP_RET_CMD_FILE_PROTECT_ON (-255)
以下为私有定义,其它联咏平台标准值请参考原厂SDK定义,如有需求请使用:
返回值 | 定义 | 备注 |
---|---|---|
1 | 开启了录制 | |
2 | 关闭了录制 | |
4 | 录音开启 | |
5 | 录音关闭 | |
10 | 拍照中 | |
11 | 拍照模式 | |
12 | 录制模式 | |
15 | 前镜头遗失 | |
16 | 后镜头遗失 | |
19 | 前镜头插入 | |
20 | 后镜头插入 | |
-254 | 关闭文件加锁 | |
-255 | 打开文件加锁 | |
4.19 视频流格式
#define WIFIAPP_CMD_MJPEG_RTSP 9994
// FL_MJPEG_RTSP,
typedef enum
{
MJPEG,
RTSP,
MJPEG_RTSP_MAX,
}MJPEG_RTSP;
4.20 FCWS
#define WIFIAPP_CMD_FCWS 9995
Enable/Disable LDWS.
Command : http://192.168.1.254/?custom=1&cmd=9995&par=1 Parameter : 1 means on 0 means off
Return :
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9995</Cmd>
<Status>0</Status>
</Function>
// 参考 WifiApp_SendCmd(WIFIAPP_CMD_NOTIFY_STATUS,WIFIAPP_RET_BATTERY_LOW);
4.21 LDWS
#define WIFIAPP_CMD_LDWS 9996
Enable/Disable LDWS.
Command : http://192.168.1.254/?custom=1&cmd=9996&par=1
Parameter : 1 means on 0 means off
Return :
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9996</Cmd>
<Status>0</Status>
</Function>
4.22 GPS除噪
#define WIFIAPP_CMD_GPS_VOICE 9997
Enable/Disable GPS VOICE.
Command : http://192.168.1.254/?custom=1&cmd=9997&par=1
Parameter : 1 means on 0 means off
Return :
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9997</Cmd>
<Status>0</Status>
</Function>
4.23 GPS开关
#define WIFIAPP_CMD_GPS 9998
Enable/Disable GPS.
Command : http://192.168.1.254/?custom=1&cmd=9998&par=1
Parameter : 1 means on 0 means off
Return :
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9998</Cmd>
<Status>0</Status>
</Function>
4.24 KEY
#define WIFIAPP_CMD_GET_KEY 9999
4.25 OTA品牌版本信息
拉取品牌和版本信息,主要用于固件端OTA服务器端控制:
http://192.168.1.254/?custom=1&cmd=8567
Return :
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>8567</Cmd>
<Status>0</Status>
<String>NT;NT96660;0G71;SS52;00;801;1.0;1.92;02:00:00:00:00:00;</String>
</Function>
示例 :
芯片厂家 | 芯片型号 | 方案商 | 品牌商 | 产品型号 | 指令版本 | 硬件版本 | 软件版本 |
---|---|---|---|---|---|---|---|
n字节 | N字节 | N字节 | N字节 | N字节 | N字节 | N字节 | N字节 |
4.26 延时录相
#define WIFIAPP\_CMD\_DELAY\_REC 9801
FL_DELAY_REC
enum _DELAY_REC
{
DELAY_REC_OFF,
//DELAY_REC_5SEC,
DELAY_REC_10SEC,
DELAY_REC_1MIN,
DELAY_REC_ID_MAX
};
4.27 预录
#define WIFIAPP_CMD_PRE_REC 9802
FL_PRE_REC
enum _PRE_REC
{
PRE_REC_OFF,
PRE_REC_ON,
PRE_REC_ID_MAX
};
4.28 计时
为了解决2016查询录制时间不准的问题,加入了socket判断状态15,在一个新文件生成的时候,固件发送
4.29 缩时录影帧率
#define WIFIAPP_CMD_DELAY_REC 9803
FL_DELAY_REC
enum _DELAY_REC
{
DELAY_REC_OFF,
1s/f,
2s/f,
4s/f,
8s/f,
DELAY_REC_ID_MAX
};
4.30 外放喇叭声音
#define WIFIAPP_CMD_BROADCASE 9807
enum _BROAD_CAST
{
BROAD_CAST _OFF,
BROAD_CAST _ON,
BROAD_CAST _ID_MAX
};
4.30 外放喇叭声音
#define WIFIAPP_CMD_VIBRATION 9808
//Vibration
enum _ VIBRATION
{
VIBRATION _OFF,
VIBRATION _ON,
VIBRATION_ID_MAX
};
4.30 手势识别
#define WIFIAPP_CMD_GESTURES__REC 9804
FL_GESTURES_CTR
enum _ GESTURES_CTR
{
GESTURES_CTR _OFF,
GESTURES_CTR _HIGH,
GESTURES_CTR _MID,
GESTURES_CTR _LOW,
GESTURES_CTR _ID_MAX
};
4.31 守卫时长 guard
#define WIFIAPP_CMD_GUARD_TIME 9805
FL_GUARD_TIME
enum _GUARD_TIME
{
GUARD_TIME_12H,
GUARD_TIME_24H,
GUARD_TIME_72H,
GUARD_TIME _ID_MAX
};
4.32 放大倍数
#define WIFIAPP_CMD_focus_mux 9806
FL_GUARD_TIME
enum _FOCUS_MUX
{
GUARD_TIME_0X,
GUARD_TIME_1X,
GUARD_TIME_2X,
GUARD_TIME_3X,
GUARD_TIME _ID_MAX
};
4.33 影像格式
#define WIFIAPP_CMD_VIDEO_FORMAT 8039
VIDEO_FORMAT
enum _ VIDEO_FORMAT
{
VIDEO_FORMAT _MP4,
VIDEO_FORMAT _TS,
VIDEO_FORMAT _ID_MAX
};
4.34 TF卡格式化提醒间隔时间
#define WIFIAPP_CMD_FORMAT_REMINDER 8030
FORMAT_REMINDER
enum _ FORMAT_REMINDER
{
FORMAT_REMINDER_1,
FORMAT_REMINDER_2,
FORMAT_REMINDER_3,
FORMAT_REMINDER _ID_MAX
};
4.34 系统异常
#define WIFIAPP_CMD_SYSTEM_ABNORMAL 8038
SYSTEM_ABNORMAL
enum _ SYSTEM_ABNORMAL
{
SYSTEM_ABNORMAL _OFF,
SYSTEM_ABNORMAL _ON,
SYSTEM_ABNORMAL _ID_MAX
};
4.35 获取SD卡容量 8040
#define WIFIAPP\_CMD\_SDCARD\_INFO 8040
SDCARD_INFO 返回值用#隔离,以下为示例: 14.47#Class 10#10MB/Ss 备注: SD卡容量单位为GB,这部分只能为数字,不用带单位
4.36 录像音量 8038
#define WIFIAPP_CMD_SYSTEM_ABNORMAL 8038
SYSTEM_ABNORMAL
enum _ SYSTEM_ABNORMAL
{
SYSTEM_ABNORMAL _OFF,
SYSTEM_ABNORMAL _ON,
SYSTEM_ABNORMAL _ID_MAX
};
4.37 震动录像 8042
#define WIFIAPP_CMD_ VIBRATION_VIDEO 8042
VIBRATION_VIDEO
enum _ VIBRATION_VIDEO
{
VIBRATION_VIDEO_OFF,
VIBRATION_VIDEO_ON,
VIBRATION_VIDEO_MAX
};
4.38 切换后摄像头 8043
#define WIFIAPP_CMD_ SWITCH_REAR 8043
SWITCH_REAR
参数:无
4.39 锁档百分比 8045
#define WIFIAPP_CMD_SOSMEMORY_PERCENT 8045
SOSMEMORY_PERCENT
enum _ SOSMEMORY_PERCENT
{
SOSMEMORY_PERCENT _1,
SOSMEMORY_PERCENT _20,
SOSMEMORY_PERCENT _30,
SOSMEMORY_PERCENT _50,
SOSMEMORY_PERCENT _ID_MAX
};
4.40 镜头旋转 9050
关闭(Off)、打开(On)
Command:http://192.168.1.254/?custom=1&cmd=9050&par=0
Parameter:0 设置为 关闭 1 设置为 打开
XML Return:
<xml version="1.0" encoding="UTF-8">
<Item>
<Cmd>9050</Cmd>
<Name>SENSOR_ROTATE</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
4.41 格式化提示设置 9051
Command:http://192.168.1.254/?custom=1&cmd= 9051&par=0
Parameter:0 设置为 关闭
1 设置为 1 Month
2 设置为 2 Month
3 设置为 3 Month
XML Return:
<Item>
<Cmd>9051</Cmd>
<Name>FORMAT_HINT</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>1 Month</Id>
</Option>
<Option>
<Index>2</Index>
<Id>2 Month</Id>
</Option>
<Option>
<Index>3</Index>
<Id>3 Month</Id>
</Option>
</MenuList>
</Item>
4.42 语音提示音 9052
关闭(Off)、打开(On)
Command:http://192.168.1.254/?custom=1&cmd= 9052&par=0
Parameter:0 设置为 关闭
1 设置为 打开2
XML Return:
<Item>
<Cmd>9052</Cmd>
<Name>SOUND_HINT</Name>
<MenuList>
<Option>
<Index>1</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
4.43 指示灯 9053
自动(Auto)、关闭(Off)、打开(On)
Command:http://192.168.1.254/?custom=1&cmd=9053&par=0
Parameter:0 设置为 自动
1 设置为 关闭
2 设置为 打开
XML Return:
<Item>
<Cmd>9053</Cmd>
<Name>FILL_LIGHT</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>AUTO</Id>
</Option>
<Option>
<Index>1</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>2</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
4.44 镜像开关 v
关闭(Off)、打开(On)
Command:http://192.168.1.254/?custom=1&cmd= 9054&par=0
Parameter:0 设置为 关闭 1 设置为 打开
XML Return:
<Item>
<Cmd>9054</Cmd>
<Name>SENSOR_Mirror</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>
</Option>
<Option>
<Index>1</Index>
<Id>ON</Id>
</Option>
</MenuList>
</Item>
4.45 加锁 9055
解锁(Deblocking)、加锁(Locking)
Command:http://192.168.1.254/?custom=1&cmd=9055&par=0
Parameter:0 设置为 解锁
1 设置为 加锁 XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9055</Cmd>
<Status>0</Status>
</Function>
3031指令增加
<Item>
<Cmd>9055</Cmd>
<Name>Lockr</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>Deblocking</Id>
</Option>
<Option>
<Index>1</Index>
<Id>Locking</Id>
</Option>
</MenuList>
</Item>
4.46 夏令时
关闭(Off)、打开(On)
Command:http://192.168.1.254/?custom=1&cmd=9056&par=0
Parameter:0 设置为 关闭 1 设置为 打开
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9056</Cmd>
<Status>0</Status>
</Function>
4.47 速度单位
Command:http://192.168.1.254/?custom=1&cmd=9057&par=0
Parameter:0 设置为 KNH
1 设置为 MPH
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9057</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>9057</Cmd>
<Name>Speed</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>KMH</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>MPH</Id>
</Option>
</MenuList>
</Item>
4.48 时区
Command:http://192.168.1.254/?custom=1&cmd=9058&par=0 XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9058</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Cmd>9058</Cmd>
<Name>TimeZone</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>GMT-12:00</Id>
</Option>
<Option>
<Index>1</Index>
<Id>GMT-11:00</Id>
</Option>
<Option>
<Index>2</Index>
<Id>GMT-10:00</Id>
</Option>
<Option>
<Index>3</Index>
<Id>GMT-9:00</Id>
</Option>
<Option>
<Index>4</Index>
<Id>GMT-8:00</Id>
</Option>
<Option>
<Index>5</Index>
<Id>GMT-7:00</Id>
</Option>
<Option>
<Index>6</Index>
<Id>GMT-6:00</Id>
</Option>
<Option>
<Index>7</Index>
<Id>GMT-5:00</Id>
</Option>
<Option>
<Index>8</Index>
<Id>GMT-4:00</Id>
</Option>
.
.
.
<Option>
<Index>23</Index>
<Id>GMT+11:00</Id>
</Option>
<Option>
<Index>24</Index>
<Id>GMT+12:00</Id>
</Option>
</MenuList>
</Item>
4.49 屏幕保护
Command:http://192.168.1.254/?custom=1&cmd=9060&par=0
Parameter:0 设置为 关闭 1 设置为 1分钟 2 设置为 3分钟
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9058</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>9060</Cmd>
<Name>ScreenSaver/Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>1Min</Id>
</Option>
<Option>
<Index>2</Index>-
<Id>3Min</Id>
</Option>
</MenuList>
</Item>
4.50 主屏幕显示
Command:http://192.168.1.254/?custom=1&cmd=9061&par=0
Parameter:0 设置为 显示时间
1 设置为 显示车速
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9061</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>9061</Cmd>
<Name>ScreenDisplay</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>Time</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>Speed</Id>
</Option>
</MenuList>
</Item>
4.51 超速行驶提醒
Command:http://192.168.1.254/?custom=1&cmd=9063&par=0
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9063</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>9063</Cmd>
<Name>Speed_Limit</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>30km/h</Id>
</Option>
<Option>
<Index>2</Index>
<Id>40km/h</Id>
</Option>
<Option>
<Index>3</Index>
<Id>50km/h</Id>
</Option>
<Index>4</Index>
<Id>60km/h</Id>
</Option>
<Option>
<Index>5</Index>
<Id>80km/h</Id>
</Option>
<Option>
<Index>6</Index>
<Id>90km/h</Id>
</Option>
</MenuList>
</Item>
4.52 疲劳驾驶提醒
Command:http://192.168.1.254/?custom=1&cmd=9066&par=0
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9066</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>9066</Cmd>
<Name>Fat_Dri_Rem</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>1Hour</Id>
</Option>
<Option>
<Index>2</Index>
<Id>2Hour</Id>
</Option>
<Option>
<Index>3</Index>
<Id>3Hour</Id>
</Option>
<Index>4</Index>
<Id41Hour</Id>
</Option>
<Option>
<Index>5</Index>
<Id>5Hour</Id>
</Option>
</MenuList>
</Item>
4.54 延时关机
Command:http://192.168.1.254/?custom=1&cmd=9065&par=0
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9065</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>9065</Cmd>
<Name>Delayed_Shutdown</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>1 minute/Id>
</Option>
<Option>
<Index>2</Index>
<Id>10 minute/Id>
</Option>
<Option>
<Index>3</Index>
<Id>30 minute</Id>
</Option>
</MenuList>
</Item>
4.54 缩时录影
Command:http://192.168.1.254/?custom=1&cmd=8002&par=0
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>8002</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>8002</Cmd>
<Name>Microfilm _Recording</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>OFF</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>4 Hour</Id>
</Option>
<Option>
<Index>2</Index>
<Id>8 Hour</Id>
</Option>
<Option>
<Index>3</Index>
<Id>12 Hour</Id>
</Option>
</Option>
<Option>
<Index>4</Index>
<Id>24 Hour</Id>
</Option>
</MenuList>
</Item>
4.55 语音音量(控制机器声音大小)
Command:http://192.168.1.254/?custom=1&cmd=9067&par=0
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9067</Cmd>
<Status>0</Status>
</Function>
3031返回增加
<Item>
<Cmd>9067</Cmd>
<Name>Voice_Volume</Name>
<MenuList>
<Option>
<Index>0</Index>
<Id>Hig</Id>-
</Option>
<Option>
<Index>1</Index>
<Id>Middle/Id>
</Option>
<Option>
<Index>2</Index>
<Id>Low</Id>
</Option>
<Option>
<Index>3</Index>
<Id>Off</Id>
</Option>
</MenuList>
</Item>
4.56 震动(控制机器是否发出震动)
Command:http://192.168.1.254/?custom=1&cmd=9068&par=0
Parameter:0 设置为 关 1 设置为 开
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9068</Cmd>
<Status>0</Status>
</Function>
4.57 后镜头曝光
Set Movie EV value.
Command: http://192.168.1.254/?custom=1&cmd=9069&par=6
Parameter: depend on project movie EV enumeration; current value as below
Reference Parameter
enum _EXPOSURE
{
EV_P20,
EV_P16,
EV_P13,
EV_P10,
EV_P06,
EV_P03,
EV_00,
EV_N03,
EV_N06,
EV_N10,
EV_N13,
EV_N16,
EV_N20,
EV_SETTING_MAX,
};
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9069</Cmd>
<Status>0</Status>
</Function>
4.58 声控(通过语音控制设备)
Command:http://192.168.1.254/?custom=1&cmd=9072&par=0
Parameter:0 设置为 关 1 设置为 开
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9072</Cmd>
<Status>0</Status>
</Function>
4.59 断开WiFi自动录像
Command:http://192.168.1.254/?custom=1&cmd=9070&par=0
Parameter:0 设置为 关 1 设置为 开
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9070</Cmd>
<Status>0</Status>
</Function>
4.60 切换自动录像
Command:http://192.168.1.254/?custom=1&cmd=9071&par=0
Parameter:0 设置为 关 1 设置为 开
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9071</Cmd>
<Status>0</Status>
</Function>
4.61 时速与经纬度浮水印(9072)
Command:http://192.168.1.254/?custom=1&cmd=9072&par=0
Parameter:0 设置为 关 1 设置为 开
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>9072</Cmd>
<Status>0</Status>
</Function>
附件-
8568 指令
固件查询是否可以跟app链接,固件绑定app,如果固件确认失败就不跟app想链接;
http://192.168.1.254/?custom=1&cmd=8568&str=param
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>8568</Cmd>
<Status>0</Status>
</Function>
Param:APP发送过来的数据;固件需要调用sunCheckDataValid(Param)函数判断这个数据是否合法,返回0,为合法,非零有问题;
sunCheckDataValid(Param):函数来源于通用gps库;
8569 获取设备支持功能集
http://192.168.1.254/?custom=1&cmd=8569
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>8569</Cmd>
<Status>0</Status>
<String>type:0;snap:1;gps:1;photo:1;lock:0;rtsp:0;playback:2;</String>
</Function>
8887 获取设备GPS信息
http://192.168.1.254/?custom=1&cmd=8887
XML Return:
<?xml version="1.0" encoding="UTF-8" ?>
<Function>
<Cmd>8887</Cmd>
<Status>0</Status>
<Signal>America#31:46,5,6;28:45,189,25;32:44,38,28;10:42,38,28;25:37,38,28;26:37,38,28;1:31,38,28;29:30,38,28;16:25,38,28;23:23,38,28;3:0,38,28;0:0,38,28$China#25:40,38,28;32:40,38,28;15:38,28,38;10:37,38,28;37:37,38,28;16:35,38,28;1:30,38,28;18:0,18,35;14:0,18,35;22:0,18,35;13:0,18,35;10:0,18,35</Signal>
<String>2014/04/24 21:21:05 N:22.93058 E:114.02580 H:17 25 km/h </string>
</Function>
备注 Signal
1.第一层级国家和国家之间用$进行数据分割
2.第二层级key(国家)和value(数据值,卫星数据用分号(;)分割)用#进行数据分割
3.第三层级的key(卫星编号)和value(信号值,方位角,高度角)用:进行数据分割