diff options
Diffstat (limited to 'recipes-bsp/multitech/mts-io/mts-io.init')
-rw-r--r-- | recipes-bsp/multitech/mts-io/mts-io.init | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/recipes-bsp/multitech/mts-io/mts-io.init b/recipes-bsp/multitech/mts-io/mts-io.init index ee127a5..c3c3216 100644 --- a/recipes-bsp/multitech/mts-io/mts-io.init +++ b/recipes-bsp/multitech/mts-io/mts-io.init @@ -184,10 +184,13 @@ mfser_init() { set_gpslink() { hw=$(${SYSFS} show hw-version) + # hw_name is the hw-version before the hyphen. hw_name=(${hw//-/ }) gpscap=$(cat ${sysdir}/capability/gps) - - if ((gpscap == 0)) ; then + + # For all hardware except MTCDTIPHP, the gpscapability + # flag indicates whether or not we have a GPS. + if ! [[ ${hw_name} =~ ^MTCDTIPHP$ ]] && ((gpscap == 0)) ; then return fi @@ -201,10 +204,6 @@ set_gpslink() { return fi - if [[ ${hw} == MTCDT ]] && [[ ${HWLVL} == 0.0 ]] ; then - # No GPS - return - fi if [[ ${hw_name} == MTCDTIPHP ]] ; then NEED_I2C_RESET=1 ln -sf /dev/ttyXRUSB0 /dev/gps0 |