Operating Systems for Small Devices PDF

Title Operating Systems for Small Devices
Author Liam Thorpe-Young
Pages 4
File Size 73.3 KB
File Type PDF
Total Downloads 172
Total Views 282

Summary

Operating Systems for Small Devices CM10195 - Systems Architecture 2 - Assignment 1 Liam Thorpe-Young - March 2013 Significant developments are occurring in many areas of computing hardware. All this hardware would not operate coherently if it were not for an Operating System (OS) taking control. Sm...


Description

Operating Systems for Small Devices CM10195 - Systems Architecture 2 - Assignment 1 Liam Thorpe-Young - March 2013

Significant developments are occurring in many areas of computing hardware. All this hardware would not operate coherently if it were not for an Operating System (OS) taking control. Small devices such as Mobile Phones, Routers, Home Appliances, Transport, and even NASA’s Lunar Rover all require an OS to function; but this OS can not merely be a cut down version of a General Purpose Operating System (GPOS), it must be a refined OS that has been carefully designed, although with hardware advancements it is becoming increasing possible that a stripped down OS could be used. This idea is supported in the mobile phone sector by Mery (2003) from Symbian: Scaling down a PC operating system, or bolting communication capabilities onto a small and basic operating system, results in too many fundamental compromises (Mery, 2003, p.1). What is needed to power a mobile phone is not a mini-operating system but a different operating system one that is tailored (Mery, 2003, p.4). Reference: [3]

An OS for these small devices has many resource constraints that enforce how it is designed. These constraints and where possible the OS’s solutions or workarounds are detailed below: ! Power Management Unlike on a GPOS, power management on small devices is essential (although it is still important on a GPOS). Devices such as mobile phones and embedded medical devices should never need to be powered down, this is because they need to sound alarms, accept incoming calls, and operate critical systems, doing so on a limited power source [3]. These along with bespoke hardware devices such as GPS, multiple wireless interfaces and micro-motors are not features we usually expect from a computer running a GPOS; therefore, the OS must handle power responsibly. Power consumption can be reduced by the OS for certain hardware devices such as GPS or wireless receivers during idle or low use periods, and even possibly disabling such features when power levels are low; this means the core tasks of the device are handled [14]. Reduced use of such power hungry components is also efficient, ensuring a minimum number of background tasks are required for operating the device and reducing overall CPU usage can help save energy, the OS requires a well defined power management system as well as task management system to ensure this. ! CPU Power and Architecture The CPU power on a small device is relatively limited and is usually of a different architecture (ARM vs x86/64); this means the most small or embedded devices will be run on RISC architectures instead of CISC; the OS needs to be designed appropriately. To overcome the problem of a reduced power CPU the OS must have a very efficient Task Management mechanism and Inter-Task Communication process, the OS needs to ensure that the most important tasks are run first, this is the same as on a GPOS, but it is more essential in this case as it is much more obvious to the user if this is not done correctly, mobiles are not expected to ‘lock up’ (see Reliability). Task management improves the efficiency of the system by running concurrent tasks and scheduling tasks efficiently. A great example of how this can be achieved on a resource limited Liam Thorpe-Young - March 2013!

1

