Jump to content
The simFlight Network Forums

Recommended Posts

Posted

Hi Paul,

Found a way to make your DLL crash.  According to your docs, if I want to read a FSUIPC Offset with a size of 1, I should use 'byte' or 'sbyte'.  I've not had any issues with using 'byte' however any 'sbyte' will throw an exception when you do the FSUIPCConnection.Process(); command.  For instance, if you define this sbyte offset to be able to read the glideslope (0C49 1 NAV1 Glideslope Needle: –119 up to +119 down):

private Offset<byte> glideslope = new Offset<byte>(0x0c49);

Once the debugger hits, the Process() command, the exception of

System.InvalidCastException: 'Specified cast is not valid.'

Weird thing is it causes an exception not on the first time through but on subsequent runs.

- Dirk

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.