Since firmware 10.43, an IQ on screen when you start Position.enableLocationEvents(options, method(:setPosition));

Hi I have several issue in ERA (and user mail) because since new firmware 10.43, my application AVIONIQ has an IQ on start.

All is good before 10.43;

For these watches monkeyVers>=336

It's Error Name: Unhandled Exception
Occurrences: 2
First Occurrence: 2022-11-22
Last Occurrence: 2022-11-22
Devices:
 D2Tm Mach 1: 10.43
App Versions: 4.4.0
Languages: eng
Backtrace:
GenView.initializeGPS:250  it's  Position.enableLocationEvents(options, method(:setPosition));

I don't understand why this situation with new firmware 10.43

Can you help me

My code is

function initializeGPS(){

 
  ModeGPS = getSpecialProperty(0,"ModeGPS",3);    // a special function to get the settings.  default is 3 so GPS+ GALILELO
 
                                                System.println(
                                                " initializeGPS monkeyVers="+monkeyVers + "\n"+
                                                " ModeGPS="+ModeGPS  + "\n"+
                                                " CONFIGURATION_GPS="+ (Position has :CONFIGURATION_GPS) + "\n"+
                                                " CONFIGURATION_GPS_GLONASS="+ (Position has :CONFIGURATION_GPS_GLONASS)+"\n"+
                                                " CONFIGURATION_GPS_GALILEO="+ (Position has :CONFIGURATION_GPS_GALILEO)+"\n"+
                                                " CONFIGURATION_GPS_BEIDOU="+ (Position has :CONFIGURATION_GPS_BEIDOU)+"\n"+
                                                " CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1="+ (Position has :CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1)+"\n"+
                                                " CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1_L5="+ (Position has :CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1_L5)+"\n"+
                                                " CONFIGURATION_SAT_IQ="+ (Position has :CONFIGURATION_SAT_IQ) +"\n"+
                                                " CONSTELLATION_GPS="+ (Position has :CONSTELLATION_GPS) +"\n"+
                                                " CONSTELLATION_GLONASS="+ (Position has :CONSTELLATION_GLONASS) +"\n"+                                            
                                                " CONSTELLATION_GALILEO="+ (Position has :CONSTELLATION_GALILEO) +"\n"  
                                                );
                    var options;
                      // var options = Position.LOCATION_CONTINUOUS; // pour corriger le bug 10.43
                    if (monkeyVers>=320)  {
                                        options = {
                                            :acquisitionType => Position.LOCATION_CONTINUOUS
                                        };
 //
                                        if (Position has :POSITIONING_MODE_AVIATION) {
                                            options[:mode] = Position.POSITIONING_MODE_AVIATION;
                                            //System.println("Ok aviation");
                                        }
                                        if (monkeyVers>=336  )  {  // for EPIX2, and all recents watches
//
//
                                                    options[:configuration] = CheckMODEGPS(1); // mode configuration
//
 //
                                        }
                                        else {
                                                    options[:constellations ] =CheckMODEGPS(0); // mode constellation
                                                    // manque le cas options = Position.LOCATION_CONTINUOUS;
                                                }  
                                        }
                    else {
                            options = Position.LOCATION_CONTINUOUS;
                            // System.println("Ok monkeyVers<320");
                    }

 
                          options = Position.LOCATION_CONTINUOUS;
                            // System.println("Ok monkeyVers<320");
                    }

 
                //System.println("options="+options);
                Position.enableLocationEvents(options, method(:setPosition));   // here is IQ
// In this case
// options={
:acquisitionType => Position.LOCATION_CONTINUOUS,
:mode=>  Position.POSITIONING_MODE_AVIATION,
:configuration==>  Position.CONFIGURATION_GPS_GALILEO
 

}

