This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Is there a way to emulate BLE packet error?

Hello, Is there a way to test packet corruption? My setup would be that I have my FW in nRF52-DK. Then I would test communication using nRF51-Dongle. I would like to force dongle to corrupt selected packet. By this I would like to test that nRF52-DK application is correctly reacting for tested packet corruption. Is it possible with dongle? If so can you point me to some API/example? Or if it is not possible with dongle is there some other way how to do it?

Parents
  • Hi,

    Generally you can look at the Direct Test Mode along with application note An34 (and added python scripts).

    If a packet is dropped in BLE it will automatically be resent, this is part of the protocol. So it might not make sense to handle things based on a single packet failing.

    Best regards,

    Øyvind

  • Thank you for links. But DTM seems rather to test BLE HW. I would rather like to test application. My previous experience is that I used Alpwise stack before. For example in alpwise API during connection you call BLEGAP_ConnectWithIntervals() and you wait for TaskBLE_GAP_CB_Connected(). IT works 99% of times. But sometimes when specific packet is corrupted the TaskBLE_GAP_CB_Connected() is never called and application waits forever. When I debug it I add my own timer and handle the case. I'm not sure yet how robust Nordic API is but I would like to have tools on dongle side to kill some packets. For example when my app is in role CENTRAL and sends CONNECT_IND packet I want to kill this packet so dongle reacts as if it never received packet. And I want to test that API returns me some error after some timeout, or I will add timeout myself. I want to test my application + Nordic API that system works for errors in any packet. For that I need to have tools to kill selected packets... And perhaps the answer is that such tools does not exists...

Reply
  • Thank you for links. But DTM seems rather to test BLE HW. I would rather like to test application. My previous experience is that I used Alpwise stack before. For example in alpwise API during connection you call BLEGAP_ConnectWithIntervals() and you wait for TaskBLE_GAP_CB_Connected(). IT works 99% of times. But sometimes when specific packet is corrupted the TaskBLE_GAP_CB_Connected() is never called and application waits forever. When I debug it I add my own timer and handle the case. I'm not sure yet how robust Nordic API is but I would like to have tools on dongle side to kill some packets. For example when my app is in role CENTRAL and sends CONNECT_IND packet I want to kill this packet so dongle reacts as if it never received packet. And I want to test that API returns me some error after some timeout, or I will add timeout myself. I want to test my application + Nordic API that system works for errors in any packet. For that I need to have tools to kill selected packets... And perhaps the answer is that such tools does not exists...

Children
No Data
Related