SPP(BR/EDR) SPP BR-EDR CYBT413055 02 EVAL MASTER MODE

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
237_KGKT
Level 2
Level 2
25 sign-ins 10 replies posted 10 sign-ins

I am currently working on the SPP sample program on CYBT-413055-02 EVAL and it is working fine. That means I can connect to any Android phone (terminal app). The phone works like a master, then it initiates the connection with the EVAL board. The EVAL is in slave mode

[CYBT-413055-02 EVAL] <<==BR/EDR=<< [Android Phone]


I now need to initiate the connection with the EVAL board.

[CYBT-413055-02 EVAL] >>==BR/EDR=>>[Android Phone]

I tried this with the API wiced_bt_spp_connect from the spp library, but it didn't work. I think I need to put the EVAL board in master mode first (to start inquiry and paging) before trying to reconnect.

I found out that there are many steps that I need to follow

 

  1. Start an inquiry if peer device address is unknown . API wiced_bt_start_inquiry (in wiced_bt_dev.h file for API details)
  2. inquiry scan call back will list all the peer BT classic devices
  3. You can send a pair request to the concerned peer device if needed . API wiced_bt_dev_sec_bond
  4. You can send SPP profile level connection Spp connect . Check API wiced_bt_spp_connect in spp_lib.c

 

  1. Begin BR/EDR inquiry for peer devices with => wiced_bt_start_inquiry(&spp_inq_parms,spp_inquiry_result_cback_t);

for the Inquiry parameter =>

wiced_bt_dev_inq_parms_t     spp_inq_parms =
{
.mode = BTM_GENERAL_INQUIRY,
.duration = 250,
.filter_cond_type = BTM_FILTER_COND_BD_ADDR,
.filter_cond???

};

  1. The Inquiry parameter are not complete or maybe wrong
  2. I do not now how i can handle the "inquiry result callback"

 

@AnjanaM_61 

0 Likes
1 Solution

What's the peer device for your application? Could you try to use two modules for the test first?

If you are using a phone, you need to open a spp app on the phone to initiate the spp service. And there may be some compatible problems with different apps.

View solution in original post

0 Likes
3 Replies
Owen_Zhang123
Moderator
Moderator
Moderator
5 questions asked 500 solutions authored 250 sign-ins

Please check the audio watch demo for the inquiry and inquiry result callback procedure.

The related code is located in hci_control_inquiry and hci_control_inquiry_result_cback.

@Owen_Zhang123  Thank you! It was Very helpful

it is now possible to list the device around me. But i cannot succesfully initiate a connection with them

by an attempt to connect the "wiced_bt_spp_connection_failed_callback_t" ist perfomed

how can i fix this.

I am using ModusToolbox 2.4 /2.3

@AnjanaM_61 

0 Likes

What's the peer device for your application? Could you try to use two modules for the test first?

If you are using a phone, you need to open a spp app on the phone to initiate the spp service. And there may be some compatible problems with different apps.

0 Likes