AnsweredAssumed Answered

Computation Results are Rubbish if Variable in CCM

Question asked by krick.julian on Oct 2, 2014
Latest reply on Nov 12, 2014 by waclawek.jan
The strangest thing is happening.
I do some DSP computation on float arrays with the CMSIS library, especially arm_fir_decimate_f32 on an STM32F407VG. I use CooCox.
As my need for RAM grew, I decided to relocate some arrays into the CCM. No big deal, I modified the linker script by adding:

.ccm :
{
  .= ALING(4);
  *(.ccm)
  .= ALIGN(4);
} > CCMRAM


And I placed a variable
float32_t workspace_f32[4096];
in the Core Coupled Memory with
float32_t workspace_f32[4096] __attribute__ ((section (".ccm")));

Everything compiles and links nicely, no problem.

For the FIR decimation I got 3 float array in the RAM, the input signal, the output signal and the state buffer.
I can move the arrays for the state buffer and the input signal to the CCM and everything works as before (except from cycles needed for the computation of course). But when I move output buffer array to the CCM, its contents are complete rubbish and entirely different from what they're supposed to be.

How on earth is this possible?

Regards,
Julian

Outcomes