This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Apple Notification Center Service (ANCS) in Zephyr OS

Hello everyone!

Has anyone ever implemented ANCS  (Apple Notification Center Service) in ZephyrOS?

We are using nRF51822 SoC with the goal to connect to the smartphone running iOS and exchange data. Do we need to implement ANCS in the code even though we don't want to receive BLE notifications from the smartphone?


I know that in nRF Connect SDK ANCS is part of the stack (link).

Thanks in advance for your time and efforts.

Sincerely,

Bojan.

Parents
  • Just to shed more light on the issue...

    It seems we need ANCS implemented in the firmware so that the iOS application running in the background mode can receive notifications from nRF51.

    Can we implement ANCS in nRF51822 running Zephyr OS?

  • Hello,

    Yes, the ANCS GATT server is on the phone, and you need to implement the client for it on the nRF side. While we generally do not recommended using the 51 series with Zephyr (Compatibility matrix), I don't see any reasons for why it should not work either.

    Have you tried to build our ANCS sample with your Zephyr installation?

    https://github.com/nrfconnect/sdk-nrf/tree/main/samples/bluetooth/peripheral_ancs_client

    Best regards,

    Vidar

  • Hello, .

    Thanks for the useful info. I am using Zephyr v2.6.0 and the west tool for compilation (so it's not nRF Connect SDK-based environment).

    When I included the following ANCS-related things from the peripheral_ancs_client example into the prj.conf file:

    CONFIG_BT=y
    CONFIG_BT_PERIPHERAL=y
    CONFIG_BT_DEVICE_NAME="ANCS"
    CONFIG_BT_SMP=y
    CONFIG_BT_GATT_CLIENT=y
    CONFIG_BT_GATT_DM=y
    
    # Enable ANCS client
    CONFIG_BT_ANCS_CLIENT=y
    
    # Enable GATT Service client
    CONFIG_BT_GATTP=y
    
    # Enable bonding
    CONFIG_BT_SETTINGS=y
    CONFIG_FLASH=y
    CONFIG_FLASH_PAGE_LAYOUT=y
    CONFIG_FLASH_MAP=y
    CONFIG_NVS=y
    CONFIG_SETTINGS=y

    and tried to compile, I got the following errors:

    prj.conf:39: warning: attempt to assign the value 'y' to the undefined symbol BT_GATT_DM
    prj.conf:42: warning: attempt to assign the value 'y' to the undefined symbol BT_ANCS_CLIENT
    prj.conf:45: warning: attempt to assign the value 'y' to the undefined symbol BT_GATTP
    
    error: Aborting due to Kconfig warnings
    

    Do you have any idea what I am missing here?

    Thanks in advance.

    Cheers Beers!

    Bojan.

Reply
  • Hello, .

    Thanks for the useful info. I am using Zephyr v2.6.0 and the west tool for compilation (so it's not nRF Connect SDK-based environment).

    When I included the following ANCS-related things from the peripheral_ancs_client example into the prj.conf file:

    CONFIG_BT=y
    CONFIG_BT_PERIPHERAL=y
    CONFIG_BT_DEVICE_NAME="ANCS"
    CONFIG_BT_SMP=y
    CONFIG_BT_GATT_CLIENT=y
    CONFIG_BT_GATT_DM=y
    
    # Enable ANCS client
    CONFIG_BT_ANCS_CLIENT=y
    
    # Enable GATT Service client
    CONFIG_BT_GATTP=y
    
    # Enable bonding
    CONFIG_BT_SETTINGS=y
    CONFIG_FLASH=y
    CONFIG_FLASH_PAGE_LAYOUT=y
    CONFIG_FLASH_MAP=y
    CONFIG_NVS=y
    CONFIG_SETTINGS=y

    and tried to compile, I got the following errors:

    prj.conf:39: warning: attempt to assign the value 'y' to the undefined symbol BT_GATT_DM
    prj.conf:42: warning: attempt to assign the value 'y' to the undefined symbol BT_ANCS_CLIENT
    prj.conf:45: warning: attempt to assign the value 'y' to the undefined symbol BT_GATTP
    
    error: Aborting due to Kconfig warnings
    

    Do you have any idea what I am missing here?

    Thanks in advance.

    Cheers Beers!

    Bojan.

Children
Related