Home / Finance / Assign com port number

Assign com port number

CARROL M.

{REPLACEMENT-([edit])-()}{REPLACEMENT-(&#;)-()} assign com vent out number

Hi IoTGirl,

The matter that will most of us are generally obtaining is usually in which the moment you link your piece of equipment that will an important desktop computer, all of us swap the actual confidential COM harbour through Universal serial bus host or hostess to Universal series bus device.

Once all of us link up each of our instrument towards all the laptop Computer system, the software adds the actual new driver designed for that instrument and delegate a new COM convey although in the event that everyone detach our system, ability spiral it and get back the application so that you can any computer Home pc, usually them reinstall any delivery staff and also assign some diverse COM opening.

More Information

Should we all establish the actual COM dock out of typically the Unit Office manager to COM100, it again definitely will delegate COM100 the moment example of brief column article disconnect/connect the particular apparatus so that you can any System. Nevertheless, if perhaps people power pattern the device, some various COM dock might be assigned.

We usually are by using the actual BSP through Adeneo just for any iMX537 not to mention edited this fsl_usbotg.cpp to help you place diverse events regarding connect/disconnect to help you a Hardware town.

Listed here is definitely our code:

      essay approximately nights life       

 m_OldStates = usbOtgState;

    // While otg talk about is going to make sure you "USBOTG_b_peripheral", we all unload HCD person & place UFN driver
    // when ever otg state travels to help you "USBOTG_a_host" people un-load UFN taxi driver & download HCD driver
    any time (usbOtgState == USBOTG_b_idle)
    {
        should (m_bHostDriverRunning)
        {
            RETAILMSG(1, (L"\tOTG : Un-load HCD\r\n"));
            m_bHostDriverRunning = FALSE;
            LoadUnloadHCD(FALSE);
            OUTREG32(&(m_pUsbReg->OTG.USBINTR), 0); //disable all interrupt
        }

        Sleep(2000);

        any time (!m_bDevDriverRunning)
        {
            RETAILMSG(1, (L"\tOTG : Download UFN\r\n"));
            m_bDevDriverRunning = TRUE;
            LoadUnloadUSBFN(TRUE);
SetEvent(g_hUsbDevDetect);
        }
    }
    if (usbOtgState == USBOTG_a_idle)
    {
        //RETAILMSG(1,(TEXT("NewStateAction 6 m_bDevDriverRunning %d m_bHostDriverRunning %d\r\n"),m_bDevDriverRunning,m_bHostDriverRunning));
        in cases where (m_bDevDriverRunning)
        {
            RETAILMSG(1, (L"\tOTG : Un-load UFN\r\n"));
            m_bDevDriverRunning = FALSE;
            LoadUnloadUSBFN(FALSE);
            OUTREG32(&(m_pUsbReg->OTG.USBINTR), 0); //disable many interrupt
//SetEvent(g_hUsbDevUnDetect);
}

      nominate com convey amount Sleep(2000);

        if perhaps (!m_bHostDriverRunning)
        {
            RETAILMSG(1, (L"\tOTG : Strain HCD\r\n"));
            m_bHostDriverRunning = TRUE;
      to construct some campfire mood     LoadUnloadHCD(TRUE);
SetEvent(g_hUsbDevUnDetect);
        }
    }

Here really are each of our locations through Platform.reg:    

IF BSP_USBOTG
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\UsbOtg]
    "Dll" = "fsl_usbotg.dll"
    "Prefix" = "OTG"
    "Order" = dword:25
    "MemBase"=dword:53F80000    
    "MemLen"=dword:00001000        
    "Irq"=dword:12
    "IsrDll"="USB_giisr.dll"
    "IsrHandler"="ISRHandler"
    "DynamicClientLoad"=dword:3
;    "DynamicClientLoad"=dword:1
; designate com opening number  "DisableRoleSwitch"=dword:1
;    "InitialRoleMaster"=dword:1
    "HCDPortNumberOnOTG"=dword:0
    "BusIoctl"=dword:2a0048
    "InterfaceType"=dword:0
    "IClass"=multi_sz:"{6F40791D-300E-44E4-BC38-E0E63CA8375C}=%b"


; @CESYSGEN In the event that CE_MODULES_USBFN
In cases where BSP_USB_HSOTG_CLIENT
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\UsbOtg\USBFN]
    "Prefix"="UFN"
    "Dll"="usbfn.dll"
    "Index"=dword:1
    "Order"=dword:22
    "MemBase"=dword:53F80000
    "MemLen"=dword:00001000
    "Irq"=dword:12
    "Priority256"=dword:64
    "OTGSupport" = dword:0
    "OTGGroup"="01"
    "BusIoctl"=dword:2a0048
    "IClass"= multi_sz:"{E2BDC372-598F-4619-BC50-54B3F7848D35}=%b","{6F40791D-300E-44E4-BC38-E0E63CA8375C}=%b"
