Hello
I Assume you are trying to run the code stand alone (without debugger) and your global variable are not initialized properly.
Am I right?
You need to adjust your .lcf file to copy initialization values for global variables from ROM to RAM at startup.
For more information on how to achieve that please refer to ColdFire_Build_Tools_Reference.pdf section "Coldfire Linker" -> "LCF Syntax" -> "ROM-RAM Copying".
Also if you create a project using the wizard, you should get a file MCF52259_INTERNAL_FLASH.lcf, which includes the appropriate commands to copy initialization value to RAM at startup.
I hope this helps.
CrasyCat