打印
[应用相关]

STM32 USB转虚拟串口需要安装驱动?

[复制链接]
23421|18
手机看帖
扫描二维码
随时随地手机跟帖
跳转到指定楼层
楼主
saystar|  楼主 | 2008-7-3 17:52 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
我把例程序移植到我的软件上之后系统响应到该设备可是需要安装驱动程序?在哪里可以下载到啊?
沙发
jeames| | 2008-7-3 17:55 | 只看该作者

ST的网站上有哦

没仔细找??

使用特权

评论回复
板凳
saystar|  楼主 | 2008-7-3 18:00 | 只看该作者

好多啊E文啊

俺E文超差的。。。。。

使用特权

评论回复
地板
jeames| | 2008-7-3 18:08 | 只看该作者

???有中文的界面

搂主不会连“中国”二字也不认识吧!!

使用特权

评论回复
5
saystar|  楼主 | 2008-7-3 18:13 | 只看该作者

中国里面没有

俺到英文站点里面找到鸟。。。

使用特权

评论回复
6
jeames| | 2008-7-3 18:20 | 只看该作者

哈哈

就是没仔细找

http://www.stmicroelectronics.com.cn/stonline/mcu/MCU_Pages.htm

在这哩

使用特权

评论回复
7
computer00| | 2008-7-3 20:31 | 只看该作者

只需要一个inf文件安装即可~~~~不用sys文件的~~

;将下面内容复制到记事本,然后把扩展名改成.inf。
;你只要修改下面的USBVID_8888&PID_0006,将VID和PID改成你自己程序中的就可以安装拉~~~

; Windows USB CDC Setup File
; Copyright (c) 2000 Microsoft Corporation
; Copyright (c) 2006 Recursion Co., Ltd.

[Version] 
Signature="$Windows NT$" 
Class=Ports
ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} 
Provider=%COMPANY% 
LayoutFile=layout.inf
DriverVer=12/06/2007,1.0.0.1

[Manufacturer] 
%MFGNAME% = ManufName

[DestinationDirs] 
DefaultDestDir=12 

[ManufName] 
%Modem3% = Modem3, USBVID_8888&PID_0006

;------------------------------------------------------------------------------
;  Windows 2000/XP Sections
;------------------------------------------------------------------------------

[Modem3.nt]
CopyFiles=USBModemCopyFileSection
AddReg=Modem3.nt.AddReg 

[USBModemCopyFileSection]
usbser.sys,,,0x20

[Modem3.nt.AddReg] 
HKR,,DevLoader,,*ntkern 
HKR,,NTMPDriver,,usbser.sys
HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" 

[Modem3.nt.Services] 
AddService=usbser, 0x00000002, DriverService

[DriverService] 
DisplayName=%SERVICE%
ServiceType=1
StartType=3
ErrorControl=1
ServiceBinary=%12%usbser.sys 

;------------------------------------------------------------------------------
;  String Definitions
;------------------------------------------------------------------------------

[Strings] 
COMPANY="电脑圈圈的家当"
MFGNAME="电脑圈圈"
Modem3="电脑圈圈做的USB转串口" 
SERVICE="USB2UART Driver"

使用特权

评论回复
8
dkill| | 2008-7-4 09:09 | 只看该作者

如果协议不是hid cdc 等 而是自己定义的

那么驱动也是这样安装吗?

使用特权

评论回复
9
samuelyu| | 2008-7-4 09:28 | 只看该作者

应该是可以的;

只要你配置好相应的 INF 描述字段就可以;

使用特权

评论回复
10
dkill| | 2008-7-4 09:36 | 只看该作者

您说的描述字段 指的是?

可以以7楼的程序  说明一下吗  不胜感激

使用特权

评论回复
11
computer00| | 2008-7-4 09:44 | 只看该作者

自己定义的类,windows就不自带这个sys文件了,需要自己开发

但是安装文件通常还是一个inf文件,并且还需要提供一个过多个sys文件。



相关链接:http://blog.21ic.com/user1/2198/archives/2008/46442.html

使用特权

评论回复
12
dkill| | 2008-7-4 10:50 | 只看该作者

下载地址3:Computer00USB驱动.rar

没有链接

使用特权

评论回复
13
computer00| | 2008-7-4 11:00 | 只看该作者

那是服务器出了问题……

这个只是个例子,说明要自己提供sys文件的。

你做串口的话,可以去网上找个现成的程序来改改。DDK目录下好象也有串口的例子。

使用特权

评论回复
14
dkill| | 2008-7-4 11:47 | 只看该作者

这个是端口描述符 没有协议 驱动怎么写呢

