I am trying to read TCAS data and tried to read offset F068 (Traffic Range) but it returns 0, see if you can see where I am going wrong :D
Dim dwResult As Long
Dim range As Byte
FSUIPC_Read &HF000, 1, VarPtr(range), dwResult
FSUIPC_Process dwResult
MsgBox range
I have also tried to 'inject' the TCAS structure in to offset 1F80 as it says to in the FSUIPC SDK, but still no avail.
Public Type TCASData
id As Single
lat As Long
lon As Long
alt As Long
hdg As Integer
gs As Integer
vs As Integer
comm As Integer
stat As Byte
call As String * 15
End Type
Dim tDat As TCASData
Dim dwResult As Long
FSUIPC_Write &H1F80, Len(tDat), VarPtr(tDat), dwResult
FSUIPC_Process (dwResult)
And then I try reading the offset above and it still doesnt work :? . I hope I have explained it ok and I hope you are able to help.
Thanks
Craig