Lines Matching full:usb0

155 	USB0->USBTRC0 |= USB_USBTRC0_USBRESET_MASK;  in kinetis_usb_init()
158 USB0->CTL = 0; in kinetis_usb_init()
160 USB0->CTL |= USB_CTL_USBENSOFEN_MASK; in kinetis_usb_init()
162 if ((USB0->PERID != USBFSOTG_PERID) || in kinetis_usb_init()
163 (USB0->REV != USBFSOTG_REV)) { in kinetis_usb_init()
167 USB0->BDTPAGE1 = (uint8_t)(((uint32_t)bdt) >> 8); in kinetis_usb_init()
168 USB0->BDTPAGE2 = (uint8_t)(((uint32_t)bdt) >> 16); in kinetis_usb_init()
169 USB0->BDTPAGE3 = (uint8_t)(((uint32_t)bdt) >> 24); in kinetis_usb_init()
172 USB0->ISTAT = 0xFF; in kinetis_usb_init()
175 USB0->INTEN = USB_INTEN_USBRSTEN_MASK; in kinetis_usb_init()
177 USB0->USBCTRL = USB_USBCTRL_PDE_MASK; in kinetis_usb_init()
189 USB0->ENDPOINT[i].ENDPT = 0; in usb_dc_reset()
194 USB0->CTL |= USB_CTL_ODDRST_MASK; in usb_dc_reset()
195 USB0->CTL &= ~USB_CTL_ODDRST_MASK; in usb_dc_reset()
198 USB0->ISTAT = 0xFF; in usb_dc_reset()
200 USB0->ERRSTAT = 0xFF; in usb_dc_reset()
202 USB0->ERREN = 0xFF; in usb_dc_reset()
204 USB0->ADDR = 0x00; in usb_dc_reset()
206 USB0->INTEN = (USB_INTEN_USBRSTEN_MASK | in usb_dc_reset()
236 USB0->CONTROL = USB_CONTROL_DPPULLUPNONOTG_MASK; in usb_dc_attach()
245 USB0->CTL &= ~USB_CTL_USBENSOFEN_MASK; in usb_dc_detach()
246 USB0->CONTROL &= ~USB_CONTROL_DPPULLUPNONOTG_MASK; in usb_dc_detach()
355 USB0->ENDPOINT[ep_idx].ENDPT = 0; in usb_dc_ep_configure()
387 USB0->ENDPOINT[ep_idx].ENDPT |= (USB_ENDPT_EPHSHK_MASK | in usb_dc_ep_configure()
393 USB0->ENDPOINT[ep_idx].ENDPT |= USB_ENDPT_EPHSHK_MASK; in usb_dc_ep_configure()
395 USB0->ENDPOINT[ep_idx].ENDPT |= USB_ENDPT_EPRXEN_MASK; in usb_dc_ep_configure()
397 USB0->ENDPOINT[ep_idx].ENDPT |= USB_ENDPT_EPTXEN_MASK; in usb_dc_ep_configure()
402 USB0->ENDPOINT[ep_idx].ENDPT |= USB_ENDPT_EPRXEN_MASK; in usb_dc_ep_configure()
404 USB0->ENDPOINT[ep_idx].ENDPT |= USB_ENDPT_EPTXEN_MASK; in usb_dc_ep_configure()
452 USB0->ENDPOINT[ep_idx].ENDPT &= ~USB_ENDPT_EPSTALL_MASK; in usb_dc_ep_clear_stall()
471 USB0->CTL &= ~USB_CTL_TXSUSPENDTOKENBUSY_MASK; in usb_dc_ep_clear_stall()
774 USB0->CTL &= ~USB_CTL_TXSUSPENDTOKENBUSY_MASK; in usb_dc_ep_read_continue()
872 uint8_t istatus = USB0->ISTAT; in usb_kinetis_isr_handler()
873 uint8_t status = USB0->STAT; in usb_kinetis_isr_handler()
879 USB0->ADDR = (uint8_t)0; in usb_kinetis_isr_handler()
886 USB0->CTL |= USB_CTL_ODDRST_MASK; in usb_kinetis_isr_handler()
887 USB0->CTL &= ~USB_CTL_ODDRST_MASK; in usb_kinetis_isr_handler()
896 USB0->ERRSTAT = 0xFF; in usb_kinetis_isr_handler()
949 USB0->ADDR = dev_data.address & 0x7f; in usb_kinetis_isr_handler()
963 USB0->INTEN |= USB_INTEN_RESUMEEN_MASK; in usb_kinetis_isr_handler()
972 USB0->INTEN &= ~USB_INTEN_RESUMEEN_MASK; in usb_kinetis_isr_handler()
980 USB0->ISTAT = istatus; in usb_kinetis_isr_handler()