Skip to content

Instantly share code, notes, and snippets.

View CodeWithSouma's full-sized avatar
🎯
Focusing

Soumadip Dey CodeWithSouma

🎯
Focusing
View GitHub Profile
@CodeWithSouma
CodeWithSouma / gist:c61f439cd0a3c8da53068b47105f7983
Last active December 27, 2020 15:22
Please help me to solve this problem
## Thsi code is taken from SensorMPU925X.java (PS-Lab android client)
scienceLab = ScienceLabCommon.scienceLab;
I2C i2c = scienceLab.i2c;// here i am trying to get i2c but it returns null
try {
if (i2c == null) throw new IOException("i2c not found"); // i add this line to check i2c is null or not
sensorMPU925X = new MPU925x(i2c);
} catch (IOException e) {
Log.d("ic2", "onCreate: "+e);
e.printStackTrace();
}