Author Topic: Problems programing flash memory  (Read 9216 times)

Offline eduardovra

  • Newbie
  • *
  • Posts: 11
    • View Profile
Problems programing flash memory
« on: December 27, 2007, 06:29:28 PM »
Hi Mark
I have a M52233DEMO board and I've got some problems programing the flash memory of the microcontroler in the full mode (Bootloader + BareMin in the same file).
The curious is that it works if a burn them separate.
I'm using CW 5.7.0 for programing and I intend to use CFFlash in the future.

Any tips will be appreciated.

Regards

Eduardo

Offline mark

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3236
    • View Profile
    • uTasker
Re: Problems programing flash memory
« Reply #1 on: December 27, 2007, 09:12:44 PM »
Hi Eduardo

Usually you would have received CW 6.3 or CW6.4 with the M52233DEMO board. I haven't seen the CW 5.7.0 version so I wonder whether it could be a problem with this?

Note that the full build doesn't contain the boot loader. The full version works without a boot loader - it is a standalone version containing the standard initialisation plus the application.

It is strange that you can program the bootloader project and the BareMin project but not the full project - generally the full project is the simplest to use. Have you verified that the flash is being correctly deleted (and not only parts of it) since loading to a device which has non-deleted sections which needs to be programmed results in an error.

Are you getting an error message when trying?

Regards

Mark

Offline eduardovra

  • Newbie
  • *
  • Posts: 11
    • View Profile
Re: Problems programing flash memory
« Reply #2 on: January 30, 2008, 07:31:18 PM »
Hi

I'm sorry for the late post but I've made big mistakes here. I was thinking the bootloader was in the same project as baremin (haven't read all the documentation).
I was looking for some way to burn the flash memory of Coldfire using just one binary file, because in the production line the microcontrolers are programed one by one.
Then I've found a GPLed tool that can manipulate Motorola's s19 files, it can the found here:

http://srecord.sourceforge.net/

It has Windows and Linux ports, and can be used to join the bootloader with baremin, this made our work easier.

Regards

Eduardo Vieira

Offline mark

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3236
    • View Profile
    • uTasker
Re: Problems programing flash memory
« Reply #3 on: January 30, 2008, 08:47:11 PM »
Hi Eduardo

Yes, for programming in a production environment it is much more practical and efficient to have the two files combined into one.

The uTasker project for the SAM7X has a conversion tool which combines the same files in binary form. The reason is that it is not possible (at least not that easily) to load the two programs individually using teh SAM-BA tool and so this was immediately added. It makes sense to possibly do the same thing for the M5223X project so I will put this on the "to do" list.

Here is the content of the bat file in the SAM7X project showing that there is both a file merge for programming boot loader + application and then a conversion fr the uploadable version:

uTaskerMerge.exe ..\..\..\..\uTaskerBoot\IAR_SAM7X\Release\Exe\uTaskerBoot.bin uTaskerV1.3.bin uTaskerV1.3_boot.bin
uTaskerConvert.exe uTaskerV1.3.bin z_Upload.bin -0x1234 -a748b6531124


Fortunately you have also found a method to do the same already.

Regards

Mark