Solution to the problem of STM32 VCP PC-side driver installation failure ---- tried and solved the problem

Publisher:世界因你而精彩Latest update time:2018-05-20 Source: eefocusKeywords:STM32 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

STM32, when using USB VCP function, that is, virtual serial port function, select USB_OTG_FS Device_Only, as shown above. cube automatically generates the project without modification. Insert the USB into the computer, STMicroelecronics Virtual COM Port (COM4) can be successfully displayed in the port item of WIN10 or WIN7 system device manager, but a yellow exclamation mark is displayed before the driver, indicating a warning that there is a problem with the device installation.

question:

In the usbd_cdc.c file, there is a USBD_malloc in the USBD_CDC_Init function, which can be debugged by setting a breakpoint. pdev->pClassData is NULL, indicating that malloc did not apply for space.

Solution:

The reason why malloc fails to apply for space is not because of a problem with the USBD_malloc function, but because the system heap space is too small and the application space is larger than the heap space, so the application fails. You only need to increase the value of Heap_Size EQU 0x200 in the startup_stm32f429xx.s system startup file.




//======================================================================

Remark::

1> Run dpinst_amd64.exe under C:\Program Files (x86)\STMicroelectronics\Software\Virtual comport driver\Win8 under win10 to install the driver successfully-----the displayed serial port will not have an exclamation mark!!!


Keywords:STM32 Reference address:Solution to the problem of STM32 VCP PC-side driver installation failure ---- tried and solved the problem

Previous article:STM32M CUBE implements printf to print debugging information and implements single-byte reception
Next article:Chapter 51 Setting FLASH read/write protection and release - Playing with STM32-F429 series without any blind spots

Recommended ReadingLatest update time:2024-11-16 14:59

Analysis of STM32 I2C bus occupancy problem
I have been solving the I2C bus occupancy (BUSY) problem of STM32 MCU these days . I think it is a good lesson to share with you. The STM32F207 MCU has three I2Cs. I2C1 is used to connect DSP/Codec/EEPROM in Pre-ES1 and it works well. The new hardware (ES1) moved the Codec/EEPROM to I2C3, but the DSP remained on I
[Microcontroller]
STM32 motor control synchronous electrical angle test description
Preface When using the ST   FOC motor library , when using the Hall signal as the position signal, it is necessary to input the synchronous electrical angle data. This data is input according to the characteristics of the current motor in use, and the electrical angle will be synchronized every time the Hall signal ch
[Microcontroller]
STM32 motor control synchronous electrical angle test description
Problems encountered in reading and writing 24C02 with STM32
I have been working on I2C these days, reading the data from 24C02. I typed the code silently and then simulated it. The code is just the following two lines, which write a byte and then read it. I2C_EE_BufferWrite( &write,100, 1); I2C_EE_BufferRead(&read,100, 1);  Then all kinds of things went wrong, and afte
[Microcontroller]
Problems encountered in reading and writing 24C02 with STM32
Errors in stm32 and how to solve them
1. error: #256: invalid redeclaration of type name "s32" (declared at line 470 of "C:\Keil_STM32\ARM\INC\ST\STM32F10x\stm32f10x.h") Solution: Open the stm32f10x_conf.h file, comment out "#include "stm32f10x_type.h"" on line 21, save the stm32f10x_conf.h file, and recompile. 2. warning: #47-D: incompatible redefini
[Microcontroller]
STM32 GPIO related registers (Part 2)
STM32 microcontrollers can only communicate with the outside world if they have ports. Only by learning how to control ports can we make better use of peripherals, establish connections with the outside world, and give full play to our own advantages.          First, let's introduce the basic GPIO related registers:
[Microcontroller]
File analysis of STM32 USB project
First, let me introduce the STM32 USB project I built with reference to other projects:               A brief introduction: Startup is of course used to store the startup files of STM32, CMSIS is used to store the core files of STM32 core ARMCortex, and the library functions of STM32 peripherals are placed in the Std
[Microcontroller]
File analysis of STM32 USB project
Cannot run when using keil to debug stm32
When using Keil, the number of breakpoints cannot exceed 5. If there are more than 5 breakpoints, you will not be able to enter the debugging interface. If more than 5 breakpoints are hit during debugging, an alarm message or error prompt will appear Fixes: Previously, based on experience, the number of breakpoi
[Microcontroller]
Cannot run when using keil to debug stm32
STM32 RCC configuration process
    There are 5 clock sources in STM32: ①. HSI is a high-speed internal clock, RC oscillator, with a frequency of 8MHz. ②. HSE is a high-speed external clock that can be connected to a quartz/ceramic resonator or an external clock source with a frequency range of 4MHz~16MHz. ③. LSI is a low-speed intern
[Microcontroller]
STM32 RCC configuration process
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号