<?xml version="1.0" encoding="utf-8"?>
<glgps xmlns="http://www.glpals.com/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.glpals.com/ glconfig.xsd" >

<!-- It is highly recommended to view/edit this file with syntax-highlighting 
    editors such as notepad++ or vim. This way, one can easily distinguish 
    comments and valid code.
-->

<!--Typical Windows hal for evaluation kit connect to USB cable -->
<hal     
    PortName="BCMGNSS1"
    BaudRate="921600"
    DisableCoreDumpUponAssert="-1"
    LogEnabled="false"
    DisableConsoleIO="true"
    LogDirectory="%APPDATA%\Broadcom\Location"
    AssistanceSources="0x1A1"
    NvStoWriteToFile="false"
    LtoDownloadIntervalSeconds="14400"
    LogLineThreshold="1000000"
/>

<!-- GLL Engine: See allPartners\deliverables\gll_distr\inc\glgpsapi.h for 
    supported parameters 
-->

<gll
    LogPriMask="LOG_INFO"
    LogFacMask="LOG_DEFAULT"
    PsfRecoverJobsUponBadTime="true"
    PsfNotConnected="true"
    RfType="GL_RF_47531_BRCM_EXT_LNA"
    FrqPlan="FRQ_PLAN_26MHZ_2PPM"
/>

<!-- List of jobs can be performed by the GPS controller    -->

<!-- Short test for hardware, GPIO and UART bring up -->
<job Id="Bringup">
    <task>
        <req_pos_single AccuracyMask="50" Timeout="30" />
    </task>
</job>

<!-- Stress test for hardware, GPIO and UART robustness, requires satellite
signal receptions -->
<job Id="Serial_Stress_Need_Satellites">
    <task Id="CollectAlmanacA_" Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos ValidFixes="800"/>
    </task>
    <task Id="Hot_Starts" Repeat="43200">
        <req_pos ValidFixes="1"/>
    </task>
    <task Id="CollectAlmanacB_" Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos ValidFixes="800"/>
    </task>
</job>

<!-- Stress test for hardware, GPIO and UART robustness, satellites not 
required -->
<job Id="Serial_Stress_No_Satellites">
    <task Id="ContinuousA_" Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos_single AccuracyMask="50" Timeout="900" />
    </task>
    <task Id="Open_Close_" Repeat="43200">
         <req_pos_single AccuracyMask="50" Timeout="2" />
    </task>
    <task Id="ContinuousB_" Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos_single AccuracyMask="50" Timeout="900" />
    </task>
</job>

<!-- Periodic Position Fix using default settings -->
<job Id="Periodic">
    <task>
        <req_pos/>
    </task>
</job>

<!-- Periodic Position with the ROM almanac ignored for simulator testing -->
<job Id="Simulator_Periodic">
    <task Repeat="1">
        <startup IgnoreRomAlm="true" />
        <req_pos ValidFixes="2000" DurationSec="4500"/>      
    </task>
</job>

<!-- This job must be performed before any systematic tests  -->
<job Id="CollectAlmanac">
    <task Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos ValidFixes="800"/>
    </task>
</job>

<!-- This job must be performed every time the GPS simulator scenario is reset  -->
<job Id="CollectEphemeris">
    <task Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos ValidFixes="200"/>
    </task>
</job>

<!-- Systematic Test: Repetitive cold starts (reference time/ephemeris/position unknown) -->
<job Id="Cold_Starts">
    <task Repeat="100" EnableRandomSleepBetweenIterations="true">
        <startup
            IgnoreOsc="false"
            IgnoreRomAlm="false"
            IgnoreRamAlm="false"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos ValidFixes="1"/>
    </task>
</job>

<!-- Systematic Test: Repetitive cold starts with the ROM almanac ignored for 
    simulator testing -->
<job Id="Simulator_Cold_Starts">
    <task Repeat="100" EnableRandomSleepBetweenIterations="true">
        <startup
            IgnoreOsc="false"
            IgnoreRomAlm="true"
            IgnoreRamAlm="false"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_pos ValidFixes="1"/>
    </task>
</job>

<!-- Systematic Test: Repetitive warm starts (ephemeris unknown)
    Stored ephemeris data is discarded before the start begins
    This simulates GPS receiver start after it was left off for more that 4 hours
-->
<job Id="Warm_Starts">
    <task Repeat="100" EnableRandomSleepBetweenIterations="true">
        <startup IgnoreNav="true"/>
        <req_pos ValidFixes="1"/>
    </task>
</job>

<!-- Systematic Test: Repetitive warm starts performed on GPS simulator -->
<job Id="Simulator_Warm_Starts">
    <task Repeat="100" EnableRandomSleepBetweenIterations="true">
       <startup 
            IgnoreRomAlm="true"
            IgnoreNav="true" 
       />
       <req_pos ValidFixes="1"/>
    </task>
</job>

<!-- Systematic Test: Repetitive far starts -->
<job Id="Far_Starts">
    <task Repeat="100">
        <startup 
            IgnoreNav="true" 
            IgnoreTime="true"
        />
        <req_pos ValidFixes="1" />
    </task>
</job>

<!-- Systematic Test: Repetitive lost starts (reference position unknown) -->
<job Id="Lost_Starts">
    <task Repeat="100">
        <startup 
            IgnoreNav="true" 
            IgnorePosition="true"
        />
        <req_pos ValidFixes="1" />
    </task>
