Cannot connect to LPC-link

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Cannot connect to LPC-link

266 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by andres.cass on Wed Aug 19 11:14:27 MST 2015
Hi. I am working with element4 (Embest) LPC4357-EVB. I was programming it with a LPC-link from an LPCXPRESSO 1769 board without any problem with a custom made adapter for the 20 pin JTAG connector ni the EVB board.

But I tried to download a simple program that turns on a LCD display. The program downloads to the microcontroller but the LPCxpresso show me an error that I can't remember and now I cant connect again to it.
When I try to debug from LPCxpresso it shows me a window with the message "JTAG Cpmfoguration. Not available devices found." as is no microcontroller connected to the LPC-link.
Also, when I connect the LPC-link to the EVB board it seems as it's being reseted contnuosly by the LPC-link.

I'm on windows 7 with LPCXpresso v7.5.0 [Build 254] [2014-10-31]

Any one knows what can be happening?
Thank you.

Andres


PS: here is the code of my program:

/**
 * Systick 1mS clock required for emWin time functions
 */
volatile uint32_t systick_timems;

/* mSec delay */
static void lcdDelay(uint32_t delay)
{
delay += systick_timems;
while (systick_timems < delay) {}
}

/**
 * @briefSystick handler
 * @returnNothing
 */
void SysTick_Handler(void)
{
systick_timems++;
}

int main(void) {

    // TODO: insert code here
    SystemCoreClockUpdate();
/* Enable and setup SysTick Timer at a periodic rate */
SysTick_Config(SystemCoreClock / 1000);
Chip_GPIO_Init(LPC_GPIO_PORT);

    // Force the counter to be placed into memory
    volatile static int i = 0 ;

    Chip_SCU_PinMuxSet(0x7, 7, (SCU_MODE_FUNC0 | SCU_MODE_PULLDOWN)); //GPIO3_15 func 0
    Chip_SCU_PinMuxSet(0xA, 3, (SCU_MODE_FUNC0 | SCU_MODE_PULLDOWN)); //GPIO4_10 func 0

    Chip_GPIO_SetPinDIROutput(LPC_GPIO_PORT, 3, 15);
    Chip_GPIO_SetPinDIROutput(LPC_GPIO_PORT, 4, 10);

    Chip_SCU_PinMuxSet(0xE, 7, (SCU_MODE_FUNC4 | SCU_MODE_PULLDOWN));
    Chip_GPIO_SetPinDIROutput(LPC_GPIO_PORT, 7, 7);

    Chip_GPIO_SetPinOutHigh(LPC_GPIO_PORT, 3, 15);
    Chip_GPIO_SetPinOutHigh(LPC_GPIO_PORT, 4, 10);

    // Enter an infinite loop, just incrementing a counter

    while(1) {
        i++ ;
        lcdDelay(500);
        Chip_GPIO_SetPinToggle(LPC_GPIO_PORT, 7, 7);

    }
0 Kudos
2 Replies

242 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by andres.cass on Wed Aug 19 12:45:39 MST 2015
For now I found that I can reprogram the MCU while pushing down the reset button.
So for the time it is resolved. I am waiting for LPC-Link 2 to arrive to me, because I've purchased it a little time ago.

Thank you for the response.
Regars.

Andres
0 Kudos

242 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by lpcxpresso-support on Wed Aug 19 11:38:32 MST 2015

Have you tried booting your part into the ISP, erasing flash, then download a known working example? If you can, this might suggest your application has destabilized the part (e.g. invalid PLL setting), or interfered with debug operation.

Regaining debug access to target MCU

Please include the debug log output to the console after your connection fails.

The Debug Log

Is it possible your Launch (Debug) Configuration is corrupt, or wrong? Delete the configuration, and use the Quickstart Panel to start the Debug session (and also creates a new launch configuration).

Thanks and regards,
LPCXpresso Support
0 Kudos