From 6234b68b7e2769c7fa74093b05a9baaf11e7e738 Mon Sep 17 00:00:00 2001 From: Elijah Parker Date: Thu, 4 Aug 2022 16:05:22 -0500 Subject: [PATCH] adding Sony A7IV --- camera/ptpjs/drivers/olympus.js | 3 ++- camera/ptpjs/drivers/sony.js | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/camera/ptpjs/drivers/olympus.js b/camera/ptpjs/drivers/olympus.js index 231a8274..24c12519 100644 --- a/camera/ptpjs/drivers/olympus.js +++ b/camera/ptpjs/drivers/olympus.js @@ -34,7 +34,7 @@ function exposureEvent(camera) { if(!camera._expCache) camera._expCache = {}; var update = false; for(var k in camera.exposure) { - if(camera.exposure[k].ev != camera._expCache[k]) { + if(camera.exposure[k] && camera.exposure[k].ev != camera._expCache[k]) { camera._expCache[k] = camera.exposure[k].ev; update = true; } @@ -1078,6 +1078,7 @@ driver.setFocusPoint = function(camera, x, y, callback) { driver.setLiveviewSize = function(camera, w, h, callback) { var liveviewSize = camera.config.liveviewSize; + if(!liveviewSize) return callback && callback("not supported"); liveviewSize.x = w; liveviewSize.y = h; var newSize = (w << 16) | h; diff --git a/camera/ptpjs/drivers/sony.js b/camera/ptpjs/drivers/sony.js index c2dc219a..b9849270 100644 --- a/camera/ptpjs/drivers/sony.js +++ b/camera/ptpjs/drivers/sony.js @@ -69,6 +69,7 @@ driver.supportedCameras = { '054c:0d2b': { name: "Sony A7C", supports: { shutter: true, aperture: true, iso: true, liveview: true, destination: true, focus: true, _bufTime: 2500, newISO: true } }, '054c:0d9f': { name: "Sony A7R IV A", supports: { shutter: true, aperture: true, iso: true, liveview: true, destination: true, focus: true, _bufTime: 2500, newISO: true } }, '054c:0da3': { name: "Sony FX3", supports: { shutter: true, aperture: true, iso: true, liveview: true, destination: true, focus: true, _bufTime: 2500, newISO: true } }, + '054c:0da7': { name: "Sony A7 IV", supports: { shutter: true, aperture: true, iso: true, liveview: true, destination: true, focus: true, _bufTime: 2500, newISO: true } }, } var properties = {