2

I'm searching an embedded RTOS which supports the functionality to update the software without to compile/link the whole kernel and application SW. The concept would be like in Windows or Unix Desktop Systems: Download an application module (compiled/linked binary) to the target without touching the kernel (decoupled from kernel). One RTOS which supports such Memory Protected Downloadable Application Modules (DAM) is ThreadX from ExpressLogic ( www.rtos.com/products/threadx/ ).

Does anybody know other RTOS (small footprint, target CPU Cortex-M3), which supports such DAM concept?

Does anybody have experience with DAM of ThreadX? Some approved literature?

Thanks in advance!

DannyD
  • 161
  • 1
  • 1
  • 3
  • There are a lot of RTOSes that support what you're looking for. What other features do you care about? – Carl Norum Jan 06 '12 at 19:15
  • Not much more than a preemtive scheduler, tasks with priorities. But low interrupt latency time, small kernel size (2k), small RAM usage. – DannyD Jan 06 '12 at 19:29
  • @Carl Norum: which RTOSes support this concept? – DannyD Jan 06 '12 at 19:42
  • The ability to dynamically load and execute modules in a 2K kernel may be asking a lot! That is probably the minimum size of a kernel with scheduling and IPC and nothing much else. How large is a ThreadX kernel when this feature is included? It is probably smaller than any of my suggestions. – Clifford Jan 07 '12 at 20:52
  • @Carl: The answer to that would be an answer to the question, not a comment. If he knows of any, hopefully he will post an answer in due course ;-) – Clifford Jan 07 '12 at 20:54
  • Express Logic tells that the ThreadX Kernel uses under 2k which is really a small footprint I think. We don't ned any filesystem, graphical stuff etc. Just a kernel with scheduling, so QNX, VxWorks or Windows CE would be oversized. I thought about RTOS like FreeRTOS, embOS but with a runtime module load function. – DannyD Jan 08 '12 at 21:28
  • @DannyD: Marketing reasons would suggest that Express Logic are likely to state the *minimum* kernel size for teh target with the highest code density. I would expect to include scheduling, IPC, timer handling and little else. I would imagine that DAM is additional, and will presumably also need whatever protocol-stack or file system is required to load such modules? Segger embOS and FreeRTOS certainly do not support this, though they would not prevent you from implementing such functionality yourself, though it is not a trivial task.. – Clifford Jan 09 '12 at 09:43
  • @DannyD: Of the three I suggested, VxWorks would be the smallest, but the target shell and loader both require that the application symbol table is included in the load, increasing RAM footprint. Note however that Express Logic's "2K" footprint probably refers to code space only not data. VxWorks scales down to about 10K and is probably comparable to ThreadX on a like-for-like configuration basis. QNX is also very scalable, however, my error; QNx requires an MMU, so will not run on Cortex-M3 – Clifford Jan 09 '12 at 10:09

3 Answers3

1

QNX Neutrino can do that. It is a complete RTOS rather than just a kernel, and has a Unix-like interface and POSIX API. It uses the Korn shell by default, but can use alternative shells or a windowing GUI interface. It is far smaller and more scalable than Linux or Windows Embedded, while being a true RTOS.


WindowsCE is real-time capable (though not as flexible or as fast as a typical RTOS, but deterministic and with a true priority based pre-emptive scheduler).


VxWorks can dynamically load and link object modules to an already loaded and running kernel.

It is not quite the same as on Windows or Linux, it works by partial linkage on the development host, then linkage is completed at run-time on the target. Any unresolved link dependencies in the object file being loaded must exist in the target, either in the kernel or in previously loaded object files.

The resulting run-time still behaves as a monolithic application as if it had been fully linked on a development host, so each module must have unique external symbols and no main() function. The runtime loader/linker does not execute the loaded module, but the VxWorks shell is capable of directly executing any public function by function name, so you simply call the loaded module's entry point from the command line or a script.


Clifford
  • 88,407
  • 13
  • 85
  • 165
  • Note that QNX requires an MMU, so will not run on Cortex-M3. My error, but I'll let it stand for reference. It may serve to inform processor selection for anyone else requiring this functionality. – Clifford Jan 09 '12 at 10:09
0

The footprint is very small. The kernel, module manager, a small demo app with memory protection and module support comes under 15kB.

With threadx you can do this under cortex m3 as it can use the mpu, no mmu necessary. As far as I know other OSes have trouble there.

Andres
  • 1
  • 1
0

Am not an expert on Cortex-M3, but why not use Linux for Cortex? Linux has the concept of "modules" which can be loaded and unloaded at runtime. Not the entire kernel, and not all functionality of course.

You may want to check out Linux Lodable Kernel Modules HOWTO which provides excellent documentation on the subject:

"One advantage is that you don't have to rebuild your kernel as often. This saves you time and spares you the possibility of introducing an error in rebuilding and reinstalling the base kernel. Once you have a working base kernel, it is good to leave it untouched as long as possible."

Etamar Laron
  • 1,172
  • 10
  • 23
  • Linux isn't a real-time operating system. – Carl Norum Jan 06 '12 at 19:32
  • Thanks, but Linux would be oversized for our application, we don't need any stuff like file system, network stacks, etc. We need a small real time kernel, with low context switching time, low interrupt latenc. – DannyD Jan 06 '12 at 19:32
  • @Etamar Laron: The meaning of DAM is not to upgrade the kernel with modules. You add some new functionality with a module on application layer. – DannyD Jan 06 '12 at 19:46
  • Yes, I'm aware of that. But since the question did not specify any requirement other than "to update the software without to compile/link the whole kernel and application SW" - it is a good fit. Linux is indeed not a "hard" real-time OS but for firm/soft real-time is may be adequate, once many of the unnecessary stuff is removed. – Etamar Laron Jan 06 '12 at 21:08
  • @Etamar: Actually he specified *"RTOS, small footprint, Cortex-M3"*, the first two are not satisfied by Linux, and most Cortex-M3 systems lack the memory required to run Linux - hence the small footprint requirement. Besides Cortex-M3 lacks an MMU so the advantages of Linux (if any) are severely diminished. – Clifford Jan 07 '12 at 21:00