I have made a custom board based on the raytac NRF52840 module (MDBT50). When i load in the USBD CDC example (SDK version: 15.2), The device is not detected. There is no output on the 'dmesg' (my OS is Ubuntu 16.04). What could be the problem? Do i need to merge the USB CDC example with Soft Device?
On the hardware side I have directly connected the D+ and D- pins to the USB connector and 5V from USB connector to VBUS ans VDDH. and GND to GND. Do i need to add any other components?
The log from UART after adding few more log statements (see attached main.c):
<info> app: USBD CDC ACM example started.
<info> app: USB power detected
<info> app: USB ready
<info> app: USB event started
<info> app: DRV Suspend
uart_cli:~$
Update 1: I also tried connecting 1.8V to VDD and VDDH but still it does not work.
Update 2: tried with 3.3v to VDD and VDDH, still not working
Update 3: I power it with another 3V supply, I was able to get it to work once but after that this is printed in dmesg (3V is observed on D+ line)
[ 7216.966807] usb 1-1.3: new full-speed USB device number 61 using ehci-pci
[ 7217.046771] usb 1-1.3: device descriptor read/64, error -32
[ 7217.234809] usb 1-1.3: device descriptor read/64, error -32
[ 7217.422730] usb 1-1.3: new full-speed USB device number 62 using ehci-pci
[ 7217.502821] usb 1-1.3: device descriptor read/64, error -32
[ 7217.690761] usb 1-1.3: device descriptor read/64, error -32
[ 7217.878816] usb 1-1.3: new full-speed USB device number 63 using ehci-pci
[ 7218.294801] usb 1-1.3: device not accepting address 63, error -32
[ 7218.374801] usb 1-1.3: new full-speed USB device number 64 using ehci-pci
[ 7218.790747] usb 1-1.3: device not accepting address 64, error -32
[ 7218.790855] usb 1-1-port3: unable to enumerate USB device
and NRF LOG:
<info> app: USBD CDC ACM example started.
<info> app: USB power detected
<info> app: USB ready
<info> app: USB event started
<info> app: DRV Suspend
<info> app: DRV Resume
<info> app: DRV Suspend
<info> app: DRV Resume
<info> app: DRV Suspend
uart_cli:~$