Module capsules::usb_user
[−]
[src]
USB system call interface
This capsule provides a system call interface to the USB controller.
Instantiation
The UsbSyscallDriver
must be created by passing a reference to something
that implements hil::usb::Client
(that is, something that is connected to
the USBC), as well as a Grant
for managing application requests. For
example:
// Configure the USB controller let usb_client = static_init!( capsules::usbc_client::Client<'static, sam4l::usbc::Usbc<'static>>, capsules::usbc_client::Client::new(&sam4l::usbc::USBC)); sam4l::usbc::USBC.set_client(usb_client); // Configure the USB userspace driver let usb_driver = static_init!( capsules::usb_user::UsbSyscallDriver<'static, capsules::usbc_client::Client<'static, sam4l::usbc::Usbc<'static>>>, capsules::usb_user::UsbSyscallDriver::new( usb_client, kernel::Grant::create()));
Reexports
use core::cell::Cell; |
use kernel::AppId; |
use kernel::Callback; |
use kernel::Driver; |
use kernel::Grant; |
use kernel::ReturnCode; |
use kernel::hil; |
Structs
App | |
UsbSyscallDriver |
Enums
Request |
Constants
DRIVER_NUM |
Syscall number |