Author Topic: LPC2388 programs only once  (Read 38036 times)

PQPGuy

  • Jr. Member
  • **
  • Posts: 8
    • View Profile
Re: LPC2388 programs only once
« Reply #60 on: October 19, 2017, 02:14:14 AM »
I must have uploaded the wrong file.  This should be the right one (see attached).

Andy Ayre

  • ESAcademy Staff
  • Sr. Member
  • *****
  • Posts: 2190
    • View Profile
    • Embedded Systems Academy, Inc.
    • Email
Re: LPC2388 programs only once
« Reply #61 on: October 19, 2017, 02:25:44 AM »
This one appears to be from Flash Magic version 5.7x to 5.91, still very old. We can't support such old versions.

However I do see in your debug file that Flash Magic sends a line of data and the device fails to echo it back. Looks like the bootloader stopped responding while programming 0x40000000 -> 0x40000200.

Try removing the first 512 bytes from your hex file (you can do this manually in Notepad) or relocate all of your code to above 0x40000200 and re-test. If you can reliably program then it would seem to be a problem with programming/accessing the first 512 bytes of flash. If you can't then it might be a problem with the power supply to the device - would be helpful to know if it fails at random times or always the same block of memory.

Note that to provide further help it would need to be with the latest version of Flash Magic.

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

Andy Ayre

  • ESAcademy Staff
  • Sr. Member
  • *****
  • Posts: 2190
    • View Profile
    • Embedded Systems Academy, Inc.
    • Email
Re: LPC2388 programs only once
« Reply #62 on: October 19, 2017, 02:31:19 AM »
Also you might want to try lowering the baudrate and see if that helps. I've seen some devices struggle at 115200.
Embedded Systems Academy, Inc.
support at esacademy dot com

PQPGuy

  • Jr. Member
  • **
  • Posts: 8
    • View Profile
Re: LPC2388 programs only once
« Reply #63 on: October 19, 2017, 02:39:33 AM »
Andy,

Yes, there IS a power controller (89LPC931) that goes to sleep if it doesn't hear back from the device for 60 seconds.  Which FM setting (in the latest version) should I use to overrule this behavior?  I have the "use DTR and RTS to enter ISP mode" option checked and the "assert DTR and RTS while COM port is open" one unchecked.

Lowering the baudrate proved pointless.  Of course, I've tried this like one million times.

Many thanks.

Andy Ayre

  • ESAcademy Staff
  • Sr. Member
  • *****
  • Posts: 2190
    • View Profile
    • Embedded Systems Academy, Inc.
    • Email
Re: LPC2388 programs only once
« Reply #64 on: October 19, 2017, 02:51:21 AM »
What exactly does the LPC2388 need to do to tell the 89LPC931 to keep it alive? Send data on the UART? Some other signal?
Embedded Systems Academy, Inc.
support at esacademy dot com