Advanced Driver Options



Yüklə 338,83 Kb.
Pdf görüntüsü
səhifə9/13
tarix08.10.2017
ölçüsü338,83 Kb.
#3923
1   ...   5   6   7   8   9   10   11   12   13

 

 

 



Copyright © 2008-2014 Future Technology Devices International Limited 

22 


 

Document Reference No.: FT_000073 

Advanced Driver Options AN_107 Application Note

 

AN_107 Version 2.53 



Clearance No.: FTDI# 63 

 

6.6.7



 

Disable Modem Ctrl At Startup 

This option is used to control the modem control signals DTR and RTS at startup. In normal 

operation, the modem control signals at startup follow the behaviour of the legacy port. However, 

due to timing differences between a legacy COM port and a virtual COM port, a "spike" on one of 

these signals in the legacy port can appear as an assertion of the signal in the virtual COM port. 

Devices that monitor these signals can enter the wrong state after an unplug-replug cycle on USB.  

Note that if the "Serial Enumerator" option in the property page is selected, then the enumeration 

sequence causes the modem control signals to change at startup. So if it is necessary to select 

"Disable Modem Ctrl At Startup", then it is likely that "Serial Enumerator" should be unchecked in 

the property page. 

The Disable Modem Ctrl At Startup option is controlled through bit 1 of byte 1 of the first DWORD 

of the ConfigData entry in the FTDIPORT.INF file. This is the same entry that contains the Baud 

rate table. 

The first DWORD is shown in bold in the INF fragment below. 

[FtdiPort.NT.HW.AddReg] 

HKR,,"ConfigData",1,01,00,3F,3F,10,27,88,13,C4,09,E2,04,71,02,38,41,9C,80,4E,C0,34,00,

1A,00, 0D,00,06,40,03,80,00,00,D0,80 

Please note that this entry is byte-reversed, so MSB the DWORD reads 3F 3F 00 01 and the least 

significant bit is Bit 0. When disabled(modem control at startup enabled), the DWORD would read 

3F 3F 00 01. When enabled (modem control at startup disabled), the DWORD would read 3F 3F 

02 01

Alternatively, the default can be overridden by directly editing the ConfigData parameter in the 

virtual COM port's registry entry. 

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\FTDIBUS\VID_0403+PID_6001+12345678\00

00\DeviceParameters\ConfigData 

Note that if DisableModemControlSignalsAtStartup is set TRUE by editing the installation file or the 

registry, the same considerations as above apply to "

Serial Enumerator

 

". So it may be necessary 



to remove references to "serenum" in "UpperFilters" in the AddReg sections of the installation file, 

and in the UpperFilters key in the virtual COM port's registry entry. 

 

6.7

 

Changing the Driver Priority 

For some applications (e.g. audio data transmission), it is possible to change the priority level of 

the driver to provide better performance.  The InPriorityLevel and OutPriorityLevel values can be 

set to a value between 1 and 31.  The default value for both of these parameters is 16. 

The custom driver priority option is enabled through bit 11 of the first DWORD of the ConfigData 

entry in the FTDIPORT.INF file.  This is the same entry that contains the Baud rate table. 

The first DWORD is shown in bold in the INF fragment below. 

 

[FtdiPort.NT.HW.AddReg] 



HKR,,"ConfigData",1,01,00,3F,3F,10,27,88,13,C4,09,E2,04,71,02,38,41,9C,80,4E,C0,34,00,

1A,00,0D,00,06,40,03,80,00,00,D0,80 

[FtdiPort.NTamd64.HW.AddReg] 

HKR,,"ConfigData",1,01,00,3F,3F,10,27,88,13,C4,09,E2,04,71,02,38,41,9C,80,4E,C0,34,00,

1A,00,0D,00,06,40,03,80,00,00,D0,80 

 



 

 

 



Copyright © 2008-2014 Future Technology Devices International Limited 

23 


 

Document Reference No.: FT_000073 

Advanced Driver Options AN_107 Application Note

 

AN_107 Version 2.53 



Clearance No.: FTDI# 63 

Please note that the ConfigData entry is byte-reversed, so MSB the DWORD reads 3F 3F 00 01 and 

the least significant bit is Bit 0.  With the driver default priority, the DWORD would read 3F 3F 00 

01.  With custom driver priority enabled, the DWORD would read 3F 3F 08 01. 

 

In addition to enabling custom driver priority in the Config Data entry, some parameters must be 



set up to control the behaviour.  These parameters can also be set up in FTDIPORT.INF as follows: 

 

[FtdiPort.NT.HW.AddReg] 



HKR,,"InPriorityLevel",0x00010001,16 

HKR,,"OutPriorityLevel",0x00010001,16 

[FtdiPort.NTamd64.HW.AddReg] 

HKR,,"InPriorityLevel",0x00010001,16 

HKR,,"OutPriorityLevel",0x00010001,16 

 

These values are held in the registry under this key: 



HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\FTDIBUS\{Device VID, PID and serial 

number}\0000\Device Parameters 

 

Note that custom driver priority is rarely required and setting driver priority to an excessive level 



may result in machine lock-up.  Use custom driver priority with care and consult FTDI support if in 

doubt. 


 

6.8

 

Specifying the COM Port Allocation Start Value 

As of CDM 2.08.02, the co-installer applies to all FTDI devices and can accept an optional 

parameter to specify the initial index for COM port allocation.  The default behaviour for the CDM 

driver is to start the allocation at COM3.  If a COM port is in use, the next available COM port 

number will be used.  The initial index is specified for a specific VID and PID combination and can 

be included in the FTDIPORT INF file with the following entry: 

 

[FtdiPort.NT.AddService.AddReg] 



HKR,"Parameters\VID_0403&PID_6001","InitialIndex",0x00010001,14 

 

and the following line should be added to the [FtdiPort.NT.AddService] section: 



 

AddReg=FtdiPort.NT.AddService.AddReg 

 

This example will cause devices with a VID of 0x0403 and PID of 0x6001 to have their COM ports 



allocated from COM14 onwards.  Note that the VID and PID identifiers in bold in the above 

example should be customised for the particular device required.   

This values are held in the registry under this key: 

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\FTSER2K\VID_{vendorID}&PID_{productI

D} 

 

 



 


Yüklə 338,83 Kb.

Dostları ilə paylaş:
1   ...   5   6   7   8   9   10   11   12   13




Verilənlər bazası müəlliflik hüququ ilə müdafiə olunur ©genderi.org 2024
rəhbərliyinə müraciət

    Ana səhifə