Hello. I've been using your IMU demo as a reference for creating my own IMU project in Mbed using the same FRDM-STBC-AGM01 shield with Freescale's FRDM-K64F. I am having difficulties calibrating the magnetometer to compensate for soft iron effects and after going over the calibrate.nut file I noticed generateMag() function. I've downloaded MagMaster and have tried running the function on the Esquilo Air using the Esquilo IDE, but I am not able to generate any output in the MagMaster GUI. What needs to be done in order for me to be able to see the transformation matrix needed for calibrating the magnetometer? If anyone could give me guidance, I would greatly appreciate it. Thanks!
Using the generateMag() function in IMU Demo (MagMaster)
From the generateMag() comment:
// Download and follow the directions for a magnetometer calibration
// program like MagMaster. Run the generateMag() function to generate
// averaged magnetometer samples that MagMaster can read over a serial
// port from UART0.
In generateMag() the data is being sent out the Esquilo UART0 at 9600 bps. I haven't run MagMaster, but it is implied from the comment that it can import this data over a serial port from MagMaster. If so, to get it you need to hook up a serial port from your computer running MagMaster to your Esquilo's UART0. To do this you'll need a TTL-level serial interface. I'd recommend an FTDI cable like this: https://www.adafruit.com/products/70. If you use this cable, you may need to install the appropriate drivers, depending on your OS. Then tell MagMaster to import the data from whatever port the FTDI cable enumerated as and run generateMag() on your Esquilo.
There are other options besides the FTDI cable, and if you have used one before there's a learning curve. Google is your friend...
Thanks. I'll give it a try.