canon_ble #82

Merged
mattmcw merged 149 commits from canon_ble into main 2023-08-01 03:38:52 +00:00
1 changed files with 13 additions and 3 deletions
Showing only changes of commit 699c2dbec8 - Show all commits

View File

@ -91,13 +91,23 @@ cam.end = function (c, id, ms) {
}
};
cam.exposure = function (exposure) {
cam.exposure = async function (exposure) {
var obj = {
id : uuid(),
exposure
};
var change = false;
try {
change = await gui.confirm(`Are you sure you want to set camera exposure to ${exposure}ms?`);
} catch (err) {
log.error(err);
}
if (change) {
log.info(`Setting exposure: ${exposure}`);
ipcRenderer.sendSync(cam.id, obj);
} else {
timing.updateUI('#cam_time', timing.data['cam']);
}
}
cam.listen = function () {