measurement of RSSI or transit time of a message via BLE with the Nordic 52840 and another slave board.

I have this problem, with a Nordic nRF52840 board I have to transmit a byte of known length, which I have to select a priori, and transmit it to a second slave evaluation board and then measure the RSSI value and the time it takes for the data packet to arrive depending on where the board is located, thus also going back to the distance value at which the two boards are located.
I would then also like to do the same thing with my android smartphone used as a slave.

I have tried to follow the examples I can find of nRF connect for desktop a bit, and in particular the codes available in visual studio code, but the standard codes there do not seem to answer my question.
Could you perhaps help me by explaining where to find an example code to modify to achieve this, and how to program the second board via the nRF52840?

thanks in advance!

Parents Reply Children
  • Hi Amanda, thanks again.

    I tried connecting the BC840E to the PC and launching from the command line "C:\Users\leonardo\Documents\CHARM\nrf_dm_mod\build_1\zephyr>nrfjprog -f NRF52 --program zephyr.hex --chiperase --reset" (I moved to the path you see because it contains my zephyr.hex build result nrf_dm)

    however with only BC840E I get this error: "C:\Users\leonardo\Documents\CHARM\nrf_dm_mod\build_1\zephyr>nrfjprog -f NRF52 --program zephyr.hex --chiperase --reset
    ERROR: No debuggers were discovered.
    NOTE: For additional output, try running again with logging enabled (--log).
    NOTE: Any generated log error messages will be displayed.

    So I also connected the nRF52840 board to the PC and connected it to the BC840E via the 10 wires. This time the error disappeared: "C:\Users\leonardo\Documents\CHARM\nrf_dm_mod\build_1\zephyr>nrfjprog -f NRF52 --program zephyr.hex --chiperase --reset
    [ #################### ] 0.376s | Erase file - Done erasing
    [ #################### ] 1.997s | Program file - Done programming
    WARNING: A programming operation has been performed without --verify.
    WARNING: Programming can fail without error.
    Applying system reset.
    Run."

    However, I suspect that by doing this I am programming the nRF52840 board and not the BC840E board.
    And I also don't know how to verify that the BC840E was flashed with my zephyr.hex program correctly.

  • Hi, 

    The recommended way to program and debug nRF52-based products is using an nRF52 DK (an nRF52840 DK in your case), this is also stated in the BC840 datasheet, page.17. I have corrected my previous reply.

    Regards,
    Amanda H.  

  • Hi Amanda,

    I have reviewed the page you pointed me to over and over again, but unfortunately it only explains how to make the connections.
    For the part of the code to load problem (not solved), I refer you to my answer above (23 hours ago from now), when I put the code provided by datasheet into the command line.

    Since I haven't been able to programme this board for more than two weeks, would it be possible to arrange a quick video call to solve the problem?

    Thanks in advance!

  • Hi, 

    Unfortunately, I don't have the BC840E board to show you the connection, but it's the same as the datasheet showed. Please make sure to provide power to both nRF52840DK and the BC840E board. Let the J-Link Commander can detect the board with 3.3v 

    -Amanda H.

  • Hi Amanda,

    OK, the 2 boards are connected to the computer's usb and connected to each other via the '10-conductor cable for connection'.
    I opened J-link Commander and it returns exactly what you showed me in the reply above.
    Now what is the next step?

Related