summaryrefslogtreecommitdiff
path: root/recipes-bsp
diff options
context:
space:
mode:
authorJohn Klug <john.klug@multitech.com>2021-09-23 06:17:16 -0500
committerJohn Klug <john.klug@multitech.com>2021-10-05 14:40:49 -0500
commitae5e958a7214588a3c5bb4fe0604af9c8b848187 (patch)
tree92503328e717eab6c996673cb87df4f046159e71 /recipes-bsp
parent734b8c4be86d4472ebc8ad408265d8d3ef890b34 (diff)
downloadmeta-multitech-ae5e958a7214588a3c5bb4fe0604af9c8b848187.tar.gz
meta-multitech-ae5e958a7214588a3c5bb4fe0604af9c8b848187.tar.bz2
meta-multitech-ae5e958a7214588a3c5bb4fe0604af9c8b848187.zip
mts-io init script must set serial link even when there is no GPS
Diffstat (limited to 'recipes-bsp')
-rw-r--r--recipes-bsp/multitech/mts-io.inc2
-rwxr-xr-xrecipes-bsp/multitech/mts-io/mts-io.init33
2 files changed, 22 insertions, 13 deletions
diff --git a/recipes-bsp/multitech/mts-io.inc b/recipes-bsp/multitech/mts-io.inc
index 8caf810..a00f9aa 100644
--- a/recipes-bsp/multitech/mts-io.inc
+++ b/recipes-bsp/multitech/mts-io.inc
@@ -7,7 +7,7 @@ LIC_FILES_CHKSUM = "file://io-module/COPYING;md5=94d55d512a9ba36caa9b7df079bae19
file://io-tool/COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
"
do_fetch[depends] += "virtual/kernel:do_shared_workdir"
-INC_PR = "r1"
+INC_PR = "r2"
SRCREV = "${PV}"
PR = "${INC_PR}.0"
diff --git a/recipes-bsp/multitech/mts-io/mts-io.init b/recipes-bsp/multitech/mts-io/mts-io.init
index 3aa76af..ed0475e 100755
--- a/recipes-bsp/multitech/mts-io/mts-io.init
+++ b/recipes-bsp/multitech/mts-io/mts-io.init
@@ -250,34 +250,43 @@ set_links() {
[[ -d /var/run/config ]] || mkdir /var/run/config
gpscap=$(cat ${sysdir}/capability/gps)
- # 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
-
+
# Oldest MTRV1 uses venus on ttyS1.
# Newest MTRV1 usus U-Blox on ttyS1.
if [[ ${hw_name} == MTRV1 ]] ; then
case "${hw}" in
MTRV1-0.0)
- ln -sf /dev/ttyS1 /dev/gps0
- echo "venus" >"$GPSCONFIGTYPE"
+ if ((gpscap == 1)) ; then
+ ln -sf /dev/ttyS1 /dev/gps0
+ echo "venus" >"$GPSCONFIGTYPE"
+ fi
return
;;
MTRV1-0.1|MTRV1-0.2|MTRV1-0.3)
- ln -sf /dev/ttyXRUSB0 /dev/gps0
- echo "u-blox" >"$GPSCONFIGTYPE"
+ if ((gpscap == 1)) ; then
+ ln -sf /dev/ttyXRUSB0 /dev/gps0
+ echo "u-blox" >"$GPSCONFIGTYPE"
+ fi
return
;;
*)
- ln -sf /dev/ttyS1 /dev/gps0
+ if ((gpscap == 1)) ; then
+ ln -sf /dev/ttyS1 /dev/gps0
+ echo "u-blox" >"$GPSCONFIGTYPE"
+ fi
ln -sf /dev/ttyS4 /dev/ext_serial
- echo "u-blox" >"$GPSCONFIGTYPE"
return
;;
esac
fi # MTRV1 hardware version name
+
+ # Continue with non-MTRV1 hardware.
+
+ # For all other hardware except MTCDTIPHP, the gpscapability
+ # flag indicates whether or not we have a GPS.
+ if ! [[ ${hw_name} =~ ^MTCDTIPHP$ ]] && ((gpscap == 0)) ; then
+ return
+ fi
case ${hw_name} in
MTR|MTHS)