Problems when opening the COM1 at boot time

  • We have a PicoCOM4 R1.20 with kernel XIPNKPC4_CORE_CF2_121029.


    We experiencing problems in opening the serial port COM1 at boot time.


    In our application we need both serial ports (COM1 and COM2) to communicate. Our problem is the COM1 will not initialise and error is returned when we boot up the hardware with both netdcu config utility and debug output are disabled .


    To check the hardware we have booted with the debugger and opend the serial ports one by one.
    Serial debug output at boot time is disabled and the netdcu config utility reports on the interface COM1. After sending the command "quit" the utility exits. The application is started and runs with no errors.
    To swichtch off the netdcu config utility we have put the system/ndcucfg/port to "COM3", whitch is not used. After saving the registry we rebooted with no netdcu config utility. The terminal only reports an boot promt "<0>". That the sign that the boot loader can still be called.
    Now we start our application again, but an error is returned when opening COM1.


    Please help urgently, because we are about to release our hardware with the PicoCOM4 for production shortly.

    Mit freundlichen Grüßen
    Jörg Bartel


    Entwicklungsinenieur
    Saxon Junkalor GmbH
    Alte Landebahn 29
    06846 Dessau


    Tel: 0340 5510344

  • Hello,
    customer "egert" have same problem (http://www.forum.fs-net.de/viewtopic.php?f=45&t=3049) but he does not give me details!


    Note, by default COM3: is used for "ndcucfg" and "serial debug otuput". So COM1: and COM2: should be available for your application (refer HW- and Device Driver Docu.).


    1. Do you use a special nboot?
    2. Can yo send me serial boot output (not ndcucfg output)?
    3. Can you enter "device enum" into "nducfg" and post the result?
    4. Did you configure serial pins as DIO, I2C, ...?


    PS
    5. What results call of "GetLastError" after "CreateFile"?

    F&S Elektronik Systeme GmbH
    As this is an international forum, please try to post in English.
    Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.

  • Hello,
    ok, sorry you are right COM1: is used as debug - and ndcucfg port.
    And i can reproduce the error! I will check it.

    F&S Elektronik Systeme GmbH
    As this is an international forum, please try to post in English.
    Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.

  • Hello,
    we have to do further investiagations and try to include resolution into next kernel revision. In the meanwhile you may use following workaround:
    1. disable serial debug output, do NOT disable "ndcucfg"
    2. before access COM1: quit "ndcucfg" by call "ndcucfg -c quit", eg. via "CreateProcess".
    3. now COM1: should be accessable.
    Is this possible?


    PS: step 2 does not work! Because it creates a new instance of ndcucfg and terminates this instance!
    If COM1: does not receivce while booting you may use the timeout paramater to terminate the program:

    Code
    1. Reg open \system\ndcucfg
    2. REM terminate "ndcucfg" if no character arrives during 4s
    3. Reg set value Timeout dword 4
    4. Reg save


    As soon we have time we will invastigate the problem.

    F&S Elektronik Systeme GmbH
    As this is an international forum, please try to post in English.
    Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.

  • We have done some progress in this problem. It looks like that there is another service that is trying to use COM1 -> "Bluetooth modem".


    Please try to set the BT modem to another port. E.g.:

    Code
    1. reg open \Software\microsoft\bluetooth\modemgw
    2. reg set val ModemPortName string COM7:
    3. reg save


    We are curently looking in more detail into this issue to get a proper solution.

    Software developer, F&amp;S Elektronik Systeme GmbH
    As this is an international forum, please try to post in English.
    Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.