When I create a new Processor Expert project for a board I already have the components configured, then an easy way to transfer components from one project to another is to copy-paste the components. In the ‘source’ project I select the components I want to use, choose Copy (or CTRL+C shortcut on Windows):
Eclipse is not the fastest and snappiest IDE of the world, but in my view the most versatile and open one. And as with any tool: using it the wrong way does not make it better. Sometimes I have students in my classes which complain that Eclipse is slow, even on a decent machine. Looking at their notebook screens and Eclipse workspace usually tells me right away what they are doing ‘wrong’: there are many, many projects open in the workspace, the most I have seen was more than 50 projects (yikes!!!)!
For the GNU ARM tools it is easy to print out the code and date size information, see
- GNU Additional Tools: Create Flash Image, Print Size and Extended Listing Options
- Code Size Information with gcc for ARM/Kinetis
- text, data and bss: Code and Data Size Explained
But this is all for ARM cores. What if I use other architectures like S08 or ColdFire in Eclipse?
The new flagship of FRDM boards is the FRDM-K64F board. After FTF I have explored different ways debugging the board, and received many comments and questions about it (thanks!). Freescale announced the supports with the new Eclipse based Kinetis Design Studio (KDS). But until KDS is out, how can I use the FRDM-K64F board with CodeWarrior?
One of my embedded projects is to measure the running time in a sports event (see “Sports Timing System in a Lunch Box“). The recorded time is stored in an EEPROM plus sent over USB or wireless connection to the host. It would be great if I could print out the time and ranking directly, so if there is no PC, the system can be small and tiny. So here is my next project and tutorial: Printing with the Freedom board!
Using Processor Expert is an awesome tool: it generates source code for me, and I can can ‘dynamically’ tune my projects to my needs. Still, sometimes it is better or desirable to have a ‘normal’ or ‘static’ project. This is very well possible with Processor Expert (see “Sneaking from Processor Expert” or “Disable my Code Generation“): I can generate the code one time, and then use it without Processor Expert.
To make this even easier, I have added an option to the FreeRTOS Processor Expert component to generate ‘static’ code I can copy-paste to projects and tool chains which are either not supported by Processor Expert, or just for ‘static’ projects.
Naturally, I have several project ideas lingering around. No time to make them all (for now). One of it is interfacing the Raspberry Pi camera with a microcontroller. To store the images, I need plenty of RAM on the device, and so far the Kinetis microcontroller did not have that. Finally, Freescale announced the K64F120 a few months back, and my ordered TWR-K64F120M board arrived on my desk, waiting to be used: Finally I get an ARM Cortex-M4F with 1 MByte of FLASH and 256 KByte of RAM :-).
I have created and published on GitHub a new component ‘CriticalSection’:
This component is a wrapper between my components and the problematic current implementation in Processor Expert (see
ExitCritical(): Why Things are Failing Badly). It uses a flexible approach and uses macros to either use my modified version of
ExitCritical(), or simply defaults to the original implementation.
This is Part 3 of an ongoing tutorial to use the Arduino Ethernet Shield R3 with a Freescale FRDM-KL25Z board (or any other board you like).
In Part 1 I worked on the SD card, in Part 2 I have added basic network connection. Now time to run a web server with my FRDM-KL25Z :-). With this, I can get access to my board through the network, and the board will host a web page where I can do pretty much everything: showing status, or adding functions to turn on things like an LED 🙂
Time to write an update about the RNet Wireless Stack. The stack has been successfully used for the Sumo Robots as wireless controller. In the last week, there has been a lot smaller and larger extensions for it. And because the nRF24L01+ modules are so inexpensive, I bunkered more than 50, with 20 still left to be deployed:
Yes, I have been busy with all the different ARM Cortex Mx cores I’m using in my projects. But beside of the ‘ARM domination of the world’, there are other interesting processors out there. While the ARM cores have added DSP (Digital Signal Processing) capabilities blurring the boundaries between pure MCU and DSP processors, there is still a place (or niche?) for specialized DSP processors. The power of such processors is in the domain of fast signal processing, e.g. for intelligent power switches or for advanced motor control.
CodeWarrior for MCU10.5 comes with a new Eclipse and new Processor Expert. Things are working very well so far. But I have spotted an issue which seems to be related to the new Eclipse Juno used: sometimes the Processor Expert ‘Components’ view is not correctly showing the current project used.
In my earlier post “S-Record Generation with gcc for ARM/Kinetis” I documented how to have the ARM GNU gcc toolchain to produce a S19 (Motorola (or now Freescale) S-Record) file. Here are a few more tips on that subject:
- Changing length of S-Records
- Only using 32bit addresses
- Combining S19 files
If you were wondering why I am pushing the FRDM-KL25Z boards hard to the micro-amps, then have a look at this:
The five boards are the first set of prototypes with a FRDM-KL25Z for a battery operated wireless sensor network based on the nRF24L01+ 2.4GHz transceiver.
Eclipse based IDE’s have typically one limitation: the IDE has not much scripting capabilities. Yes, I can use things like JUnit for testing, but if it comes to build and debug C/C++ applications, then support gets really rare. An exception to this is CodeWarrior for MCU which features a command line version of the IDE which can be used for test automation as I used it in one of my tutorials. What I missed so far is to have a command line interface for Processor Expert to generate code. This is now possible with CodeWarrior for MCU10.5 :-).
For many projects I need to store configuration or sensor data. For this I’m using either an SD card or program the internal flash memory of the microcontroller. Using the internal flash is a good thing as it does not need an external component. However, the typical number of programming cycles is limited to 10k-50k which is a limiting factor if data has to be recorded over a long time or very often. That’s why I’m using the very popular external 24xx external EEPROM devices from Microchip.
I finally completed my project turning the FRDM-KL25Z board into a USB mouse device :-). The form factor and the capabilities of the Freedom board makes it a great board for implementing it as a ‘custom mouse’. All what I need is the USB stack running on it and have it acting as USB HID Mouse device.
For my embedded systems lecture I need a wireless connection to the robot we will develop during that course. So far I have SMAC (IEEE802.15.4) and Bluetooth worked out. But that IEEE802.15.4 (ZigBee) is expensive, and the cheap Bluetooth modules are great for robot-to-host connection, but not for swarm robots which need to communicate to each other. Alex Vecchio (see this post) pointed me to a $2.75 (!) wireless module featuring the Nordic Semiconductor nRF24L01+. Exactly what I needed, with an incredible low price :-).
Summer finally has arrived in Switzerland. Yes, I live in a moderate climate zone, but if the outside temperature goes above 28-30° Celsius as these days, then sleeping at night is not that comfortable as it should be in my view. Luckily, I’m in a good constructed house with good insulation, so it takes a few days until it heats up. But I love to keep the temperature below 25° Celsius, especially at night. I do have a heating system which combines geothermal and solar heating. The question is: how can I use it for cooling during hot summer days? The solution: some extra plumbing, a Freescale Tower system and the Freescale FRDM-KL25Z board 🙂