You are on page 1of 8

Attitude to Learn DEPIK would like to help all the good students like you, who are interested

in E mbedded and System Programming. DEPIK defines a student as good if student posse s the followng attitude. Interest(I) Initiative(I) Thinking(T) You basically should have Interest in computers to know more. Like how hardware in side a computer works, how operating system works and how an application prog ram runs on a computer etc.. Just interest alone is not sufficient, in fact a lot of students say they got lo t of interest. But you need Initiative to learn or find answers for them. And finally the most important thing is Thinking. Thinking makes lot of wonders. If you start thinking, you will find answers for most of the questions. When th inking is coupled with initiative, you try to search for the answers, you may as k someone or go and search on the internet, or do an experiment to find the answ er yourself. DEPIK is meant for such students with IIT attitude. Computer Careers The careers or job opportunities in computer field can be classified in to the f ollowing groups: Software Programming Hardware Programming (VLSI) Administration Testing or Quality Assurance (QA) Software Programming We can classify the programmers or programming jobs based on various parameters. Following are some parameters: Programming Language Used Operating System Used Abstraction Layer Used Based on the programming language, we classify programmers, as Assembly programm ers, C programmers, C++ programmers, Java programmers, C# programmers etc.. Based on the OS we classify as Linux/Unix Programmers, Windows Programmers, Mac Programmers etc.. We develop programs on some abstraction layer that is by using the services prov ided by the underlying abstraction layer. The lowest layer is hardware abstracti on. Developing programs directly to run on top of hardware comes under this laye r. Next layer is OS abstraction layer. In this layer, we develop programs by usi ng OS services. While programming at OS abstraction layer, we do not care about hardware. Final layers are application abstraction layers. These application abs traction layers run on top of OS abstraction layer, and provide various applicat ion abstractions like Graphical User Interface (GUI), Web application environmen t, Database application environment etc.. While developing programs on top of ap plication abstractions, we do not care about underlying OS. DEPIK's expertise lies in System Programming that includes the following skills:

C and Assembly Languages Linux/Unix Operating System Hardware Abstraction Layer and OS abstraction layer Hardware Programming (VLSI) Hardware programming is required to design and develop a new hardware chips. The hardware logic of a chip is specified by using a hardware language such a Veril og and VHDL. So one should learn these languages and associated tools. Students also should be good at Digital Electronics to learn these hardware languages. Administration Administration is about managing and maintaining the Hardware, Operating System, Network and Applications. In small organizations a single administrator called System Administrator will do all the above works. However large organizations wi ll have separate administrators for each of the above works. So the following ar e various administration careers possible: OS administration (Unix/Linux/Solaris/HP-US/Windows) Network Administration (LAN/WAN) Application Administration (Database/WEB/SAP) Testing or Quality Assurance Test Engineers are QA Engineers are responsible for testing and assuring the qua lity of the application programs developed by programmers. Depending on the type of applications these engineers are testing, we can classify these careers as b elow: GUI Application Testing Web Application Testing Network Protocol Testing Telecom Protocol Testing The protocol testing requires very good knowledge of the protocols. These test e ngineers should be as good as or even better than the developers of the protocol s. In order to test the protocols, the tester may need to develop some applicati ons. Typically scripting languages such as Perl, Python, TCL are used to write t est applications. The scripting languages are also useful to automate the testin g process (Test Automation) as well as for System and Network administration. Kn owledge of C language is going to be very helpful in learning these languages. Another type of testing possible is called unit testing or API testing. When pro grammers (developers) develop some generic functions, these generic functions sh ould tested to validate that these functions are working as expected or not. For this purpose, the testers should know the programming language used to call tho se API functions. What is embedded system? When you think of a computer, you normally think about a PC. But around us, ther e are so many invisible computers, embedded inside some other systems. For example, your mobile has got one computer inside. Your DVD player or Dish-TV box has got one computer inside. Almost all computer peripheral devices like pr inters, scanners and modems have got computers inside them. Similarly most of th e consumer electronic devices like digital cameras, MP3 players have got compute rs in side them.

