XenevaOS
Loading...
Searching...
No Matches
Functions
dwc2_usbdev.cpp File Reference
#include "dwc2_usbdev.h"
#include <Drivers/uart.h>
#include <Mm/kmalloc.h>
#include <string.h>
#include <Mm/pmmngr.h>
#include <_null.h>
#include <Hal/AA64/aa64cpu.h>
#include "usb_stdhub.h"
#include "lan7800.h"
#include "usb_hid.h"
Include dependency graph for dwc2_usbdev.cpp:

Functions

void dwc2_usb_get_string (dwc2_core_regs *regs, dwc2_usb_device *dev, uint8_t index, uint16_t langID, char *out)
 
bool dwc2_usbdev_initialize (dwc2_core_regs *regs, uint8_t port, uint8_t hub_addr, uint8_t hub_port, uint8_t speed)
 

Detailed Description

BSD 2-Clause License

Copyright (c) 2022-2026, Manas Kamal Choudhury All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Function Documentation

◆ dwc2_usb_get_string()

void dwc2_usb_get_string ( dwc2_core_regs regs,
dwc2_usb_device dev,
uint8_t  index,
uint16_t  langID,
char *  out 
)

◆ dwc2_usbdev_initialize()

bool dwc2_usbdev_initialize ( dwc2_core_regs regs,
uint8_t  port,
uint8_t  hub_addr,
uint8_t  hub_port,
uint8_t  speed 
)

dwc2_usbdev_initialize – initializing usb device

Parameters
port– port number
hub_addr– hub device address
hub_port– hub's port number
speed– speed of the port

get the first device descriptor