Hello All,
Working on PIC 18F252, I actually succeed making the I2C feature working with PIC's hardware implementation.
But I found a bug on the file located here on the sources files (from august 19):
sdcc\device\lib\pic16\libio\i2c\i2copen.c
Problem is on line 33:
TRISCbits.TRISC3 = 1; TRISCbits.TRISC2 = 1; <<<< should be TRISCbits.TRISC4 = 1;
Because on PIC18F252, 452, and more... Hardware pins for I2C are on RC3 and RC4 (not RC2!!)
Are you agree whit that ?
Matthieu
Log in to post a comment.
Hello All,
Working on PIC 18F252, I actually succeed making the I2C feature working with PIC's hardware implementation.
But I found a bug on the file located here on the sources files (from august 19):
sdcc\device\lib\pic16\libio\i2c\i2copen.c
Problem is on line 33:
TRISCbits.TRISC3 = 1;
TRISCbits.TRISC2 = 1; <<<< should be TRISCbits.TRISC4 = 1;
Because on PIC18F252, 452, and more... Hardware pins for I2C are on RC3 and RC4 (not RC2!!)
Are you agree whit that ?
Matthieu