Looking for common bugs in Arduino projects

  • a "wrong" I2C address (0x3F vs 0x27 due to the two different versions of the PCF8574)
  • wrong baud settings between sketch and Serial Monitor
  • blocking the code with delay and then trying to read a button with an ISR
  • do to much in an ISR, or even using a delay or Serial.print in an ISR
  • use wrong variable sizes
  • posting just snippets of code instead of a MRE
  • using several nested if conditions instead of a FSM
  • using makros which could be replaced with const/constexpr
2 Likes