-
Notifications
You must be signed in to change notification settings - Fork 116
Description
Hello,
First of all, I really want to thank you for providing such an amazing piece of software.
My name is Vamshi, a PhD student from Ryerson University, Toronto, we are working on a project in which we need to control a Prepar3D(P3D) simulation with external data sources (data coming in from a python program...we are using a gps data log file to send data into the simulation.)
I have landed on Python-SimConnect and have been thanking the gods for it serves the exact purpose. I am trying to run the setup and keep running into the following error:
"SIMCONNECT_EXCEPTION_VERSION_MISMATCH"
This is obviously because the SimConnect version being used and the s/w was designed for is FS2020. The P3D sim i am using is P3D V5 which has a simconnect version of 5.1.0. Thus, the server (P3D) does not match the Client SimConnect version.
Since both FS2020 and P3D all develop with SimConnect to send/receive data, this should work.
I've also tried another thing, I've moved the simconnect.dll files from the P3D path into the python project file so that it can reference a dll generated with the libraries compiled on the P3D side. However, I get the following error:
" File "C:\Users\MIMS-PC\AppData\Local\Programs\Python\Python38\lib\ctypes_init_.py", line 391, in getitem
func = self._FuncPtr((name_or_ordinal, self))
AttributeError: function 'SimConnect_Open' not found"
It says simconnect_open not found, in the attributes.py file, we notice that the:
self.SimConnect = cdll.LoadLibrary(library_path)
SIMCONNECTAPI SimConnect_Open(
HANDLE * phSimConnect,
LPCSTR szName,
HWND hWnd,
DWORD UserEventWin32,
HANDLE hEventHandle,
DWORD ConfigIndex)
SIMCONNECTAPI SimConnect_Open is commented out.
These are two possible methods that I am trying right now. Looking forward to your reply and your guidance.
Can you please please please guide me through this? It will help me so much with my studies in creating an amazing data-driven simulation.