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

Use D+ and D- for Debug Serial Output

Hi

I've been developing using an NRF52 DK and have moved onto my own design board, I have one small problem which I'm unable to replicate using the DK. On my own board, I have D+ and D- connected up to a USB connector but as yet unused (for future development). I have a J-Link connected to the SW interface, all is working fine.

My question is can I redirect serial debugging output via D+ and D- (e.g. NRF_LOG_INFO output via D+ and D-)?

Thanks

Andrew

Parents
  • Hi Andrew

    If I understand you correctly you want to set up the USBD interface in the nRF52 device (nRF52840?) to send serial data over the USB interface?

    Unfortunately the NRF_LOG API doesn't have it's own USB CDC backend, for easily outputting data over USB, but if you use the CLI module you can route logging and CLI commands through USB CDC. The drawback of this method is that you need to add CLI to your example, if you're not already using it. 

    Best regards
    Torbjørn

Reply
  • Hi Andrew

    If I understand you correctly you want to set up the USBD interface in the nRF52 device (nRF52840?) to send serial data over the USB interface?

    Unfortunately the NRF_LOG API doesn't have it's own USB CDC backend, for easily outputting data over USB, but if you use the CLI module you can route logging and CLI commands through USB CDC. The drawback of this method is that you need to add CLI to your example, if you're not already using it. 

    Best regards
    Torbjørn

Children
Related