Quantcast
Channel: Wireless Connectivity
Viewing all articles
Browse latest Browse all 116964

Forum Post: RE: GAVD_Data_Write() is returning a value -65 . what does this error code mean

$
0
0

Hi Vishvesh,

I wanted to check if you were able to hear any audio on the sink by sending the GAVD data repeatedly as you were trying earlier, to make sure that the source implementation and the connection process is working.

I am trying to list the things that you may have to do. We have not developed an application like this but the specs do not prevent it so will work on this with you.

I will recap the things that I would do to develop this and you can check if you are doing the same. This is not an exhaustive list but a starting point. You may already be doing the things listed. 

1.  Send us the PAN module name that you are using. 

2.  Register a source and a sink endpoint (as discussed earlier, source endpoint may not be needed but good to have if headphones wants to connect back)

3. Connect to the headphone, discover the (sink) endpoint, get its capabilities and record the MediaOutMTU. Disconnect.

4. Use this information to set your own capabilities and your MTU.

5. When the source connects to your intermediate device, check what it set the configuration for codec to be in set configuration.

6. Connect to the (end) sink.  Set configuration using the values in #5.

7. When you receive GAVD data, make sure that the length is less than the MediaOutMTU for the end sink, that way you do not have to send it over multiple packets. 

8. Have some mechanism to trigger sending data to end sink once the intermediate device receives data from the master source. 

9. You can tweak the memory, increase it by increasing MEMORY_BUFFER_SIZE in bt_ucfg.h (This may help in the insufficient resource issue)

10. You (intermediate device) may also want to be the master for both the connections. To do this, you should trigger a role change if the remote device connects to the intermediate device and you should not allow the remote device to trigger a role change if you connect to the remote device (the device that initiates the connection is the master) 
to achieve this, use these parameters when you initialize the stack. This will make your application a little rigid but will help in this topology.

//sConnectParams.L2CA_Link_Connect_Request_Config    = cqAllowRoleSwitch;  //This is what it could be in your code. Change this line to

sConnectParams.L2CA_Link_Connect_Request_Config    = cqNoRoleSwitch;

// sConnectParams.L2CA_Link_Connect_Response_Config = csMaintainCurrentRole; //This is what it could be in your code. Change this line to

sConnectParams.L2CA_Link_Connect_Response_Config = csRequestRoleSwitch; 


L2CA_Set_Link_Connection_Configuration(g_uiBluetoothStackID, &sConnectParams);

Hope this helps to get on the same page and it is an effort to make sure we have not missed anything.

Best Regards,

Stonestreet One. 

 


Viewing all articles
Browse latest Browse all 116964

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>