For information on how to retrieve locations from the Location Framework (LFW), see
C++ API Documentation > S60 API Reference Guide > C++ API Reference > S60 Platform Services > Location Services > Location Acquisition API
Java API documentation > JavaDocs > JSR-179: Location API
For information on how to retrieve locations from the Location Framework (LFW), see Location Acquisition API in the S60 API Reference Guide.
For information on how to retrieve locations from the Location Framework (LFW), see Location API (JSR-179) in Java API Documentation > JavaDocs
To get module status from the Simulation PSY, a user first needs to
connect to RPositionServer
and open a sub-session to
Simulation PSY using RPositioner
.
Example of how to retrieve module status from Simulation PSY:
TPositionModuleStatus moduleStatus; TPositionModuleStatusEvent moduleEvent; TRequestStatus status; RPositionServer positionServer; RPositioner simPSY; const TPositionModuleId KSimulationPSYUid = {0x101f7a81}; User::LeaveIfError(positionServer.Connect()); CleanupClosePushL(positionServer); // Asynchronous module status moduleEvent.SetRequestedEvents(TPositionModuleStatusEvent::EEventAll); positionServer.NotifyModuleStatusEvent(moduleEvent, status, KSimulationPSYUid); TInt err = simPSY.Open(positionServer, KSimulationPSYUid); // Variable err could be checked CleanupClosePushL(simPSY); User::WaitForRequest(status); moduleEvent.GetModuleStatus(moduleStatus); TPositionModuleStatus::TDeviceStatus deviceStatus = moduleStatus.DeviceStatus(); TPositionModuleStatus::TDataQualityStatus qualityStatus = moduleStatus.DataQualityStatus(); // Do something with moduleStatus, deviceStatus, qualityStatus // Synchronous module status User::LeaveIfError(positionServer.GetModuleStatus(moduleStatus, KSimulationPSYUid)); deviceStatus = moduleStatus.DeviceStatus(); qualityStatus = moduleStatus.DataQualityStatus(); // Do something with moduleStatus, deviceStatus, qualityStatus CleanupStack::PopAndDestroy(2, &positionServer); // simPSY
Simulation PSY reports module status during its life cycle. Module status is reported only when Simulation PSY is opened and closed, that is, no status is reported during location requests.
The following module statuses are reported:
Module Status |
Event Group |
Comment |
---|---|---|
|
DeviceStatus |
Reported if an input file cannot be found or is corrupt |
|
DeviceStatus |
Reported when Simulation PSY is unloaded. |
|
DeviceStatus |
Reported when Simulation PSY is online and ready to retrieve position information. |
|
DataQualityStatus |
Reported when Simulation PSY is unloaded. |
|
DataQualityStatus |
Reported when Simulation PSY is online and ready to retrieve position information. |