CYW20719 SPP sending data hasn't completed by using API (wiced_bt_spp_rx_flow_enable)

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

cross mob
SeunghanLim
Level 5
Level 5
Distributor - Changnam INT
250 sign-ins 50 replies posted 50 questions asked

When we sending data via SPP, we are using API  'wiced_bt_spp_rx_flow_enable'  

We are testing In case of above,  last some data cannot be sent 

 

Test condition :

     PC : Bluetooth intergrated  on board

    Teraterm  Termianl : PC Side  & Device(CYW20719) Side 

                                          Setting -> local echo off 

     Eclipsed IDE Modustoolbox2.3 Wiced BTSDK v3.10

 

 Test application :

       Modustoolbox RFCOMM_Serial_port base

       Timer added for  writing data through PUART

       MEMCPY will be called in case of RFCOMM data receiving or Timer calling.

        wiced_bt_spp_rx_flow_enable  function  will be called as following the buffer size increasing .

 

   Test method :

          PC scanning DEVICE(20719EVK) -> Connect -> Open Serial port with TERATERM -> Local Echo off ->  Sending file( more than 20KB)  -> Log check

spp_rx_data_callback handle:2 len:100 20-61, total rx 18500
spp_rx_data_callback handle:2 len:100 63-61, total rx 18600
spp_rx_data_callback handle:2 len:100 79-74, total rx 18700
spp_rx_data_callback handle:2 len:100 68-72, total rx 18800
spp_rx_data_callback handle:2 len:100 65-76, total rx 18900

Disable flow
spp_rx_data_callback handle:2 len:100 69-73, total rx 19000
spp_rx_data_callback handle:2 len:100 0d-63, total rx 19100

En flow
spp_rx_data_callback handle:2 len:100 68-67, total rx 19200
spp_rx_data_callback handle:2 len:100 20-2c, total rx 19300
spp_rx_data_callback handle:2 len:100 20-73, total rx 19400
spp_rx_data_callback handle:2 len:100 20-64, total rx 19500
spp_rx_data_callback handle:2 len:100 6f-20, total rx 19600
spp_rx_data_callback handle:2 len:100 72-74, total rx 19700
spp_rx_data_callback handle:2 len:100 75-20, total rx 19800

        If you send a one byte character by press keyboard in PC Side terminal,  You can find out 100byte length data be recieved in device side on teraterm.

       ex) spp_rx_data_callback handle:2 len:100 6d-64, total rx 66400

      this phenomenon will keep going until bluetootn connection lost.

 

 

 

 

Daniel Lim
0 Likes
1 Solution
Owen_Zhang123
Moderator
Moderator
Moderator
5 questions asked 500 solutions authored 250 sign-ins

Could you try to enable the flow control in the connection_up event? Per my test, there is no problem to enable the flow control once the connection is created. Please do not disable/enable the flow control during the transfer.

View solution in original post

5 Replies