I am making my own "7 segment LED driver". I know there is a lot of examples on the internet, I just want to try my own. But I have a piece of code that does not work and I don't know why. Can somebody explain to me why it is not working?
When I put in this, it works:
digitalWrite(pins[0], one[0]);
digitalWrite(pins[1], one[1]);
digitalWrite(pins[2], one[2]);
digitalWrite(pins[3], one[3]);
digitalWrite(pins[4], one[4]);
digitalWrite(pins[5], one[5]);
digitalWrite(pins[6], one[6]);
So of course I tried using for():
for (byte i = 0; i >= 6; i++)
{
digitalWrite(pins[i], one[i]);
}
And this does not work. But why? I think it should. Btw. pins is const byte array and one is const bool array.
Thanks in advance for any suggestions!