Open vongomben opened 1 year ago
@vongomben the issue is about the "funny" I2C sharing on Nano pinout ( SDA/SCL are shorted with A4/A5). When analogRead(A4)
is called, the I2C stops being functional and this locks the sketch when IMU.accelerationAvailable()
is then called.
If the I2C accelerometer was externally connected, it would be feasible to fix this by using another SERCOM for I2C (https://learn.adafruit.com/using-atsamd21-sercom-to-add-more-spi-i2c-serial-ports/creating-a-new-wire) . Unfortunately, since the connection is internal, there's no chance to use the onboard LSM6DS3 and A4/A5 at the same time :disappointed:
Thanks @facchinm
This is a really precious information
I could bypass this by using a demux https://www.youtube.com/watch?v=Dco6jo9xgAo
Hi! Apparently I'm facing an issue which is more interesting and hard than my capabilities. When using
Arduino_JSON
vers 0.2.0 andArduino_LSM6DS3
1.0.2 I find an interesting issue in dealing with the IMU and the reading of 8 different analog readings.The code that "silences" the Serial port is this one.
NOTE: if I comment the JSON incapsulation of the analog readings everything keeps on stopping (hence that is not the problem). Apparently the problem is the 8 analog readings.
Fun Fact: if I add one reading and one JSON incapluation at a time, everything "breaks" when I reach two readings printed (alongside the JSON
Any help from @facchinm