📄 2410usb.c
字号:
#include "def.h"
#include "2410addr.h"
#include "2410lib.h"
#include "2410slib.h"
#include "mmu.h"
#include "uart.h"
#include "timer.h"
void UsbMain(void);
extern U32 downloadAddress, downloadFileSize;
U32 Console_Uart = 0;
U32 Console_Baud = 115200;
/******************************************************************************
【功能说明】系统主函数
******************************************************************************/
void Main()
{
SetClockDivider(0, 1);
SetSysFclk(FCLK_96M); //to save power, use 48M
Port_Init();
Isr_Init();
Uart_Init(0, Console_Baud);
Uart_Select(Console_Uart);
EnableModuleClock(CLOCK_ALL);
rMISCCR &= ~(0x3007); //USB port0,1 = normal, D0~D31 pull-up enable
Uart_Printf("\nGEC2410 USB download file");
UsbMain();
while(1);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -