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.

cc2540 broadcasting mode



Hi all,

Am using the keyfob with keyfobdemo application and dongle flashed with host Test Releaseall Project ,

In the keyfobdemo app ,i have the advertisement flag as GENERAL and i have set the

initial_advertising_enable = TRUE;

In the preprocessor i have enabled the PLUS_BROADCASTER=TRUE .

i have removed the pheripheral.c and pheripheral.h file from the keyfob demo project and added the pheripheralBroadcaster.c and pheripheralBroadcaster.h file .(as mentioned in the software developer guide ) 

But after flashing this hex file ,i cannot able to find my keyfob while scanning ?

My final goal is to make the device advertising forever ( even in the connection state ) ,So when i establish the connection with the key fob from the dongle_1, i will scan again from the other dongle_2 ,I should able to get the advertisement from the keyfob ,which proves it is always advertising !

In the above steps , when i use the pheripheral.c and pheripheral.h(instead of pheripheralBroadcaster.c and pheripheralBroadcaster.h ) ,i can able to scan my device from the dongle_1 and i can establish the connection ,but when i scan the device from the other dongle_2 ,i cannot receive any advertisement from the keyfob because the keyfob is in connection with the Dongle_1 ,when i terminate the connection with Dongle_1, Dongle_2 is receiving advertisement while scanning ! 

Kindly help to resolve this !

Thanks ,

Senthil

  • Hey Ti folks .

    Any reply on this issue ?? Am expecting some HELP ! 

    I forget to mention that i am using the BLE 1.2 .

     Thanks in advance ,

    Senthil

  • Senthil kumar103423 said:

    My final goal is to make the device advertising forever ( even in the connection state ) ,So when i establish the connection with the key fob from the dongle_1, i will scan again from the other dongle_2 ,I should able to get the advertisement from the keyfob ,which proves it is always advertising !

    Core v.4:

    1.1.1 State and Role Combination Restrictions

    The Link Layer in the Connection State shall not operate in the Master Role and Slave Role at the same time.

    The Link Layer in the Connection State operating in the Slave Role shall have only one connection.

    The Link Layer shall not operate in the Initiating State if the Link Layer is already operating in the Connection State in the Slave Role.

    If the Link Layer is already operating in the Connection State or Initiating State, the Link Layer shall not operate in the Advertising State with a type of advertising that could result in the Link Layer entering the Connection State in the Slave Role.

  • Leo Thanks for Reply ,

    • The Link Layer in the Connection State shall not operate in the Master Role and Slave Role at the same time.

    • The Link Layer in the Connection State operating in the Slave Role shall have only one connection.

    But in my case , I want my slave in connected state ,to advertise "unconnectable undirected advertisement " ,So that i don't want to establish the connection with other device to make the link layer to act as a slave for two Masters ,But i want that advertisement ,because i want other masters to detect the slave ( in connection state ). 

  • Hi Ti Folks ,

    In the Software developer's guide ( SWRU271B Version 1.2 ) ,it is mentioned in section 3.4.2 

    ================================================================================

    GAP Peripheral / Broadcaster Multi-Role Profile
    The peripheral / broadcaster multi-role profile operates almost identically to the peripheral role
    profile; however it provides additional functionality allowing the device to operate in both the
    peripheral and broadcaster GAP roles simultaneously. In order to use this multi-role functionality,
    the files peripheral.c and peripheral.h should be excluded from the build, and the files
    peripheralBroadcaster.c and peripheralBroadcaster.h should be included. In addition, the
    preprocessor value PLUS_BROADCASTER should be defined when using the peripheral /
    broadcaster multi-role profile.

    ================================================================================

    I have followed the same but I cannot even find the advertisement while scanning i.e Pheripheral role itself not working ,

    am i missing something ?

    Kindly pay attention promptly ! 

    Regards,

    Senthil

  • Hi ,

    It can be solved by removing the BROADCASING PART in void GAPRole_Init( uint8 task_id ) function in the line  

    gapRole_profileRole = (GAP_PROFILE_PERIPHERAL | GAP_PROFILE_BROADCASTER );

    i.e. 

    gapRole_profileRole = (GAP_PROFILE_PERIPHERAL );

    Regards ,

    Senthil

  • Hello,

    Put an example with some updates to peripheralBroadcaster and app to change adv data  on the wiki at

    http://processors.wiki.ti.com/index.php/Category:BluetoothLE

    The profile role init mentioned above should be in 1.2.1 already, but you are correct that it was an issue in 1.2, as the peripheral lib contains all the functionality for peripheral and broadcaster.

    BR,

    -Greg

  • Hi Greg

    I have downloaded the application and integrated the relevant changes. It works well.  I have observed that when in connection and sending adv packets, the rate of sending adv packets is roughly 1sec.  How can I change this rate?  

    thanks in advance

    ~LD

  • Hello,

    i also download the "PeripheralBroadcaster - Peripheral device sending out advertisements while connected. "  form wiki web side.

    but i can not success for advering  while connected. could you help what  " integrated the relevant changes" need to add.

    thansk

  • Hi Ewing ,

    It can be solved by removing the BROADCASING PART in void GAPRole_Init( uint8 task_id ) function in the line  

    gapRole_profileRole = (GAP_PROFILE_PERIPHERAL | GAP_PROFILE_BROADCASTER );

    i.e. 

    gapRole_profileRole = (GAP_PROFILE_PERIPHERAL );

    Kindly see the entire post ,where it is already posted ,moreover i think the link shared by Greg has a File that will work straight away ! 

    Nice Day,

    Senthil