Skip to content

Commit

Permalink
Workaround for apparent ASI SDK 1.31 and 1.32 bug that gives bogus de…
Browse files Browse the repository at this point in the history
…fault values for GPS controls on cameras that don't have GPS and fails to complete exposures if the value is written back. More discussion on the issue at indilib#867
  • Loading branch information
jpaana committed Dec 20, 2023
1 parent 85b986c commit 0678139
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions indi-asi/asi_base.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1436,6 +1436,13 @@ void ASIBase::createControls(int piNumberOfControls)
ASI_BOOL isAuto = ASI_FALSE;
ASIGetControlValue(mCameraInfo.CameraID, cap.ControlType, &value, &isAuto);

// Workaround for apparent ASI SDK 1.31 and 1.32 bug that gives bogus default values for GPS
// controls on cameras that don't have GPS and fails to complete exposures if the value is written back.
if (cap.ControlType == ASI_GPS_START_LINE || cap.ControlType == ASI_GPS_END_LINE)
{
value = 0;
}

if (cap.IsWritable)
{
LOGF_DEBUG("Adding above control as writable control number %d.", ControlNP.size());
Expand Down

0 comments on commit 0678139

Please sign in to comment.