Ok. I have found error in your code.
In the fourth argument you must pass a pointer to the first drawing element in the list of elements.
0, // Callback...
First of all. Have you tried to convert SDK example project "CGaugeSample" to Visual Studio 2019? Does it works? I mean can you load and see gauges from that example in your test airplane? have you also copied debug information (*.pdb) file with the dll before start debuger?
I have found a solution, not perfect by the way.
I guess that P3D (FSX) uses DirectSound (dsound.dll) primary buffer. I have tried to add DirectSound to the Pop-Up window and do some Cooperative, but I don't know what settings P3D (FSX) uses. If sim have used DSBCAPS_GLOBALFOCUS may be it will...
I have also tried not to mute sound from sim main window, but unsuccessful. I know that it possible. Look at the IVAO pilot client. Client's main window has focus for keyboard and mouse and doesn't mute sim sound. Default kneeboard window also doesn't mute sim sound.
Try to unregister your add-on directory.
"%P3D%\Prepar3D.exe" "-Configure: Category=Add-on Package, Operation=Remove, Title=SimVariableModule"
Then run P3D and after that again register it
"%P3D%\Prepar3D.exe" "-Configure: Category=Add-on Package, Operation=Add, Title=SimVariableModule...
The Indago UAS in P3D v4.5 was impelented using PDK and the module is located inside SimObjects\Modules\Quadrocopter.dll library. You can see that sim.cfg file contains CategoryId = GUID. It loads data from xml files as parameters. Properties that exposed in Control directory can be mapped from...
1. You can do it anly with buttons not axis. Current implemenation (%P3D%\SimObjects\Modules\Quadrocopter.dll) has registered control properties like "ThrottleSet", "ThrottleRelease" and etc. with EVENTTYPE_NORMAL (not EVENTTYPE_AXIS). You can set you key assignment (Joystick or Keyboard) in...
First of all we can't see you code, both PDK addon and SimConnect client. I can't tell you are doing right or wrong.
As far as I know, your statements are wrong. Properties and Events that you have registered to your SimObject are accessible from SimConnect clients (maybe scripts, I don't sure)...
There are some ways:
1. Create simulation behaviour for your SimObject using ISimulation interface and P3D will process it with specified frequency when instances of your SimObject exists. (Simplest and recommended way)
2. Register static methods as Callbacks to the messages of sim events using...
I'm using Visual Studio 2015 and as far as I know VS2017 works the same. The trick is that VS automatically attach debugger to your dll from project output directory. You don't need to copy it somewhere every time.
1. Has you created add-on.xml file for your dll?
For my example above it's copied...
Events for properties in terms of P3D connects name of event with your Set function.
I use Visual studio to debug dll. My projects settings are:
Debugging -> Command = $(P3D)\Prepar3D.exe
Debugging -> Working Directory = $(P3D)
note that P3D and P3D_SDK are user variables in Windows that points...
For the slow dive into PDK with examples I recommend (by increasing complexity): DataHarvester -> CustomPDKObjects -> CameraPDK -> SimpleCar -> SimpleAirplane -> Engine -> RadarAltimeter ...
First three of them are not SimObjects but global plugins.
It's not hard but powerfull.
For GUID (Global Unique IDentifier) generation use GUIDGenerator.exe in SDK folder or from the Visual Studio menu Tools->Create GUID :p
About IUknown and other stuff look for COM (Component Object Model) documentation and tutorials 1, 2. Actually you need to know the...
Hi RED COOL.
As I know, in PDK you can register custom Properties and Events callback for that properites which can be accessed via scripts and SimConnect clients for:
1. SimObjects (using ISimObjectManager for a class of SimObjects or using IBaseObject interface for the instance of existing...