How to implement a USB CDC/ACM department

Hi :

Can anyone guide to implement a USB CDC /ACM

I have complete the USB to Com port driver and I wanna to support the AT /modem command transfer from my driver that make my phone can dial up to net.

wish you can help me to design this driver ,Detail or any relative material would be better

A little more details from your end will help us.

Thanks
Anshul Makkar
www.justkernel.com
xxxxx@justkernel.com

On Thu, May 13, 2010 at 5:33 PM, wrote:

> Hi :
>
> Can anyone guide to implement a USB CDC /ACM
>
> I have complete the USB to Com port driver and I wanna to support the AT
> /modem command transfer from my driver that make my phone can dial up to
> net.
>
> wish you can help me to design this driver ,Detail or any relative material
> would be better
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>


Thanks
Anshul Makkar
www.justkernel.com
xxxxx@justkernel.com

Well ,Thanks for your reply!

This driver had been implement by Microsoft and the driver binary file is usbser.sys

For the reason that the driver have some bug ,I try to rewrite this driver

This driver was implement for USB device to virtual a com port. and the application can

communicate with device by this com port.

E.g. some mobile phone use usbser.sys as the cable driver ,and then dial up to connect to the net by GPRS

I had complete a part of this driver (USB driver and virtual a com port ) , but I can dial up to connect to the Internet because I didn’t complete the CDC/ACM part , the driver can not understand the AT command and the modem .

I have not idea of CDC/ACM .and try to listen to U driver expert . and learn more about how to implement this protocol .

It is a long word .and It is kind of you for reading my bad english express

Let me try to answer it .

This driver should consist of 2 parts ,

it plays roles to upper driver(modem) as an entity(actually it’s a filter driver as modem driver) understanding modem request . You can refer to fakemodem(enclosed in WDK samples) for details.

it’s also functions to lower driver as USB client driver. So you need to format the received data in accordance with USB . You can refer to usbcdc11.pdf for details .

Hope they are helpful to you.

Dear Daniel Xie

Yes ,you are right ! I had read over the usbcdc11.pdf .

But didn’t understand much about that .and I did not have serial cable ( for com port there maybe some serial command transfer over the USB cable). how can I map this hardware exactly

@Podun Yu

As Daniel Xie told, fakemodem is best place to strart.

ACM class understands “AT” commands and in one of the descriptor(s) (I guess INterface desc) the type/version of protocol supported is given.

you have to support various IOCTL(s) to be able to connect to modem (or loosely internet) , WAIT_MASK and RS232 signals (DTR etc) are one of those . Refer to fakemodem for more info

Hope this helps you

I would suggest that you look at the serial sample as well. It shows all of the IOCTls you need to support to be a serial port

d

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Thursday, May 13, 2010 9:05 PM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] How to implement a USB CDC/ACM department

@Podun Yu

As Daniel Xie told, fakemodem is best place to strart.

ACM class understands “AT” commands and in one of the descriptor(s) (I guess INterface desc) the type/version of protocol supported is given.

you have to support various IOCTL(s) to be able to connect to modem (or loosely internet) , WAIT_MASK and RS232 signals (DTR etc) are one of those . Refer to fakemodem for more info

Hope this helps you


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

Thanks Doron and JItender!

I had read the serial sample code .

and I has a puzzle that the serial sample is the driver for a serial real device (8250 UART) . So It deals with the commands by writing the controller memory(base address + offset) .

But The driver that i will implement is a USB device virtual a com port ,how i deals with the serial command ?

For example :
If my driver want to deal with a command IOCTL_SERIAL_SET_DTR ,should I poss this command to the lower driver or do something in my driver then complete this command .

For every instance where you see hw access substitute it with sending the appropriate PURB

d

sent from a phpne with nonoard

-----Original Message-----
From: xxxxx@hotmail.com
Sent: May 13, 2010 11:20 PM
To: Windows System Software Devs Interest List
Subject: RE:[ntdev] How to implement a USB CDC/ACM department

Thanks Doron and JItender!

I had read the serial sample code .

and I has a puzzle that the serial sample is the driver for a serial real device (8250 UART) . So It deals with the commands by writing the controller memory(base address + offset) .

But The driver that i will implement is a USB device virtual a com port ,how i deals with the serial command ?

For example :
If my driver want to deal with a command IOCTL_SERIAL_SET_DTR ,should I poss this command to the lower driver or do something in my driver then complete this command .


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer