Hi Pete and Roman,
Thank you both for posting all this info, and sorry for not replying right away. I actually went with Pete's advice and learned how to program in lua with offsets. Found it not too hard and super useful. Here is my two-liner for setting the Obs:
-----
obs2=ipc.readSW(0x0C60) * 360 / (65536) +180
ipc.writeSW(0x0C5E,obs2)
----
And here is how I set the heading bug:
----
lat, lon, alt, pitch, bank, hdgT = ipc.readStruct(0x0560,"3DD", "2SD", "1UD")
hdgM = hdgT - (ipc.readSW(0x02A0) * 65536)
hdgM = hdgM * 360 / (65536 * 65536)
ipc.writeSW(0x07CC,hdgM*65536/360)
------
Programmed a few other things too, like displaying current Dme distance in the Lua window.
Thanks Pete for such a useful tool!! I wouldn't be able to do my IFR training at home without it.
Val