</job>

<!-- Systematic Test: Repetitive hot starts  -->
<job Id="Hot_Starts">
    <task Repeat="100">
        <req_pos ValidFixes="1"/>
    </task>
</job>

<!-- This job performes series of single shot requests using the data stored 
      in NVRAM to simulate assistance data received from the network 
      The QoS parameters are set to maxmize the GPS sensitivity 
-->
<job Id="Assisted_Cold_Starts">
    <task Repeat="100">
        <startup 
            IgnoreRomAlm="true" 
            IgnoreRamAlm="true"
        />
        <asst>
            <!--pos Lat="-30.0" Lon="-50.0" Alt="50" /-->
            <pos Lat="33.7691" Lon="-84.4062" Alt="300" />
            <!--pos Lat="37.0" Lon="-122.0" Alt="50" /-->
            <!--pos Lat="37.26533652" Lon="-121.94128855" Alt="51.4" /-->
        </asst>
        <req_pos_single AccuracyMask="50" Timeout="30" />
    </task>
</job>

<!-- This job performes series of single shot requests using the data stored 
      in NVRAM to simulate assistance data received from the network 
      The QoS parameters are set as it woudld be set by Spirent ULTS executing 
      3GPP TS performance tests.
-->
<job Id="3GPP_Assisted_Cold_Starts">
    <task Repeat="100">
        <startup 
            IgnoreRomAlm="true" 
            IgnoreRamAlm="true"
        />
        <asst>
            <!--pos Lat="-30.0" Lon="-50.0" Alt="50" /-->
            <pos Lat="33.7691" Lon="-84.4062" Alt="300" />
            <!--pos Lat="37.0" Lon="-122.0" Alt="50" /-->
            <!--pos Lat="37.26533652" Lon="-121.94128855" Alt="51.4" /-->
        </asst>
        <req_pos_single AccuracyMask="25" Timeout="20" />
    </task>
</job>

<!-- Starts single-channel factory test mode.  
     The signal is expected to initially be in the range from -125 dBm to -142 dBm
     with the frequency offset range from -2 ppm to +2 ppm for this mode to provide
     reliable results.
     
     The name Factory_High_SNR is legacy only. The recommended name is
     Factory_Track_Test.     
-->    
<job Id="Factory_High_SNR">
    <task Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_ftest
            Prn="1"
            FactoryTestMode="GL_FACT_TEST_CONT"
            FactoryTestItems="GL_FACT_TEST_WER" 
            AveragingIntervalSec="10" 
            DurationSec="20"
        />
    </task>
</job>

<job Id="Factory_GPS_Track_Test">
    <task Repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
       />
        <req_ftest
            Prn="1"
            FactoryTestMode="GL_FACT_TEST_CONT"
            FactoryTestItems="GL_FACT_TEST_WER" 
            AveragingIntervalSec="10" 
            DurationSec="120"
       />
    </task>
</job> 

<!-- GPS + GLONASS -->
<job Id="Factory_GNSS_Track_Test">
    <task repeat="1">
        <startup
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
       />
        <req_ftest
            Prn="1"
            Fcn="0" 
            FactoryTestItems="GL_FACT_TEST_WER" 
            FactoryTestMode="GL_FACT_TEST_CONT"
            AveragingIntervalSec="10" 
            DurationSec="120"
       />
    </task>
</job>


<!-- This job is intended to be ran after the Factory_Track_Test job 
     It uses the TCXO offset stored in NVRAM during the Factory_Track_Test job.
     
     This is a low-signal strength acquisition only test. It performs repeated 
     acquisitions but no tracking, hence it cannot be used to produce, for 
     example, WER measurements.
-->
<job Id="Factory_Low_SNR">
    <task Repeat="1">
        <startup
            IgnoreOsc="false"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_ftest
            Prn="1"
            FactoryTestMode="GL_FACT_TEST_CONT"
            FactoryTestItems="GL_FACT_TEST_WER" 
            AveragingIntervalSec="10" 
            DurationSec="200"
        />
     </task>
</job>

<job Id="Factory_Low_SNR_Acquisition">
    <task repeat="1">
        <startup
            IgnoreOsc="false"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
        />
        <req_ftest
            Prn="1"
            FactoryTestMode="GL_FACT_TEST_CONT"
            FactoryTestItems="GL_FACT_TEST_WER" 
            AveragingIntervalSec="10" 
            DurationSec="200"
        />
    </task>
</job>

<job Id="Factory_GPS_CW_Test">
    <task Repeat="1">
        <startup 
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
       />
        <req_ftest 
            Prn="1"
            FactoryTestItems="GL_FACT_TEST_CW" 
            FactoryTestMode="GL_FACT_TEST_ONCE"
            AveragingIntervalSec="10" 
            DurationSec="60"
       />
    </task>
</job> 

 <job Id="Factory_GLONASS_CW_Test">
    <task repeat="1">
        <startup 
            IgnoreOsc="true"
            IgnoreRomAlm="true"
            IgnoreRamAlm="true"
            IgnorePosition="true"
            IgnoreNav="true"
            IgnoreTime="true"
       />
        <req_ftest 
            Fcn="0" 
            FactoryTestItems="GL_FACT_TEST_CW" 
            FactoryTestMode="GL_FACT_TEST_ONCE"
            AveragingIntervalSec="10" 
            DurationSec="60"
       />
    </task>
</job>
</glgps>
