Question Details

No question body available.

Tags

c embedded i2c microchip mcu

Answers (1)

December 11, 2025 Score: 3 Rep: 133 Quality: Medium Completeness: 80%

I finally managed to get I²C working on the ATSAMD11D14A, and it turned out there were two separate issues.

I2CBUS

I2CBUS

1. Even though PA08 and PA09 can be mapped to SERCOM0, they cannot be used for I²C Master

The SAMD11 SERCOM pinmux allows many pins to be connected to SERCOM0, but I²C Master mode only works on SERCOM PAD0 and PAD1.

So I had to switch to a valid PAD0/PAD1 pin pair.

The only available pins left for me were:

#define SMARTAGI2CSDAPINMUX  PINMUXPA04DSERCOM0PAD0
#define SMARTAGI2CSCLPINMUX  PINMUXPA07CSERCOM0PAD1

After switching to PA04 (SDA) and PA07 (SCL), the SERCOM finally generated clock pulses.

2. A required clock was not enabled

The SAMD11 uses the GCLKSERCOMSLOW clock source for SMBus/I²C time-out features.
In my case, I had to explicitly enable

SMARTAGI2CSERCOM->I2CM.CTRLA.bit.LOWTOUTEN = 1;

Edit: Added Images of the I2C Bus actually probing an reciving back the RXNACK