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

nrf52832 , switch central mode to peripheral mode

Hi, 

I have to nrf52832 , s132 modules working as peripheral and central.

I would like to get an idea and input on how to change central mode to peripheral mode.

The purpose of my project is to fetch the advertising device RSSI (nrf52832- peripheral)and then forward(nrf52832 central mode to peripheral mode) the data to another BLE module and publish the data.

1) How to change the operating modes?

2} What are the settings that i should consider at the peripheral that is advertising?

3)How can i proceed ?

4) How can i send the RSSI values of the advertising packet, in the scan report of central after changing in the operating mode to peripheral to advertise that data?

Thanks,

Uma

Parents Reply Children
  • is there a way where i do not switch modes but send over the advertising device RSSI  in the scan report of central to other device?
    How can do that.

  • If you have both modes running at the same time, and all the time, then there is no need for mode switching.

    As far as putting stuff into a Scan Report, it really makes no difference where the data comes from - it's just data!

  • Hi,

    Is the following what you are looking for?

    Device A, in the broadcaster role. This is the device advertising.

    Device B, combining the observer and peripheral roles. This is the device listening to the advertisements to determine RSSI, which it then sends over a BLE link to device C.

    Device C, in central role. This is the device receiving the RSSI reports. (The reports describe the signal strength of Device A when received by Device B.)

    S132 lets you run roles concurrently, so you use the SoftDevice API (either directly or through SDK libraries) to set up the activities that you need. They will then run concurrently (you do not have to manually switch between e.g. observing and connecting as peripheral.) I can direct you to relevant examples when I know what roles and behavior you are looking for.

    Regards,
    Terje

  • This kind of thing is really hard to explain in words - especially when there's also a language barrier!

    I think  needs to provide a diagram illustrating the requirement.

    This is from the Relay example that I mentioned earlier:

    So, in 's post, 

    • 'Device A' would be the 'Peripherals';
    • 'Device B' would be the 'Relay' - which would be 's device;
    • 'Device C' would be the 'Central'.

  • Hi,

    This is what trying to achieve.

    Device 1: in the broadcaster role. This is the device advertising.

    Device 2 : in the broadcaster role. This is the device advertising.

    Central :Scanning and getting RSSI (as of now this is just as observer)

    Another peripheral : have to establish connection with that central and get the RSSI values and publish to know which device is nearer to central.(something like having the advertising devices on the assets and then tracking them ).

    I hope i am a bit more clear

Related