Embedded Xinu Operating System
An ongoing research project and educational operating system.
 All Data Structures Files Functions Variables Typedefs Enumerations Macros Groups Pages
Macros | Functions
usbdebug.c File Reference
#include <stdlib.h>
#include <stdio.h>
#include <kernel.h>
#include <interrupt.h>
#include <usb_core_driver.h>
#include <usb_hub_driver.h>
#include <usb_std_defs.h>
#include <usb_subsystem.h>

Macros

#define USBINFO_TREE_SPACES_PER_LEVEL   6
 
#define USBINFO_TREE_LINES_PER_PORT   2
 

Functions

void usb_log (int priority, const char *func, struct usb_device *dev, const char *format,...)
 
const char * usb_status_string (usb_status_t status)
 
const char * usb_class_code_to_string (enum usb_class_code class_code)
 
const char * usb_speed_to_string (enum usb_speed speed)
 
const char * usb_transfer_type_to_string (enum usb_transfer_type type)
 
const char * usb_direction_to_string (enum usb_direction dir)
 
usb_status_t usb_get_string_descriptor (struct usb_device *dev, uint8_t index, uint16_t lang_id, struct usb_string_descriptor *buf, uint16_t buflen)
 
usb_status_t usb_get_ascii_string (struct usb_device *dev, uint32_t iString, char *strbuf, uint32_t strbufsize)
 
const char * usb_device_description (const struct usb_device *dev)
 
void usb_print_device_descriptor (const struct usb_device *dev, const struct usb_device_descriptor *desc)
 
syscall usbinfo (void)
 

Detailed Description

This file contains USB core functions not strictly necessary for USB to actually operate. This includes:

To disable all the above functionality, set USB_EMBEDDED to TRUE in usb_util.h. Obviously, only do this if you know what you're doing.