I am trying to implement an i2c slave to another device, but Arduino for some reason completely stops sending ACK after receiving some data.
First packet is coming through just fine until some point, and on any consecutive ones Arduino doesn't even acknowledge device address.
I've tried this with several different boards with exactly the same result.
#include <Arduino.h>
#include <Wire.h>
void receiveEvent(int howMany) {
while (Wire.available()) {
Wire.read();
}
Serial.println(howMany);
}
void requestEvent() {
Serial.println("req");
}
void setup() {
Serial.begin(115200);
Wire.begin(56);
Wire.onReceive(receiveEvent);
Wire.onRequest(requestEvent);
}
void loop() {
}