This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

multi profile roles:observer and broadcaster



HI,

 is it possible to have the CC2541 run as an observer and broadcaster simultaneously ? Allow the device to  scans for advertisements and to  broadcast non-connectable advertisements?

Thanks!

  • Yes. Just be sure when calling GAP_DeviceInit to enable both roles.

  • Hi

    When combining the observer and broadcaster role, for example adding the simpleBLEBroadcaster to the simpleBLEObserver do you need to duplicate the process event.  In other words will the task  look like this.

    void osalInitTasks( void )
    {
      uint8 taskID = 0;

      tasksEvents = (uint16 *)osal_mem_alloc( sizeof( uint16 ) * tasksCnt);
      osal_memset( tasksEvents, 0, (sizeof( uint16 ) * tasksCnt));

      /* LL Task */
      LL_Init( taskID++ );

      /* Hal Task */
      Hal_Init( taskID++ );

      /* HCI Task */
      HCI_Init( taskID++ );

    #if defined ( OSAL_CBTIMER_NUM_TASKS )
      /* Callback Timer Tasks */
      osal_CbTimerInit( taskID );
      taskID += OSAL_CBTIMER_NUM_TASKS;
    #endif

      /* GAP Task */
      GAP_Init( taskID++ );

      /* Profiles */
      GAPObserverRole_Init( taskID++ );
    GAPBroadcasterRole_Init( taskID++ );

      /* Application */
      SimpleBLEObserver_Init( taskID++ );

    SimpleBLEBroadcaster_Init( taskID );
    }

    Because I am assuming the OSAL will need to process the events separately?

  • Hi, I am going to use BLE as wireless module. then I have  two boards ,one master board and one slave board. I have one question.It is possible that I'm using one  boards 2 min as master and next two minute as slave?? Or Master module is always Master and the other one is slave? it is not possible change the role of module with program of microcontroller? thanks in advance