Re: IOBluetooth framework not calling my callback, why?
Re: IOBluetooth framework not calling my callback, why?
- Subject: Re: IOBluetooth framework not calling my callback, why?
- From: Bubba Giles <email@hidden>
- Date: Thu, 08 Jul 2004 11:01:11 -0700
What is the status returned from IOBluetoothDeviceRemoteNameRequest() - is
it 0 (success)? Also, you do not need to provide "device_name" to the
function if you are using it asynchronously, so just pass NULL there (not
that it should matter).
jason
>
Hey all.
>
>
when I call IOBluetoothDeviceRemoteNameRequest synchronously, it
>
connects to the remote device, fetches the name, no problem....
>
however, when I provide a callback (as the API provides should result
>
in an asynchronous response coming back at my callback), I just end up
>
'falling through' and my callback never gets called. Any suggestions?
>
>
here are the relevant pieces, thanks in advance for any guidance:
>
>
>
/* The inDeviceRef is properly set up, and the call gets made: */
>
>
IOBluetoothDeviceRef
>
inDeviceRef=IOBluetoothDeviceCreateWithAddress(&device_address);
>
>
status = IOBluetoothDeviceRemoteNameRequest(inDeviceRef,
>
RemoteNameRequestCallback,
>
self,
>
device_name);
>
>
/* Proto and setup of the callback: */
>
void RemoteNameRequestCallback(void* userRefCon,IOBluetoothDeviceRef
>
deviceRef,IOReturn status);
>
>
void RemoteNameRequestCallback(void* userRefCon,IOBluetoothDeviceRef
>
deviceRef,IOReturn status) {
>
printf("Hello");
>
}
>
_______________________________________________
_______________________________________________
bluetooth-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/bluetooth-dev
Do not post admin requests to the list. They will be ignored.