diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 0e32becad..74ddda8ea 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -1868,7 +1868,7 @@ int icom_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) if (mode_len == 3) { - priv_data->filter = modebuf[2] - '0'; + priv_data->filter = modebuf[2]; rig_debug(RIG_DEBUG_TRACE, "%s: modebuf[0]=0x%02x, modebuf[1]=0x%02x, modebuf[2]=0x%02x, mode_len=%d, filter=%d\n", __func__, modebuf[0], diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 9120c3643..b93aab6c1 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -203,7 +203,7 @@ struct icom_priv_data int x25cmdfails; // This will get set if the 0x25 command fails so we try just once int x1cx03cmdfails; // This will get set if the 0x1c 0x03 command fails so we try just once int poweron; // to prevent powering on more than once - int filter; // Current filter selected + unsigned char filter; // Current filter selected }; extern const struct ts_sc_list r8500_ts_sc_list[];