kopia lustrzana https://github.com/Hamlib/Hamlib
use ptt port pathname same as rig port pathname when unset and rig is type serial
git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@2915 7ae35d74-ebe9-4afe-98af-79ac388436b8Hamlib-1.2.11
rodzic
cccd274baa
commit
6feb18f611
|
@ -474,6 +474,9 @@ int HAMLIB_API rig_open(RIG *rig)
|
||||||
break;
|
break;
|
||||||
case RIG_PTT_SERIAL_RTS:
|
case RIG_PTT_SERIAL_RTS:
|
||||||
case RIG_PTT_SERIAL_DTR:
|
case RIG_PTT_SERIAL_DTR:
|
||||||
|
if (rs->pttport.pathname[0] == '\0' &&
|
||||||
|
rs->rigport.type.rig == RIG_PORT_SERIAL)
|
||||||
|
strcpy(rs->pttport.pathname, rs->rigport.pathname);
|
||||||
rs->pttport.fd = ser_open(&rs->pttport);
|
rs->pttport.fd = ser_open(&rs->pttport);
|
||||||
if (rs->pttport.fd < 0)
|
if (rs->pttport.fd < 0)
|
||||||
rig_debug(RIG_DEBUG_ERR, "Cannot open PTT device \"%s\"\n",
|
rig_debug(RIG_DEBUG_ERR, "Cannot open PTT device \"%s\"\n",
|
||||||
|
@ -499,6 +502,9 @@ int HAMLIB_API rig_open(RIG *rig)
|
||||||
case RIG_DCD_SERIAL_DSR:
|
case RIG_DCD_SERIAL_DSR:
|
||||||
case RIG_DCD_SERIAL_CTS:
|
case RIG_DCD_SERIAL_CTS:
|
||||||
case RIG_DCD_SERIAL_CAR:
|
case RIG_DCD_SERIAL_CAR:
|
||||||
|
if (rs->dcdport.pathname[0] == '\0' &&
|
||||||
|
rs->rigport.type.rig == RIG_PORT_SERIAL)
|
||||||
|
strcpy(rs->dcdport.pathname, rs->rigport.pathname);
|
||||||
rs->dcdport.fd = ser_open(&rs->dcdport);
|
rs->dcdport.fd = ser_open(&rs->dcdport);
|
||||||
if (rs->dcdport.fd < 0)
|
if (rs->dcdport.fd < 0)
|
||||||
rig_debug(RIG_DEBUG_ERR, "Cannot open DCD device \"%s\"\n",
|
rig_debug(RIG_DEBUG_ERR, "Cannot open DCD device \"%s\"\n",
|
||||||
|
|
Ładowanie…
Reference in New Issue