diff options
author | Suren A. Chilingaryan <csa@dside.dyndns.org> | 2011-12-12 10:29:52 +0100 |
---|---|---|
committer | Suren A. Chilingaryan <csa@dside.dyndns.org> | 2011-12-12 10:29:52 +0100 |
commit | d1a0a2e0322e6c5b05ba7817c1c0405dc20e5414 (patch) | |
tree | 2e42a1b869eae7281d040ce9d56baf2e2998e19b | |
parent | 9a51195b1ce73005e87c00448c908286fb5c07d7 (diff) | |
download | ipecamera-d1a0a2e0322e6c5b05ba7817c1c0405dc20e5414.tar.gz ipecamera-d1a0a2e0322e6c5b05ba7817c1c0405dc20e5414.tar.bz2 ipecamera-d1a0a2e0322e6c5b05ba7817c1c0405dc20e5414.tar.xz ipecamera-d1a0a2e0322e6c5b05ba7817c1c0405dc20e5414.zip |
Increase event timeout for large trigger times
-rw-r--r-- | cli.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1339,6 +1339,12 @@ int TriggerAndGrab(pcilib_t *handle, GRAB_MODE grab_mode, const char *evname, co ctx.max_triggers = num; ctx.trigger_count = 0; ctx.trigger_time = trigger_time; + + + if ((timeout)&&(trigger_time * 2 > timeout)) { + timeout = 2 * trigger_time; + ctx.timeout = timeout; + } // We don't really care if RT priority is imposible pthread_attr_init(&attr); |