You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • Unless I'm missing something, this is all documented in the digitalWrite reference?

    digitalWrite([LED1,LED2], 0) // both off
    digitalWrite([LED1,LED2], 1) // LED2
    digitalWrite([LED1,LED2], 2) // LED1
    digitalWrite([LED1,LED2], 3) // LED1 + LED2
    

    Basically if you put an array in then you can write the pins directly with a binary number - it's hugely useful for things like LED displays, where you might want to write values to several pins at once.

About

Avatar for Gordon @Gordon started