All these computers are called embedded computers because they got embedded insi de some other systems. One important point to note here is that, computer does not always mean a system that includes monitor, keyboard, mouse and CPU box. Computer is the one that co ntains CPU(micrprocessor),Memory and Input/Output. All these three things could present inside a very small single chip. Best example is your USB pen drive (or flash disk). However small it may be, it got embedded computer inside, and when you power on it runs the software present in the memory, just like a PC. Embedded programmers are responsible for developing such software that runs on e mbedded computers. How embedded computers are different from Standard computers such as PCs? Embedded computers always runs a single program present in its memory. Where as PCs hold tens or hundreds of programs(applications) on its hard disk. Whenever y ou start a program, it will get loaded into memory and get executed. So PCs are designed to run multiple applications as and when you need. You may use PC to de velop C or Java programs, to write a document, to browse internet, to play a gam e, to play music or to play a movie and so on. You also can get a new applicatio n from your friend or download from Internet and able to run it on PC. Where as a digital camera runs always a single application, which will allow you to take photographs, view photographs and transfer them to PC. You never be abl e to load a new program into digital camera and use it for some other purpose. B asically embedded devices will not have such option of loading new programs. Another difference with embedded systems is the kind of hardware used. The hardw are used in embedded system is fine tuned to run just that single application. B ecause we know that the embedded computer is going to run a single application, we just use enough hardware to run that application. For example if small microcontroller (small chip with CPU,memory and IO built in to it) is enough, we just use that. In some embedded computers 32 bit CPUs are u sed with 16 to 64 Mega bytes of memory. Large embedded computers may have multip le 32 bit CPUs connected over some bus. How to develop software for embedded system (i.e. embedded computer) Embedded computer typically will be a small board having CPU, Memory and IO inte rfaces. That embedded computer can not be used to develop software. It can be us ed only to run and test the software, which is developed on a separate system. So to develop software for embedded board, we need a separate computer such a PC running Linux or PC running windows. This computer on which we develop software for embedded system is called a 'Host' computer. The embedded computer itself i s called a 'Target' computer. So embedded development environment is always refered as 'Host - Target' environ ment. Host is used to develop the software, and target is for executing and test ing the software. Another important feature of embedded development environment is the usage of cr oss compilers or cross development tools. As in most of the cases the CPU presen t in the embedded computer will be different from the CPU of host computer. Typi cally the host computer contains Pentium CPU, where as embedded computer may be having ARM/MIPS/DSP/Microcontroller as CPU. So we need compilers which will run on Pentium computers but produce the executable code for the CPU present on the embedded computer.

Such compilers are called cross compilers. For each type of CPU, a separate cros s compiler is required. Once you have these cross development tools, you can wri te a program on the host computer, compile it using the cross compiler, link it with libraries and build the executable. Now you got the executable file, but re member that, this executable will not run on you PC. It runs only on the target board. So how to run this program on the target board. This is our next topic. How to run the software developed on host, on an embedded computer? This is important and interesting aspect of embedded development. There exist va rious ways of loading the software to target board, running, testing and debuggi ng it. Two most common methods are: Using JTAG Emulator Using Bootloader or Debug Monitor software Most of the embedded computer boards have got JTAG interface (connector). You ma y have to buy a JTAG emulator kit to use the JTAG interface. This kit allows you to connect the embedded board to your host's (i.e. PC) serial/parallel/LAN port . This kit also comes with JTAG software that runs on host. Using this JTAG soft ware you can download the executable file, you have built above, on to the targe t board, run and debug it on the target board. Another method is to use Bootloader. All most all the 32 bit CPU based embedded computers will have bootloader software present in the ROM or flash memory of th ose boards. When you power-on the embedded board, this bootloader program will r un. This bootloader program allows you to download the executable file on to tar get board and run it. This is a low cost and simple alternative to using JTAG ki ts. If you have used any time 8085 or 8086 microprocessor kits, these kits also have got bootloader in the ROM. You may be calling that as monitor or Debug moni tor program instead of bootloader. DEPIK's Bootloader DEPIK is selling a bootloader software, which runs on a PC motherboard and makes PC motherboard as powerful embedded board. Now you can develop embedded program s for your motherboard and can download those embedded programs to motherboard u sing this bootloader. This software is very very useful for Engineering colleges to practice embedded programming without buying any new embedded boards. For mo re information click 'Products' menu. Embedded Systems with and without Operating System We can classify the embedded systems based on whether an operating system is use d inside or not. Most of the embedded systems that are using 32 bit CPUs, will u se operating systems like RTOS or Embedded Linux. Simple embedded systems based on microcontrollers will not use any OS. All the complex and large embedded systems use OS. The OS provides multi-tasking , Inter task communication and synchronization, Memory management, I/O system, F ile system and Networking services. By using these service of OS, one can develo p complex embedded systems. DEPIK's RTOS - dpKernel DEPIK has developed an RTOS named 'dpKernel'. The dpKernel runs on PC motherboar ds as well as ARM boards. DEPIK has sold this RTOS to various engineering colleg es. DEPIK's bootloader and this RTOS is the perfect combination to develop compl ex and large applications on the PC motherboards. This is a low cost solution to develop high-end embedded software.

