Code Monkey home page Code Monkey logo

libusb_stm32's Introduction

Lightweight USB Device Stack

  • Lightweight and fast
  • Event-driven process workflow
  • Completely separated USB hardware driver and usb core
  • Easy to use.

Supported hardware

HW driver Written on Endpoints Features MCU series
usb_stmv0 GCC C 8 Internal S/N, Doublebuffered, BC1.2 STM32L0x2 STM32L0x3 STM32L4x2 STM32L4x3 STM32F0x2 STM32F0x8
usb_stmv0a GCC ASM 8 Internal S/N, Doublebuffered, BC1.2 STM32L0x2 STM32L0x3 STM32L4x2 STM32L4x3 STM32F0x2 STM32F0x8
usb_stmv1 GCC C 8 Internal S/N, Doublebuffered STM32L1xx
usb_stmv1a GCC ASM 8 Internal S/N, Doublebuffered STM32L1xx
usb_stmv2 GCC C 6 Internal S/N, Doublebuffered, BC1.2 STM32L4x5 STM32L4x6 (OTG FS (Device mode))
  1. Single physical endpoint can be used to implement
  • one bi-directional/single-buffer logical endpoint (CONTROL)
  • one mono-directional/double-buffer logical endpoint (BULK OR ISOCHRONOUS)
  • two mono-directional/single-buffer logical endpoints (BULK OR INTERRUPT)
  1. At this moment BULK IN endpoint can use both buffers, but it is not real doublebuffered.

  2. Tested with STM32L052, STM31L100, STM32L476RG

Implemented definitions for classes

  1. USB HID based on Device Class Definition for Human Interface Devices (HID) Version 1.11
  2. USB DFU based on USB Device Firmware Upgrade Specification, Revision 1.1
  3. USB CDC based on Class definitions for Communication Devices 1.2

Using makefile

  • to build library module
make module MODULE=path/module.a DEFINES="mcu spcified defines" CFLAGS="cpu cpecified compiler flags"
  • to build demo
make demo MCU=stm32l100xc
make demo MCU=stm32l052x8
make demo MCU=stm32l476rg
  • to flash demo using st-flash
make program

Default values:

Variable Default Value Means
CMSIS ../../cmsis path to CMSIS root folder
MCU stm32l100xc MCU selection for demo project
CFLAGS -mcpu=cortex-m3 -mfloat-abi=soft MCU specified compiler flags
DEFINES STM32L1 STM32L100xC MCU specified defines
INCLUDES $(CMSIS)/device/ST $(CMSIS)/include path to ST CMSIS includes

Useful Resources

  1. USB Implementers Forum official site
  2. USB Made Simple
  3. LUFA - the Lightweight USB Framework for AVRs.
  4. Open Source ARM cortex m microcontroller library

libusb_stm32's People

Contributors

dmitrystu avatar oleggalizin avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.