system is from the Embedded OS Design for the Lunar Exploration Rover (LER) [4]. The task management system here used different states (PEND/SUSPEND, READY, DELAY and EXECUTING) for task transition for processing tasks, additionally the LER OS used preemptive scheduling that was based on priority and a round-robin system that determined the next task. Improving real-time and concurrency was also very important on this OS, so a very sophisticated scheduling algorithm was also used. This clearly demonstrates how an OS for a small or in this case embedded device can be tuned to take advantage of limited resources. ! Small Memory Footprint On of the biggest challenges facing the design of an OS for a small device is using as little space as possible for the OS itself. Many GPOS now require GB’s of storage which is not feasible for small devices. Android and iOS are typically under 2GB, and with the advancement of hardware this leaves plenty of memory for additional data. This is only because the OS’s have been designed to be smaller. Again taking the example of embedded systems, a stock Linux system would be too sophisticated and large (500MB). Przywara, A., et al (2003) [5] describes how embedded systems only require a small portion of the operating system, most of the storage can be used for data by trimming the OS to only a couple of megabytes. Cutting down an OS causes more issues in its own right, Przywara, A., et al (2003) [5] also describes (for Linux) how crosscompiling the C Library, UNIX tools and application without care can result in binaries that are still larger than required; but custom version of embedded Linux can be successfully reduced to 2MB and therefore is an incredibly scaleable OS. ! Restricted Memory Most small devices have to run with a very limited amount of RAM; this causes significant performance issues if the OS does not manage memory carefully. One of the most common techniques is ‘Demand Paging’. With this technique, the memory has ‘slots’; these slots are filled with pages when they are requested, this results in the most required pages being keep close in memory [16]. Android employs its own memory management technique [15]. Processes are organised into certain states: active, visible, started, background and empty. Empty processes are frequently killed, releasing the memory. Active processes are only killed at a last resort. By carefully managing processes Android ensures memory is only being used for critical tasks and where possible memory is made free. ! Physical Device Restrictions Small devices doesn’t necessarily mean a physically small device (for example the Lunar Rover). However the size and design of a small device can seriously effect the cooling mechanism, therefore usage of the CPU must be carefully controlled to prevent overheating. Also effected are available power supply as the battery has a physical constraint on the device, and currently the battery can be the largest physical component inside a small device. The OS cannot determine the size of the device but it must cope with the effects associated with such properties. ! Boot Time Users of small devices do not expect a long boot sequence. In most embedded systems there is not commonly a device to boot or install a system from, the OS therefore requires flexible boot loaders to enable the system to start efficiently. Przywara, A., et al (2003) [5] details that the boot loader is normally stored in a write protected area of memory allowing the writing of boot images and files. This boot loader must have to ability to both load and run a kernel in the case of Liam Thorpe-Young - March 2013!

2

unsupervised operation. Embedded systems typically don’t use disks due to power consumption and speed. ! Reliability Crashes, Bugs and Reboots are issues unfortunately expected on GPOS’s simply because they are common, however users do not expect their mobile phones of medical devices to crash or lock up whilst in operation. The embedded OS for the LER used trap and exception management, watchdog monitoring and multi-machine redundancy techniques to ensure its reliability, most of these required support from the hardware [4]. An OS can also ensure that critical data is held in volatile memory for as little time as possible, and for mobile OS’s if a task management issue occurs the system can recover without intervention from the user. Some small OS’s where safety is critical run concurrent systems, comparing timing and results from one another as well as running diagnostics, this ensures that failure can be predetermined and the system can still run when failure occurs. Another OS optimisation is good compiler design. Lumpur, K., 2008 [17] Outlines how a good complier can make significant performance improvements on embedded devices. When efficient code is compiled for specific architectures many areas of performance see improvement; these include execution speed, memory and system power consumption as well as I/O and memory performance. There are currently a few common OS’s for small devices. In the mobile sector there are two main competitors, Android (Google) and iOS (Apple). Android is a UNIX-like OS, programmed in C, C++ and Java on a modified Linux kernel. Its target devices are ARM based devices but there is a project to port it to x86 [8]. iOS is written in C, C++ and Objective-C and based on a Hybrid XNU kernel, iOS is often perceived as being much more fluid and intuitive than rivalling mobile OS’s. Unlike other OS’s iOS is also strictly licensed to run on non-Apple hardware [9], however arguably the sign of a good OS is one that operates with good task, memory and resource management as well as I/O control and error recovery [18] independent of architecture and hardware. Also in the mobile OS market are Windows Phone 8 and Symbian. For years Symbian was the market leader but now holds only a tiny market share and was discontinued on 24th January 2013 [10]. Microsoft offers Windows Phone 8, based on a Hybrid NT kernel [11] they, like Apple, are trying to blur the gap between the GPOS and the mobile OS. There are also the common Embedded OS’s, Linux actually dominates the market and its most common Embedded OS is Embedded Linux [6]. Also in the market are Windows Embedded [12] and for Real Time Operating System’s (RTOS’s) there is VxWorks [13]. A real time OS such as RTLinux requires even more tailoring and careful design and is usually a Real Time extension built on an Embedded OS. Most embedded applications require deterministic behaviour for this to be achieved the system must react to an external event with a very high timing precision. Memory management, disabled interrupts and scheduling policy need to be carefully considered in the OS design [5]. Small devices clearly show significant improvements in hardware design and manufacturing techniques but they still present great resource restrictions that require an optimised OS. By optimising a small OS with some of the methods described efficient and reliable use of these devices can be achieved. Liam Thorpe-Young - March 2013!

