Modification of the usb_cdc_acm example for custom nRF52833 board and integrating with usb_hid

I have a custom nRF52833 board that acts as an HID device, which works perfectly. I now need to get values from the USB to the serial monitor for easy debugging purposes. I learnt that this could be done using the usb_cdc_acm class.

1. While an example for nRF52840 is given in the nRF SDK, I don't know how to modify it for my custom board in Segger embedded studio in which the code for USB acting as an HID device is written. I tried using  Developing for nRF52811 user guide given in nordic infocenter as a reference but couldn't understand it.

2. I also have no idea how to integrate it with the already existing project in which the USB acts as an HID device.

I am using nRF5_SDK_17.0.2 with Windows 10 OS.

I am a beginner with nRF. Could somebody please help me out?

Parents
  • Hello,

    Thank you for your patience with this.

    I am a beginner with nRF.

    Welcome!
    Please do not hesitate to ask if you should encounter any issues or questions - we're happy to help!

    1. While an example for nRF52840 is given in the nRF SDK, I don't know how to modify it for my custom board in Segger embedded studio in which the code for USB acting as an HID device is written. I tried using  Developing for nRF52811 user guide given in nordic infocenter as a reference but couldn't understand it.

    When adapting an example to your custom board you will need to make a new board file or description that matches the custom board's layout, since all the examples assumes the different DK layouts. You could take a look in the sdk\components\boards directory to see how these should look.

    2. I also have no idea how to integrate it with the already existing project in which the USB acts as an HID device.

    Do I understand you correctly that the custom board you have is already using the USB peripheral of the nRF52833?
    Please note that the nRF52833 has only got 1 USB instance so if this is already in use by your application we might have to look for other possibilities for these debug messages.

    I tried using  Developing for nRF52811 user guide given in nordic infocenter as a reference but couldn't understand it.

    Lastly, could I ask you whether there is a particular reason for using the user guide for a different SoC? Is there a specific part of this user guide that you think could be useful, or some other reason?

    Best regards,
    Karl

Reply
  • Hello,

    Thank you for your patience with this.

    I am a beginner with nRF.

    Welcome!
    Please do not hesitate to ask if you should encounter any issues or questions - we're happy to help!

    1. While an example for nRF52840 is given in the nRF SDK, I don't know how to modify it for my custom board in Segger embedded studio in which the code for USB acting as an HID device is written. I tried using  Developing for nRF52811 user guide given in nordic infocenter as a reference but couldn't understand it.

    When adapting an example to your custom board you will need to make a new board file or description that matches the custom board's layout, since all the examples assumes the different DK layouts. You could take a look in the sdk\components\boards directory to see how these should look.

    2. I also have no idea how to integrate it with the already existing project in which the USB acts as an HID device.

    Do I understand you correctly that the custom board you have is already using the USB peripheral of the nRF52833?
    Please note that the nRF52833 has only got 1 USB instance so if this is already in use by your application we might have to look for other possibilities for these debug messages.

    I tried using  Developing for nRF52811 user guide given in nordic infocenter as a reference but couldn't understand it.

    Lastly, could I ask you whether there is a particular reason for using the user guide for a different SoC? Is there a specific part of this user guide that you think could be useful, or some other reason?

    Best regards,
    Karl

Children
Related