// allocDHW returns a reference to the USB hardware abstraction for the given
// device controller driver. Should be called only one time and during device
// controller initialization.
allocDHW returns a reference to the USB hardware abstraction for the given
device controller driver. Should be called only one time and during device
controller initialization.
// allocDHW returns a reference to the USB hardware abstraction for the given // device controller driver . Should be called only one time and during device // controller initialization .
func allocDHW(port, instance int, dc *dcd) *dhw {
	switch port {
	case 0:
		dhwInstance[instance].dcd = dc
		dhwInstance[instance].bus = nxp.USB1
		dhwInstance[instance].phy = nxp.USBPHY1
		dhwInstance[instance].irq =
			interrupt.New(nxp.IRQ_USB_OTG1,
				func(interrupt.Interrupt) {
					coreInstance[0].dc.interrupt()
				})
	case 1:
		dhwInstance[instance].dcd = dc
		dhwInstance[instance].bus = nxp.USB2
		dhwInstance[instance].phy = nxp.USBPHY2
		dhwInstance[instance].irq =
			interrupt.New(nxp.IRQ_USB_OTG2,
				func(interrupt.Interrupt) {
				})
	}
	return &dhwInstance[instance]
}
func allocDHW ( port , instance int , dc * dcd ) * dhw { switch port { case 0 : dhwInstance [ instance ] . dcd = dc dhwInstance [ instance ] . bus = nxp . USB1 dhwInstance [ instance ] . phy = nxp . USBPHY1 dhwInstance [ instance ] . irq = interrupt . New ( nxp . IRQ_USB_OTG1 , func ( interrupt . Interrupt ) { coreInstance [ 0 ] . dc . interrupt ( ) } ) case 1 : dhwInstance [ instance ] . dcd = dc dhwInstance [ instance ] . bus = nxp . USB2 dhwInstance [ instance ] . phy = nxp . USBPHY2 dhwInstance [ instance ] . irq = interrupt . New ( nxp . IRQ_USB_OTG2 , func ( interrupt . Interrupt ) { } ) } return & dhwInstance [ instance ] }
allocDHW returns a reference to the USB hardware abstraction for the given
device controller driver.
allocDHW returns a reference to the USB hardware abstraction for the given device controller driver .
//coreInstance[1].dc.interrupt()