Lee College of Engineering Department of Electrical and

  • Slides: 1
Download presentation
Lee College of Engineering Department of Electrical and Computer Engineering Micro. C/OS-II, a Real-Time

Lee College of Engineering Department of Electrical and Computer Engineering Micro. C/OS-II, a Real-Time Kernel on the ATmega 128 L Microcontroller. Arthi Varadarajan and Dr. James M. Conrad Introduction Micro. C/OS-II The purpose of this project was to embed a real time kernel on the microcontroller ATmega 128 L and demonstrate the multitasking capability through an application running on the STK 500/501 board. The Micro. C/OS-II was chosen as the operating system because of its: • simplified design process, • preemptive RTOS time critical events which could be handled quickly and efficiently, • better usage of resources by providing valuable services like mailboxes, queues, semaphores. UC/OS 2 Hardware/Software Architecture Micro. C/OS-II is a highly portable, ROMable, scalable, preemptive real-time, multitasking kernel (RTOS) for microprocessors and microcontrollers. Written in ANSI C for maximum portability, Micro. C/OS-II has been ported to more than 40 different processor architectures ranging from 8 - to 64 -bit CPUs. Certifiable for use in safety-critical systems, this RTOS has been proven to be robust, reliable, and safe enough to use in your own applications. APPLICATION SOFTWARE (Your Code!) UC/OS-2 (Processor-Independent Code) UC/OS 2 Configuration (Application- Specific) UC/OS 2 Port (Processor specific code) Software Hardware CPU Timer AVR Studio® is an Integrated Development Environment for writing and debugging AVR applications in Windows® 98/XP/ME/2000 and Windows NT® environments. AVR Studio provides a project management tool, source file editor and chip simulator. Research Highlights A considerable amount of research was done in porting a real time operating system to the ATmega 128 L. The source code for the Micro. C/OSII was integrated with the port file configurations for the microcontroller. A board support package for the hardware configurations was also created. After the operating system was ported, a simple application was run on the target board which involved blinking one of the two LED’S alternately, thereby demonstrating the multitasking capability. ATMEL ATmega 128 L is the microcontroller used for the board. This low power, high performance AVR® 8 -bit microcontroller has an operating voltage range of 2. 7 V to 5 V. It also has 128 K insystem programmable flash, 4 K internal RAM, and JTAG interface for programming. TEST SET UP The above figure is a hardware layout of the test set up. The STK 501 board with the ATmega 128 L chip sits on top of the STK 500 board. The LEDS are connected to the respective ports through the connectors. The boards are powered through the JTAG mk 11. CONCLUSION Through this project, we understand that porting a real time kernel to any microcontroller can be adapted in a similar fashion. With a thorough understanding of operating system concepts, the principle can be applied across any microcontroller and potentially tap their inherent capability. Contact info: Dr James M. Conrad[jmconrad@uncc. edu], Arthi Varadarajan[avaradar@uncc. edu] University of North Carolina at Charlotte, Electrical and Computer Engineering Department, 9201 University City Blvd, Charlotte, NC 28223