Who are the best fit for embedded programming? Increasingly more and more software is being developed for embedded devices. Now a days most of the embedded devices are having large and complex software insid e. This is happening because of the availability powerful hardware with 32 bit C PUs and with larger memory but at lower costs. Embedded Programming is ideal for ECE/EEE engineering and MSc(Electronics) stude nts who would like to enter into software field. If these students are intereste d in hardware development, VLSI is the other choice. But Embedded software will offer much wider choices when compared with VLSI. VLSI is a very specific domain , where as embedded programmers can be easily switched to other software domains . Computer science students are also best for embedded programming, as embedded applications are becoming more software intensive. We can classify the embedded systems based on the type of CPUs used, into the fo llowing categories: 8 bit micro-controller based embedded systems DSP (Digital Signal Processor) based embedded systems 32 bit CPU based embedded systems with Embedded Operating System. Large Multi-processor based systems or Network processor systems The first type are simple embedded systems. The software inside them will be ver y small and simple as these microcontrollers will have very less amount of memor y. Very minimal C programming skills are good enough to develop software for the se systems. These are low-end embedded systems. Most of the DSP based embedded systems are signal processing systems. The progra mming requires good understanding of DSP concepts, algorithms and good mathes ba ckground. DSP is a small niche area within embedded systems. DSP based signal mo dulation and demodulation, Audio and Video compression and decompression are the important applications of DSP in embedded systems. The 32 bit CPU based embedded systems with embedded OS or Real Time OS are the m ost common large embedded systems. These systems will have huge amount of memory (typically 8 to 64 MB of RAM and 4 to 32MB of Flash). In larger embedded system s multiple such CPUs are used. These embedded applications are highly software intensive with huge amount of so ftware running inside. To support these large applications, these embedded syste ms always have Operating systems inside them. This calls for very good programmi ng skills and good understanding on using the operating system. These are high-end embedded systems; the skills required to develop these embedd ed systems are high in demand and value. Lot of students are under the impression that all embedded systems are based on microcontrollers. So very minimum programming skills are enough and no need of a ny operating system knowledge. These assumptions are not correct. Embedded indus try is looking for high end C programmers with data structures and with good kno wledge of Operating systems. Most of the networking, Telecom and Audio/Video consumer electronic devices will fall into this categiry. So along with C programming and OS knowledge, it will be an additional advantage to learn Networking protocols or Telecom protocols or Audio/Video compression and decompression algorithms. But final important point is that C and Data structures are essential skills. In dustry will be happy to take you, if you are a good C programmer, does not matte r if you do not know OS, Networking or Telcom.

