ISP break detect mode

Started by Helmuth Lechner, March 17, 2006, 04:34:27 AM

Previous topic - Next topic

Helmuth Lechner

Hallo!
Who has an explanation of my regarded problems. I used the MCB900 board from KEIL and programmed the device LCP932 via break detect mode. This happens without any problems. If i start the same procedure without the handshake signals DTR and RTS there is no response from the LPC922. The short circuits for DTR-DSR and RTS-CTS (DSUB7-8/DSUB1-4-6) is made equal is made at MCB900 board. The start sequence

erikm

i do not understand what you actually are saying, but why do you not just use NoTouch and all these problems becomes distant memories.

Erik

erik

Andy Ayre

NoTouch I think is a better approach. Relying on correct configuration of the UART to get back into ISP mode is a bit risky. If you want some example code to do it, see www.codearchitect.org and check the "enable break detect" option.

Embedded Systems Academy, Inc.
support at esacademy dot com

Helmuth Lechner

O.K. Perhaps I expressed wrong that you understand my problem. Now by other words:
The LPC922 is implemented in my application with his own RS232 converter like the MAX563. My application has only the 2 lines RxD and TxD. With my application software the LPC922 will be driven in the BRAKE DETECT Mode of ISP. And now I want program the LPC922 with Flash Magic as I have done with MCB900.
Why it doesn't work? I see no difference, then by using the BREAKE DEDECT Mode, the RxD-Line must be enough! Or not?
Helmuth

Andy Ayre

In order for the break detect method to work, the RxD line must be pulled low for two byte periods, and the application must be correctly configured to enable the ISP entry method.

If you use ISP -> Start Bootloader and check the Send Break Condition option, it will ensure that the RxD line is pulled low for whatever baud rate the device is using. Double-check this with a scope on the RxD pin.

If that looks good then check that your application is running.

If it is, then double-check that you configured the UART correctly. Use the code generated by Code Architect (www.codearchitect.org) as an example.

Embedded Systems Academy, Inc.
support at esacademy dot com

Helmuth Lechner

Thanks for your hints!
I checked the RxD-line but I don't see the low for 2 bytes. I used the Flash Magic in the BRAKE DETECT Mode. You are sure that the Flash Magic generates the Break contition via RxD?
Helmuth

Andy Ayre

I tested it when it was implemented, so I believe it works.

Try using a script to trace back the RxD line to the PC com port and see where the signal is not getting through. Let me know what you find.

Embedded Systems Academy, Inc.
support at esacademy dot com

Helmuth Lechner

Hi Andy!
I checked again on the RxD-line there is only the two

Andy Ayre

I just ran a test to double-check this.

Hardware:

MCB900 v4
P89LPC935 rev A

Software:

Flash Magic 2.49

Placed jumper on reset
Programmed in test program that changed the LEDs and supports break detect ISP entry
Placed jumper on Run = program executes, can see LEDs change
In Flash Magic disabled Use DTR and RTS to enter ISP mode
Went to ISP -> Start Bootloader
Selected Send Break Condition
Clicked on Start Bootloader = LEDs went off
Choose ISP -> Read Device Signature = device signature read, in ISP mode

So it seems to work ok. What happens if you follow these steps exactly?

Embedded Systems Academy, Inc.
support at esacademy dot com

Andy Ayre

To send the break condition, Flash Magic calls SetCommBreak. See:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/devio/base/setcommbreak.asp

This is independant of any hardware that may be attached.

Embedded Systems Academy, Inc.
support at esacademy dot com

Helmuth Lechner

Hi Andrew,
This week starts well! It works perfect along your instruction 03-23-06!!!
Thanks for your cooporation!
Best regards
Helmuth