software section of Micro C/OS-II kernel in ARM powered microcontroller


CHAPTER 7 
SOFTWARE SECTION
7.1. Keil IDE Software
        Keil IDE is a windows operating system (os) software program that runs on a PC to develop applications for ARM microcontroller and digital signal controller [7]. It is also called Integrated Development Environment or IDE because it provides a single integrated “environment” to develop code for embedded microcontroller. The rest of this briefly explains embedded system development and how Keil IDE is used.
         An embedded system is typically a design making use of the power of a small microcontroller, like a Phillips ARM. These microcontrollers combine a microprocessor unit(like the CPU in a desktop PC) with some additional circuits called “peripherals”, plus some additional circuits on the same chip to make a small control module requiring few other external devices. This single device can then be embedded into other electronic and mechanical device for low-cost digital control [7].
Keil software is the leading vendor for 8/16-bit development tools (ranked at first position in the 2004 embedded market study of the embedded system and EE times magazine).Keil software is represented worldwide in more than 40 countries, since the market introduction in 1988; the Keil C51 compiler is the de facto industry standard and supports more than 500 current 8051 device variants [7]. Now, Keil software offers development tools for ARM.
            Keil software makes C compilers, macro assemblers, real-time kernels, debuggers, simulators, integrated environments, and evaluation boards for 8051, 251, ARM and XC16x/C16x/ST10 microcontroller families.
An Example of using Keil uVision3 for creating Keil ARM’s Project:
1. Open Keil uVision Program which is Text Editor of Keil-ARM uses for writing C Language Source Code Program as inthe picture.
2.         Set default value to translate uVision3 Code to use withKeil uVision3 Program and Keil ARM.

 
There are 3 default values of them –Use Keil ARM ToolsUseGNU Tools, andUse ARM Tools- in this case, select “Use Keil ARM Tools then assign position of folder to savedefault value of Keil ARM Program. Generally, it is“C:\Keil\ARM\”, but if you install Keil in other position,you need to change correctly as in the picture.
3. Create new Project File. Click Project New Project then set the position of folder that you want to save with its title. For example, if you want to create Project File named LED_BLINK and save in folder named LED, you can set them by yourself [7]. After you fill its name in File name blank, click save project File as in the picture.
 
Program proceeding waits for users to set No. of MCU after you saved Project File. No.of Philips’MCU in ET-ARM STAMP LPC2119 Board is LPC2119 then click OK as in the picture Next, users need to confirm to copy File Startup of Keil to use with Philips’MCU or not because Startup File is the beginning value of MCU such as Stack values and default value to use with Phase-Lock-Loop. You should set values of them before starting to run your written program; otherwise MCU is added orders to run by the written program. Startup File of Keil-ARM is Assembly Language and is set to work with Keil Development. So, there are some different specifications to use. You can’t use Startup File with ET-ARM STAMP LPC2119 Board immediately; you need to change some default value. Using Keil ARM Program to translate orders, users need to correct Startup File to set value as well as ET-ARM STAMP LPC2119 Board form. In this case, select “No” to protect Keil uVision3 copy Startup File of Keil-ARM to use in this Project.
4. Copy File named ”Startup.s” that is in ETT’s CD-ROM in folder named “SOURCE_KEIL” into the same position of New Project File File named “Startup.S” which is contained orders of ARM7 in Assembly Language uses to set the necessary default value of MCU such as setting Stack value, Initial Phase-Lock-Loop, MAM Function, and MCU”s Vector. If you add “Startup.s File” from Keil or copy file from other source to use with “ET-ARM STAMP LPC2119 Board”, its program in Startup is different, and it will effect on written program [7]. 
5. Select Option of Project File. Click Project Option for target ‘target 1’ then select Tab of Target for setting MCU Target value. The proceeding is; X-TAL is 19.6608 MHz and set the MCU Memory is condition to translate Keil ARM Program as in the picture. 
6. Start to write Source Code with C Language by click File New… The Text File is displayed. In the first time, you should set its name as “Text1” as in the picture.
 
After finished to write program in C Language, you click save this file with its surname as”.C”. For example, File Save As… and then set its file name as “.main.c” as in the picture.
After saved file, colour of letters in this program is changed with its function such as Comment, Variable, and Order. It is the good point of Keil uVision3 program and users use it easily as in the picture.
7. Add File with Project File by click Project Components, Environment, Books[7]… then select Tab Project Components and then select Add File In the first time, you should select Files of type as “C Source files(*.c) because it shows other files name in Source Code. Click icon file named “main.c” then select Add file named “Startup.s” to Project File Set new File of type as “ASM Source files (*.s*;*.src;*.a*)”. Its file named Startup.s is shown in file name blank, click icon file “Startup.s”, and then select Add.
Fig 7.1: Output Screenshot of KEIL
8. Translate program by click Projects Rebuild all target files. Keil uVision3 Program can order Keil ARM Program to translate program immediately After translated program correctly without any mistake (0 Error and 0 Warning), you will get the HEX File name as same as the Project File name. Users can download HEX File to MCU immediately [7].
7.2. Flash Magic
Flash magic can control the entry into ISP mode of some microcontroller devices by using the COM port handshaking signals to control the device. Typically the handshaking signals are used to control such pins as Reset, PSEN and VCC. The exact pins used depend on the specific device. When this feature is supported, Flash Magic will automatically place the device into ISP mode at the beginning of an ISP operation.

 
Fig 7.2: Screenshot of Flash Magic

Flash Magic will then automatically cause the device to execute code at the end of the ISP operation.
CHAPTER-8
CONCLUSION AND FEATURE WORKS
 8.1 Conclusion
The system is thus designed and tested and found, thus the system is working properly. Proper set of instruction suitable for a specific application always lead to a better system
The science is a vast field and invention of new system is a part of it so still better systems. Can be invented and implemented with a bit of intelligence
8.2 Feature Works
 The most of the current kernels (RTOS) are successfully used in today’s real-time embedded systems, but they increase the cost and reduce flexibility.
Next generation real-time operating systems would demand new operating systems and task designs to support predictability, and high degree of adaptability. So our project can be further improve vise by utilization of upcoming new RTOS according to your application.

0 comments:

Post a Comment