DualGPIOled experiment

hello there!

ever got short on GND or +3.3V pins?
of LEDcomponents with only normal leads and no urge to apply jumpwires??

i've been wanting to do the experiment a few time ago
but i recently executed the simple plan

i soldered a current limiting resistor to the short LEDlead (-) and left the long lead (+)
now i connected, two LED's to only GPIO's
the GND (-) (LOW) will be formed by a GPIO and the +3.3volts (HIGH) also a GPIO next to eachother
and so LED's can blink !

perhaps inspirering for you and your projects?
Blink

Turns an LED on for one second, then off for one second, repeatedly.
int outgnd1 = 13; //D7
int outon1 = 12; //D6
int outgnd2 = 14; //D5
int outon2 = 4; //D4
// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(outgnd1, OUTPUT); //was D9 LOW is ON!
pinMode(outgnd2, OUTPUT);
pinMode(outon1, OUTPUT);
pinMode(outon2, OUTPUT);
Serial.begin(9600);
digitalWrite(outgnd1, LOW); // turn the LED on (HIGH is the voltage level)
digitalWrite(outgnd2, LOW);
}

// the loop function runs over and over again forever
void loop() {
Serial.println(LED_BUILTIN);
digitalWrite(outon1, LOW); // turn the LED on (HIGH is the voltage level)
digitalWrite(outon2, LOW);
delay(1000); // wait for a second
digitalWrite(outon1, HIGH); // turn the LED on (HIGH is the voltage level)
digitalWrite(outon2, HIGH);
delay(1000); // wait for a second
}


ofcourse there is both SINK and SOURCE, but i don't think this matters (much)

And if you use a bicolor LED you can change the color by reversing the pins HIGH and LOW states.

Take care to not exceed port current.
Two LEDs @20mA is 80mA port current.
Close to the 100mA max rating of some boards.
Leo..

No, never. I never use Uno form-factor boards, I use Nano and other breadboard-compatible Arduino like Wemos D1 mini, on breadboards. No shortage of ground or Vcc pins on a breadboard.

Your solution is helpful to people who made the common mistake of using an Uno form-factor board to try to build a circuit instead of fitting a shield on top of the Uno which already contains the required circuit. That's what Uno form-factor was designed to do :slight_smile:

PS. Your post is breaking forum rules. Please read the forum guide before your next post. You have been a forum member for over 1 year.

1 Like

which forum rules are broken??? i have no idea, this is my second post

At least you not followed guidelines of presenting a code.

Did you read a "How to use this forum" thread?

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.