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

Major and Minor value change in code not reflecting

Hello,

Coming from different background. I am learning about how to turn my nrf52840 practically useful in indoor localization task.

First step I have adopted the example of ble_app_beacon and this is what pretty much I need, a beacon.

Now i would like to customize it. I have changed the major and minor value on line 75 and 76 in main.c of ble_app_beacon example as:

Major -> 0x01 , 0x01 

Minor-> 0x22, 0x22 

But unfortunately, same old values are reflecting back in the nrf connect mobile app. and yes i have rebuild and reloaded the softdevice and newly hex file for app.

Any help is much appreciated.

I am using sdk 16 and softdevice S140 v7.0.1

Thank you very much

Parents
  • Hi.

    That sounds very strange. I just tested this myself, and I have no problem changing and displaying the new values of the Minor/Major value.

    Are you sure that you flashed the new .hex file with the different values?

    Did you erase the flash before downloading the new .hex file to your board?

    Br,
    Joakim

  • Hi Joakim, 

    Thank you for your answer. 

    1. Yes, I load the correct newly build hex file.
    2. I have not erased the dongle, because I read in the programming tutorial with bolded " Caution " so i just didn't try it. Because these resources are sponsored by clients so I do not want it to malfunction. 

    But, I feel maybe its because the old program is embedded and I may need to erase memory contents. 

    If it is safe ( without erasing operating system ) how can I do that?

    Thank you very much.

Reply
  • Hi Joakim, 

    Thank you for your answer. 

    1. Yes, I load the correct newly build hex file.
    2. I have not erased the dongle, because I read in the programming tutorial with bolded " Caution " so i just didn't try it. Because these resources are sponsored by clients so I do not want it to malfunction. 

    But, I feel maybe its because the old program is embedded and I may need to erase memory contents. 

    If it is safe ( without erasing operating system ) how can I do that?

    Thank you very much.

Children
Related