Sie sind auf Seite 1von 36

SUBMITTED BY:

CHAITANYA KHER
Roll No.:7110955
(8TH Sem.) Final yr.
CHAITANYA KHER 2
CHAITANYA KHER 3
• LAYOUT DESIGN

• PRINTING

• ETCHING

• FINISHING

• DRILLING

• COMPONENT MOUNTING

CHAITANYA KHER 4
CHAITANYA KHER 5
CHAITANYA KHER 6
WHAT IS LINUX?

•LINUX IS AN OPERATING SYSTEM JUST


LIKE WINDOWS AND MAC OS X.

•LINUX DERIVES MANY THINGS FROM UNIX


OPERATING SYSTEM.

•LINUX IS OPEN SOURCE AND FREE.

CHAITANYA KHER 7
WHY CHOOSE LINUX

• Linux is Open Source.

• Additions to functionality are made easier.

• Large support network for developers.

• Ability the fix code without help from outside


organizations.

CHAITANYA KHER 8
Disadvantages of Linux

• Real Time Performance is provided through


Kernel Modules
• A code error can crash the entire OS

CHAITANYA KHER 9
The Linux Architecture

Same as ‘normal’ Linux


Architecture

Contains six layers of


abstraction

CHAITANYA KHER 10
Kernel & Shell

• Linux is operating system (OS).


• Linux system is described as kernel &
shell.
• Kernel is a main program of Linux
System .It controls hard wares, CPU,
memory, hard disk, network card etc.
• Shell is an interface between user and
kernel. Shell interprets your input as
commands and pass them to kernel.
CHAITANYA KHER 11
Basic Commands
• ls show files in current position
• cd change directory
• cp copy file or directory
• mv move file or directory
• rm remove file or directory
• pwd show current position
• mkdir create directory
• rmdir remove directory
• cat display file contents
• less display file contents page wise
• man display online manual
CHAITANYA KHER 12
USAGE SHARE

CHAITANYA KHER 13
PROGRAMMING IN LINUX

•VARIOUS PROGRAMMING LANGUAGES LIKE C,


C++, JAVA, FORTRAN, ETC CAN BE USED TO
MAKE AAPLICATIONS FOR LINUX.

CHAITANYA KHER 14
APPLICATIONS
• MANY LINUX DISTRIBUTIO HAVE THEIR
OWN APP. STORE FROM WHERE USERS
CAN DOWNLOAD APPLICATIONS.
•APPLICATIONS CAN BE INSTALLED FROM
INTERNET TOO.
•EXECUTABLE FILE OF EVERY LINUX
DISTRIBUTION IS DIFFERENT.(e.g. Ubuntu’s
executable file is .deb)
•MANY APPLICATIONS HAVE TO BE
INSTALLED USING TERMINAL.
CHAITANYA KHER 15
CHAITANYA KHER 16
Embedded Linux
• Any small system running Linux
• “Headless” (no display – wireless router, set-top
box, e.g.)
• User-interactive (cellphone, etc.)
• More than just kernel!
• Applications provide system-specific functionality
• Shared libraries support applications
• Kernel manages running applications, hardware
drivers
• Think of as stripped-down desktop system
• Unneeded features removed
• Embedded-specific features added
CHAITANYA KHER 17
Linux Software System Components

CHAITANYA KHER 18
Kernel

• Current Linux kernel: 2.6 series


• Fully supports ARM processors (including
• ARM926)
• Complete networking, filesystem, other support
• Configurable
• Build in only those features needed
• Multiple possible execution modes
• Execute-in-place (XIP)
• Compressed/loadable

CHAITANYA KHER 19
Drivers

• Manage hardware resources (peripherals)


• Exist for many standard peripherals
• Built-in to kernel or loadable at run-time
• Well-documented process for creating
custom

CHAITANYA KHER 20
Root File System
• Directory tree containing needed libraries,
scripts, applications
• Organization usually follows standard Unix
filesystem
• conventions (/bin, /sbin, /etc, etc.)
• Stored as standard Linux filesystem type
• Typically cramfs or jffs2 compressed filesystem
when in Flash
• Ext2/3 for disk

CHAITANYA KHER 21
Libraries

• C library
• Standard utility functions, interface to kernel
• functionality
• Several variants:
¬Glibc: big and full-featured
¬uClibc: small, configurable, targeted for
embedded systems (usual choice)
• Others as needed
• Pthreads
• GUI support
CHAITANYA KHER 22
Applications

• Created as standard Posix/Unix applications


