This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

NXP LPC1113 Uart tie-in to uVision

I am trying to learn to use the uVision IDE from Keil on an Open1114 development board and cannot seem to get the UART simulation. I am using a simple UART program that came with the IDE that prints a message and then will echo Ascii characters with the hex value.

I can connect with the development board through the com interface and program it with the "Flash Magic" program.

However, I cannot see any output on any of the "virtual" UARTs of the IDE and cannot seem to input a character. The program is always at the reading of the UART_receive routine, looking for a character as if there is not a character available and the breakpoints that are set are not hit.

How do I select the "virtual" UART under the IDE so I can test the code ?

Parents
  • I was ONLY referring to a UART "simulation". That may have been an incorrect assumption on my part.

    Here is my setup :

    Open1114 evaluation board. A uLink2 USB debug emulator. A LPC ISP UART board that gives me a RS232 connection (COM17) via USB. I can bring up the program "Flash Magic" and select COM17 and it will erase and/or program the evaluation board. I can connect to COM17 with PuTTY but there is no input/output. If I try to enter Debug in the Keil IDE, I get "Device could not be powered up" and "Error:Flash Download failed - Target DLL has been cancelled" popup windows. Without being in PuTTY, I can enter the Deebug mode without any issues, but I cannot get a (and this is what I called a "virtual" or "simulated") UART.

    How can I see the COM17 input/output in Debug mode if I cannot use PuTTY at the same time ? I saw the UART #1, UART #2, UART #3, and Debug printf viewer and tried each of these to see if I could see output from the board with no joy. I had assumed that the Keil IDE grabbed the UART driver since there was an apparent conflict with PuTTY.

    I have used the IAR IDE and I can have a PuTTY terminal open for my COM port while in the Debug mode.

    Do I need to abandon Keil completely and use IAR only ?

    The problem is that I use IAR for a work project and the Keil was for a personal (at home), so I was able to get an inexpensive uLink2 emulator, and I do not have the j-link (lite) for personal use.

    If I cannot get it resolved, I will be forced to buy a new emulator and abandon Keil...

Reply
  • I was ONLY referring to a UART "simulation". That may have been an incorrect assumption on my part.

    Here is my setup :

    Open1114 evaluation board. A uLink2 USB debug emulator. A LPC ISP UART board that gives me a RS232 connection (COM17) via USB. I can bring up the program "Flash Magic" and select COM17 and it will erase and/or program the evaluation board. I can connect to COM17 with PuTTY but there is no input/output. If I try to enter Debug in the Keil IDE, I get "Device could not be powered up" and "Error:Flash Download failed - Target DLL has been cancelled" popup windows. Without being in PuTTY, I can enter the Deebug mode without any issues, but I cannot get a (and this is what I called a "virtual" or "simulated") UART.

    How can I see the COM17 input/output in Debug mode if I cannot use PuTTY at the same time ? I saw the UART #1, UART #2, UART #3, and Debug printf viewer and tried each of these to see if I could see output from the board with no joy. I had assumed that the Keil IDE grabbed the UART driver since there was an apparent conflict with PuTTY.

    I have used the IAR IDE and I can have a PuTTY terminal open for my COM port while in the Debug mode.

    Do I need to abandon Keil completely and use IAR only ?

    The problem is that I use IAR for a work project and the Keil was for a personal (at home), so I was able to get an inexpensive uLink2 emulator, and I do not have the j-link (lite) for personal use.

    If I cannot get it resolved, I will be forced to buy a new emulator and abandon Keil...

Children
  • Ken-

    Not sure if you got any help with this, but I've been down the same road.

    I suspect the problem is both devices are trying to control the reset pin. The reset pin is brought out to both the serial port and the SWD port. The ISP uses reset to enter ISP mode, the Ulink2 uses it to enter SWD mode. The two devices are fighting for control of the same pin.

    Try connecting your USB-ISP-serial device to just the RXD, TXD & GND pins, leaving the others floating/NC. The ISP pod will not be able to reset the LPC1111 or download code, but it should see the UART data.

    Then use the Ulink2 for debugging.

    hope this helps.

    -MarkR