const u8 Virtual_Com_Port_ConfigDescriptor[] =
  {
    /*Configuation Descriptor*/
    0x09,   /* bLength: Configuation Descriptor size */
    USB_CONFIGURATION_DESCRIPTOR_TYPE,      /* bDescriptorType: Configuration */
    VIRTUAL_COM_PORT_SIZ_CONFIG_DESC,       /* wTotalLength:no of returned bytes */
    0x00,
    0x02,   /* bNumInterfaces: 2 interface */
    0x01,   /* bConfigurationValue: Configuration value */
    0x00,   /* iConfiguration: Index of string descriptor describing the configuration */
    0x50,   /* bmAttributes: self powered */
    0xc0,   /* MaxPower 0 mA */
    /*Interface Descriptor*/
    0x09,   /* bLength: Interface Descriptor size */
    USB_INTERFACE_DESCRIPTOR_TYPE,  /* bDescriptorType: Interface */
    /* Interface descriptor type */
    0x00,   /* bInterfaceNumber: Number of Interface */
    0x00,   /* bAlternateSetting: Alternate setting */
    0x03,   /* bNumEndpoints: One endpoints used */
    0xff,   /* bInterfaceClass: Communication Interface Class */
    0xff,   /* bInterfaceSubClass: Abstract Control Model */
    0xff,   /* bInterfaceProtocol: Common AT commands */
    0x00,   /* iInterface: */
   /*Endpoint 2 Descriptor*/
    0x07,   /* bLength: Endpoint Descriptor size */
    USB_ENDPOINT_DESCRIPTOR_TYPE,   /* bDescriptorType: Endpoint */
    0x82,   /* bEndpointAddress: (IN2) */
    0x03,   /* bmAttributes: Interrupt */
    VIRTUAL_COM_PORT_INT_SIZE,      /* wMaxPacketSize: */
    0x00,
    0x20,   /* bInterval: */
    /*Endpoint 3 Descriptor*/
    0x07,   /* bLength: Endpoint Descriptor size */
    USB_ENDPOINT_DESCRIPTOR_TYPE,   /* bDescriptorType: Endpoint */
    0x03,   /* bEndpointAddress: (OUT3) */
    0x02,   /* bmAttributes: Bulk */
    VIRTUAL_COM_PORT_DATA_SIZE,             /* wMaxPacketSize: */
    0x00,
    0x20,   /* bInterval: ignore for Bulk transfer */
    /*Endpoint 1 Descriptor*/
    0x07,   /* bLength: Endpoint Descriptor size */
    USB_ENDPOINT_DESCRIPTOR_TYPE,   /* bDescriptorType: Endpoint */
    0x81,   /* bEndpointAddress: (IN1) */
    0x02,   /* bmAttributes: Bulk */
    VIRTUAL_COM_PORT_DATA_SIZE,             /* wMaxPacketSize: */
    0x00,
    0x20,    /* bInterval */
    /*Data class interface descriptor*/
    0x09,   /* bLength: Endpoint Descriptor size */
    USB_INTERFACE_DESCRIPTOR_TYPE,  /* bDescriptorType: */
    0x01,   /* bInterfaceNumber: Number of Interface */
    0x00,   /* bAlternateSetting: Alternate setting */
    0x03,   /* bNumEndpoints: Two endpoints used */
    0xff,   /* bInterfaceClass: CDC */
    0xff,   /* bInterfaceSubClass: */
    0xff,   /* bInterfaceProtocol: */
    0x00,   /* iInterface: */
     /*Endpoint 2 Descriptor*/
    0x07,   /* bLength: Endpoint Descriptor size */
    USB_ENDPOINT_DESCRIPTOR_TYPE,   /* bDescriptorType: Endpoint */
    0x84,   /* bEndpointAddress: (IN2) */
    0x03,   /* bmAttributes: Interrupt */
    VIRTUAL_COM_PORT_INT_SIZE,      /* wMaxPacketSize: */
    0x00,
    0x20,   /* bInterval: */
  /*Endpoint 3 Descriptor*/
    0x07,   /* bLength: Endpoint Descriptor size */
    USB_ENDPOINT_DESCRIPTOR_TYPE,   /* bDescriptorType: Endpoint */
    0x05,   /* bEndpointAddress: (OUT3) */
    0x02,   /* bmAttributes: Bulk */
    VIRTUAL_COM_PORT_DATA_SIZE,             /* wMaxPacketSize: */
    0x00,
    0x20,   /* bInterval: ignore for Bulk transfer */
    /*Endpoint 1 Descriptor*/
    0x07,   /* bLength: Endpoint Descriptor size */
    USB_ENDPOINT_DESCRIPTOR_TYPE,   /* bDescriptorType: Endpoint */
    0x86,   /* bEndpointAddress: (IN1) */
    0x02,   /* bmAttributes: Bulk */
    VIRTUAL_COM_PORT_DATA_SIZE,             /* wMaxPacketSize: */
    0x00,
    0x20,    /* bInterval */
    
   };

使用特权

评论回复
15
computer00| | 2008-7-7 09:51 | 只看该作者

你可以看MSDN或者DDK的帮助文档,里面有串口需要的API的协议

使用特权

评论回复
16
gonghaixu| | 2013-7-13 23:05 | 只看该作者
我需要一个驱动程序 ghx-123@163.com 谢谢啊

使用特权

评论回复
17
snow112004| | 2014-9-23 16:05 | 只看该作者
computer00 好棒,你写的那本书上的程序是什么硬件的程序啊,我只看了大概但是还是不会自己写,我也要写STM32的……

使用特权

评论回复
18
picasso101| | 2014-9-25 15:42 | 只看该作者
找到了,这个确实是要的,就是一个文件

使用特权

评论回复
19
salvadorhcys| | 2017-8-22 22:24 | 只看该作者
能发给我借鉴下吗 usb-serial的传感器我不会串口驱动移植
694018406@qq.com 谢谢

使用特权

评论回复
发新帖 我要提问
您需要登录后才可以回帖 登录 | 注册

本版积分规则

19

主题

238

帖子

0

粉丝