Hi
not having yet enough skills to manage B4XPages (because I use B4A with years intervals and changes in it gave me learning problems), I adapted an old fashion program, as I said. Then I was surprised that I obtained the same result, that is to get the googlemaps map oriented according to the "bearing", with the attached prgram, base on an old Gps program. I am absolutely not a guru, so take my code just as an obsolete hint. As you can see, besides probable errors and misunderstandings, it works.
I post the project for any use or eventual further discussion and improvements.
The mechanism is the following:
In the Starter service, the GPS is initialized. Then, when location changes, the LocationChanged function is called, which calls the following :
Sub GotoPosition(loc As Location)
If gmap.IsInitialized Then
Dim CameraPosition1 As CameraPosition = gmap.CameraPosition
CameraPosition1.Initialize2(loc.Latitude, loc.Longitude, CameraPosition1.Zoom, loc.Bearing, CameraPosition1.Tilt)
gmap.moveCamera(CameraPosition1)
End If
End Sub
By the way I also Start/Stop drawing the trajectory.