5 Replies Latest reply on Jan 21, 2019 4:42 AM by user_1536336

    Where to call CyBle_GetDeviceAddress() function?

    user_1536336

      Hello,

       

      I try to get a never changing and unique device identifier for the CYBLE-212006-01 BLE module  in PSoC Creator 4.2. I think, the silicon generated device address is the right property here.

       

      2.PNG

       

      So I need to get this device address in my program. Where should I call the function "CyBle_GetDeviceAddress()"? I tried it in main.c without any success, but in StackEventHandler() it works. Are there any pre conditions to call this function?

       

      I tried it like this:

      CYBLE_GAP_BD_ADDR_T test;

      void StackEventHandler(uint32 eventCode, void *eventParam) {

       

      ...

       

      test.type = 0;

      CyBle_GetDeviceAddress(&test);

       

      ...

       

      }

       

      I set test.type to 0, to get the silicon generated device address. Is that right?

       

       

      Thanks!