I have a function in a DLL that I have to wrap with python code. The function is expecting a pointer to an array of doubles. This is the error I\'m getting:
Are you writing the wrapper in Python yourself? The error saying "expected LP_c_double instance" means it's expecting a pointer to a single double, not an array as you've suggested.
>>> ctypes.POINTER(ctypes.c_double * 10)()
<__main__.LP_c_double_Array_10 object at 0xb7eb24f4>
>>> ctypes.POINTER(ctypes.c_double * 20)()
<__main__.LP_c_double_Array_20 object at 0xb7d3a194>
>>> ctypes.POINTER(ctypes.c_double)()
<__main__.LP_c_double object at 0xb7eb24f4>
Either you need to fix your argtypes to correctly expect a pointer to an array of doubles, or you need to pass in a pointer to a single double like the function currently expects.