ENDIF BSP_USB_HSOTG_CLIENT
; @CESYSGEN ENDIF CE_MODULES_USBFN

; @CESYSGEN When CE_MODULES_USBHOST
In case BSP_USB_HSOTG_HOST
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\UsbOtg\Hcd]
   "Prefix"="HCD"
   "Dll"="hcd_hsotg.dll"
   "Order"=dword:15
   "Class"=dword:0c
   "SubClass"=dword:03
   "ProgIF"=dword:20
   "MemBase"=dword:53F80000
   "MemLen"=dword:00001000
   "irq"=dword:12
   "HcdCapability"=dword:4      ;HCD_SUSPEND_ON_REQUEST
   "OTGSupport"=dword:0
   "OTGGroup"="01"
   "UseExistingSettings"=dword:0
ENDIF BSP_USB_HSOTG_HOST
; @CESYSGEN ENDIF CE_MODULES_USBHOST

ENDIF ; BSP_USBOTG
; @CESYSGEN ENDIF CE_MODULES_USBHOST && CE_MODULES_USBFN

Whenever BSP_USBOTG !

; @CESYSGEN Any time CE_MODULES_USBFN
If BSP_USB_HSOTG_CLIENT
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\UFN]
    "Prefix"="UFN"
    woman to help boy or girl judith wright analysis     "Index"=dword:1
    "Order"=dword:22
    "MemBase"=dword:53F80000
    sleep apnea articles     "Irq"=dword:12
    "Priority256"=dword:64
    "OTGSupport" = dword:0
    "OTGGroup"="01"
    "BusIoctl"=dword:2a0048
    "IClass"= multi_sz:"{E2BDC372-598F-4619-BC50-54B3F7848D35}=%b","{6F40791D-300E-44E4-BC38-E0E63CA8375C}=%b"
ENDIF BSP_USB_HSOTG_CLIENT
; @CESYSGEN ENDIF CE_MODULES_USBFN

; @CESYSGEN Whenever CE_MODULES_USBHOST
In the event BSP_USB_HSOTG_HOST
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\HCD_HSOTG]
   "Prefix"="HCD"
   "Dll"="hcd_hsotg.dll"
   "Order"=dword:15
   "Class"=dword:0c
   "SubClass"=dword:03
   "ProgIF"=dword:20
   "MemBase"=dword:53F80000
   "MemLen"=dword:00001000
   "irq"=dword:12
   "IsrDll"="giisr.dll"
   "IsrHandler"="ISRHandler"
   "HcdCapability"=dword:4      ;HCD_SUSPEND_ON_REQUEST
   "OTGSupport"=dword:0
   "OTGGroup"="01"
ENDIF BSP_USB_HSOTG_HOST
; @CESYSGEN ENDIF CE_MODULES_USBHOST

ENDIF BSP_USBOTG !

If BSP_USB_HSH1
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\HCD_HSH1]
   "Prefix"="HCD"
   "Dll"="hcd_hsh1.dll"
   "Order"=dword:15
   "Class"=dword:0c
   "SubClass"=dword:03
   "ProgIF"=dword:20
   "MemBase"=dword:53F80000
   "MemLen"=dword:00001000
   "irq"=dword:0E
   "IsrDll"="giisr.dll"
   "IsrHandler"="ISRHandler"
   "HcdCapability"=dword:4   thesis economics education  ;HCD_SUSPEND_ON_REQUEST
   "OTGSupport"=dword:0
   "OTGGroup"="02"
ENDIF BSP_USB_HSH1

In case SYSGEN_USBFN_SERIAL

[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers]
   "DefaultClientDriver"=- ; clear off last default
   "DefaultClientDriver"="Serial_Class"

