From a92ce0afa104b34d7d3c26833239aeed9711c824 Mon Sep 17 00:00:00 2001 From: John Klug Date: Mon, 18 Mar 2019 10:38:41 -0500 Subject: Fix cold boot issue with vizzini driver and gpsd --- recipes-navigation/gpsd/gpsd/gpsd-default | 14 ++++++++++---- recipes-navigation/gpsd/gpsd_3.18.1.bb | 2 +- 2 files changed, 11 insertions(+), 5 deletions(-) (limited to 'recipes-navigation') diff --git a/recipes-navigation/gpsd/gpsd/gpsd-default b/recipes-navigation/gpsd/gpsd/gpsd-default index 168b0cf..3450731 100644 --- a/recipes-navigation/gpsd/gpsd/gpsd-default +++ b/recipes-navigation/gpsd/gpsd/gpsd-default @@ -51,16 +51,22 @@ GPSFIX="3" # function SET_GPS_SPEED { if [[ $(cat /run/config/gpstype) == u-blox ]] ; then - logger -t gpsd -p daemon.info "Attempting to set baud rate to ${GPS_BAUD}" + logger -st gpsd -p daemon.info "Attempting to set baud rate to ${GPS_BAUD}" if ! gpsctl -T 20 -t u-blox -s $GPS_BAUD -b -f $GPS_LINE ; then - logger -t gpsd -p daemon.info "WARNING: Unable to set GPS serial port speed." + logger -st gpsd -p daemon.warning "Unable to set GPS serial port speed." stty -F $GPS_LINE 9600 + sleep 1 if ! gpsctl -T 20 -t u-blox -s $GPS_BAUD -b -f $GPS_LINE ; then - logger -t gpsd -p daemon.info "WARNING: Unable to set GPS serial port speed." + logger -st gpsd -p daemon.warning "Unable to set GPS serial port speed." + stty -F $GPS_LINE $GPS_BAUD + sleep 1 + if ! gpsctl -T 20 -t u-blox -s $GPS_BAUD -b -f $GPS_LINE ; then + logger -st gpsd -p daemon.warning "Unable to set GPS serial port speed -- giving up!" + fi fi fi stty -F $GPS_LINE $GPS_BAUD - logger -t gpsd -p daemon.info "Expect a timeout error here. Need this error." + logger -st gpsd -p daemon.info "Expect a timeout error here. Need this error." gpsctl -T 2 -f $GPS_LINE stty -F $GPS_LINE $GPS_BAUD fi diff --git a/recipes-navigation/gpsd/gpsd_3.18.1.bb b/recipes-navigation/gpsd/gpsd_3.18.1.bb index 5793344..975482c 100644 --- a/recipes-navigation/gpsd/gpsd_3.18.1.bb +++ b/recipes-navigation/gpsd/gpsd_3.18.1.bb @@ -4,7 +4,7 @@ LICENSE = "BSD" LIC_FILES_CHKSUM = "file://COPYING;md5=d217a23f408e91c94359447735bc1800" DEPENDS = "dbus dbus-glib ncurses python libusb1 chrpath-replacement-native pps-tools" PROVIDES = "virtual/gpsd" -PR="m5" +PR="m6" EXTRANATIVEPATH += "chrpath-native" -- cgit v1.2.3