I am using ARM with FLOWCODE V6 for my first ARM study. I found that I can't even get LED blank right with Flowcode V6 or V7.
I am using simple AT91SAM7S64 board like this:

First of all, I fallow this post "viewtopic.php?f=54&t=14469" to modify
CODE (rx) : ORIGIN = 0x00100000, LENGTH = 0x0000E000
And change "general options / clock speed (Hz): 32000 " to meet RESET internal clock 32KHz ( correct me if I am wrong)
To get my program work, and YES, LED blank now but clock is not correct. It seems double times quicker.
I don't understand why due to can't found any clock description in Flowcode ARM.
I found there are some code in my C after Flowcode assembly. :
------------------------------------------------------
#define MX_CLK_SPEED 32000
#define FCP_NULL Unconnected_Port
#define MCK MX_CLK_SPEED
#define MCKKHz (MCK/1000)
#define MCKMHz ((MCKKHz+500)/1000)
-----------------------------------------------------
Why is the KHz is div by 1000 but MHz add 500 then div by 1000?
Sorry I don't understand C, I am new in ARM and can't find ways to correct my LED blank correctly in V6 or V7.
Please Adv. Thank you.