mathertel / DMXSerial

An Arduino library for sending and receiving DMX packets.
BSD 3-Clause "New" or "Revised" License
320 stars 76 forks source link

Why this equation in the channel const? #70

Open damccull opened 1 year ago

damccull commented 1 year ago

What is the purpose of this equation in the channel const I the DmxSerialRecv.ino example line 29?

const int startChannel = 0 * 3 + 1;

Doesn't this just get compiler optimized to 1, then further optimized into individual values and inlined further down where it's used?

What does this do?