Even if you are very good at operating systems, networking and telecom, but if y ou are not good at C, Industry may not prefer you. So that is the importance of C programing skills. DEPIK has realized the importance of improving C programming skills of ECE/EEE/M Sc(Electroncis) students studying in colleges, as well as students passed out of colleges. DEPIK is offering free material for learning C and other topics relev ant for embedded systems. Why to learn C Programming? Before discussing how to learn C, let us find out, why to learn C. If you want b ecome a good programmer, having a good command over C language is essential. C l anguage is the mother of so many modern languages and scripts. Knowledge in C ac ts as fundamental to learn these modern languages and scripts. Also C is the language of system programming. C is becoming a fast replacement f or assembly language. It is essential for the aspiring system programming profes sionals to learn C. System programming is the most fascinating field of programm ing. Also note that programming is the e art first and technology later. rding job for the people who like quality programmers and always in uality programmer. How to learn C Programming? The best way to learn C is to have access to Linux machine. Linux (or Unix) is t he best platform to learn C. Learning C with any other operating system is a com promise. If you really want to become a good programmer, the best investment you can do i s,buying some computer and loading Linux OS on it. Any old computer will do. You can get old computers for less than 8K or 9K. Or two to three friends can pool and buy a computer. This is the wise thing that can be done by all would be prog rammers. If you are a technical student studying electronics or computers, you must load Linux and practice Linux. Windows is for ordinary users and kids. Linux is for p rofessionals to learn and practice programming. If you load Linux, entire Linux OS is comes with source code. You can find source program files of all most all applications you are using. These source files have tremendous value in learning how professional programs were written. Once you are good at programming, these C program files of various applications will teach you a lot, which no textbook s can do. If you want to become a good programmer, go through the programs written by prof essionals. This chance comes only for Linux (open source) users. Learning C C language can be learned at various levels. At higher levels one can attempt mo re complex programs. Level 1 At this level one should learn writing simple C programs that contain only one f most fascinating and creative job. It is a fin Programming is also highly satisfying and rewa it. Software industry is always short of good search of them. So why don't you become such q

unction that is main function. The main function can contain following types of statements in the following seq uence. Variable declaration statements Input statements to accept values from the user Processing statements to compute the output Output statements to display the computed output. In the main function, practice the usage of following statements: If If-else If-else,If-else if-else if else Switch For loop Whilw loop Do while loop Break and continue statements Use the following types of variables in the main function: Char,short,int and float Arrays of above types Structure variables Also practice the usage of all arithmetic operators, logical operators, conditio nal operators and bit wise operators. Level 2 Writing function to do the processing. And call the function from main function to do processing. So main function contains following statements: Variable declaration statements Input statements to accept variable values from the user Calling the function by passing input arguments and getting output Output statements to display the output returned by the function Level 3 Write programs that contain multiple functions. Understand the difference between local variables and global variables and use b oth types of variables. Understand the use of pointer variable and use them Understand the difference between static allocation of memory and dynamic memory allocation and use both of them Understand the role of pointers in dynamic memory allocation Use various standard I/O library functions Level 4 Write programs that contain multiple functions distributed in multiple C files Practice linked lists (both single and double linked lists) Practice various search and sort algorithms DEPIK's Embedded and Linux Resource Center (DELRC) DEPIK since its inception is original and innovative in its approach to teach em bedded programming. Its vision always has been to produce world-class embedded p rofessionals. First we produced a Linux Live CD, in which we kept many cross compilers for emb edded development. We also developed low cost embedded boards for students to pr actice on their own using this Linux CD. Now we have come up with an Embedded Resource Center by providing a very conveni ent environment for practicing embedded and Linux programming at the lowest cost . That is just Rs.300 to Rs.500 per a month of practice. Our idea is that the co

st should not be a limiting factor, for any interested student in learning embed ded programming. In fact we encourage students with interest and talent a lot, b y going out of our way. What exactly we provide at DELRC? There are no teaching classes. Idea is to encourage learning by doing. Students have to sit infront of a computer and practice the lab assignments. However we p rovide well structured lab assignments with very good guidance and assistance. This lab environment is linked to the DEPIK's certification tests. After gaining good practical skills one can take DEPIK's certification test to get a certific ate. Also note that getting a good grade at the Certification test will have a l ot of benefit to the students. As these are only a practical sessions, students can take up them at their conve nient timings including week ends. This DELRC is also very suitable for working professionals who like to gain skills in different areas. They can come and prac tice at their convenient times. Once students are comfortable, they can also practice at their home with our Lin ux CD.This CD includes all the cross compilers. For example write programs at th eir home, come and test on the kits here. Students can also buy these kits as th ey are of low cost. Students who have cleared required certification tests are eligible for practici ng project ideas. They can come up with any project ideas then we will provide t he required hardware and guidance. Working professionals also can approach for e xecuting their project ideas. Click the following link to find the list of certification tests, for which stud ents can enrole to practice at DELRC.

You might also like