Hi. I am a relatively new user and I am trying to perform a compass calibration. I have the mBot system and purchased separately the compass and gyro. I updated the mBot firmware using mBlock and a USB connection. I have had no trouble viewing compass and gyro output (using both ports 1 and 4 interchangeably). The compass output is mostly garbage though as I think it really needs a calibration. I pushed the calibration button as the instructions indicated and the blue calibration indicator lamp would never flash.
I moved to the Arduino IDE to perform the calibration. I attempted to follow the calibration instructions in the meCompass user manual although it’s really not clear. The steps I followed are below:
- Installed Arduino IDE (v1.6.5 - the later version would get stuck in upload cycle)
- Installed latest makeblock library (v2.1.0916)
- Opened MeCompass.ino example from makeblock examples
- manually copied MeCompass.h and .cpp from “https://github.com/Makeblock-official/Makeblock-Library/tree/151315d63dea472b30d48ac50a0843d432d29f0c/makeblock” into same folder as makeblock header files
- manually copied I2Cdev.h and .cpp from “https://github.com/jrowberg/i2cdevlib/tree/master/Arduino/I2Cdev” into same folder as makeblock header files
- successfully compiled MeCompass.ino (lots of warnings but no errors)
- Used Board Arduino/Genuino Uno
- uploaded to mBot successfully
- pushed compass calibration button and nothing happens. the indicator lamp doesn’t come on and there is no indication that the button does anything.
Does anyone see any problems with the process or recommendations?
EDIT: I think I have a bad compass indicator light. I kept the USB cable hooked up to it and used the serial monitor to watch values and it was correctly entering calibration and correctly exited calibration. Now I am having some trouble connecting again via mBlock but figure there is operator error somewhere…
EDIT2: Was able to reconnect through mBlock by rebooting computer, resetting default program through USB. However, now it will not recognize the compass and gyro through mBlock. It still recognizes the compass at least through arduino (haven’t tested the gyro).