I recently bought a GPS Module to connect to my Arduino and had to learn about GPRMC sentence structure. Since GPS calculates direction by drawing a vector from the previous position to the current position, the correction for the magnetic North Pole doesn't come into consideration. The bearing in GTFS-realtime should be the same as the "Track angle in degrees True" of GPRMC. They are both in terms of True North. Imagine you are standing at the center of a circle, and you are facing true north. As you rotate clockwise 30 degrees, you will be on a bearing of 30 degrees (if you move forward). The data structure should be something like this, I think:
header {
gtfs_realtime_version: "1.0"
}
entity {
id: "myPosition"
vehiclePosition{
position{
position_id: "myBearing"{
bearing: 84.4
}
}
}
}
I figured this out from the descriptions and examples on these pages: https://developers.google.com/transit/gtfs-realtime/reference#VehiclePosition https://developers.google.com/transit/gtfs-realtime/examples/trip-updates-full
Does that help?