Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

PSoC™ 6

Level 4
50 replies posted 25 replies posted 25 sign-ins
Level 4


I have a few questions about two-processor PSoCs.

If I declare a global variable in a header file inside shared-code folder, how will this be compiled?

Will this get compiled as two variables, one for each core? Or will this be compiled as a shared memory location?

If the first, how should I declare shared memory?

And the last question, how will volatile keyword behave in two-processor environment? I used to declare variable as volatile, when it may be accessed from multiple ISRs and/or non-interrupt code. Does this mean that all shared memory should be volatile?


1 Solution
10 likes received First like received

Hello Stanislav,

The draft application note in another thread addresses the shared memory issue. There is an associated code example which I will also publish. Please let me know if these address your needs.


Mark Ainsworth

View solution in original post

3 Replies