|
|
@@ -15,20 +15,24 @@ curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d
|
|
|
// 保存日志设置
|
|
|
curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"basic.saveLogConf","params":{},"id":5}'
|
|
|
|
|
|
+// 获取网口相机
|
|
|
+// 返回: "enable'为"true"时表示已供电, "false"时表示未供电
|
|
|
+curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.getGigeCameraPower","params":{},"id":6}'
|
|
|
+
|
|
|
// 打开网口相机
|
|
|
// 参数: "true"-网口相机供电; "false"-网口相机断电
|
|
|
-curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.setGigeCameraPower","params":{"enable":"true"},"id":6}'
|
|
|
+curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.setGigeCameraPower","params":{"enable":"true"},"id":7}'
|
|
|
|
|
|
// PING网口相机
|
|
|
// 参数:目前固定网口相机的IP地址: 192.168.100.100/24
|
|
|
-curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.checkGigeCamera","params":{"ip":"192.168.100.100", "prefix": "24"},"id":7}'
|
|
|
+curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.checkGigeCamera","params":{"ip":"192.168.100.100", "prefix": "24"},"id":8}'
|
|
|
|
|
|
// 得到相机数量
|
|
|
// 参数: 海康-"hk"; 大华-"dh"; 所有-"all"
|
|
|
-curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.getSupportedCameraCount","params":{"type":"all"},"id":8}'
|
|
|
+curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.getSupportedCameraCount","params":{"type":"all"},"id":9}'
|
|
|
|
|
|
// 相机处于自动曝光模式时, 设置是否等待曝光稳定后再拍照, 参数: waitAE: 0=不等待, 1=等待(默认)
|
|
|
-curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.setWaitAEDoneForTakePhoto","params":{"waitAE":"1"},"id":9}'
|
|
|
+curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.setWaitAEDoneForTakePhoto","params":{"waitAE":"1"},"id":10}'
|
|
|
|
|
|
// 请求相机拍照
|
|
|
-curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.takePhoto","params":{"format":"jpg", "outFilename":"./test.jpg", "timeoutMs":"300"},"id":10}'
|
|
|
+curl -s -X POST http://127.0.0.1:7003/rpc -H "Content-Type: application/json" -d '{"jsonrpc":"2.0","method":"core.takePhoto","params":{"format":"jpg", "outFilename":"/tmp/test.jpg", "timeoutMs":"300"},"id":11}'
|