In my December post, New sensor expansion boards for Freedom development platform,
I introduced you to the FRDM-FXS sensor shields for the platform. From the
“Downloads” tab on the FRDM-FXS-MULTI-B webpage, you can now download demo executables for the FRDM-KL25Z and FRDM-K20D50M
boards that are compatible with Xtrinsic Sensor Fusion Toolbox for Android.
The links for the two executable are labeled FRDM-K20D50M_MQXL (compiled for
ARM® Cortex-M4) and FRDM-KL25Z-MQXL (compiled for Arm Cortex-M0+). You will
need to log in our community and accept a click-through license/disclaimer to
gain access to the files.
One of the things I like most about the Freedom development platform is its
ease of use. It can be programmed with a bootloader that allows you to plug
the board into your PC via USB, and install software (such as these files)
with a simple drag and drop. If you haven’t done this before, let me
recommend a couple of resources for you:
Now here is the really cool part, the embedded fusion library at the heart of
this functionality is now available in via the “Xtrinsic Sensor Fusion
Library for Kinetis MCUs – Evaluation Version and documentation”
link, available from the same
Downloads tab
listed above. The download package includes a datasheet describing Xtrinsic
Sensor Fusion capabilities, a user’s guide that will show you how to
get up and running, and a zip file containing a CodeWarrior
project. The evaluation version runs only on the KL25Z board. Everything in
the project, with the exception of one .c file, is precompiled. Filename
user_tasks.c is reserved for your use, and allows you to insert code at 5
specific entry points in the project. You have visibility to all fusion
outputs, and can modify the Bluetooth output stream to suite your own needs.
This is the same project used to create the executables mentioned earlier. The
evaluation version is fully compatible with the Xtrinsic Sensor Fusion
Toolbox.
The evaluation version of the kit is intended to give developers everything
they need to evaluate the quality and scope of sensor fusion libraries. Once a
decision is made to incorporate the library into a product, you will want to
upgrade to the “product development” version of the library.
This version, which will soon be available from the same download page,
provides many more bells and whistles with regard to fusion options and
underlying project structure. Differences in the three versions of the library
are summarized below:
Feature
|
Demo Version
|
Evaluation Version
|
Development Version
|
License |
Free click-through
|
Free click-through
|
Contact us for Pricing
|
CPU selection
|
MKL25Z128VLK4
MK20DX128VLH5
|
MKL25Z128VLK4
|
MKL25Z128VLK4
MK20DX128VLH5
others upon request
|
Board customizable
|
No — FRDM_KL25Z and FRDM_K20D50M only
|
No – FRDM_KL25Z only
|
Yes |
Sensor sample rate
|
Fixed |
Fixed |
Programmable |
Fusion rate |
Fixed |
Fixed |
Programmable |
Frame of Reference
|
Android |
Android |
Programmable |
Algorithms Executing
|
accel only, accel + gyro, accel + mag, accel + mag + gyro
|
Programmable |
Sleep mode enabled between samples/calculations
|
No |
No |
Programmable |
RTOS |
MQX-Lite |
MQX-Lite |
MQX-Lite |
Code flexibility
|
NONE — Executable only
|
customer code limited to 5 specific entry points
|
only Kalman and MagCal libraries are precompiled. Everything else is
supplied in source form, and can be modified.
|
Access to Processor Expert™ configuration
|
No |
No |
Yes |
Collateral Materials
|
|
datasheet
zip file containing the appropriate CodeWarrior project
user manual
|
The next table shows sensor fusion features versus sensor complement used for
the application. See the sensor fusion datasheet for additional
restrictions/details.
Feature
|
Accel only
|
Accel + gyro
|
Accel + mag
|
Accel + mag + gyro
|
Filter Type
|
Butterworth |
Indirect Kalman |
Butterworth |
Indirect Kalman |
Roll / Pitch / Tilt in degrees
|
Yes |
Yes |
Yes |
Yes |
Yaw in degrees |
No |
No |
Yes |
Yes |
Angular Rate in degrees/second
|
virtual 2 axis |
Yes |
virtual 3 axis |
Yes |
Compass heading (magnetic north) in degrees
|
No |
Yes |
Yes |
Yes |
quaternion and rotation vector
|
Yes |
Yes |
Yes |
Yes |
rotation matrix |
Yes |
Yes |
Yes |
Yes |
linear acceleration separate from gravity
|
No |
Yes |
No |
Yes |
NED (North-East-Down Frame of Reference
|
Yes |
Yes |
Yes |
Yes |
ENU (Windows 8 variant) Frame of Reference
|
Yes |
Yes |
Yes |
Yes |
ENU (Android variant) Frame of Reference
|
Yes |
Yes |
Yes |
Yes |
Magnetic calibration included
|
No |
No |
Yes |
Yes |
Gyro offset calibration included
|
N/A |
Yes |
N/A |
Yes |
FRDM-KL25Z_MQXL board support
|
Yes |
Yes |
Yes |
Yes |
FRDM-K20D50M_MQXL board support
|
Yes |
Yes |
Yes |
Yes |