In “Tutorial: Accelerating the KL25Z Freedom Board” I used the MMA8451Q accelerometer on the FRDM-KL25Z board in a very primitive way: I’m reading directly some low-level registers from the device through an I2C low-level component. No calibrating, no special device feature setting, only raw values. Since then, things have been evolved: In “Tutorial: Creating a Processor Expert Component for an Accelerometer” I started to create a driver for this accelerometer, and since then a lot more functionality has been added.
Tag Archives: Embedded Component
Tutorial: Creating a Processor Expert Component for an Accelerometer
If you are a frequent reader of this blog, then you know: I’m a big fan of Processor Expert components. While there are many Processor Expert components delivered with CodeWarrior, it lacks many components and device drivers beside of the normal on-chip peripherals. But value gets added to an embedded project with all the external devices, sensors and actuators. That’s why I have created many more components which are available on my GitHub site. Readers of this blog have asked several times to create a tutorial on how to create a Processor Expert component. So why not working on that on a long Easter weekend full of cold rain and snow?
So here we go: a tutorial how to create a Processor Expert component for the MMA8451Q accelerometer found on the FRDM-KL25Z board:
Copy of Processor Expert Components
Many times I have Processor Expert components carefully configured in one project, and then I want to have the same thing in another project. There is actually an easy way to carry out this: to copy components from one project to another.
Version Control with Processor Expert Projects
Using a version control system for software development is a standard procedure today. While things are pretty clear for ‘standard’ Eclipse projects, it is not that easy for Processor Expert projects. I’m using Processor Expert projects with Git and SVN (Subversion). I want to share here tips how to use Processor Expert projects with a version control system. Screenshots and vocabulary are for TortoiseGit and Git, but applicable to any other VCS (Version Control System).
Maze solving FRDM-KL25Z Robot goes backward for Dead-Ends
The maze solving robot based on the Freedom FRDM-KL25Z and Pololu Zumo shield has new features:
- For dead-end paths, instead turning around, the robot is driving backward
- Higher speed for going forward/backward/turns
- In the finish area, the robot turns around
- It reverts the solution path, so the robot can directly run from the finish area to the start
Freedom Logic Analyzer with DMA
The FRDM-KL25Z Open Source Logic Analyzer based on SUMP presented here was already very useful with the added trigger support. But it was not capable to do a sampling rate above a few hundred kHz. That’s ok for slower probing, but not for anything with a higher speed. Using DMA (Direct Memory Access) instead of timer based sampling can remove that limitation :-).
Freedom Robot solves the Maze
Finally I have found some time over the past week-end to enhance my Zumo robot. After I had my line following robot based on the Pololu Zumo chassis and the FRDM-KL25Z, I thought it should be easy and logical to solve a maze. Logical: yes. Easy: not that much. In fact it took me longer than expected. As always, there are a lot of tiny and important problems to solve (the maze alone was easy 🙂 ).
Tutorial: PWM with Processor Expert
For many of my applications I’m using a PWM (Pulse Width Modulated) signal. One example is the motor driver used in this project where I use one PWM signal for each motor. Another usage of PWM is to control the brightness of an LED. Processor Expert makes usage of the PWM hardware easier. Still, for some settings it is good to have the resulting signals in mind. So in this post I’m showing how the settings impact the PWM signal generated.
FreeRTOS on the FRDM-KL05Z Board
There is now an example project available on GitHub which runs FreeRTOS on the FRDM-KL05Z board:
Pololu Line Following Robot with Freedom Board
Because my first line following robot was this week at the Embedded World conference in Nürnberg, I have constructed another one around the Freedom FRDM-KL25Z board. It is based on Pololu part items and the Arduino motor shield, plus using a Bluetooth module I have used in an ealier post.







