Em Ter 09 Mai 2006 06:18, volodymyr_tymchyshyn escreveu: > Hello, > > I am using Olimex "LPC-P2106" board with JTAG pins P0.17-P0.21 > (primary group). > I prototype with LCD, so I need almost all pins set as "out" or "io". > I there any trick to set pins P0.22-P0.30 (used for alternative JTAG > and Trace) to output mode, while using the JTAG debugging? > It looks like using them as "input" is not an issue (P0.31 is used for > button on "LPC-P2106") but they do not switch to "output" in Debug > mode. The JTAG shows the values of "direction" and "out" registers > changing properly, but actual levels on pins look to remain "input"... > > I have written the application and it is working fine in "release" > mode (executed from flash), but I'd like to have debug possibility and > also run it from RAM... > > The UG (page 79) says "Function control for the pins P0.17-P0.31 is > effective only when the DBGSEL input is pulled low during Reset". > Actually it looks like the pins are set as GPIO at reset, but the > IODIR setting to output has no effect with DBGSEL=1 during Reset... > > > Thanks for help! > What I know for sure, is that you lose 15 pins with Jtag enabled at reset, ie, by pulling down DBGSEL at reset. With DBGSEL set so, there are no ways to use the remaining IOs that are not used by Jtag. Period. But, you have an alternative. You can enable Jtag by software (or better, by firmware). I dont remeber how, by I found in a site a text explaining how to do it (I didnt care about because I dont wish to do it), but its possible. I think (and I can be wrong here) that doing so you need to upload your firmware by ISP, and I dont know if you can upload a program to the RAM to execute it, by enabling Jtag by software (of course I know that it is possible enabling by hardware). All in all, my develpment process is so: I try to debug my firmware routine by routine, via Jtag. When its time to put all together, and if I need all IOs, the risc of bugs are lesser. But I agree that thats not the best way...
Message
Re: [lpc2000] LPC2106: can I use P0.22-P0.30 as "output" with primary JTAG?
2006-05-09 by Xtian Xultz
Attachments
- No local attachments were found for this message.