你的浏览器版本过低,可能导致网站不能正常访问!
为了你能正常使用网站功能,请使用这些浏览器。

F429-disco的VCP驱动问题

[复制链接]
watershade 提问时间:2015-6-4 11:50 /
最近使用f4cube V1.5开发VCP驱动,按照F429-Discovery板子的配置选择OTG-HS接口作为Device设备来用,选择CDC协议。修改完APP_RX_DATA_SIZE和APP_TX_DATA_SIZE为2048,添加LineCoding代码。可是连接到计算机上,装完驱动(VCP V1.4)之后显示错误代码10的故障。计算机业换过win764/32位的。所以估计是代码的错误,使用USB VIEW观测之后,效果如下:
Device Descriptor:
bcdUSB:             0x0200
bDeviceClass:         0x00
bDeviceSubClass:      0x00
bDeviceProtocol:      0x00
bMaxPacketSize0:      0x40 (64)
idVendor:           0x0483 (STMicroelectronics)
idProduct:          0x5740
bcdDevice:          0x0200
iManufacturer:        0x01
0x0409: "STMicroelectronics"
iProduct:             0x02
0x0409: "STM32 Virtual ComPort"
iSerialNumber:        0x03
0x0409: "000000002B1A"
bNumConfigurations:   0x01

ConnectionStatus: DeviceConnected
Current Config Value: 0x00
Device Bus Speed:     Full
Device Address:       0x03
Open Pipes:              0

Configuration Descriptor:
wTotalLength:       0x0043
bNumInterfaces:       0x02
bConfigurationValue:  0x01
iConfiguration:       0x00
bmAttributes:         0xC0 (Bus Powered Self Powered )
MaxPower:             0x32 (100 Ma)

Interface Descriptor:
bInterfaceNumber:     0x00
bAlternateSetting:    0x00
bNumEndpoints:        0x01
bInterfaceClass:      0x02
bInterfaceSubClass:   0x02
bInterfaceProtocol:   0x01
iInterface:           0x00

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x05
05 24 00 10 01

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x05
05 24 01 00 01

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x04
04 24 02 02

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x05
05 24 06 00 01

Endpoint Descriptor:
bEndpointAddress:     0x82  IN
Transfer Type:   Interrupt
wMaxPacketSize:     0x0008 (8)
bInterval:            0x10

Interface Descriptor:
bInterfaceNumber:     0x01
bAlternateSetting:    0x00
bNumEndpoints:        0x02
bInterfaceClass:      0x0A
bInterfaceSubClass:   0x00
bInterfaceProtocol:   0x00
iInterface:           0x00

Endpoint Descriptor:
bEndpointAddress:     0x01  OUT
Transfer Type:        Bulk
wMaxPacketSize:     0x0040 (64)
bInterval:            0x00

Endpoint Descriptor:
bEndpointAddress:     0x81  IN
Transfer Type:        Bulk
wMaxPacketSize:     0x0040 (64)
bInterval:            0x00

观察发现枚举应该没有问题,可是端点没有打开。不知何故?
<
收藏 评论24 发布时间:2015-6-4 11:50

举报

24个回答
mark0668 回答时间:2015-6-4 12:18:15
看下USB 驱动ID是否一样
lusonghua 回答时间:2015-6-4 12:22:04
学习学习,,,
watershade 回答时间:2015-6-4 13:31:13
最早就看过ID了,似乎不是。谢谢!
watershade 回答时间:2015-6-4 13:33:07
驱动里面的ID:
%DESCRIPTION%=DriverInstall,USB\VID_0483& PID_5740
和我用USB VIEW看到的一样。
无助呀,
莫林2020 回答时间:2015-6-4 13:52:40
可以学习
无力回天 回答时间:2015-6-4 13:54:15
xuexileafa 学习了
watershade 回答时间:2015-6-4 14:05:59
刚才我从一个国外网站上找到一段F429-Disco的例程 ,测试通过。
网站是: http://stm32f4-discovery.com/
我需要用usb view再观察一下,然后排查一下cube生成的代码还需要做什么工作。我看cube的那个um1734看了一两天,也没看明白流程。杯具呀!
下面是用usb view得出的数据:
Device Descriptor:
bcdUSB:             0x0200
bDeviceClass:         0x00
bDeviceSubClass:      0x00
bDeviceProtocol:      0x00
bMaxPacketSize0:      0x40 (64)
idVendor:           0x0483 (STMicroelectronics)
idProduct:          0x5740
bcdDevice:          0x0200
iManufacturer:        0x01
0x0409: "STMicroelectronics"
iProduct:             0x02
0x0409: "STM32 Virtual ComPort in FS Mode"
iSerialNumber:        0x03
0x0409: "00000000050C"
bNumConfigurations:   0x01

