You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Environment: PlatformIO v3.2.0 in VS Code 1.79.2 on Windows 11 (22H2 22621.1848).
Something is going wrong with the board definition or toolchain for the Nucleo U575ZI-Q.
While the blue and green LEDs (LED_BLUE and LED_GREEN, respectively) work fine, the red LED (LED_RED) does not.
The same exact test code pasted into Arduino IDE 2.1.1 (using the latest STM32 board support, 2.5.0 currently) works perfectly.
What I can rule out is an issue in the pin definition macros themselves: in both PlatformIO and in Arduino IDE, the LED_RED resolves to LED_LD3, which in turn resolves to PG2, and ultimately to pin number 105.
Test code
#include<Arduino.h>// put function declarations here:voidblink(void);
enum speeds
{
fast = 100,
medium = 500,
slow = 1000
};
speeds mydelay = slow;
enum LEDs
{
none,
red,
green,
blue
};
LEDs myled = red;
voidsetup()
{
// put your setup code here, to run once:pinMode(LED_RED, OUTPUT);
pinMode(LED_GREEN, OUTPUT);
pinMode(LED_BLUE, OUTPUT);
}
voidloop()
{
// put your main code here, to run repeatedly:blink();
}
// put function definitions here:voidblink(void)
{
delay(mydelay); // delay by current setting// toggle between colorsswitch (myled)
{
case none:
digitalWrite(LED_RED, LOW);
digitalWrite(LED_GREEN, LOW);
digitalWrite(LED_BLUE, LOW);
myled = red;
break;
case red:
digitalWrite(LED_RED, HIGH);
digitalWrite(LED_GREEN, LOW);
digitalWrite(LED_BLUE, LOW);
myled = green;
break;
case green:
digitalWrite(LED_RED, LOW);
digitalWrite(LED_GREEN, HIGH);
digitalWrite(LED_BLUE, LOW);
myled = blue;
break;
case blue:
digitalWrite(LED_RED, LOW);
digitalWrite(LED_GREEN, LOW);
digitalWrite(LED_BLUE, HIGH);
myled = red;
break;
default:
break;
}
}
Additionally, addressing the red LED in STM32CubeIDE also works fine.
I haven't tested any other GPIOs, but can do so if requested.
The text was updated successfully, but these errors were encountered:
Environment: PlatformIO v3.2.0 in VS Code 1.79.2 on Windows 11 (22H2 22621.1848).
Something is going wrong with the board definition or toolchain for the Nucleo U575ZI-Q.
While the blue and green LEDs (LED_BLUE and LED_GREEN, respectively) work fine, the red LED (LED_RED) does not.
The same exact test code pasted into Arduino IDE 2.1.1 (using the latest STM32 board support, 2.5.0 currently) works perfectly.
What I can rule out is an issue in the pin definition macros themselves: in both PlatformIO and in Arduino IDE, the LED_RED resolves to LED_LD3, which in turn resolves to PG2, and ultimately to pin number 105.
Test code
Additionally, addressing the red LED in STM32CubeIDE also works fine.
I haven't tested any other GPIOs, but can do so if requested.
The text was updated successfully, but these errors were encountered: