increased oscillator clock speed to 8MHz to speed up the bootloader, changed usb descriptor in application firmware to use the PID assigned by Microchip & removed flag making the device report that it is self powered to the host

This commit is contained in:
2019-08-23 18:17:46 -04:00
parent e55bbc58f3
commit d548fb9579
2 changed files with 4 additions and 4 deletions

View File

@@ -31,7 +31,7 @@
// CONFIG1L // CONFIG1L
#pragma config PLLDIV = 3 // PLL Prescaler Selection bits (Divide by 3 (12 MHz oscillator input)) #pragma config PLLDIV = 3 // PLL Prescaler Selection bits (Divide by 3 (12 MHz oscillator input))
#pragma config CPUDIV = OSC4_PLL6// System Clock Postscaler Selection bits ([Primary Oscillator Src: /4][96 MHz PLL Src: /6]) #pragma config CPUDIV = OSC2_PLL3// System Clock Postscaler Selection bits ([Primary Oscillator Src: /4][96 MHz PLL Src: /6])
#pragma config USBDIV = 2 // USB Clock Selection bit (used in Full-Speed USB mode only; UCFG:FSEN = 1) (USB clock source comes from the 96 MHz PLL divided by 2) #pragma config USBDIV = 2 // USB Clock Selection bit (used in Full-Speed USB mode only; UCFG:FSEN = 1) (USB clock source comes from the 96 MHz PLL divided by 2)
// CONFIG1H // CONFIG1H

View File

@@ -156,8 +156,8 @@ const USB_DEVICE_DESCRIPTOR device_dsc=
0x00, // Subclass code 0x00, // Subclass code
0x00, // Protocol code 0x00, // Protocol code
USB_EP0_BUFF_SIZE, // Max packet size for EP0, see usb_config.h USB_EP0_BUFF_SIZE, // Max packet size for EP0, see usb_config.h
0x1209, // Vendor ID, see usb_config.h 0x04D8, // Vendor ID, see usb_config.h
0x0600, // Product ID, see usb_config.h 0xECEE, // Product ID, see usb_config.h
0x0001, // Device release number in BCD format 0x0001, // Device release number in BCD format
0x01, // Manufacturer string index 0x01, // Manufacturer string index
0x02, // Product string index 0x02, // Product string index
@@ -174,7 +174,7 @@ const uint8_t configDescriptor1[]={
1, // Number of interfaces in this cfg 1, // Number of interfaces in this cfg
1, // Index value of this configuration 1, // Index value of this configuration
0, // Configuration string index 0, // Configuration string index
_DEFAULT | _SELF, // Attributes, see usb_device.h _DEFAULT, // Attributes, see usb_device.h
50, // Max power consumption (2X mA) 50, // Max power consumption (2X mA)
/* Interface Descriptor */ /* Interface Descriptor */