Re: Can't open the serial ports.
- From: "Mike M." <nospam@xxxxxxxxxxxxx>
- Date: Wed, 15 Jun 2005 15:34:15 -0400
I did build a debug image but it would start up, spew some messages and then
reboot itself in a continuous loop. I am rebuilding and taking out kitl and
kernel debugger to see if that helps. I am not using PB to debug. I don't
know how to get it to connect to my device via TCP/IP. I just hooked a
serial cable between my PC and the device and run hyperterminal to see the
messages. I ftp my image to the device and then reboot the new image.
I don't see any particular "debug zones" for the serial driver. Where do I
find those?
Thanks.
"andreolkovisky" <andreolkovisky@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:ePGYJBdcFHA.2840@xxxxxxxxxxxxxxxxxxxxxxx
> Yes.Just look out for the debug messages on the debug window on PB and
hunt
> for Serial Driver messages.By the way you will have to enable all the
debug
> zones of the Serial module.
> "Mike M." <nospam@xxxxxxxxxxxxx> wrote in message
> news:%23pqzqWbcFHA.3328@xxxxxxxxxxxxxxxxxxxxxxx
> > I am making a Debug version of the image and I have connected to my CE
> > device from my PC on COM1. Is this the next step to see if I get any
> error
> > messages during boot?
> >
> > Thanks.
> >
> > "Bruce Eitman (eMVP)" <beitmannospam@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
wrote
> in
> > message news:eZBlLSbcFHA.2212@xxxxxxxxxxxxxxxxxxxxxxx
> > > That seems to indicate that the driver loaded, then unloaded for some
> > > reason. Possibly a failure in COM_Init()
> > >
> > > Yes, it should appear under Active. That is a list of loaded drivers.
> > >
> > > --
> > > Bruce Eitman (eMVP)
> > > Senior Engineer
> > > beitman AT applieddata DOT net
> > >
> > > Applied Data Systems
> > > www.applieddata.net
> > > An ISO 9001:2000 Registered Company
> > > Microsoft WEP Gold-level Member
> > >
> > >
> > > "Mike M." <nospam@xxxxxxxxxxxxx> wrote in message
> > > news:eH%234AHbcFHA.2980@xxxxxxxxxxxxxxxxxxxxxxx
> > > > Hi andreolkovisky, I was able to connect to my device using TCP/IP
and
> > run
> > > > Remote Registry Editor. The serial drivers do NOT appear under the
> hive
> > > > HKLM\Drivers\Active but they appear under HKLM\Drivers\BuiltIn as
> Serial
> > > and
> > > > Serial2. Do they also have to appear under Active?
> > > >
> > > > Thanks.
> > > >
> > > > "andreolkovisky" <andreolkovisky@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in
> > > message
> > > > news:uFh5BqNcFHA.796@xxxxxxxxxxxxxxxxxxxxxxx
> > > > > Check out if the Serial driver for COM2 is loaded.Sems to me that
> the
> > > > driver
> > > > > is not loaded.
> > > > > If you have KITL enabled check out remote registry editor to check
> out
> > > the
> > > > > active drivers.
> > > > >
> > > > > "Mike M." <nospam@xxxxxxxxxxxxx> wrote in message
> > > > > news:u52xyeFcFHA.3712@xxxxxxxxxxxxxxxxxxxxxxx
> > > > > > That didn't do it. I had the application code working before
> prior
> > to
> > > > the
> > > > > > (departed) CE guy messing with the image.
> > > > > >
> > > > > > Thanks for the suggestion.
> > > > > >
> > > > > > Any more?
> > > > > >
> > > > > > "Mike M." <nospam@xxxxxxxxxxxxx> wrote in message
> > > > > > news:uy5bkcFcFHA.720@xxxxxxxxxxxxxxxxxxxxxxx
> > > > > > > That's just a typo in transfering. I will try the _T.
> > > > > > > Thanks.
> > > > > > >
> > > > > > > "buzz" <buzz@xxxxxxxx> wrote in message
> > > > > > > news:%23v9hDWFcFHA.456@xxxxxxxxxxxxxxxxxxxxxxx
> > > > > > > > You have m_ComPort in your CreateFile call. Do you really
> want
> > > > > ComPort?
> > > > > > > > (CString ComPort = "COM2").
> > > > > > > > Also, try TCHAR* ComPort = _T("COM2:");
> > > > > > > >
> > > > > > > >
> > > > > > > > Mike M. wrote:
> > > > > > > > > I am using PB 5.0. The target is an Advantech PCM-3348
SBC.
> > I
> > > > have
> > > > > > > > > inherited this project from a recently departed employee
and
> I
> > > am
> > > > > > > struggling
> > > > > > > > > with the serial ports. COM1 and COM2 were supposedly
> working
> > > but
> > > > > when
> > > > > > > my
> > > > > > > > > app tries to open COM2: using CreateFile it gets
> > > > > ERROR_DEV_NOT_EXIST.
> > > > > > I
> > > > > > > have
> > > > > > > > > googled the groups for hours and have checked the values
> from
> > > > posts
> > > > > I
> > > > > > > have
> > > > > > > > > seen. The BIOS settings are:
> > > > > > > > > COM1, IRQ4, 3F8
> > > > > > > > > COM2, IRQ3, 2F8
> > > > > > > > >
> > > > > > > > > I see the the serial definitions in platform.reg are
> enclosed
> > > with
> > > > > > > > > BSP_SERIAL defines. The only place I find BSP_SERIAL2
> defined
> > > is
> > > > in
> > > > > a
> > > > > > > > > section of the Platform Builder project file. Here is
that
> > > > portion
> > > > > of
> > > > > > > the
> > > > > > > > > project file. BSP_SERIAL2 is at the end.
> > > > > > > > >
> > > > > > > > > <FeatureCollection Name="BspFeatures"
> > > > > EnforceUniqueItems="True">
> > > > > > > > > <Feature Name="Item" FeatureVariable="STPC_ATAPI"
> > > > > > > Anchored="True"
> > > > > > > > > SupportedBSP="Stpc_consumer_II"
ModuleName="STPC_ATAPI.DLL">
> > > > > > > > > <CpuCollection Name="SupportedCpus"
> > > > > > > EnforceUniqueItems="False">
> > > > > > > > > <Cpu Name="Item" CpuName="x86" />
> > > > > > > > > </CpuCollection>
> > > > > > > > > </Feature>
> > > > > > > > > <Feature Name="Item" Anchored="True"
> > > > > ModuleName="RTL8139.DLL">
> > > > > > > > > <CpuCollection Name="SupportedCpus"
> > > > > > > EnforceUniqueItems="False">
> > > > > > > > > <Cpu Name="Item" CpuName="ARMV4" />
> > > > > > > > > <Cpu Name="Item" CpuName="ARMV4I" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSII" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSII_FP" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSIV" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSIV_FP" />
> > > > > > > > > <Cpu Name="Item" CpuName="SH4" />
> > > > > > > > > <Cpu Name="Item" CpuName="x86" />
> > > > > > > > > </CpuCollection>
> > > > > > > > > <StringCollectionEX Name="AdditionalVariables">
> > > > > > > > > <String>BSP_NIC_RTL8139</String>
> > > > > > > > > </StringCollectionEX>
> > > > > > > > > </Feature>
> > > > > > > > > <Feature Name="Item" Anchored="True"
> > > > > > ModuleName="COM16550.DLL">
> > > > > > > > > <CpuCollection Name="SupportedCpus"
> > > > > > > EnforceUniqueItems="False">
> > > > > > > > > <Cpu Name="Item" CpuName="ARMV4" />
> > > > > > > > > <Cpu Name="Item" CpuName="ARMV4I" />
> > > > > > > > > <Cpu Name="Item" CpuName="Emulator" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSII" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSII_FP" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSIV" />
> > > > > > > > > <Cpu Name="Item" CpuName="MIPSIV_FP" />
> > > > > > > > > <Cpu Name="Item" CpuName="SH4" />
> > > > > > > > > <Cpu Name="Item" CpuName="x86" />
> > > > > > > > > </CpuCollection>
> > > > > > > > > <StringCollectionEX Name="AdditionalVariables">
> > > > > > > > > <String>BSP_SERIAL2</String>
> > > > > > > > > </StringCollectionEX>
> > > > > > > > > </Feature>
> > > > > > > > > </FeatureCollection>
> > > > > > > > >
> > > > > > > > > These are the settings in my platform.reg file:
> > > > > > > > >
> > > > > > > > > IF BSP_NOSERIAL
> > > > > > > > >
> > > > > "Ranges"="0-0x5F,0x65-0x277,0x284-0x38F,0x392-0x3DF,0x3E2-0xFFFF"
> > > > > > > > > ENDIF ; BSP_NOSERIAL
> > > > > > > > > IF BSP_NOSERIAL !
> > > > > > > > > ;
> > > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
"Ranges"="0-0x5F,0x65-0x277,0x284-0x2F7,0x300-0x38F,0x392-0x3DF,0x3E2-0xFFFF
> > > > > > > > > "
> > > > > > > > >
> > > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
"Ranges"="0-0x5F,0x65-0x277,0x284-0x38F,0x392-0x3DF,0x3E2-0x3F7,0x400-0xFFFF
> > > > > > > > > "
> > > > > > > > > ENDIF ; BSP_NOSERIAL !
> > > > > > > > > IF BSP_SERIAL2
> > > > > > > > > ;
> > > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
"Ranges"="0-0x5F,0x65-0x277,0x284-0x2F7,0x300-0x38F,0x392-0x3DF,0x3E2-0x3E7,
> > > > > > > > > 0x3F0-0xFFFF"
> > > > > > > > >
> > > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
"Ranges"="0-0x5F,0x65-0x277,0x284-0x2F7,0x300-0x38F,0x392-0x3DF,0x3E2-0x3F7,
> > > > > > > > > 0x400-0xFFFF"
> > > > > > > > > ENDIF ; BSP_SERIAL2
> > > > > > > > > IF BSP_SERIAL3
> > > > > > > > > ;
> > > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
"Ranges"="0-0x5F,0x65-0x277,0x284-0x2E7,0x2F0-0x2F7,0x300-0x38F,0x392-0x3DF,
> > > > > > > > > 0x3E2-0x3E7,0x3F0-0xFFFF"
> > > > > > > > >
> > > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>
"Ranges"="0-0x5F,0x65-0x277,0x284-0x2F7,0x300-0x38F,0x392-0x3DF,0x3E2-0x3E7,
> > > > > > > > > 0x3F0-0x3F7,0x400-0xFFFF"
> > > > > > > > > ENDIF ; BSP_SERIAL3
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > ; @CESYSGEN IF CE_MODULES_SERIAL
> > > > > > > > > IF BSP_SERIAL3
> > > > > > > > > [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial3]
> > > > > > > > > ; "SysIntr"=dword:15
> > > > > > > > > "SysIntr"=dword:10
> > > > > > > > > ; "IoBase"=dword:02E8
> > > > > > > > > "IoBase"=dword:03E8
> > > > > > > > > "IoLen"=dword:8
> > > > > > > > > "DeviceArrayIndex"=dword:2
> > > > > > > > > "Prefix"="COM"
> > > > > > > > > "IClass"="{CC5195AC-BA49-48a0-BE17-DF6D1B0173DD}"
> > > > > > > > > "Dll"="Com16550.Dll"
> > > > > > > > > "Order"=dword:0
> > > > > > > > >
> > > > > > > > > [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial3\Unimodem]
> > > > > > > > > "Tsp"="Unimodem.dll"
> > > > > > > > > "DeviceType"=dword:0
> > > > > > > > > "FriendlyName"=LOC_FRIENDLYNAME_SERIAL3
> > > > > > > > > "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
> > > > > > > > > ENDIF BSP_SERIAL3
> > > > > > > > >
> > > > > > > > > IF BSP_SERIAL2
> > > > > > > > > [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial2]
> > > > > > > > > ; "SysIntr"=dword:14
> > > > > > > > > "SysIntr"=dword:3
> > > > > > > > > ; "IoBase"=dword:03E8
> > > > > > > > > "IoBase"=dword:02F8
> > > > > > > > > "IoLen"=dword:8
> > > > > > > > > "DeviceArrayIndex"=dword:1
> > > > > > > > > "Prefix"="COM"
> > > > > > > > > "IClass"="{CC5195AC-BA49-48a0-BE17-DF6D1B0173DD}"
> > > > > > > > > "Dll"="Com16550.Dll"
> > > > > > > > > "Order"=dword:1
> > > > > > > > >
> > > > > > > > > [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial2\Unimodem]
> > > > > > > > > "Tsp"="Unimodem.dll"
> > > > > > > > > "DeviceType"=dword:0
> > > > > > > > > "FriendlyName"=LOC_FRIENDLYNAME_SERIAL2
> > > > > > > > > "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
> > > > > > > > > ENDIF BSP_SERIAL2
> > > > > > > > >
> > > > > > > > > IF BSP_NOSERIAL !
> > > > > > > > > [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial]
> > > > > > > > > ; "SysIntr"=dword:13
> > > > > > > > > "SysIntr"=dword:4
> > > > > > > > > ; "IoBase"=dword:02F8
> > > > > > > > > "IoBase"=dword:03F8
> > > > > > > > > "IoLen"=dword:8
> > > > > > > > > "DeviceArrayIndex"=dword:0
> > > > > > > > > "Prefix"="COM"
> > > > > > > > > "IClass"="{CC5195AC-BA49-48a0-BE17-DF6D1B0173DD}"
> > > > > > > > > "Dll"="Com16550.Dll"
> > > > > > > > > "Order"=dword:0
> > > > > > > > > "Priority"=dword:0
> > > > > > > > > ; Turn on follows for Installable ISR (isr16550 supporting
> > > > SOFTWARE
> > > > > > FIFO
> > > > > > > > > ; "Irq"=dword:3
> > > > > > > > > ; "IsrDll"="isr16550.dll"
> > > > > > > > > ; "IsrHandler"="ISRHandler"
> > > > > > > > >
> > > > > > > > > [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial\Unimodem]
> > > > > > > > > "Tsp"="Unimodem.dll"
> > > > > > > > > "DeviceType"=dword:0
> > > > > > > > > "FriendlyName"=LOC_FRIENDLYNAME_SERIAL
> > > > > > > > > "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
> > > > > > > > > ENDIF BSP_NOSERIAL !
> > > > > > > > > ; @CESYSGEN ENDIF CE_MODULES_SERIAL
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > The app is built in eVC 4.0.
> > > > > > > > >
> > > > > > > > > HANDLE hPort;
> > > > > > > > > bRet = false;
> > > > > > > > > CString ComPort = "COM2:";
> > > > > > > > >
> > > > > > > > > hPort = CreateFile(m_ComPort, GENERIC_READ, 0, NULL,
> > > > > OPEN_EXISTING,0,
> > > > > > > > > NULL);
> > > > > > > > > if(hPort == INVALID_HANDLE_VALUE)
> > > > > > > > > // Log error
> > > > > > > > > else
> > > > > > > > > {
> > > > > > > > > // Do stuff
> > > > > > > > > CloseHandle(hPort);
> > > > > > > > > }
> > > > > > > > >
> > > > > > > > > The CreateFile fails with error code 55.
> > > > > > > > >
> > > > > > > > > TIA
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>
.
- Follow-Ups:
- Re: Can't open the serial ports.
- From: Mike M.
- Re: Can't open the serial ports.
- References:
- Can't open the serial ports.
- From: Mike M.
- Re: Can't open the serial ports.
- From: buzz
- Re: Can't open the serial ports.
- From: Mike M.
- Re: Can't open the serial ports.
- From: Mike M.
- Re: Can't open the serial ports.
- From: andreolkovisky
- Re: Can't open the serial ports.
- From: Mike M.
- Re: Can't open the serial ports.
- From: Bruce Eitman \(eMVP\)
- Re: Can't open the serial ports.
- From: Mike M.
- Re: Can't open the serial ports.
- From: andreolkovisky
- Can't open the serial ports.
- Prev by Date: Re: Can't open the serial ports.
- Next by Date: Re: Can't open the serial ports.
- Previous by thread: Re: Can't open the serial ports.
- Next by thread: Re: Can't open the serial ports.
- Index(es):
Relevant Pages
|