Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By Nickkarl
#82113 The issue has been solved!
The problem was that the SPI, wich writes to SD-card, shared MISO/MOSI-pins with the I2C-bus, reading from the sensors. The only thing I did was to put an SPI.end() in the beginning of the ISR -routine (wich uses I2C) and an SPI.begin() in the end of the ISR-routine.

The ISR uses the Ticker class, which I think is asynchronous and is therefor less restrictive on the time it takes for the ISR to finish, than synchronous ISRs (see link). My ISR-routine takes about 820 us.


Thanks for the help guys!