Flash Magic Forum

In-System Programming Support => ARM Cortex => Topic started by: sputnik on December 05, 2013, 02:26:48 AM

Title: [LPC1788] programming - failed to send data to the device
Post by: sputnik on December 05, 2013, 02:26:48 AM
I have a problem with the development board Open1788 (http://www.wvshare.com/product/Open1788-Standard.htm). The problem can be seen in the screenshots below.
(http://s5.hostingkartinok.com/uploads/thumbs/2013/12/6763b7d77436930e6d333a814250398b.png) (http://hostingkartinok.com/show-image.php?id=6763b7d77436930e6d333a814250398b)
(http://s6.hostingkartinok.com/uploads/thumbs/2013/12/e3011cd93d31f7ec85c5a6937f0e6911.png) (http://hostingkartinok.com/show-image.php?id=e3011cd93d31f7ec85c5a6937f0e6911)
What this could be the reason?
Title: Re: [LPC1788] programming - failed to send data to the device
Post by: Andy Ayre on December 05, 2013, 03:30:30 AM
Typically those errors occur if the device starts returning junk to the PC. 9600 baud is quite low - if you are using a 12MHz crystal then try 19200 baud. Also check the transmit and receive paths between PC and device for glitches, noise and incorrect RS232 voltage levels.

Andy
Title: Re: [LPC1788] programming - failed to send data to the device
Post by: sputnik on December 07, 2013, 11:18:17 PM
Thank you!
I was able to do it on the 38400 baud rate.
Title: Re: [LPC1788] programming - failed to send data to the device
Post by: vikrant.ere on March 16, 2014, 01:31:59 PM
Iam facing the same problem faced by Sputnik and many other members for the same LPC1788 Waveshare and related board of same controller. As per the LPC1788 errata it is capable of supporting upto 57600bps for ISP not more then this. We can sucessfully read the signature & security (it shows CRP disabled) through flash magic using baud rate of 9600. But unable to program during programming it erase the blocks and while programming initiate it wait for a while and prompt "Programming Failed [Program failed to send data to the device".

With the debug mode the programming can be done successfully but it consume more time and also it require lower baud rate while debugging. The same flash magic utility is capable of programming LPC2148, LPC2468 & LPC1768 used by us.

Please suggest if you have any solution. And also suggest whether it is advisable to use debug in normal practice for flashing the controller if the usual method doesn't work?? 

Thank You
Title: Re: [LPC1788] programming - failed to send data to the device
Post by: Andy Ayre on March 17, 2014, 12:55:43 AM
No it is not normal to use the debug mode. Please generate and send us a debug file. Instructions are here:

http://www.flashmagictool.com/debugfile.html

Please don't post the same question more than once.

Andy
Title: Re: [LPC1788] programming - failed to send data to the device
Post by: vikrant.ere on March 17, 2014, 09:16:46 PM
Thanks Andy for your reply. Please find the attached debug file.
Title: Re: [LPC1788] programming - failed to send data to the device
Post by: Andy Ayre on March 18, 2014, 12:39:29 AM
I don't see any issues with the contents of the debug file. It appears that it programmed 0x00000000 to 0x00002400 without error.

So it is a bit difficult to diagnose the problem if we can't see what is happening. Can you try to use a COM port sniffer (e.g. PortMon) to capture the send/receive data with debug mode in Flash Magic turned off? Please upload so we can compare with the contents of the debug file. Make sure to use the same hex file. Thanks.

Andy