I was trying to access some functions from a dll using python ctypes, but not sure how to pass pointers to get it to work.
Here is an example of what i am trying to call:
GetAvailableDevices ( SdkHandle session, DeviceDetail * pDev_list, uint32_t * dev_list_size )
[in] session Handle to the current sdk session
[in] pDev_list A pointer to an array of DeviceDetail structures that will receive the available device list information
[in,out] dev_list_size On input the size of the pDev_list array, on output the number of items filled into the array.
I tried the following:
from ctypes import * device_list_size = 5 device_list =  dll = cdll.LoadLibrary("C:\Sdk.dll") session = dll.CreateSession() dev_list = dll.GetAvailableDevices(session, pointer(device_list), pointer(device_list_size))
When I run the above i get : *** TypeError: type must have storage info
I am new to ctypes so not sure if this is correct, I would really appreciate if you could tell me the correct way of calling the above function.
Thanks in advance for your help.