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

pc-ble-driver compiled hex fail to work

Hi,

I have been having issues with the compile hex files I get when following the steps to build the pc-ble-driver ().  While I am able to build the hex files when I place them on my NRF52840 they fail to work with my pc-ble-driver-js code I have.  The connectivity_1.2.3_115k2_with_s132_3.1.hex file provided at (https://github.com/NordicSemiconductor/pc-ble-driver/tree/2d97262fa9940cb815778f01af9d05093558a72c/hex/sd_api_v3) works perfectly fine though.  I would assume when I build using the source code I would get a similar file.  Is there a compile time flag that I need to use to get this file?  My generated hex file is about 200 lines longer and has an extra segment in the nrfjconnect programming tool.  Below are the commands I issued to generate my hex files after setting up the build environments on my ubuntu vm.

git clone github.com/.../pc-ble-driver.git
cd pc-ble-driver/
mkdir build; cd build
cmake -G Ninja -DASIO_INCLUDE_DIR=~/build/vcpkg/installed/x64-linux/include -DCatch2_DIR=~/build/vcpkg/installed/x64-linux/share/catch2/ ..
cmake --build .
cd ../hex
mkdir build; cd build
cmake -G Ninja -DCOMPILE_CONNECTIVITY=1 -DCONNECTIVITY_VERSION=1.2.3 ..
cmake --build . --target compile_connectivity

  • Thanks for that suggestion about the s132 v3.1 it was not included in my hex folder I had copied down from git.  I had a version that was built on the master branch and found the SoftDevice in the hex folder there.  Unfortunately my generated hex file using that soft device still was not a working version.  The size actually grew it seemed and was 30kb larger than the hex included in the solution.  

    I attached the connectivity hex file generated in the sdk/nRF5_SDK_12.2.0_f012efa/examples/ble_central_and_peripheral/ble_connectivity/pca10040/ser_s132_hci/armgcc/_build folder.  Let me know if there is anything else I can answer.

    Thanks,

    Derek 


    5238.nrf52832_xxaa.hex

  • Hi,

    Instead of the master branches for pc-ble-driver and pc-ble-driver-js you should use proper releases. Otherwise you may get partial functionality and/or it may be difficult to find the correct combination of pc-ble-driver, pc-ble-driver-js and connectivity firmware. Up until now, pc-ble-driver-js has included the right commit of pc-ble-driver as a git submodule, which means that is the preferred way to get the right version of pc-ble-driver and connectivity.

    Looking at the hex file that you provided it is evident that the version_info_t data structure is not present. Can you check the project (in the SDK folder that the bootstrap script downloaded) and confirm that <sdk folder>/examples/ble_central_and_peripheral/ble_connectivity/main.c contains from around line 40 a typedef for version_info_t, followed by an instance of that struct filled with values, as found in this patch file?

    Regards,
    Terje

Related