Hey everyone,
I'm developing website in ReactJs to track my MSFS flights in real time using the FSUIPC web socket server. So far things are going ok, I'm just struggling a bit with the lack of documentation and/or formatting examples for the various offsets. Does anyone know what (if any) calculation logic needs to be performed for the ETA, and ETE offsets to get a HH:MM value for each?
This is what my offsets are defined as right now.
// this is what i'm using as my offset definition
const offsets = {
command: 'offsets.declare',
name: 'myOffsets',
offsets: [
{ name: 'altitude', address: 0x0570, type: 'int', size: 8 }, // applied calculation to response - (altitude / (65535 * 65535) * 3.28084).toFixed(0)
{ name: 'heading', address: 0x0580, type: 'uint', size: 4 }, // applied calculation to response - (heading * 360 / (65536 * 65536)).toFixed(0)
{ name: 'tas', address: 0x02B8, type: 'int', size: 4 }, // applied calculation to response - (airspeed / 128).toFixed(0)
{ name: 'ias', address: 0x02BC, type: 'int', size: 4 }, // applied calculation to response - (airspeed / 128).toFixed(0)
{ name: 'eta', address: 0x60E8, type: 'int', size: 4 }, // i'm not sure what calculation is required to get a HH:MM to go?
{ name: 'ete', address: 0x60E4, type: 'int', size: 4 }, // i'm not sure what calculation is required to get a HH:MM to go?
{ name: 'avionicsMaster', address: 0x2E80, type: 'uint', size: 4 },
{ name: 'aircraftName', address: 0x3D00, type: 'string', size: 256 },
{ name: 'lights', address: 0x0D0C, type: 'bits', size: 2 },
{ name: 'playerLon', address: 0x0568, type: 'lon', size: 8 },
{ name: 'playerLat', address: 0x0560, type: 'lat', size: 8 }
]
}
Also, I will open source what I have so far once everything is a bit more flushed out.