3

[1] Hristozov, A., 2007. Choosing the best system software architecture for your wireless smart sensor design: Part 1 [online]. Available from :http://www.embedded.com/design/prototyping-and-development/ 4007255/Choosing-the-best-system-software-architecture-for-your-wireless-smart-sensor-design-Part-1 [Accessed 17 March 2013] [2] Hristozov, A., 2007. Choosing the best system software architecture for your wireless smart sensor design: Part 2 [online]. Available from :http://www.embedded.com/design/connectivity/4026166/Choosingthe-best-system-software-architecture-for-your-wireless-smart-sensor-design-Part-2 [Accessed 17 March 2013] [3] Mery, D., 2003. Why is a different operating system needed? [online]. Available from: http://gizmonaut.net/ symbian/why_a_different_os.html [Accessed 17 March 2013] [4] (Qiao, L., et al), 2011. An Embedded Operating System Design for the Lunar Exploration Rover [online]. Available from: http://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=6004518 [Accessed 17 March 2013] [5] (Przywara, A., et al), 2003. Real-Time Operating Systems on Small Embedded Devices for Industrial Control and Communication [online]. Available from: http://ieeexplore.ieee.org/xpl/articleDetails.jsp? tp=&arnumber=1280558&contentType=Conference+Publications&searchField%3DSearch_All%26queryText %3Doperating+system+for+small+devices [Accessed 18 March 2013] [6] Tucker, A., 2000. An Overview of Embedded Linux [online]. Available from: http://www.cs.washington.edu/ education/courses/cse585/00wi/project/emlinux.pdf [Accessed 18 March 2013] [7] Wijesinghe, D., Embedded Operating Systems [online]. Available from: http://www.slideshare.net/ dinuka1988/embedded-operating-systems [Accessed 18 March 2013] [8] Wikipedia, Android (operating system) [online]. Available from: http://en.wikipedia.org/wiki/ Android_(operating_system) [Accessed 19 March 2013] [9] Wikipedia, iOS [online]. Available from: http://en.wikipedia.org/wiki/IOS [Accessed 19 March 2013] [10] Wikipedia, Symbian [online]. Available from: http://en.wikipedia.org/wiki/Symbian [Accessed 19 March 2013] [11] Wikipedia, Windows Phone 8 [online]. Available from: http://en.wikipedia.org/wiki/Windows_Phone_8 [Accessed 19 March 2013] [12] Wikipedia, Windows Embedded [online]. Available from: http://en.wikipedia.org/wiki/ Windows_Embedded [Accessed 19 March 2013] [13] Wikipedia, VxWorks [online]. Available from: http://en.wikipedia.org/wiki/Vxworks [Accessed 19 March 2013] [14] Welch, G., 1995. A Survey of Power Management Techniques in Mobile Computing Operating Systems [online]. Available from: http://www.cs.unc.edu/~welch/media/pdf/mobile.pdf [Accessed 19 March 2013] [15] mobworld, 2010. Memory Management in Android [online]. Available from: http:// mobworld.wordpress.com/2010/07/05/memory-management-in-android/ [Accessed 18 March 2013] [16] Sundaram, K., Improving Memory Management on Mobile Phones [online]. Available from: http:// www.brighthub.com/mobile/emerging-platforms/articles/29952.aspx [Accessed 18 March 2013] [17] Lumpur, K., 2008. Improving system performance through operating system optimization on embedded devices platform [online]. Available from: http://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=4580760 [Accessed 19 March 2013] [18] Central China Normal University. Characteristics of Operating System [online]. Available from: http:// elearning.ccnu.edu.cn/ermsweb/libs/cwlib/计算机专业英语/context/Text/EC7_2.htm [Accessed 21 March 2013] Liam Thorpe-Young - March 2013!

4...


Similar Free PDFs