--- In , "gregdeuerling" <egads@f...> wrote: > > I've two Philips LPC designs. One uses a LPC2294 and the other a > LPC2194. I've been working on the LPC2294 design for some time and > have not had any problems at all. My LPC2194 design is a different > story. I'm using the Keil DKARM (V1.4) and ULINK to program the > LPC's via JTAG. My LPC2194's program the 1st time but from then on > out I get an error saying: > > "JTAG Communication Failure", "Error: Flash download failed - Target > DLL has been canceled". > > I've stuck on 3 other LPC2194's and each has failed in the same way. > > I have the proper crystal freq. selected in the target settings > (12Mhz). I have "ULINK ARM Debugger" selected in the "Use target > driver for flash programming" field, and I have "LPC2000 IAP 256KB > Flash" selected for the programming algorithm. > > Like I said, I use the same setting above for a LPC2294 and it works > fine every time. The parts that fail to program a second time run > their initially flashed program just fine, I just can't get at the > JTAG port. > > I've searched the threads here and the LPC2194 errata and see there > are some programming problems with devices with early date codes. > But that problems seems to be a lockup during programming, not what > I'm seeing. I've contacted Keils support vie email, I thought I'd > try here also to see if anyone else has seen this... > > Any ideals, I'm stumped? I'll post a answer to my own problem. Happens every time, I call tech. support or post a question to a message list and I end up answering my own question!!! Anyaways, here is what I found: I think I found a problem in Philip's LPC2194 data sheet. The LPC2294 datasheet says that the JTAG pins (P1.26-P1.31) PINSEL register is set to P1.26/RTCK at reset. The LPC2194 data sheet says that the PINSEL register is set to '0' at reset. Reading that I figured that I had to write a '1' to the JTAG PINSEL register to use JTAG on the LPC2194. When I did that the JTAG port no longer worked. If I take out the JTAG PINSEL init code I can program the LPC2194 via JTAG. SO, I must assume that the LPC2194 works in the same way as the LPC2294 and the data sheet for the LPC2194 is wrong. Anyways, it works now... |