ConnectionStatus: DeviceConnected
Current Config Value: 0x01
Device Bus Speed:     Full
Device Address:       0x03
Open Pipes:              3

Endpoint Descriptor:
bEndpointAddress:     0x82  IN
Transfer Type:   Interrupt
wMaxPacketSize:     0x0008 (8)
bInterval:            0x10

Endpoint Descriptor:
bEndpointAddress:     0x01  OUT
Transfer Type:        Bulk
wMaxPacketSize:     0x0040 (64)
bInterval:            0x00

Endpoint Descriptor:
bEndpointAddress:     0x81  IN
Transfer Type:        Bulk
wMaxPacketSize:     0x0040 (64)
bInterval:            0x00

Configuration Descriptor:
wTotalLength:       0x0043
bNumInterfaces:       0x02
bConfigurationValue:  0x01
iConfiguration:       0x00
bmAttributes:         0xC0 (Bus Powered Self Powered )
MaxPower:             0x32 (100 Ma)

Interface Descriptor:
bInterfaceNumber:     0x00
bAlternateSetting:    0x00
bNumEndpoints:        0x01
bInterfaceClass:      0x02
bInterfaceSubClass:   0x02
bInterfaceProtocol:   0x01
iInterface:           0x00

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x05
05 24 00 10 01

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x05
05 24 01 00 01

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x04
04 24 02 02

Unknown Descriptor:
bDescriptorType:      0x24
bLength:              0x05
05 24 06 00 01

Endpoint Descriptor:
bEndpointAddress:     0x82  IN
Transfer Type:   Interrupt
wMaxPacketSize:     0x0008 (8)
bInterval:            0x10

Interface Descriptor:
bInterfaceNumber:     0x01
bAlternateSetting:    0x00
bNumEndpoints:        0x02
bInterfaceClass:      0x0A
bInterfaceSubClass:   0x00
bInterfaceProtocol:   0x00
iInterface:           0x00

Endpoint Descriptor:
bEndpointAddress:     0x01  OUT
Transfer Type:        Bulk
wMaxPacketSize:     0x0040 (64)
bInterval:            0x00

Endpoint Descriptor:
bEndpointAddress:     0x81  IN
Transfer Type:        Bulk
wMaxPacketSize:     0x0040 (64)
bInterval:            0x00

顺便吐槽一下cube库中F4/429-discovery没有USB Device的例程,F4X9的例程似乎也不适用。
watershade 回答时间:2015-6-4 14:22:53
通过比较,发现枚举的数据和之前那个并无不同,唯一不同的是连接状态。设备在连上主机之后的枚举应该是完成的,但是为什么端点打不开呐?通过刚才烧写的那个程序显示,硬件是没有问题的。继续探测,能不能为cube库的usb做几节教程呐,高手们,哪怕是ppt也行。
creep 回答时间:2015-6-4 14:26:29
watershade 发表于 2015-6-4 14:22
通过比较,发现枚举的数据和之前那个并无不同,唯一不同的是连接状态。设备在连上主机之后的枚举应该是完成 ...

我的F429使用的是标准库里面的USB CDC 驱动,比这个HAL好理解些,这个HAL的USB代码太复杂了
123下一页

所属标签

相似问题

关于
我们是谁
投资者关系
意法半导体可持续发展举措
创新与技术
意法半导体官网
联系我们
联系ST分支机构
寻找销售人员和分销渠道
社区
媒体中心
活动与培训
隐私策略
隐私策略
Cookies管理
行使您的权利
官方最新发布
STM32N6 AI生态系统
STM32MCU,MPU高性能GUI
ST ACEPACK电源模块
意法半导体生物传感器
STM32Cube扩展软件包
关注我们
st-img 微信公众号
st-img 手机版