• Stored in filesystem, loaded to RAM for
execution
• Standard applications
• Busybox
¬Standard Unix utilities in single package
¬Configurable feature support
• Custom applications
• GUI applications
• Anything system-specific (background network
applications, etc.) CHAITANYA KHER 23
Scripts

• Used to initalize/shut down system


• Others for access control, configuration
• Stored in /etc directory of root filesystem

CHAITANYA KHER 24
GUI
• Provide desktop environment
• Window environment for GUI application
creation and management
• Many standard apps available
• (productivity, multimedia, etc.)
• Qtopia Phone Edition
• Commercial, royalty-based
• Complete suite of applications
• Used in existing handset designs
¬Motorola A760, A780
¬Philips Nexperia Cellular System Solution
9000 reference platform
CHAITANYA KHER 25
Device and Driver Model
• Goal: separate mechanism (driver) from config
info (device)
• Device specification
• Provided in platform-specific code (vx115_vep.c)
• Device hierarchy (parents)
• Registration
• Device and driver matching and configuration
• registering devices and drivers causes match to occur
¬ driver's probe function called to configure
driver with handle to device data
• often text-based match (ex. platform devices)

CHAITANYA KHER 26
Kernel Space v/s User Space
• Each user application uses same virtual address
space (usually 0-based)
• MMU maps each app's virtual addresses to its personal
physical pages; map changes on context switch
• if give kernel pointer to userspace buffer and get
context switch, what happens to buffer reference?
• copy_from_user, copy_to_user
• transfer between user process buffer and kernel buffer
• make sure pages aren't swapped out (not an issue in
most embedded systems)
• map a kernel buffer so it can be directly accessed from
user application
• mmap function provided as part of driver interface
CHAITANYA KHER 27
Kernel Memory Allocation
• kmalloc, kfree: allocate and free memory in
kernel space
• allocates virtually and physically contiguous
buffer, returns
• virtual address
• flag specifies whether can sleep or not during
allocation
• vmalloc
• allocates virtually contiguous buffer , returns
virtual addresses
• can allocate larger buffers, but less efficient
CHAITANYA KHER 28
Debugging
• JTAG
best for kernel code and built-in drivers
not so useful for loadable modules or app code
• Usual method of kernel and driver debugging:
• print
messages to system log and console
• procfs
Can read out driver statistics/state
• objdump
Inspecting binaries (symbol info, disassembly,
etc.)

CHAITANYA KHER 29
Embedded Linux Hardware
• ARM (Advanced RISC Machine)
• Customers find their own manufacturer which
allows for greater customization

 Busses and Interfaces  Linux also supports a


wide variety IO
devices
 Printers
 Mice
 Sound
 Storage
CHAITANYA KHER  Display Devices 30
• GNU cross-platform development tool chain
• Kernel Setup Software
• Binary File Manipulation Utilities C Library
(Can be replaced with others)
• Full C Compiler
• Available IDE’s
• Anjuta
• Eclipse
• Glimmer
• KDevelop
• SourceNavigator
CHAITANYA KHER 31
• bin • usr
• boot • var
• dev • home
• etc • lib
• root • mnt
• sbin • opt
• tmp • proc

CHAITANYA KHER 32
• Linux Networking Features
• SNMP - Remote Administration
• Network Login through Telnet
• SSH
• HTTP
• DHCP

CHAITANYA KHER 33
• A fully featured Linux kernel requires about 1 MB
of memory
• The Linux micro-kernel actually consumes only
100 K
• With the networking stack and basic utilities, a
complete Linux system runs quite nicely in 500 K
of memory on an Intel 386 microprocessor, with
an 8-bit bus
• A Linux system can actually be adapted to work
with as little as 256 KB ROM and 512 KB RAM
CHAITANYA KHER 34
Web Resources:
• http://lxr.linux.no/
• Linux Device Drivers, 3rd edition, Alessandro Rubini,
O'Reilly online version at http://lwn.net/Kernel/LDD3/
• 2nd edition : http://www.xml.com/ldd/chapter/book/
• ARM Linux website: http://www.arm.linux.org.uk/
• Arm-linux-kernel mailing list
• CELF Wiki:
http://tree.celinuxforum.org/pubwiki/moin.cgi
• CELF Embedded Linux Conference:
http://www.celinux.org/elc2007/index.html
• Linux Journal: http://www.linuxjournal.com/
• Linux Magazine: http://www.linux-mag.com/

CHAITANYA KHER 35
QUESTIONS
Are
Welcome !
Thank you…
CHAITANYA KHER 36

Das könnte Ihnen auch gefallen