Package: android.hardware.gnss@1.1

IGnss

interface IGnss extends @1.0::IGnss

Represents the standard GNSS(Global Navigation Satellite System)interface.

Methods

setCallback_1_1

setCallback_1_1 (IGnssCallback callback)
generates (bool success)

Opens the interface and provides the callback routines to the implementation of this interface.

Details
Parameters
callback
Callback interface for IGnss.
Generates
success
Returns true on success.

setPositionMode_1_1

setPositionMode_1_1 (GnssPositionMode mode, GnssPositionRecurrence recurrence, uint32_t minIntervalMs, uint32_t preferredAccuracyMeters, uint32_t preferredTimeMs, bool lowPowerMode)
generates (bool success)

Sets the GnssPositionMode parameter, its associated recurrence value, the time between fixes, requested fix accuracy, time to first fix.

Details
Parameters
mode
Parameter must be one of MS_BASED or STANDALONE.It is allowed by the platform(and it is recommended)to fallback to MS_BASED if MS_ASSISTED is passed in, and MS_BASED is supported.
recurrence
GNSS postion recurrence value, either periodic or single.
minIntervalMs
Represents the time between fixes in milliseconds.
preferredAccuracyMeters
Represents the requested fix accuracy in meters.
preferredTimeMs
Represents the requested time to first fix in milliseconds.
lowPowerMode
When true, and IGnss.hal is the only client to the GNSS hardware, the GNSS hardware must make strong tradeoffs to substantially restrict power use.Specifically, in the case of a several second long minIntervalMs, the GNSS hardware must not, on average, run power hungry operations like RF and signal searches for more than one second per interval, and must make exactly one call to gnssSvStatusCb(), and either zero or one call to GnssLocationCb() at each interval.When false, HAL must operate in the nominal mode(similar to V1.0 where this flag wasn't present)and is expected to make power and performance tradoffs such as duty-cycling when signal conditions are good and more active searches to reacquire GNSS signals when no signals are present.When there are additional clients using the GNSS hardware other than IGnss.hal, the GNSS hardware may operate in a higher power mode, on behalf of those clients.
Generates
success
Returns true if successful.

getExtensionGnssConfiguration_1_1

getExtensionGnssConfiguration_1_1 ()
generates (IGnssConfiguration gnssConfigurationIface)

This method returns the IGnssConfiguration interface.

Details
Generates
gnssConfigurationIface
Handle to the IGnssConfiguration interface.

getExtensionGnssMeasurement_1_1

getExtensionGnssMeasurement_1_1 ()
generates (IGnssMeasurement gnssMeasurementIface)

This method returns the IGnssMeasurement interface.

Details
Generates
gnssMeasurementIface
Handle to the IGnssMeasurement interface.

injectBestLocation

injectBestLocation (GnssLocation location)
generates (bool success)

Injects current location from the best available location provider.

Unlike injectLocation, this method may inject a recent GNSS location from the HAL implementation, if that is the best available location known to the framework.

Details
Parameters
location
Location information from the best available location provider.
Generates
success
Returns true if successful.