BimmerGestalt / AAIdrive

Implementations of some Android Auto features as unofficial IDrive apps
MIT License
558 stars 92 forks source link

Mapbox Map is not rotated correctly #624

Closed 6i6i closed 9 months ago

6i6i commented 2 years ago

Hello,

when using the Mapbox feature i experience the problem, that the map is not rotated correctly. ( In the direction i am moving). I tried all the several options. (Use GPS from phone instead car, ...).

hufman commented 2 years ago

The map rotation uses the same car direction as the arrow. Does the arrow point in the same direction as your travel?

6i6i commented 2 years ago

Hello,

No, the arrow is also not positioned correctly. The map is rotating when I travel around corners f.ex.. I think it should be, like in other navigation systems, that the direction where I am travelling is on the top of the screen. Here it is somewhere else.

Thank you

hufman commented 2 years ago

Can you install the CDS Details addon and tell me what it shows for navigation.GPSExtendedInfo while your car is facing North? It should show a heading close to 0 or 360.

6i6i commented 2 years ago

Hello,

ok,

I'll do that Thank you.

patalmqx commented 2 years ago

Same issue for me with NBT

hufman commented 2 years ago

What does your car show for navigation.GPSExtendedInfo?

6i6i commented 2 years ago

For me it shows: {altitude=343,heading=211,speed=35202, quality=447}. This information is when I was travelling on this street: grafik

6i6i commented 2 years ago

Additional a passenger made a video (location is different)

https://user-images.githubusercontent.com/6044026/197470561-6014992a-c712-4a03-bbf7-62d9f556ef80.mp4

6i6i commented 2 years ago

@hufman Have you found something or to you need more data?

hufman commented 2 years ago

I haven't found anything. AAIdrive simply accepts whatever direction the car says it is heading. Does your car have its own compass display, and is that accurate too?

6i6i commented 2 years ago

Ok. I have to check and change the coding of NBT_EVO to activate the compass screen.

LACNR commented 1 year ago

I know having adding Navigation to AAI was difficult thing already, and glad for it being there and see the incredible progress this has gone to this day and the road to come.

I do have difficulties with the Navigation/mapbox, specifically using the GPS doesn't work for me (though I do have GPS-Tracking from CDS activated in the car as well) but I assume because I don't have native Navigation with my EntryNav AAID can't read the information. When using the phone GPS the routing technically works, but it is lagging the maps/arrow needs a few MS to update my position and the arrow is off the street most of the time (the iDrive itself is working normal no delays). Using Google Maps, AmiGo pararelly works normally, no delay so the GPS Signal itself is perfect.

Does anyone have a clue what could be the cause or how to improve performance, is it the GPS Signal, the RAM Performance of the EntryNav or Phone?

pitum1 commented 1 year ago

Navigation start ok... after some minutes the direction screen change to horizontal going the left... and never change again... I will try to make video. Note, I have internal GPS and work ok. My device NBT 4 (serie 4 - 2015) Thank you!

hufman commented 1 year ago

Please try the new beta build in the Play Store to check what compass direction the car reports through the new Car Info screen.

pitum1 commented 1 year ago

No yet  on my play store…i will wait…I will test…Thank you!

hufman commented 1 year ago

I just pushed a build this morning, and it normally takes a few days to roll out, my bad for getting excited :) photo1681442702

Mikkooooo commented 1 year ago

Hi all, I've tried the latest BETA. I come from #689 and I have a X5 F15 with ID4++. The compass bearing and the map rotatation/orientation doesn't work properly. My car compass bearing is often different from the AAIDRIVE car info screen and I don't know why. It only works if I'm exactly in the North direction (360°) Could it be related to the small RAM in ID 4 ?

GlMcCabe commented 1 year ago

Navigation seems to be working well in the latest beta, however, the map does not scroll and instead is still for 2 to 8 seconds and then moves quickly to a more current location. Also, the rotating arrow starts up when I come to a stop and finally settles in an unusual heading (not direction of travel) in about 15 seconds.

6i6i commented 1 year ago

Please try the new beta build in the Play Store to check what compass direction the car reports through the new Car Info screen.

Hi,

Thank you very much for the new beta build. To have all this information on the screen is really awesome!!!

I did a longer drive yesterday haveing an eye on the direction degree value that shows in the Driving detail screen. I had additionally my phone running with a compass application that shows the same value. What I've noticed: If I go exactly to north it is correct with 360°. But If I go a little bit north east where the phone shows 10 -15 degrees the value on the idrive screen shows 110°. In the complete ride I've never seen any value below 100°. So there is always a offset between the real direction and what is displayed in the idrive display (coming from AAIDrive). The offset is not a static value, but it differs between 100 and 0. F.ex. If I go exactly to south which should be 180°. The value 230 is displayed. That is also exactly the behaviour that is shown when using the Mapbox functionality. Probably ID4 is doing something different here?

I also checked the direction in the internal navigation of Idrive and there it is always correct.

hufman commented 1 year ago

Hmmm I'm not sure.. AAIdrive changes the heading from the car slightly to switch it to rotate the other direction, and so I added a field to the GPS Details page to show the raw heading from the car. I also saw a hint in BMW Connected's code that the value range might be up to 256, not the full 360, and so I added a tweak to handle this range. Are there any ID4 cars that show the correct rotation, or any ID5 cars that show an incorrect rotation? Try out this custom build!

6i6i commented 1 year ago

Thank you for the custom build. I'll report as soon as I get into the car after work.

Mikkooooo commented 1 year ago

Hi Walter, I‘ve downloaded the custom build apk and the app cannot be installed. I‘ve installed the latest beta. Do I have to delete that beta first before installing your custom build is possible ?

6i6i commented 1 year ago

Hi Walter, I‘ve downloaded the custom build apk and the app cannot be installed. I‘ve installed the latest beta. Do I have to delete that beta first before installing your custom build is possible ?

Yes. You have to uninstall the play store version first.

Hmmm I'm not sure.. AAIdrive changes the heading from the car slightly to switch it to rotate the other direction, and so I added a field to the GPS Details page to show the raw heading from the car. I also saw a hint in BMW Connected's code that the value range might be up to 256, not the full 360, and so I added a tweak to handle this range. Are there any ID4 cars that show the correct rotation, or any ID5 cars that show an incorrect rotation? Try out this custom build!

Great. The tweak worked.. The value is now correct and also the map box map is rotatet correctly!!!

hufman commented 1 year ago

That's awesome! Did anyone else test it too, for further confidence before I merge it to the main build?

Mikkooooo commented 1 year ago

I have tested it too and it runs ok ! Sometimes the arrow is beside the street and it‘s a littlebit slowly. I‘ve noticed that the parts of the app sometimes crashed, sometimes ist was HASS Gestalt, sometimes Map and sometimes Spotify. I think I‘ve also noticed that running the app with battery optimizing runs better than without it. But that can be a coincidence. Many thanks again ,Walter for the great work !!!