Skip to content

Commit

Permalink
get rid of manual USB driver installation by using MS OS descriptors
Browse files Browse the repository at this point in the history
  • Loading branch information
benedekkupper committed Aug 25, 2020
1 parent bb62c88 commit aecf3f0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 20 deletions.
6 changes: 6 additions & 0 deletions Config_FreeRTOS/usbd_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@ extern "C"
* protocol (v1.1A) shall be used instead of the standard DFU (v1.1). */
#define USBD_DFU_ST_EXTENSION 1

/** @brief Selects which Microsoft OS descriptor specification should be used (if any).
* Supported values are: 0, 1, 2
* @note Microsoft OS 2.0 descriptors are supported by Windows 8.1 and higher.
* Unless the device is required to operate on earlier Windows OS versions, use version 2. */
#define USBD_MS_OS_DESC_VERSION 2

/** @} */

/** @} */
Expand Down
19 changes: 0 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,25 +24,6 @@ There are two possible supported software configurations:
* Reprogramming via USB supported by DFU interface (DFU standard implementation to reboot to ROM)
* [FreeRTOS][FreeRTOS] variant allows the choice of any lwIP APIs to be used by the application

## Driver installation on Windows 10

Even though NCM is a standardized USB protocol (unlike RNDIS), and the necessary driver
is already included by Microsoft, Windows doesn't bind the appropriate driver to it automatically.
Here's a step by step guide to install the correct driver:

1. Find the NCM interface device in Device Manager under "Other devices" (it goes under the name "LwIP gateway"
2. Browse the computer for driver software
3. Pick from available driver list
4. Select "Network adapters" as device type
5. Select "MSFT" manufacturer (it's code for Microsoft), "UsbNcm Host Device" model
6. Profit

In case you also want to use the bootloader functionality,
you have to perform these steps for the "STM32 BOOTLOADER" device as well. The parameters are:
- Device type = Universal Serial Bus devices
- Manufacturer = STMicroelectronics
- Model = STM32 BOOTLOADER

[FreeRTOS]: https://www.freertos.org/
[lwIP]: https://savannah.nongnu.org/projects/lwip/
[USBDevice]: https://github.com/IntergatedCircuits/USBDevice

0 comments on commit aecf3f0

Please sign in to comment.