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

Using the on board USB in NRF Connect

is there a sample or some documentation for how to use the USB port to output text from the nRF52840 dongle in a nRF Connect Zephyr application?

It would seem that the very first sample program for the NRF Connect environment and the nRF52840 dongle should be a very simple 'hello world' sending the string to the USB port configured as a serial device that can be seen on any computer running a serial terminal.

I have found a few references to code that can communicate over the USB port but they are all NRF5 or earlier and use libraries and files that are not available in the NRF Connect SDK installation. They also seem to make it much more complex than it needs to be by adding all sorts of other pieces, such as BLE, to the mix.

Given the fact that the nRF52840 dongle is such an amasingly useful device and it has a full blown USB port (hardware at least), one would think it would be an obvious first step to add that port as an available log destination to make debugging possible. I can't imagine it could be that difficult to do, but given the complexity of the SDK and the almost total lack of meaningful 'how to' documentation it seems to be a Herculean task to figure out how ti do this by just looking at the header files for the SDK..

Related