Flash Magic Forum

General => General Discussion => Topic started by: Daniel.L on August 23, 2012, 02:35:53 AM

Title: Reset device using the flash magic dll
Post by: Daniel.L on August 23, 2012, 02:35:53 AM
Hi,

I'm using the flash magic dll functions, LPC925 device, and need to reset the device after programming.

Can anyone help me with the fm_reset function arguments? (didn't find any documetation..)

Thanks in advance,
Daniel
Title: Re: Reset device using the flash magic dll
Post by: Daniel.L on August 23, 2012, 05:04:52 AM
i tried the following line code:
presults = fm_reset(FM_RESET,0x00000000,0);

and i keep getting "Device does not support operation. (reset)"

Thanks,
Daniel
Title: Re: Reset device using the flash magic dll
Post by: Andy Ayre on August 24, 2012, 01:25:47 AM
It's not supported because the bootloader in the device does not have a command to reset the device. Please see the user manual from NXP for the LPC900 family.

The only way to reset it is to use DTR and RTS to control VDD and RST by adding supporting hardware such as can be found on the Keil MCB900 board. Flash Magic will then automatically reset the device just before closing the COM port.

fm_reset is fully documented in FMPSCManual.pdf, section 4.18.

Andy
Title: Re: Reset device using the flash magic dll
Post by: Daniel.L on August 25, 2012, 12:50:05 AM
Hi Andy,

Thank you for your reply.

Just to be sure, If i don't have the supporting hardware on the board (Its a medical device so its forbidden), i can't reset the device using sofware?

Is there any way to change the bootloader to reset the device?

Thanks in advance,
Daniel
Title: Re: Reset device using the flash magic dll
Post by: Andy Ayre on August 28, 2012, 12:57:12 AM
You could write your own bootloader cloned from NXP's that resets the device when Flash Magic finishes verifying, for example.

Other than that, no, I don't know of a way.

Andy
Title: Re: Reset device using the flash magic dll
Post by: Daniel.L on September 02, 2012, 07:18:19 AM
ok, i will implement the reset by hardware.

Thank you Andy for your help!