2024-05-23 06:31 AM - edited 2024-05-23 06:32 AM
Hallo all,
I am currently playing around with the NUCLEO-H745Zi-Q board. I was wondering if it is possible to read a GPIO pin on both cores without taking care of synchronization. I realized that there is no such option in CubeMX. In Pin Context Assignment we can choose between ARM Cortex-M7, ARM Cortex-M4 and free.
So I made up a little example: I want to read the state of the boards push button and set the state of two LEDs accordingly, one with each core.
So I first generated code assigning the pin to one core and afterwards I generated code, assigning the pin to another core. Finally I merged the two source codes, added the LED stuff and flashed it. It seems to work like a charm.
So now I am still wondering: Is it ok to do it that way? Are there potential problems? Is there a “right” way to do it?
2024-05-23 06:42 AM
Should be able to read the GPIOx->IDR from either core