The purpose of this blog is to showcase how a single USB bus can be used as the physical transport for multiple protocols when an external CPU is the controller.
Boards: nRF52840-DK x 3
NCS Tag: v1.5.0
Ubuntu 18.04.5 LTS
Zigbee NCP Host SW v0.9.3
Using a single USB bus reduces the number hardware components and complexity of implementing data transfers over disparate buses for different protocols. For instance, Nordic software supports simultaneous use of multiple protocols such as Zigbee and BLE. Nordic software further supports having the Zigbee protocol stack and the BLE stack controlled by an external CPU through software API serialization over a bus such as UART or SPI. In case of Zigbee, this architecture is called the Network Co-Processor (NCP) and, in case of BLE, it is called Host Controller Interface (HCI). As stated, in both cases the Nordic SoC acts as the responder which runs the radio and low-level stack and the external CPU is the controller which dictates the high-level logic of an application.
To reduce the component costs on a custom board, a single USB bus can be used that will support the multiplexing of multiple protocols. With a USB Full Speed bandwidth of 12 Mb/s, the USB bus has ample bandwidth for most controller-responder architecture use cases.
This demo will require 3 boards with the following roles:
west build --board=nrf52840dk_nrf52840 --pristine -- -DCONF_FILE=prj_usb.conf
Open a 2rd Terminal Window, attach the HCI controller to the system:
sudo btattach -B /dev/ttyACM1 -S 1000000 -p h4
sudo btmgmt --index 0
sudo NCP_SLAVE_PTY=/dev/ttyACM0 ./application/light_sample/light_control/light_control