Circuit Lake

Electronic Project and Circuit Collection

AvrX, Real Time Kernel for AVR Microcontroller

05/16/2012 Category: AVR

AvrX is a Real Time Multitasking Kernel for AVR microcontrollers written in assembly. Total kernel size varies from ~500 to 700 words depending upon which version is being used. Since the kernel is provided as a library of routines, practical applications take up less space because not all functions are used. AvrX has 40 API in the following six categories: Tasking, Semaphores, Timer Management, Message Queues, Single Step Debugging support, and Byte FIFO support with synchronization.

AvrX 2.6, the latest version, is built for the IAR Systems and GCC C compiler. It is written for a small memory model (16 bit pointers) and a native C interface. The number of tasks, semaphores, messages and timers is limited only by system SRAM.


By using RTOS (Real Time OS), programmer can write linear code which is much easier to design, debug, understand and it is almost always smaller. All state machines for specific task will be maintained by OS.

“Since each task appears to have a complete CPU, it is also easier to develop independent modules that can be wired together later on. With the included debug monitor tasks can be paused, stepped and resumed at run time – useful for debug and calibration. Because the monitor is a separate, high priority, task, it almost always allows a working window into the system no matter how broken the user code is”, said Larry Barello, the AvrX designer. Visit here to learn more about AvrX.