V2.0
This commit is contained in:
@@ -62,7 +62,7 @@ void Var_Init(void)
|
||||
int main(void)
|
||||
{
|
||||
uint8_t ret;
|
||||
NVIC_PriorityGroupConfig(NVIC_PriorityGroup_2);
|
||||
NVIC_PriorityGroupConfig(NVIC_PriorityGroup_1);
|
||||
SystemCoreClockUpdate();
|
||||
Delay_Init();
|
||||
USART_Printf_Init(115200);
|
||||
|
||||
@@ -37,7 +37,7 @@ void USBWakeUp_IRQHandler(void)
|
||||
/*******************************************************************************
|
||||
* @fn USBWakeUp_IRQHandler
|
||||
*
|
||||
* @brief T his function handles USB exception.
|
||||
* @brief This function handles USB exception.
|
||||
*
|
||||
* @return None
|
||||
*/
|
||||
|
||||
@@ -100,7 +100,7 @@ const uint8_t USBD_StringVendor[USBD_SIZE_STRING_VENDOR] = {
|
||||
const uint8_t USBD_StringProduct[USBD_SIZE_STRING_PRODUCT] = {
|
||||
USBD_SIZE_STRING_PRODUCT,
|
||||
USB_STRING_DESCRIPTOR_TYPE,
|
||||
'C', 0, 'H', 0, '3', 0, '2', 0, 'F', 0, '2', 0 , '0', 0, 'x', 0
|
||||
'C', 0, 'H', 0, '3', 0, '2', 0, 'V', 0, '2', 0 , '0', 0, 'x', 0
|
||||
};
|
||||
|
||||
/* USB Device String Serial */
|
||||
|
||||
@@ -23,6 +23,9 @@ void HardFault_Handler(void) __attribute__((interrupt("WCH-Interrupt-fast")));
|
||||
*/
|
||||
void NMI_Handler(void)
|
||||
{
|
||||
while (1)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
|
||||
@@ -111,10 +111,10 @@ static void SetSysClockTo144_HSI( void );
|
||||
void SystemInit (void)
|
||||
{
|
||||
RCC->CTLR |= (uint32_t)0x00000001;
|
||||
RCC->CFGR0 &= (uint32_t)0xF8FF0000;
|
||||
RCC->CFGR0 &= (uint32_t)0xF0FF0000;
|
||||
RCC->CTLR &= (uint32_t)0xFEF6FFFF;
|
||||
RCC->CTLR &= (uint32_t)0xFFFBFFFF;
|
||||
RCC->CFGR0 &= (uint32_t)0xFF80FFFF;
|
||||
RCC->CFGR0 &= (uint32_t)0xFF00FFFF;
|
||||
RCC->INTR = 0x009F0000;
|
||||
SetSysClock();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user