瀏覽代碼

Fix duplicate variable name conflict on Teensy 3.6

main
PaulStoffregen 6 年之前
父節點
當前提交
c661104527
共有 1 個檔案被更改,包括 6 行新增6 行删除
  1. +6
    -6
      ehci.cpp

+ 6
- 6
ehci.cpp 查看文件

USBPHY_PLL_SIC = USBPHY_PLL_SIC_PLL_POWER | USBPHY_PLL_SIC_PLL_ENABLE | USBPHY_PLL_SIC = USBPHY_PLL_SIC_PLL_POWER | USBPHY_PLL_SIC_PLL_ENABLE |
USBPHY_PLL_SIC_PLL_DIV_SEL(1) | USBPHY_PLL_SIC_PLL_EN_USB_CLKS; USBPHY_PLL_SIC_PLL_DIV_SEL(1) | USBPHY_PLL_SIC_PLL_EN_USB_CLKS;
// wait for the PLL to lock // wait for the PLL to lock
int count=0;
int pll_count=0;
while ((USBPHY_PLL_SIC & USBPHY_PLL_SIC_PLL_LOCK) == 0) { while ((USBPHY_PLL_SIC & USBPHY_PLL_SIC_PLL_LOCK) == 0) {
count++;
pll_count++;
} }
//println("PLL locked, waited ", count);
//println("PLL locked, waited ", pll_count);


// turn on power to PHY // turn on power to PHY
USBPHY_PWD = 0; USBPHY_PWD = 0;
// now with the PHY up and running, start up USBHS // now with the PHY up and running, start up USBHS
//print("begin ehci reset"); //print("begin ehci reset");
USBHS_USBCMD |= USBHS_USBCMD_RST; USBHS_USBCMD |= USBHS_USBCMD_RST;
int count = 0;
int reset_count = 0;
while (USBHS_USBCMD & USBHS_USBCMD_RST) { while (USBHS_USBCMD & USBHS_USBCMD_RST) {
count++;
reset_count++;
} }
println(" reset waited ", count);
println(" reset waited ", reset_count);


init_Device_Pipe_Transfer_memory(); init_Device_Pipe_Transfer_memory();
for (int i=0; i < PERIODIC_LIST_SIZE; i++) { for (int i=0; i < PERIODIC_LIST_SIZE; i++) {

Loading…
取消
儲存