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

Bluetooth uart and ANT

Dear Members,

I have a question related with bluetooth as UART port,

Is it possible that I use this code base as a starter ?

E:\nRF5_SDK_17.0.2_d674dde\examples\ble_peripheral\ble_app_uart\main.c

I'm using ANT and nRF52840,

Any suggestions ?

Best regards and thanks,

Parents
  • Hi Torbjorn,

    I want to collect data from ANT sensor then transmit the data using bluetooth to my mobile phone ?

    Do you have any codes for ANT collecting data from crank power meter ? so far I have cadence, speed and HRM,

    I want to collect sensor data from power meter as well on the bike,

    Can I reuse the code inside this :

    E:\nRF5_SDK_17.0.2_d674dde\examples\ble_peripheral\ble_app_uart\main.c

    I want to merge with the code in :

    E:\nRF5_SDK_17.0.2_d674dde\examples\ant\experimental\ant_shared_channel\m2m\main_hrm_bsc_lcd.c

    Regards,

  • Hi 

    Thanks for the description. 

    We don't have any examples for the power meter profile unfortunately, but there are library files for it so it should be possible to modify one of the existing ANT+ examples to use BPWR:
    \nRF5_SDK_17.0.2_d674dde\components\ant\ant_profiles\ant_bpwr

    As for merging these two examples this is a bit more work I am afraid. 

    I would recommend starting out with the ble_app_uart example, and merge the ANT example into this, as the Bluetooth examples require a lot of additional libraries and configuration settings that can be hard to set up from scratch. 

    Essentially then the work looks like this:

    1) Change the ble_app_uart example to use the S332 SoftDevice instead of the S132. 

    2) Change one of the existing ANT+ examples to use the BPWR profile. 

    3) Try to merge the various files, code and configuration from the ANT+ example into the ble_app_uart example. 

    Best regards
    Torbjørn

  • Hi Torbjorn,

    Thanks for the reply,

    I have merged ANT+ BSC and HRM, I'm thinking now to merge them with BLE_UART and

    ANT_BPWR,

    E:\nRF5_SDK_17.0.2_d674dde\examples\ant\ant_plus\ant_bpwr\bpwr_rx\main.c

    I got issues when compiling ant_bpwr from original source :

    ..\..\..\..\..\..\..\..\components\libraries\util\sdk_errors.h(73): error:  #5: cannot open source input file "nrf_error.h": No such file or directory

    I reckon it's related with folder option for library in Keil,

    any ideas on rectifying it?

    Best regards,

  • Hi 

    I actually see similar issues when trying to build the examples. 

    I don't normally handle ANT cases, so I will have to do some checking internally to see if this is a known issue. 

    I will do my best to get back to you by tomorrow. 

    Best regards
    Torbjørn

  • Hi again

    Apparently it is necessary to download the ANT SoftDevice, network keys and similar from them directly. It is not included with the SDK out of the box. 

    Someone took the time to write down all the steps in this case:
    https://devzone.nordicsemi.com/f/nordic-q-a/63928/ant-softdevice-integration-into-ant-example-projects-for-nrf5-sdk-17-0-0

    Best regards
    Torbjørn

Reply Children
No Data
Related