Forums

Troubles bringing board up

Started by STOEZEL October 19, 2008
Hi,

I have designed my own LPC2129 board. I program it using the Olimex openOCD USB
JTAG and GCC.

I previously worked with an LPC2148 and I was very happy with my development tool
chain. I was able to bring up an LPC2148 board from Olimex very quickly. However I am
having a very hard time developing with this LPC2129-based board.

I can program the LPC2129 and step through the code ok. However I have noticed that the
board tends to suddenly die, for no obvious reasons (at least in my eyes).

An example here (the UART code I use comes form the GNUARM website):

This loop works fine, it would print stuff on the UART port for ever...

unsigned int cnt = 0;
while(1 == 1)
{
uart0Puts("before time loop\r\n");
for(cnt = 0; cnt < 1000; cnt++)
{}
uart0Puts("after time loop\r\n");
}

Surprisingly this one does not (note the time wait counts up to 10000 this time):
unsigned int cnt = 0;
while(1 == 1)
{
uart0Puts("before time loop\r\n");
for(cnt = 0; cnt < 10000; cnt++)
{}
uart0Puts("after time loop\r\n");
}

This loops a few times, then the CPU seems to halt...

I do not enable the watchdog.

Am I missing something?

Could it be that whenever the CPU loops quicker/longer it consumes more power, and
somehow the power supply drops, halting the CPU?
Any suggestion?

An Engineer's Guide to the LPC2100 Series