initial magnetometer integration & wire lib fixes