Open mlerjen opened 6 years ago
Relates to #1073.
How stable is the compass reading on your device (when you don't move it)?
I wonder if might make more sense to connect these features to the "temporary position markers" ("TPM") created by , either just the last one, or the last N (giving you crossing bearings).
My experience has unfortunately been that the magnetometers are too inaccurate to really be useful, but this is only based on using a few devices which were released several years ago, maybe there exist better ones.
As a side note, I think it could be very interesting to try to use vision-based pose estimation with ARCore to stabilize the orientation estimate. I think it should be able to give very good results as long as the device camera has a reasonable view of the ground. But while this should give very good relative precision, it will still not give good absolute accuracy on its own. Perhaps it would be acceptable when fused with magnetometer measurements, but this would still fail if those measurements have a bias (as I suspect they might have). As an alternative, perhaps it could be worth trying to fuse ARCore's pose estimates with the GPS position estimates, for example with a variant of a Kalman Filter. Then, when the GPS position moves, this is compared to the movement direction estimated by ARCore to give it information on the absolute orientation (which is not dependent on an inaccurate magnetometer). I am not sure though whether the ARCore tracking is stable enough over a long enough period of time to be able to average out the GPS noise. In case it does work, it should result in both quite accurate absolute position and orientation estimates for the device. The only big downside might be that it probably drains the battery very quickly.
In case the above works, there would be even more nice things one could try with ARCore / computer vision, such as marking an object in the camera view and having its position estimated automatically, but this gets offtopic.
Actually, an initial attempt at fusing the ARCore and GPS estimates might be very simple:
This could be extended by accounting for the accuracy estimates of the GPS estimates, and to align the height as well, but should already allow to judge whether this might be useful.
@dg0yt: The stability of the compass reading is not perfect but "okay" (need to re-calibrate regularly). There are small "jumps" while holding the device stable. (Maybe one could filter (average) the reading a bit more? or Introduce the possibility to pause the map adjustment-> to overrule the compass relying on other indications (basemap a.s.o.).
Personally I would see 1 & 2 as directly related to ANA, while 3 could also be related to the TPM. In contrast to TPM we have a "direction of interest" allowing to provide a more detailed scale bar towards this direction (thus more detailed scale bar if ANA and TPM are switched on?).
Before someone jumps into implementation :-) I have got a couple of changes on top of class Compass
which should go in before any other changes to the processing of sensor readings. The key change is a adopting a functional style, i.e. properly return values (even for vectors) instead of passing in pointers. The resulting code is much easier to read and understand.
I have got a couple of changes on top of class Compass
Cf. #1170, especially ~9ed40d3~ 0ebcf33 (No, not a single new feature yet. But it does cut build times when touching this code.)
Two more comments: 1) The compass is actually very good on my "prehistoric" galaxy note 2 if re-calibrated on regularly ( 8-shape move; approx 10 times a day). I guess the compass was never the issue, but the GPS. All the compass is worthless without the proper positioning. I work with an external gps, with 1-2m accuracy most of the day. 2) I mounted a laser pointer on my device to use a direction pointer. Thus I point to a feature or to a direction with the pointer in real world and get the correspondent direction on screen by the grey hairline. The next step forward now would be to replace the pointer with a range finder... and to connect the range finder via Bluetooth to the device and Mapper. -> a temporary mark would be shown at the distance (by RF) in the pointing direction of your device (by internal compass; instead of constructing every RF measurement by hand). As an example one could get the outline of a clearing just by pointing at its bordering objects.
Just to let you know my vision.
I wonder if there was a standardized easy way to establish communication between a random Range Finder and Mapper.
My dream is to connect a "Wii"-control (GPS/compass/Gyro to get best result), voice command to change symbol, possibiity to draw line/area and at same time combined with possibility to add point objects, kind of left/right mouse click. Forgive my off topic message!
Discussion
Enhancements
Result
In my opinion this would be a game-changer. Enhanced that way it would integrate compass, location display, distance rings, move to location and somehow the INFO button in one single functionality.
Configuration
Mapper Version: a.s.a.p. :-) Operating System: Android