#4037 closed enhancement (fixed)
[PATCH] LiveGps: Frequent position updates leech too much CPU on low-end devices
Reported by: | casualwalker | Owned by: | casualwalker |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Plugin | Version: | |
Keywords: | Cc: |
Description
LiveGps Plugin redraws the screen each time it receives a new set of data from GPSD, which is about once per second.
When JOSM runs on a low-end device (such as a netbook), JOSM reacts very sluggish to user-input, as all CPU power is consumed by frequent updates.
Proposed solution:
- LiveGPS suppresses update events, until a minimal amount of time has elapsed, by default this is set to 5 sec.
- This interval can be configures in a config value named "livegps.refreshinterval" (in milliseconds).
This was already mentioned in the Wiki, although this is not the right place...
http://wiki.openstreetmap.org/index.php/JOSM/Plugins/LiveGPS#TODOs
I already implemented this feature, it even worked outside ;-)
Patches will follow, as soon as I clean up the code a bit.
Attachments (2)
Change History (8)
comment:1 by , 15 years ago
Owner: | changed from | to
---|
comment:2 by , 15 years ago
Status: | new → assigned |
---|
comment:3 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
If you have any questions re these patches or need another format, re-open this bug and ask me.
comment:4 by , 15 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Summary: | LiveGps: Frequent position updates leech too much CPU on low-end devices → [PATCH] LiveGps: Frequent position updates leech too much CPU on low-end devices |
Don't close tickets until patches have been applied. Closed tickets are history. Nobody cares for them.
comment:5 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
In [o18941].
Some rules for next time
- Use .diff or .patch as extension
- Only one patchfile
- Don't reformat code you did not change
- Don't leave pointless debug code inside
comment:6 by , 15 years ago
Got myself a svn account and improved this feature some more:
- Config setting is in seconds
- Set to 0 disables the suppression
- each position from gpsd still will be added to the layer (and the track); so, when the display is eventually refreshed, you "suddenly" see a couple of new positions. Thus, no position is lost and JOSM is still responsive.
Patches will follow within the next few days.