Question
Using HSEM of STM32H7 ( sharing data )
Hi,
I am working in project in which I use an STM32H745, So am trying to share data between the two CPUs.
first I create structure in the two CPU like this :
I used the same memory address
struct shared_data
{
uint8_t drdyM4;
float32_t data_to_M7[6][1024];
float32_t data_from_M7[1024];
};
volatile struct shared_data * const data_ptr = (struct shared_data *)0x38001000;This is working fine . I can share data.
Now I want to use HSEM to protect reading and writing process.
I have two question please :
1- How to use the HSEM ? is it what I should use for the interrupt between the two CPUs ?
2- Is my structure is protected from other code writing ( code can write on the same memory address) ?
Thank you
