Skip to content

Commit a38856e

Browse files
thatcomputerguy0101cswilson252
authored andcommitted
Set raw exposure before setting auto exposure (PhotonVision#2429)
On a Luma P1, autoexposure on first boot was getting overridden with the manual exposure setting. This was traced back to PhotonVision#1814, where the order of setting auto exposure and raw exposure was flipped. This flips it back.
1 parent 4af2b63 commit a38856e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

photon-core/src/main/java/org/photonvision/vision/processes/VisionModule.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -465,13 +465,13 @@ boolean setPipeline(int index) {
465465
pipelineSettings.cameraExposureRaw = 10; // reasonable default
466466
}
467467

468+
settables.setExposureRaw(pipelineSettings.cameraExposureRaw);
468469
try {
469470
settables.setAutoExposure(pipelineSettings.cameraAutoExposure);
470471
} catch (VideoException e) {
471472
logger.error("Unable to set camera auto exposure!");
472473
logger.error(e.toString());
473474
}
474-
settables.setExposureRaw(pipelineSettings.cameraExposureRaw);
475475
if (cameraQuirks.hasQuirk(CameraQuirk.Gain)) {
476476
// If the gain is disabled for some reason, re-enable it
477477
if (pipelineSettings.cameraGain == -1) pipelineSettings.cameraGain = 75;

0 commit comments

Comments
 (0)