How to communicate with the NetDCU (PicoMOD or PicoCOM as well) as a virtual COM port from
your desktop PC over USB?
You can do that with the Windows CE Serial USB Function Driver (called serialusbfn.dll).
#1 Installing the Windows CE component:
- [HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers\USBSER_Class]
- "Dll"="serialusbfn.dll"
- "DeviceName"="USBFNS2:"
- "Prefix"="COM"
- "DeviceArrayIndex"=dword:1
- "IClass"=multi_sz:"{CC5195AC-BA49-48a0-BE17-DF6D1B0173DD}","{C375C787-B721-4b8e-B67F-A112D5C0A404}"
- "idVendor"=dword:045E
- "Manufacturer"="Generic Manufacturer (PROTOTYPE--Remember to change idVendor)"
- "idProduct"=dword:0079
- "Product"="Generic Serial (PROTOTYPE--Remember to change idVendor)"
- "bcdDevice"=dword:90
- "Tsp"="Unimodem.dll"
- "DeviceType"=dword:0
- "Index"=dword:9
- [HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers]
- "DefaultClientDriver"="USBSER_Class"
#2 Installing the desktop PC component (Windows XP):
You need the installation *.inf file and the usbser.sys file located together in the same directory. When you connect the NetDCU for the first time (with the modified registry from above) to your development pc you will be asked to install a driver. Select the concernig directory where the *.inf file and the usbser.sys is located. After the installation you will see the NetDCU as a virtual COM port in the device manager of your development pc (Figure 1).
The *.inf file content:
- [Version]
- Signature="$Windows NT$"
- Class=Ports
- ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318}
- Provider=%VCOM_M%
- DriverVer=14/01/2009,0.0.0.1
- [Manufacturer]
- %VCOM_M%=Generic Manufacturer
- [Generic Manufacturer]
- %VCOM%=VCOM_USB, USB\VID_045E&PID_0079
- [DestinationDirs]
- DefaultDestDir=10,System32\Drivers
- [VCOM_USB]
- CopyFiles=VCOMCopyFiles
- AddReg=VCOMAddReg
- [VCOMCopyFiles]
- usbser.sys
- [VCOMAddReg]
- HKR,,DevLoader,,*ntkern
- HKR,,NTMPDriver,,usbser.sys
- HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider"
- [VCOM_USB.Services]
- AddService = usbser,0x0002,VCOMService
- [VCOMService]
- DisplayName = %VCOM_DISPLAY_NAME%
- ServiceType = 1 ; SERVICE_KERNEL_DRIVER
- StartType = 3 ; SERVICE_DEMAND_START
- ErrorControl = 1 ; SERVICE_ERROR_NORMAL
- ServiceBinary = %10%\System32\Drivers\usbser.sys
- LoadOrderGroup = Base
- [Strings]
- VCOM_M = "Generic Manufacturer (PROTOTYPE--Remember to change idVendor)"
- VCOM = "Generic Serial (PROTOTYPE--Remember to change idVendor)"
- VCOM_DISPLAY_NAME = "Generic Serial VCOM"
#3 Communicate with NDCUCFG.EXE via the virtual COM port.
#3.1 Setup NDCUCFG.EXE to start on COM port of the USBSER_Class (HKLM\System\NDCUCFG => set value "Port" to "COM9:")
#3.2 Reboot the NetDCU.
#3.3 Setup PC Connection from Control Panel => PC Connection: See Figure 2. Press OK.
#3.4 Connect your PC to the USB device port using a USB cable. You will see NetDCU as COM port in your device manager (Figure 1).
#3.5 Open DCUTerm.exe (Terminalprogram) and open respective COM port.
#3.6 Start NDCUCFG.EXE on the NetDCU (from commandline) like that: "ndcucfg x".
DKuhne.