Fixing ‘TWBR’ was not declared in this scope

The old implementation in the library:

// switch to 400KHz I2C
    TWBR = ((F_CPU / 400000L) - 16) / 2; // see twi_init in Wire/utility/twi.c

Change it to:


This should fix the error.

One response to “Fixing ‘TWBR’ was not declared in this scope”

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.