X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/rsbs2/blobdiff_plain/87f4338b452dea4fdebba3eac573bec999642eb9..9be02f67a49da607764c543b572c1a1988182e5c:/bmc/i2c.c?ds=inline diff --git a/bmc/i2c.c b/bmc/i2c.c index f0816f0..07d2e79 100644 --- a/bmc/i2c.c +++ b/bmc/i2c.c @@ -3,6 +3,7 @@ #include #include "i2c.h" #include "bmc.h" +#include "config.h" #include "ipmb.h" #define TWCR_ACK TWCR = (1< + * TWBR = (F_CPU/(2 * SCL)) - 8 + */ + TWBR = (F_CPU/(2*I2C_FREQ))-8; TWAR = BMC_ADDR & 0xfe; TWDR = 0x00; TWCR &= ~((1<