Skip to content

Commit

Permalink
Bug fix only first focuser is visible
Browse files Browse the repository at this point in the history
Due to the underlying device name setting, the fact that FocusLynx
has two independent drivers, its name setting does not work. With
this fix the device names of the two focusers are fix to FocusLynx F1/F2.
  • Loading branch information
Wolfgang Reissenberger committed Sep 26, 2023
1 parent ff8656b commit bfce81f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/focuser/focuslynx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ FocusLynxF1::FocusLynxF1(const char *target)
* F1 or F2 to set the target of the created instance
*/
setFocusTarget(target);
// set the focuser name to a fixed value to ensure that both focusers are visible
setDeviceName(FocusLynxF1::getDefaultName());

// Both communication available, Serial and network (tcp/ip)
setSupportedConnections(CONNECTION_SERIAL | CONNECTION_TCP);
Expand Down Expand Up @@ -752,6 +754,8 @@ void FocusLynxF1::setDebug(bool enable)
FocusLynxF2::FocusLynxF2(const char *target)
{
setFocusTarget(target);
// set the focuser name to a fixed value to ensure that both focusers are visible
setDeviceName(FocusLynxF2::getDefaultName());

// The second focuser has no direct communication with the hub
setSupportedConnections(CONNECTION_NONE);
Expand Down

0 comments on commit bfce81f

Please sign in to comment.