Use the Source, Luke! (2)

IC-7410product

So let’s see how IC-7410 is supported by Hamlib.

% dpkg -l | grep hamlib
ii  libhamlib-dev   1.2.15.3-1ubuntu4 amd64 Development library to control radio transceivers and receivers
ii  libhamlib-utils 1.2.15.3-1ubuntu4 amd64 Utilities to support the hamlib radio control library
ii  libhamlib2      1.2.15.3-1ubuntu4 amd64 Run-time library to control radio transceivers and receivers

First, we have to download the source code from here.

% ls -l ~/Downloads/hamlib-1.2.15.3/icom/*.h
-rw-r--r-- 1 user1 user1  1507 11月  2  2012 icom/frame.h
-rw-r--r-- 1 user1 user1  9525 11月  2  2012 icom/icom.h
-rw-r--r-- 1 user1 user1 14342 11月  2  2012 icom/icom_defs.h
-rw-r--r-- 1 user1 user1  2208 11月  2  2012 icom/optoscan.h

% ls ~/Downloads/hamlib-1.2.15.3/icom/*.c
delta2.c  ic471.c   ic707.c   ic728.c  ic7410.c  ic761.c   ic7800.c  ic9100.c  icr20.c    icr8500.c  omni.c
frame.c   ic475.c   ic718.c   ic735.c  ic746.c   ic765.c   ic781.c   ic92d.c   icr7000.c  icr9000.c  optoscan.c
ic1275.c  ic7000.c  ic7200.c  ic736.c  ic751.c   ic7700.c  ic820h.c  ic970.c   icr71.c    icr9500.c  os456.c
ic271.c   ic703.c   ic725.c   ic737.c  ic756.c   ic775.c   ic821h.c  icom.c    icr72.c    icrx7.c    os535.c
ic275.c   ic706.c   ic726.c   ic738.c  ic7600.c  ic78.c    ic910.c   icr10.c   icr75.c    id1.c

A little bit surprising, because I thought all the rig dependent definitions are in ic*.h

 % wc *.h ic7410.c
   38   234  1507 frame.h
  252  1273  9525 icom.h
  394  2271 14342 icom_defs.h
   65   289  2208 optoscan.h
  233   751  7880 ic7410.c
% cat ic7410.c     <--- excerpt

/*
 *  Hamlib CI-V backend - description of IC-7410
 *  Copyright (c) 2011 by Stephane Fillod
 */

/*
 * Guess from IC7600
 */
#define IC7410_STR_CAL { 16, \
        { \
        {   0, -54 }, /* S0 */ \
        { 124,   0 }, /* S9 */ \
        { 246,  60 } /* S9+60dB */  \
        } }

/*
 * IC-7410 rig capabilities.
 *
 * TODO: complete command set (esp. the $1A bunch!) and testing..
 */
static const struct icom_priv_caps ic7410_priv_caps = {
                0x80,   /* default address */
                0,              /* 731 mode */
                ic756pro_ts_sc_list
};

Note that the source code is also available at:
https://github.com/N0NB/hamlib/blob/master/icom/ic7410.c

% cat icom_defs.h     <--- excerpt
/*
 *  Hamlib CI-V backend - defines for the ICOM "CI-V" interface.
 *  Copyright (c) 2000-2010 by Stephane Fillod
 */

/*
 * Set mode data (C_SET_MODE) sub commands
 */
#define S_LSB   0x00            /* Set to LSB */
#define S_USB   0x01            /* Set to USB */
#define S_AM    0x02            /* Set to AM */
#define S_CW    0x03            /* Set to CW */
#define S_RTTY  0x04            /* Set to RTTY */
#define S_FM    0x05            /* Set to FM */
#define S_WFM   0x06            /* Set to Wide FM */
#define S_CWR   0x07            /* Set to CW Reverse */
#define S_RTTYR 0x08            /* Set to RTTY Reverse */
#define S_AMS   0x11            /* Set to AMS */
#define S_PSK   0x12            /* 7800 PSK USB */
#define S_PSKR  0x13            /* 7800 PSK LSB */

/* filter width coding for newer ICOM rigs with 3 filter width */
#define PD_WIDE_3       0x01    /* Wide */
#define PD_MEDIUM_3     0x02    /* Medium */
#define PD_NARROW_3     0x03    /* Narrow */

The above definitions match well with the following descriptions in the operation manual:

icomremote

http://www.icom.co.jp/world/support/download/manual/pdf/IC-7410_ENG_1.pdf

Now that you have the source, if anything goes wrong, it’s your fault!