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.

CC2541: CC2541 based HM-10 avoiding sleep mode

Part Number: CC2541

Hi all,

I am using HM-10 as a prototype which is based on CC2541. My system is mains powered and hence i don't require to place device in sleep mode. I want that device should advertise always when not connected to phone so that anytime phone can connect to it. But i am finding that after certain time HM-10 stops advertising and hence i am not able to connect to it. I would like to tell that this ready made module doesn't have 32.768khz crystal placed on it.

Can anyone please suggest how i can make the device advertising when not connected? I have not defined POWER_SAVING pre-processor.

Also is 32.768KHz crystal necessary to place?

I would also like to add that i am not using HM-10 AT command. In stead i am using HM-10 module just as CC2541 device and programmed with TI BLE stack.

Regards

Singh

  • I have found solution but I don't know if this is correct approach or not.
    I have commented below function which is called during initialization in SimpleBLEPeripheral_Init()
    "GAPRole_SetParameter( GAPROLE_ADVERT_OFF_TIME, sizeof( uint16 ), &gapRole_AdvertOffTime );" which turns off advertising after 30sec by default.

    other approach i found is create timer based event to enable and start advertising every 25sec.

    I know advertising always is not good practice but Idea to advertise always is because i don't want any external intervention like switch press as it is not accessible to user. Also anytime app needs to connect to module and for this module should always be in advertising mode.

    Is there any problem with this approach?
    Any other approach is most welcome.

    Regards
    Singh
  • It sounds no problem with your implementation.