(:CIQ2HighMemory) function CheckMODEGPS(quoi){
            var TModeGPS=ModeGPS-1;
            if (ModeGPS==255) {TModeGPS=6;} // on veut le mode AutoGNSS
            if (quoi==1) { // cas configuration
                        var TabMethodConfig=[
                            :CONFIGURATION_GPS,
                            :CONFIGURATION_GPS_GLONASS,
                            :CONFIGURATION_GPS_GALILEO,
                            :CONFIGURATION_GPS_BEIDOU,
                            :CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1,
                            :CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1_L5,
                            :CONFIGURATION_SAT_IQ
                        ];
                        var TabMethodConfigVal=[
                                                1,
                                                2,
                                                3,
                                                4,
                                                5,
                                                6,
                                                255
                                        ];
                      System.println("Cas quoi="+quoi);
                     System.println("TabMethodConfig="+TabMethodConfig);

                        if (Position has TabMethodConfig[TModeGPS]) {
                             System.println("cas has configuration return="+TabMethodConfigVal[TModeGPS]+ " ModeGPS="+ModeGPS);
                            return TabMethodConfigVal[TModeGPS];
                        }
                        else {
                             System.println("cas pas le has configuration return="+TabMethodConfig[0]+ " ModeGPS="+ModeGPS);
                            return TabMethodConfigVal[0]; // seulement CONFIGURATION_GPS
                        }
                    }
 
            else { // cas constellation
                    //System.println("Cas quoi="+quoi);
                    var TabMethodConstell=[
                        :CONSTELLATION_GPS,
                        :CONSTELLATION_GLONASS,
                        :CONSTELLATION_GALILEO
                    ];
                        var TabMethodConfigVal=[
                                                [0],
                                                [0,1],
                                                [0,2]

                                        ];
                    //System.println("TModeGPS="+TModeGPS+ "  TabMethodConstell.size()="+ TabMethodConstell.size());
                    if (TModeGPS<TabMethodConstell.size()) {
                            if (Position has TabMethodConstell[TModeGPS]) {
                                //System.println("cas has constellation return="+TModeGPS+ " ModeGPS="+ModeGPS);
                                return  TabMethodConfigVal[TModeGPS];
                            }
                            else {
                                //System.println("cas pas le has constellation return="+ TabMethodConfigVal[0]);
                                return TabMethodConfigVal[0]; // seulement CONSTELLATION_GPS
                            }          
                        }
                        else {
                                //System.println("cas TModeGPS >2  return="+ TabMethodConfigVal[0]);
                                return TabMethodConfigVal[0]; // seulement CONSTELLATION_GPS
                            }  
            }
}    
  • This a bit tricky.  My first report of a crash on a device with 3.3.6 and anything other than just GPS cased a crash made me send an update to the store that always used just GPS, so others wouldn't see the crash until I had time to sort things out.

    Spent some time today doing just that.

    I have two booleans to control things

    hasNewGPS1=(Position has :CONSTELLATION_GLONASS);
    hasNewGPS2=(Position has :hasConfigurationSupport);

    If hasNewGPS1 is true and hasNewGPS2 is false, I do things as I did before.  And when I enableLocationEvents I use

    :constellations => constellations

    If hasNewGPS2 is true I use

    :configuration  => <a valid value after using hasConfigurationSupport to check it for true/false>

    I'm testing on a real watch (the sim device isn't working right yet) and so far so good.  No crashes and I do see the different options on real devices.

  • For some things like weather widgets, I just use the default (GPS Only) as things won't be that different 100 feet from my exact spot Slight smile

  • Using this scheme on a fr 255, I see GPS, GPS_GLONASS_GALILEO_BEIDOU_L1, and GPS_GLONASS_GALILEO_BEIDOU_L1_L5 as options in my app.

  • Thanks Jim.

    It would have been easier for system 5 to be CIQ5 and system 6 to be CIQ 6. Here we are on CIQ 3.3.6 for system 6 and CIQ 3.3.2 for system 5. What is the interest in creating this complexity and why has :CONFIGURATION_GPS  is true but not in the real watch

    Didier

  • Which watch?  CONFIGURATION_GPS is true on a fr 255 with the latest firmware.

  • It would have been easier for system 5 to be CIQ5 and system 6 to be CIQ 6. Here we are on CIQ 3.3.6 for system 6 and CIQ 3.3.2 for system 5.

    I'm sorry to bring this up again, but:

    System 4 = CIQ 3.1 for CIQ 3.* devices, and CIQ 4.0 for CIQ 4.* devices

    System 5 = CIQ 3.2 for CIQ 3.* devices, and CIQ 4.1 for CIQ 4.* devices

    System 6 = CIQ 3.3 for CIQ 3.* devices and CIQ 4.2 for CIQ 4.* devices

    The reason the "System X" scheme was invented is because CIQ 3 devices will never get CIQ 4 (which has some exclusive features), but both CIQ 3 and CIQ 4 are still being actively maintained (i.e. receiving new shared features).

    This feature in question that's said to be available since API 3.3.6 is:

    - introduced in SDK 4.1.6

    - available with CIQ 3.3.6 for CIQ 3.* devices

    - available with CIQ 4.1.6 for CIQ 4.* devices

    (I will note that the label "System 4/5/6" per se isn't what's important - what's really important is knowing what CIQ version a given device needs in order to support a particular feature.)

    Anyway, just another data point demonstrating that Garmin's "System X" scheme has failed. It would be nice if the documentation just spelled out what "since API 3.3.6" really means.

    Which watch?  CONFIGURATION_GPS is true on a fr 255 with the latest firmware.

    The OP says:

    "For these watches monkeyVers>=336

    D2 Mach 1: 10.43"

    Note that D2 Mach is a CIQ 4 device. I have no idea if version 10.43 supports CIQ 4.1.6 or not, but the current device file says:
    "connectIQVersion": "4.0.6",

    Then again the current device file for fr255 says:
    "connectIQVersion": "4.1.2"

    So that doesn't prove anything.

    If would be nice if there was an official resource which maps device type/firmware version to CIQ version support. Seems to me there's no way of knowing unless you own the device or you ask a user, since it's not in crash log.

  • In the sim for the 255, it "has" hasConfigurationSupport(), and the valid configs are CONFIGURATION_GPS, CONFIGURATION_GPS_GLONASS and CONFIGURATION_GPS_GALILEO.

    On a real 255 with 13.21 FW (CIQ 4.1.6), it has CONFIGURATION_GPS, CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1 and CONFIGURATION_GPS_GLONASS_GALILEO_BEIDOU_L1_L5

    I'm using the 4.1.7 SDK