-
-
Notifications
You must be signed in to change notification settings - Fork 214
Description
Low level pin linkage
I am using a Portenta H7 Lite mounted on a PCB to control some experiment apparatuses.
Issue: Whenever I set the pin mode of any of these pins A5, D8, D9 as OUTPUT, the pin A3 (which is also set as output) would be rendered uncontrollable. Either it will be always HIGH or always LOW.
What I mean is the following blinking sketch would be problematic:
#define pin_LED A3
#define pin_problem A5 //A5,D8,D9 any of these pin declared as output would make pin A3 uncontrollable
void setup() {
pinMode(pin_LED, OUTPUT);
pinMode(pin_problem, OUTPUT); //comment or uncomment this line to see the difference
}
void loop() {
digitalWrite(pin_LED, HIGH);
delay(500);
digitalWrite(pin_LED, LOW);
delay(500);
}
Trouble shooting: I initially thought it is the problem of my PCB but it turns out the issue remained when the board is powered by USB and used standalone.
Then I suspect I somehow damaged the board in a previous incorrect connection. However, I ordered a new board and the issue remained. Using Arduino IDE and PlatformIO would both produce the same result.
This is when I started to really suspect there is a low level crosstalk error either software/hardware.
I don't know who to talk to for such low level problem.
If anyone has one of the portenta H7 laying around, please check if your board also suffer from this issue. You only need a LED or multi-meter to probe pin A3.
Board: Portenta H7 Lite (M7 core)
IDE 1: Arduino 1.8.19, Arduino Mbed OS Portenta Boards, by Arduino version 2.8.0
IDE 2: PlatformIO core 6.0.1, framework-arduino-mbed @ 3.0.1, in VS Code
Thank you for your attention.