Skip to content

Commit

Permalink
Separate ZWO AM5 into 2 different aliases for WiFi and USB to make it…
Browse files Browse the repository at this point in the history
… easier for 1st time connections
  • Loading branch information
knro committed Jan 19, 2024
1 parent 4625cf2 commit 7837566
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
10 changes: 7 additions & 3 deletions drivers.xml
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,14 @@
<driver name="Pegasus NYX-101">indi_lx200_pegasus_nyx101</driver>
<version>2.1</version>
</device>
<device label="ZWO AM5" manufacturer="ZWO">
<device label="ZWO AM5 WiFi" manufacturer="ZWO">
<driver name="ZWO AM5">indi_lx200am5</driver>
<version>1.0</version>
</device>
<version>1.1</version>
</device>
<device label="ZWO AM5 USB" manufacturer="ZWO">
<driver name="ZWO AM5">indi_lx200am5</driver>
<version>1.1</version>
</device>
<device label="Celestron GPS" manufacturer="Celestron">
<driver name="Celestron GPS">indi_celestron_gps</driver>
<version>3.6</version>
Expand Down
6 changes: 4 additions & 2 deletions drivers/telescope/lx200am5.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@

LX200AM5::LX200AM5()
{
setVersion(1, 0);
setVersion(1, 1);

setLX200Capability(LX200_HAS_PULSE_GUIDING);

Expand All @@ -60,7 +60,9 @@ bool LX200AM5::initProperties()
tcpConnection->setDefaultHost("192.168.4.1");
tcpConnection->setDefaultPort(4030);
tcpConnection->setLANSearchEnabled(true);
setActiveConnection(tcpConnection);

if (strstr(getDeviceName(), "WiFi"))
setActiveConnection(tcpConnection);

///////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Properties
Expand Down

0 comments on commit 7837566

Please sign in to comment.