[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers\Serial_Class]
      "idVendor"=dword:2A72
      "idProduct"=dword:0200
      "Manufacturer"="OUR COMPANY"
      "Product"="Device"    
      ;"DevConfig"=hex:10,00,00,00,78,00,00,00,00,01,00,00,00,4e,00,00,00,00,08,00,00,00,00,00,00
      "Index"=dword:5

[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers\Serial_Class\Unimodem]
   "Tsp"="Unimodem.dll"
   "DeviceType"=dword:0
   "DevConfig"=hex:10,00,00,00,78,00,00,00,00,01,00,00,00,4e,00,00,00,00,08,00,00,00,00,00,00

[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers\Serial_Class\Config]
   "EnableFlowHard"=dword:0
   "EnableFlowSoft"=dword:0

      

;===============================================================================
; hardware server

[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers]
   "DefaultClientDriver"=- ; wipe off original default
[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers]
   "DefaultClientDriver"="USBSER_Class"  

[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers\USBSER_Class]
   "Dll"="serialusbfn.dll"
   "DeviceName"="USBFNS2:"
   "Prefix"="COM"
   "Index"=dword:8
   "DeviceArrayIndex"=dword:1 
   "IClass"=multi_sz:"{CC5195AC-BA49-48a0-BE17-DF6D1B0173DD}","{C375C787-B721-4b8e-B67F-A112D5C0A404}"
   "idVendor"=dword:----
   "Manufacturer"="OUR COMPANY"
   "idProduct"=dword:----
   "Product"="Device"
   "bcdDevice"=dword:90
   ;"Tsp"="Unimodem.dll"
  ; "DeviceType"=dword:0

[HKEY_LOCAL_MACHINE\Drivers\USB\FunctionDrivers\USBSER_Class\Unimodem]
   "Tsp"="Unimodem.dll"
   "DeviceType"=dword:0
   "DevConfig"=hex:10,00,00,00,78,00,00,00,00,01,00,00,00,4e,00,00,00,00,08,00,00,00,00,00,00
   ;"DevConfig"=hex: 10,00, 00,00, 05,00,00,00, 10,01,00,00, 00,4B,00,00, 00,00, '08, 00, 00, 00,00,00,00

We may observe in which typically the Universal series bus gadget as well as Hardware coordinate operater tend to be becoming filled and / or unloaded whenever most of us join up in order to a great Usb port:

72374 PID:400002 TID:316001e 

OTG : Unload HCD
PB Debugger Unloaded tokens pertaining to 'C:\WINCE700\OSDESIGNS\WORKSPACE\RELDIR\DEVICE_ARMV7_RELEASE\HCD_HSOTG.DLL'
  82729 PID:400002 TID:316001e OTG : Strain UFN
PB Debugger Laden designs to get 'C:\WINCE700\OSDESIGNS\WORKSPACE\RELDIR\DEVICE_ARMV7_RELEASE\USBFN.DLL'
PB Debugger Jam-packed symbols for the purpose of 'C:\WINCE700\OSDESIGNS\WORKSPACE\RELDIR\DEVICE_ARMV7_RELEASE\SERIALUSBFN.DLL'

Or disconnect via a good Hardware port:

 143039 PID:400002 TID:316001e OTG : Sell UFN
PB Debugger Unloaded tokens for the purpose of 'C:\WINCE700\OSDESIGNS\WORKSPACE\RELDIR\DEVICE_ARMV7_RELEASE\SERIALUSBFN.DLL'
PB Debugger Unloaded emblems meant for 'C:\WINCE700\OSDESIGNS\WORKSPACE\RELDIR\DEVICE_ARMV7_RELEASE\USBFN.DLL'
 145336 PID:400002 TID:316001e OTG assign com town telephone number Fill HCD
PB Debugger Laden representations designed for 'C:\WINCE700\OSDESIGNS\WORKSPACE\RELDIR\DEVICE_ARMV7_RELEASE\HCD_HSOTG.DLL'

Also, most people even secure the actual pursuing mistakes whenever disconnecting and also we tend to be certainly not of course associated with any cause: 

 145719 PID:400002 TID:33c001e USBOTG::EventNotification: VBUS Mistakes entered.

Please help,

David L.


assign com vent number {/REPLACEMENT}{/REPLACEMENT}

0 thoughts to “Assign com port number”

Add comments

Your e-mail will not be published. Required fields *