History: usbd_base

This page describes all changes made to the usbd_base package, Embedded USBD Base System, since its release.


3.32r2 (2021-06-09, 19:32):

  • Modified configtool so can generate CDC-NCM configuration descriptors.

3.32 (2021-06-07, 16:30):

  • Fixed how the packet size of the Endpoints is extracted from the device descriptor, because only the lower 11 bits have to be taken into account.
  • Added a USBD_ prefix to definitions in usbd_std.c.
  • Fixes in customer Lint warnings elimination. Removed unnecessary type casts, modified call_usercb() return value type, etc.

3.31 (2021-03-12, 12:00):

  • Eliminated customer Lint warning.

3.30 (2020-11-17, 15:00):

  • Changed MIN macro name to HCC_MIN.
  • Eliminated warnings.

3.29 (2020-09-20, 16:35):

  • Added support for task self deletion.

3.28 (2020-06-12, 16:35):

  • Device class drivers can subscribe to get notified of connection status change.

3.27 (2020-04-21, 15:35)

  • Added a fix in usbd_set_config() to remove the pending transfer on EP0. This caused an issue when a new SETUP packet is received and the previous transfer was aborted by the driver. In this case the stack responded by setting a stall to the EP0 and right after that the new SETUP packet was processed resulting in a new transfer on EP0. However, because of the stall the host responded with a reset, which againled to a stall. This could happen in very rare cases when the processing task could not be scheduled fast enough.

3.26 (2019-09-13, 12:00):

  • C++ compiler errors.

3.25 (2018-08-27, 16:30):

  • Eliminated static analysis issues.

3.24 (2019-05-29, 18:10):

  • Added OTG SRP and HRP support.

3.23 (2019-05-20, 17:19):

  • Added support for getting the active Alternate Interface index belonging to an Interface index. Use case: the Audio 2.0 class driver might need this to know what format the choose when starting playback.

3.22 (2019-01-10, 16:04):

  • Some multi-interface class drivers (for example, Audio) might fail to get configured or were configured incorrectly during enumeration.

3.21 (2018-12-14, 13:06):

  • Increased USBD EP0 task stack (original size was too little).

3.20r2 (2018-08-29, 18:19):

  • Document HTML link added to the documentation folder.
  • History and document files renamed to the package name.

3.20 (2017-09-20, 13:17):

  • USB strings can be overridden on-the-fly by using callback functions.
  • Changed  code style to meet coding standard's rules.


  • Interruption of any control transaction (typically by pulling the USB cable out during enumeration) could cause the device to stop answering further host requests.

3.18 r2:

  • RNDIS configuration template updated for compatibility with Windows 8.x/10.


  • An error detected while servicing standard requests issued by a host now results in halting the control endpoint - meaning it will send STALL handshake until receiving the next Setup request.

3.17 r3:

  • CDC-ECM configuration template updated for compatibility with all Linux hosts.

3.17 r2:

  • USB configuration utility modified to support more than one sampling frequency in one audio AS descriptor.


  • Added support for USB drivers handling control handshake transfers automatically.
  • psp_types.h included from config file.


  • Remote Wakeup implemented.


  • Get Interface Status Control transfer had wrong Status stage. Zero length OUT packet must be sent instead of receiving zero length IN packet.

3.14 r3:

  • Config tool updated to generate descriptors compatible with HID class driver major version 6 and above.

3.14 r2:

  • XML Notepad removed from hcc/util/configtool directory.


  • psp_types.h used instead of stdint.h and stddef.h.
  • Compiler warnings were eliminated.
  • Corrected VER_RNGBUF_MAJOR check.  


  • Corrected SOF_TIMER version check in usbd.h.


  • Added support for MS OS descriptor.


  • Corrected handling of find_ep() return value.


  • Added defines for USB device Feature TEST MODE.


  • Added possibility to do a set_config() from usbd_start(), because some USB core answers SET CONFIG automatically.


  • Added support for user serial string.


  • Set Feature TEST MODE implemented.


  • EP0 and control task priorities moved from the config file to usbd_std.c.
  • debug trace removed from usbd_std.c.
  • return values changed from OAL_... to USBD_...


  • Warnings removed.


  • const added to USBD configuration to avoid warnings.


  • usbd_transfer_b() could address incorrect areas if called with invalid endpoint handle.


  • Now drops transfer when an endpoint is stalled.
  • USBH_INVALID_IFC_NDX introduced.


  • Parses all configurations even if found a valid one. This way interfaces with the same class/subclass/protocol in different configurations can work.


  • Initial release.