' **********************************************************************
' * Script name:   GPS Qual                                            *
' * Description:   The device filters the position using the AT$GPSQUAL*
' *                Command, the unit willsne position every x seconds  *
' *                defined in the timer1                               *
' * Responsible:   Ramiro Sanchez                                      *
' * Date:          03/17/2011                                          *
' **********************************************************************
' --------------------------------------------------------------------
' General configuration
' --------------------------------------------------------------------
AT&F
AT+GSN
AT$PKG?
AT$MDMID?
at+cgatt=0
at+cgdcont=1,"IP","proxy"
at$friend=1,1,"209.42.60.137", 1735,3
at$udpapi=,1720


AT$EVENT=9,1,12,1,1
AT$EVENT=9,3,40,9,7868622
AT$EVENT=9,3,40,9,4260549

at$gpsqual=?

'$GPSQUAL: flg,hdop,sats,unc,uncTO,delay,speed,accel,dist,hdgchg,yr,hdgspd,ssj,vUnc,ctu

' flg: 1=3d fix,2=no prop fix,4=pos ext,8=meas ext

' hdop: $GPGSA HDOP threshold

' sats: Number of satellites 

' unc: TI's uncertainty value (in meters)

' uncTO: uncertainty timeout (obsolete)

' delay (secs): delay before reporting a lock after suspect report

' speed (knots): speed threshold used to block report

' accel (knots/sec): one-sec acceleration threshold used to block report

' dist (meters): one-sec distance threshold used to block report

' hdgchg (degs/sec): one-sec hdg chg threshold used to block report

' yr: current year minus 2000

' hdgspd (knots): speed where hdg chg is applicable

' ssj: # of satellites where speed jump has been detected

' vUnc: velocity uncertainty threshold

' ctu: clock time uncertainty toggles


at$gpsqual=12,0,4,200,0,0,10,0,500,0,1,0,0,50,3

at+cgatt=1
at$areg=2
at&w

