VelcroMan 0 Newbie Poster

I'm trying to use the BlueSoleil SDK with Python. To do this i use ctypes to call the BlueSoleil DLL. Here is the code:

import ctypes

print ctypes.cdll.BsSDK.Btsdk_Init()
print ctypes.cdll.BsSDK.Btsdk_StartBluetooth()
	
print ctypes.cdll.BsSDK.Btsdk_StartDeviceDiscovery(0,0,0)
##
print ctypes.cdll.BsSDK.Btsdk_GetInquiredDevices(None,None)

The last call should return the number of active BT devices around, which is 3. But, it returns 0. I tried this in IDLE as well, and waited a while between the two last function calls. (Where the empty comment is). But, no success.

I might have misunderstood something. Here is the docs on Btsdk_GetInquiredDevices():

Btsdk_GetInquiredDevices  
 
Prototype  BTUINT32 Btsdk_GetInquiredDevices ( 
        BTDEVHDL*    pdevice_handles,  
        BTUINT32    max_dev_num 
      );  
Description  The Btsdk_GetInquiredDevices  function  gets a list of   handles  to  the 
device records that are marked as “ Inquired”  devices . 
 
Parameters   pdevice_handles  [out] Pointer to the buffer to receive the device 
handles. If this parameter is set to NULL, the total 
number of available handles is returned. 
 
max_dev_num  [in] Specifies the maximum number of handles 
can be copied to the buffer pointed to  by the 
pdevice_handles   parameter. If  pdevice_handles  is 
set to NULL, the value of  max_dev_num 
parameter is ignored.  
 
Return:   If  pdevice_handle  is not NULL and  max_dev_num  is nonzero, the 
return value is the number of handles copied to the buffer pointed to by 
pdevice_handles. 
 
If pdevice_handle is NULL, the return value is the total number of 
available handles.  
 
 
Remarks 
 
Before calling  Btsdk_Get InquiredDevices , the device database must be initialized by a 
previous successful call to Btsdk_Init. 
 
A device discovered during the inquiry procedure is marked as  an “ Inquired”   device. The 
“ Inquired”  flag will be kept until the next time Btsdk_StartDeviceDiscovery or Btsdk_Done is 
called.