2025-08-07 7:57 AM - last edited on 2025-08-07 8:13 AM by Andrew Neil
Hi everyone,
I am working on a project with the STM32H755ZI-Q (Nucleo H755ZI-Q) board, and I am following this tutorial for Inter-Processor Communication (IPC) using OpenAMP: Link to tutorial.
The setup involves two processors (M4 and M7). Here's the LED behavior that I have implemented:
LED1 (PB0) is assigned to M4.
LED2 (PE1) and LED3 (PB14) are assigned to M7.
When M7 sends a message to M4, M4 replies, and LED1 turns ON.
If M7 receives the expected message, LED2 turns ON; otherwise, LED3 should turn ON.
Everything seems to work fine when LED2 is assigned to M7 (PB14), as it turns ON as expected. However, when I swap the assignments and move LED2 to LED3 (PB14), LED3 doesn’t turn on, despite the message being received and processed correctly.
I have tried putting LED3 in a while loop in the main function and toggling it manually with:
HAL_GPIO_TogglePin(GPIOB, GPIO_PIN_14);
but still, LED3 (PB14) does not turn ON.
Has anyone encountered a similar issue or can suggest where the problem might lie?
Any help would be greatly appreciated!
Thanks in advance!
Solved! Go to Solution.
2025-08-11 9:47 AM
Hello,
I'm not sure what is actually the problem,
but based on your zip file, here attached are "main.c" files where I got the RED LED turn on instead of the ORANGE LED when receiving the right message.
2025-08-07 8:38 AM
Ensure it is assigned a core context and is being initialized as a GPIO output.
If in doubt, look at the GPIOB register and ensure MODER bits are as expected.
2025-08-07 8:57 AM
Hi @TDK,
Thanks for the reminder! Those are things I always keep in mind when working with GPIO initialization and configuration.
2025-08-07 9:01 AM
Hello,
Share code, ioc file, if you can.
Use a voltmeter to check PB14 output on CN8. Q3 transistor or LD3 LED might be non working.
2025-08-07 9:23 AM
Hi @Mike_ST ,
I’ve tested my LEDs with the Blinky code, and everything is working fine. Here’s the code I’m using:
2025-08-07 9:48 AM
while (1)
{
/* USER CODE END WHILE */
/* USER CODE BEGIN 3 */
HAL_GPIO_WritePin(GPIOB, GPIO_PIN_14, GPIO_PIN_SET);
}
It's probably working as intended but gets changed in the main loop before you can visually notice.
2025-08-07 3:56 PM - edited 2025-08-07 4:06 PM
Hi @TDK ,
I initially thought that might be the issue, but after switching to HAL_GPIO_WritePin(), it still didn’t work. I want LED3 to work in the callback function when a message is received by M7 — LED2 works fine there, but LED3 doesn’t. I even tried putting LED3 in a while loop to check if it would work, but it still didn’t in either case.
2025-08-07 5:07 PM
Remove the code in the main loop where you continuously set the pin state high. That's the issue.
2025-08-07 6:17 PM - edited 2025-08-07 6:23 PM
Hi @TDK ,
It seems there was a misunderstanding. The issue I'm currently facing is with LED3. Initially, I had it placed only in the callback, not in the main loop. However, LED3 wouldn't turn on, even when I set the pin state to high. So, I moved it into the main loop to test it further. But even then, when I set the pin state to high, the LED still wouldn't turn on.
To isolate the problem, I created a new project just to blink the LEDs, and in that setup, the LEDs work as expected.
I believe running that code on the Nucleo H755ZI-Q board will provide you with clearer results.
2025-08-11 8:20 AM
Hi @Mike_ST ,
Do you have any recommendations for addressing this issue?