Namespaces
Variants
Actions
(Difference between revisions)

Archived:Location.getCourse() and Location.getSpeed() not working in S60 3rd FP1 Emulator (Known Issue)

Jump to: navigation, search
m (Hamishwillee - Bot change of template (Template:KnowledgeBase) - now using Template:ArticleMetaData)
m (Hamishwillee -)
(3 intermediate revisions by one user not shown)
Line 1: Line 1:
[[Category:S60 3rd Edition, Feature Pack 1]]{{KBKI}}
+
[[Category:S60 3rd Edition FP1]][[Category:Known Issue]][[Category:Java ME]][[Category:Code Snippet]][[Category:S60 3rd Edition FP1]][[Category:Bluetooth API (JSR-82)]][[Category:Emulator]][[Category:Symbian]]
__NOTOC__
+
{{ArticleMetaData <!-- v1.2 -->
__NOEDITSECTION__
+
{{ArticleMetaData
+
|id=Unofficial - No ID assigned|platform=S60 3rd Edition, FP1
+
|devices=Emulator
+
|category=Java ME
+
|subcategory=JSR-82
+
|creationdate=May 3, 2009
+
|keywords= Location getCourse() getSpeed()
+
 
+
 
|sourcecode= <!-- Link to example source code (e.g. [[Media:The Code Example ZIP.zip]]) -->
 
|sourcecode= <!-- Link to example source code (e.g. [[Media:The Code Example ZIP.zip]]) -->
 
|installfile= <!-- Link to installation file (e.g. [[Media:The Installation File.sis]]) -->
 
|installfile= <!-- Link to installation file (e.g. [[Media:The Installation File.sis]]) -->
|sdk=<!-- SDK(s) built and tested against (e.g. [http://linktosdkdownload/ Nokia Qt SDK 1.1]) -->
+
|devices= Emulator
|devicecompatability=<!-- Compatible devices (e.g.: All* (must have GPS) ) -->
+
|sdk= <!-- SDK(s) built and tested against (e.g. [http://linktosdkdownload/ Nokia Qt SDK 1.1]) -->
|signing=<!-- Empty or one of Self-Signed, DevCert, Manufacturer -->
+
|platform= S60 3rd Edition, FP1
|capabilities=<!-- Capabilities required (e.g. Location, NetworkServices.) -->
+
|devicecompatability= <!-- Compatible devices (e.g.: All* (must have GPS) ) -->
|author=[[User:Schoenke]]
+
|dependencies= <!-- Any other/external dependencies e.g.: Google Maps Api v1.0 -->
 +
|signing= <!-- Empty or one of Self-Signed, DevCert, Manufacturer -->
 +
|capabilities= <!-- Capabilities required by the article/code example (e.g. Location, NetworkServices. -->
 +
|keywords= Location getCourse() getSpeed()
 +
|language= <!-- Language category code for non-English topics - e.g. Lang-Chinese -->
 +
|translated-by= <!-- [[User:XXXX]] -->
 +
|translated-from-title= <!-- Title only -->
 +
|translated-from-id= <!-- Id of translated revision -->
 +
|review-by= <!-- After re-review: [[User:username]] -->
 +
|review-timestamp= <!-- After re-review: YYYYMMDD -->
 +
|update-by= <!-- After significant update: [[User:username]]-->
 +
|update-timestamp= <!-- After significant update: YYYYMMDD -->
 +
|creationdate= 20090503
 +
|author= [[User:Schoenke]]
 
}}
 
}}
  
 
==Description==
 
==Description==
To get a LocationProvider that provides current speed and course, the criteria have to be set accordingly before retrieving the instance of LocationProvider:
+
To get a {{Icode|LocationProvider}} that provides current speed and course, the criteria have to be set accordingly before retrieving the instance of {{Icode|LocationProvider}}:
  
 
<code java>
 
<code java>
Line 28: Line 32:
 
</code>
 
</code>
  
This works fine for S60 3rd FP1 devices. But if the ''setSpeedAndCourseRequired'' criterion is set in the emulator, the call of getInstance() always returns null.
+
This works fine for S60 3rd FP1 devices. But if the {{Icode|setSpeedAndCourseRequired}} criterion is set in the emulator, the call of {{Icode|getInstance()}} always returns {{Icode|null}}.
 
+
The purpose of an emulator is voided if it doesn't behave like the devices it represents...
+
 
+
==How to reproduce==
+
just try it as described above...
+
 
+
==Solution==
+
Fix this non-conformity... and in the meantime document it as a Known Issue
+
  
[[Category:Known Issue]]
+
The purpose of an emulator is voided if it doesn't behave like the devices it represents.
[[Category:Java ME]]
+
[[Category:Bluetooth]]
+
[[Category:Code Examples]]
+
[[Category:S60 3rd Edition, Feature Pack 1]]
+

Revision as of 02:45, 5 November 2012

Article Metadata

Tested with
Devices(s): Emulator

Compatibility
Platform(s): S60 3rd Edition, FP1

Article
Keywords: Location getCourse() getSpeed()
Created: schoenke (03 May 2009)
Last edited: hamishwillee (05 Nov 2012)

Description

To get a LocationProvider that provides current speed and course, the criteria have to be set accordingly before retrieving the instance of LocationProvider:

Criteria criteria = new Criteria();
criteria.setSpeedAndCourseRequired(true);
LocationProvider locationProvider = LocationProvider.getInstance(criteria);

This works fine for S60 3rd FP1 devices. But if the setSpeedAndCourseRequired criterion is set in the emulator, the call of getInstance() always returns null.

The purpose of an emulator is voided if it doesn't behave like the devices it represents.

226 page views in the last 30 days.
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved