diff options
author | Suren A. Chilingaryan <csa@suren.me> | 2014-01-28 12:21:35 +0100 |
---|---|---|
committer | Suren A. Chilingaryan <csa@suren.me> | 2014-01-28 12:21:35 +0100 |
commit | f83e1d4082d4a7b5802ca665acab088dcea52863 (patch) | |
tree | 9e570a9912a98e627c862448f6396a8fcdd7eff5 | |
parent | 0f41a2e0c38d66dc6af89d3a59a573b9a38f7ceb (diff) | |
download | ipecamera-f83e1d4082d4a7b5802ca665acab088dcea52863.tar.gz ipecamera-f83e1d4082d4a7b5802ca665acab088dcea52863.tar.bz2 ipecamera-f83e1d4082d4a7b5802ca665acab088dcea52863.tar.xz ipecamera-f83e1d4082d4a7b5802ca665acab088dcea52863.zip |
Properly support triggering with new revision of UFO camera
-rw-r--r-- | ipecamera/ipecamera.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ipecamera/ipecamera.c b/ipecamera/ipecamera.c index 54df33f..605d733 100644 --- a/ipecamera/ipecamera.c +++ b/ipecamera/ipecamera.c @@ -647,11 +647,12 @@ int ipecamera_trigger(pcilib_context_t *vctx, pcilib_event_t event, size_t trigg GET_REG(status3_reg, value); } while (value&0x20000000); */ - - SET_REG(control_reg, IPECAMERA_FRAME_REQUEST|IPECAMERA_READOUT_FLAG); + + GET_REG(control_reg, value); + SET_REG(control_reg, value|IPECAMERA_FRAME_REQUEST); usleep(IPECAMERA_WAIT_FRAME_RCVD_TIME); //CHECK_REG(status_reg, IPECAMERA_EXPECTED_STATUS); - SET_REG(control_reg, IPECAMERA_IDLE|IPECAMERA_READOUT_FLAG); + SET_REG(control_reg, value); pcilib_calc_deadline(&ctx->next_trigger, IPECAMERA_NEXT_FRAME_DELAY); |