Hi,
I am using the shared memory block between CLA and CPU to transfer some 32-bit variables. From what I can see, this memory is inherently16-bit and wondered what needs to be done to ensure that the CPU performs an atomic 32-bit read since the CLA task that is writing the data is asynchronous to the CPU code reading the data.
I have also noticed that declaring a mixture of 32-bit and 16-bit variables in this shared memory causes read problems for the 16-bit variables. For example, if I create two variables, one 16-bit, the other 32-bit, and assign both variables the same value, then the 16-bit value is corrupt. On inspection in the memory browser, I notice the variable is assigned to address 0x1481 but the actual value is stored at address 0x1480. Is there an issue with odd addresses and if so what is the best way to force any 16-bit variables onto an even address? I should also say that my code is being generated using Simulink Embedded Coder (using the C2000 toolbox) so I want to avoid having to make manual edits to the auto-code.
Any help much appreciated.
Thanks
Richard