I am using KDS3.0.0 with a custom board with processor Mk64f.
Thank you for your attention, But I find the problem.
It was when I generate the PEx code, the new part of code was created inside the another function, and it was generating the undefine reference.
thanks one more time.