Uploading Firmware & Testing USB device
After we have the software and hardware done we upload the firmware to the PIC32MX470F512 microcontroller. After uploading the firmware, we then connect the USB device to the computer/PC. The device driver should automatically install. If this does not happen and you are asked to choose the driver by windows then you should navigate to the <install-dir>/apps/usb/device/cdc_com_port_single/inf directory and choose the .inf file.
If correctly installed you should get similar windows driver installation message as shown below.
The next step is then open a terminal like putty and then configure the serial communication by selecting the appropriate com port and baud rate. The com port in this tutorial is 4(your can be different) and the baud rate should be set to 9600 as shown below.
Then in the terminal, type any alphabet like a for example and you should see b. This confirms that the USB device is working.