Re: ESP32-CAM ov2640 exposure control/FREX mode
Posted: Thu Jul 18, 2019 9:05 pm
I did new frame capture, with mostly same settings, but this time with "Wait for next VSYNC" enabled:
This was the captured frame after I clicked "doit" button:
These were the last two rows of Arduino IDE "serial Monitor" output:
In difference to yesterday, today we know exactly when the 1.05ms time frame of the two 50µs long flashes happened:
Because of "Waiting for next VSYNC" at the very beginning of capturing 2nd last 161ms frame.
Since the 170ms offset reaches into next (last) frame it seems that the missing top part of global shutter propeller is the area of last frame that was already captured (rolling shutter) for last frame, before stopping the stream is initiated (this is the browser code executed when clicking on "doit"):
I expected now, that capturing with these settings would be completely recreatable.
But that was not the case.
Time for sending the updateConfig http requests might differ (Wifi).
Sleeping is done in browser, not sure how precisely timewise recreatable the actual start of the sleep is.
Also the waiting for VSYNC is executed on ESP32, while the wait and stop stream happen in browser.
This was the captured frame after I clicked "doit" button:
These were the last two rows of Arduino IDE "serial Monitor" output:
Code: Select all
...
MJPG: 20556B 161ms (6.2fps), AVG: 155ms (6.5fps), 0+0+0+0=0 0
MJPG: 21333B 161ms (6.2fps), AVG: 156ms (6.4fps), 0+0+0+0=0 0
Because of "Waiting for next VSYNC" at the very beginning of capturing 2nd last 161ms frame.
Since the 170ms offset reaches into next (last) frame it seems that the missing top part of global shutter propeller is the area of last frame that was already captured (rolling shutter) for last frame, before stopping the stream is initiated (this is the browser code executed when clicking on "doit"):
Code: Select all
async function doit(ms) {
updateConfig(ges_vsync_value)
updateConfig(doitButton)
await sleep(ms)
stopStream();
}
But that was not the case.
Time for sending the updateConfig http requests might differ (Wifi).
Sleeping is done in browser, not sure how precisely timewise recreatable the actual start of the sleep is.
Also the waiting for VSYNC is executed on ESP32, while the wait and stop stream happen in browser.