1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/examples/usbus_minimal
Juan Carrano 8b88666f3d tests,examples/usb: PID, VID warning only when building.
The warning issued when the PID and VID are set to the default values should
not be printed on `make clean` and other targets, only with `make all` and it
should be a proper target.

To do: replace shell echos with proper $(warning ..) calls.
2019-09-02 12:20:32 +02:00
..
main.c usbus_minimal: Adapt example to auto_init 2019-06-05 16:17:01 +02:00
Makefile tests,examples/usb: PID, VID warning only when building. 2019-09-02 12:20:32 +02:00
README.md USBUS: add minimal working example 2019-06-05 14:51:27 +02:00

usbus_minimal example

This is a minimalistic example for RIOT's USB stack. The application will initialize and start the USB stack. The stack is started without any USB handlers, it should show up as an empty USB device on the host.

RIOT doesn't own any USB vendor and product ID. To compile this example, add your own vendor and product ID to the makefile:

CFLAGS += -DUSB_CONFIG_VID=0xYOURVID -DUSB_CONFIG_PID=0xYOURPID

The example demonstrates basic USB communication between a host and a RIOT based USB peripheral. Tools such as lsusb should display the device and detailed information about the device such as descriptor strings.