Something what I say quite often is: “Google is your friend”. It means that the answer to many questions can be found with an internet search engine. And I have to admit that I have to ‘google’ my own articles to find solutions for problems I feel I have seen in the past too :-).
But for the one problem below I did not find anything: not on my own blog, and not anywhere else in the internet:
Eclipse includes a background parser called ‘Indexer’ which is used to assist the developer with various kind of information, for example jumping to a variable declaration or definition. Basically it is a parser running in the background collecting information about the sources and building up that ‘index’ data base.
The company Feller sells a wall mountable ‘Smart Light Control’: this provides 4 push buttons compatible with the Philips Hue system (on, off, dimming, etc). Unlike many other remote controls and buttons it is a great design and available in different colors. Feller does have a ‘classic’ wall switch series too, so this one is perfect to replace or augment an existing installation and make it ‘smart’.
The Eclipse CODAN (Code Analysis) plugin is part of CDT and is a powerful static analysis tool finding all kind of possible bugs and issues. Still to my surprise not many C/C++ developers take advantage of it maybe because they are not aware that it exists?
ups! Programming error detected by CODAN
In this article I show a few tips how to effectively use it, especially with the NXP MCUXpresso SDK.
The NXP MCU-Link is a powerful $10 debug probe for ARM Cortex-M devices and works with the NXP LinkServer for debugging. The LinkServer does not an implement a gdb server, so it limits its usage e.g. for scripting or command line debugging. But as MCU-Link is also a CMSIS-DAP compatible debug probe, I can use it with OpenOCD which is open source and implements a GDB server. This article shows how I can use it with the MCU-Link.
The MCU-Link is a $10 CMSIS-DAP capable debug probe which works out-of-the box with the MCUXpresso Eclipse based IDE. This is great for development, but how can I programming with the push of a button or a script? The answer is no: there is an easy way to use the debug probe outside Eclipse from a shell script, and you can use that MCU-Link probe to do the job. This is especially useful as with the example below where I have to program 60 boards this week-end :-).
The NXP Kinetis devices implement a UID (Unique ID) for each device, using the ‘Unique Identification Register) which is part of the SIM (System Integration Module):
SIM Unique ID (NXP K22P144M120SF5RM.pdf Reference Manual)
While this number should be unique, I was wondering last week why students in the labs reported the same UID for multiple robots in the lab. So maybe this number is not so unique as it should be? Continue reading →
Reentrancy is an attribute of a piece of code and basically means it can re-entered by another execution flow, for example by an interrupt or by another task or thread. This is an important concept and still a lot of code ‘in the wild’ does violate reentrancy. As a result the application crashes immediately in the best case. Worse it crashes randomly or even worse it behaves incorrectly 😦 .
Reentrancy is always a concern if using standard library functions, including printf() or malloc(). FreeRTOS offers a reentrant wrapper to the standard malloc() and free() (Memory Scheme 3)