串口拍照完毕后自动延时关闭电源

N938
XI.CHEN 6 months ago
parent 9767036d54
commit a282111810

@ -337,7 +337,6 @@ void GpioControl::PowerControlThreadProc()
if (it->references == 0) if (it->references == 0)
{ {
// Should turn off the power // Should turn off the power
time_t tt = it->closeTime;
if ((it->closeTime == 0) || (it->closeTime <= ts)) if ((it->closeTime == 0) || (it->closeTime <= ts))
{ {
// close it directly // close it directly

@ -1746,6 +1746,8 @@ bool CPhoneDevice::TakePhoto(const IDevice::PHOTO_INFO& photoInfo, const vector<
CameraPhotoCmd(ts, localPhotoInfo.channel, 0, localPhotoInfo.resolution, 0, param.serfile, param.baud, param.addr); CameraPhotoCmd(ts, localPhotoInfo.channel, 0, localPhotoInfo.resolution, 0, param.serfile, param.baud, param.addr);
XYLOG(XYLOG_SEVERITY_INFO, "Taking photo over"); XYLOG(XYLOG_SEVERITY_INFO, "Taking photo over");
pThis->TakePTZPhotoCb(3, localPhotoInfo); pThis->TakePTZPhotoCb(3, localPhotoInfo);
pThis->ClosePTZSensors(localPhotoInfo.closeDelayTime);
GpioControl::setCam3V3Enable(false, localPhotoInfo.closeDelayTime);
}); });
t.detach(); t.detach();

Loading…
Cancel
Save