Anda di halaman 1dari 17

Industrial Training Report

Sponsored by

Hindustan Computers Limited


C-133, Industrial Area , Phase-8 Mohali , Mohali - 160055

Submitted to

Department of Electronics and Communication Engineering


Maharishi Markandeshwar Engineering College Maharishi Markandeshwar University Mullana, Ambala.

Submitted by

Komal Bansal 11090417

Table of Contents Chapter Contents


1 Introduction to the Industry / Company 1.1 Company profile & vision 1.2 Management objectives

Page No.
1-2 1 2

Introduction- Embedded Systems

Software Used

Study of various modules 4.1 Interfacing of LEDs with The MCU 4.2 Interfacing of switches with The MCU 4.3 Interfacing of 7 Segment Display with The MCU 4.4 Interfacing of DC Motor with The MCU 4.5 Relay 4.6 Stepper Motor 4.7 Liquid Crystal Display

COMPANY PROFILE
HCL: Overview
Hindustan Computers Ltd., one of the Indias largest electronics, computing and information technology company. Founded in 1976 by Mr. Shiv Nadar, Ajai Chawdhary and four other colleagues Based in Noida, its a $ 5 billion company with over 60,000 employees and is working in 26 countries

VISION
A global corporation enriching lives and enabling business transformation for our customers, with leadership in chosen technologies and markets. Be the first choice for employees and partners, with commitment to sustainability.

MANAGEMENT OBJECTIVES
To fuel initiative and foster activity by allowing individuals freedom ofaction and innovation in attaining defined objectives.

STRENGTHS OF HCL
1. Industry Experience of 32 years 2. True Corporate Exposure

IMPORTANCE OF MANAGEMENT TRAINING


To improve knowledge and efficiency for the job Provide useful tools to improve the leadership and management ability. Understand the roles and responsibilities as a manager.

CHAPTER-1 INTRODUCTION TO THE DEPARTMENT


An embedded system is a computer system designed to perform one or a few dedicated functions often with real-time computing constraints. It is embedded as part of a complete device often including hardware and mechanical parts. By contrast, a general-purpose computer, such as a personal computer (PC), is designed to be flexible and to meet a wide range of end-user needs. Embedded systems control many devices in common use today. Embedded systems are controlled by one or more main processing cores that is typically either a microcontroller or a digital signal processor (DSP). The key characteristic is however being dedicated to handle a particular task, which may require very powerful processors. Since the embedded system is dedicated to specific tasks, design engineers can optimize it reducing the size and cost of the product and increasing the reliability and performance.

CHARACTERISTICS
1. Embedded systems are designed to do some specific task, rather than be a generalpurpose computer for multiple tasks. Some also have real-time performance constraints that must be met, for reasons such as safety and usability; others may have low or no performance requirements, allowing the system hardware to be simplified to reduce costs. 2. Embedded systems are not always standalone devices. Many embedded systems consist of small, computerized parts within a larger device that serves a more general purpose. 3. The program instructions written for embedded systems are referred to as firmware, and are stored in read-only memory or Flash memory chips. They run with limited computer hardware resources: little memory, small or non-existent keyboard and/or screen.

CHAPTER-2 SOFTWARE USED


The Keil 8051 Development Tools are designed to solve the complex problems facing embedded software developers. When starting a new project, simply select the microcontroller you use from the Device Database and the Vision IDE sets all compiler, assembler, linker, and memory options for you. Numerous example programs are included to help you get started with the most popular embedded 8051 devices. The Keil Vision Debugger accurately simulates on-chip peripherals (IC, CAN, UART, SPI, Interrupts, I/O Ports, A/D Converter, D/A Converter, and PWM Modules) of your 8051 device. Simulation helps you understand hardware configurations and avoids time wasted on setup problems. Additionally, with simulation, you can write and test applications before target hardware is available.

VARIOUS STEPS TO USE THE KEIL COMPILER:


Open keil from the start menu. Select a new project from the project menu. Make a new folder in any drive. Name the project as abc and then click save. Right click on target, then options for the target, then choose the device, set the crystal frequency, click on the create hex file option to create hex file at the output. Then create a new file from the file menu and save it with the same name of project using extension .c or .asm. Right clicks on the source group, then click on add files option to add the files and then click on close.

CHAPTER-3 : STUDY OF VARIOUS MODULES 3.1 INTERFACING OF LEDs WITH THE MICROCONTROLLER

The LED is based on the semiconductor diode. When a diode is forward biased (switched on), electrons are able to recombine with holes within the device, releasing energy in the form of photons. This effect is called electroluminescence and the color of the light (corresponding to the energy of the photon) is determined by the energy gap of the semiconductor. LEDs present many advantages over incandescent light sources including lower energy consumption, longer lifetime, improved robustness, smaller size, faster switching, and greater durability and reliability.

3.1.1CIRCUIT DIAGRAM:

3.2 INTERFACING OF SWITCHES WITH THE MICROCONTROLLER


Take 2 pin three switches and connect their one pin to the GND. Now connect the other pin of switches to three pins of microcontroller (say P3.0, P3.1, P3.2). Now burn the code for the three patterns of LEDs using switches.

3.3 INTERFACING OF SEVEN SEGMENT DISPLAY WITH THE MICROCONTROLLER

Single seven segment display. Double seven segment display. A seven-segment display (abbreviation: "7-seg(ment) display"), less commonly known as

a seven-segment indicator, is a form of electronic display device for displaying decimal numerals that is an alternative to the more complex dot-matrix displays. Seven-segment displays are widely used in digital clocks, electronic meters, and other electronic devices for displaying numerical information. In addition to the ten numerals, seven segment displays can be used to show letters of the latin, cyrillic and greek alphabets including punctuation, but only few representations are

unambiguous and intuitive at the same time: uppercase A, B, C, E, F, G, H, I, J, L, O, P, S, U, Y, Z, and lowercase a, b, c, d, g, h, i, n, o, q, r, t, u.

3.4 INTERFACING OF DC MOTOR WITH THE MICROCONTROLLER


This section begins with an overview of the basic operation of DC motors. Then we describe how to interface a DC motor to the 8051. Finally, we use C language programs to demonstrate the concept of pulse width modulation (PWM) and show how to control the speed and direction of a DC motor.

DC MOTOR:
A direct current (DC) motor is another widely used device that translates electrical pulses into mechanical movement. In the DC motor we have only + and - leads. Connecting them to a DC voltage source moves the motor in one direction. By reversing the polarity, the DC motor will move in the opposite direction. One can easily experiment with the DC motor. For example, small fans used in many motherboards to cool the CPU are run by DC motors. By connecting their leads to the + and - voltage source, the DC motor moves.

3.4.1 Unidirection Control:


Figure shows the DC motor rotation for clockwise (CW) and counterclockwise (CCW) rotations.

3.4.4 CIRCUIT DIAGRAM:

3.5 RELAY:

A relay is an electrically operated switch. Current flowing through the coil of the relay creates a magnetic field which attracts a lever and changes the switch contacts. The coil current can be on or off so relays have two switch positions and most have double throw (changeover) switch contacts as shown in the diagram. Relays allow one circuit to switch a second circuit which can be completely separate from the first. For example a low voltage battery circuit can use a relay to switch a 230V AC mains circuit. There is no electrical connection inside the relay between the two circuits; the link is magnetic and mechanical. Most relays are designed for PCB mounting but you can solder wires directly to the pins providing you take care to avoid melting the plastic case of the relay. The supplier's catalogue should show you the relay's connections. The coil will be obvious and it may be connected either way round. Relay coils produce brief high voltage 'spikes' when they are switched off and this can destroy transistors and ICs in the circuit. To prevent damage you must connect a protection diode across the relay coil.

3.5.1 CIRCUIT DIAGRAM:

STEPPER MOTOR
Motion Control, in electronic terms, means to accurately control the movement of an object based on either speed, distance, load, inertia or a combination of all these factors. There are numerous types of motion control systems, including; Stepper Motor, Linear Step Motor, DC Brush, Brushless, Servo, Brushless Servo and more.

A stepper motor is an electromechanical device which converts electrical pulses into discrete mechanical movements. Stepper motor is a form of ac. motor .The shaft or spindle of a stepper motor rotates in discrete step increments when electrical command pulses are applied to it in the proper sequence. The motors rotation has several direct relationships to these applied input pulses. The sequence of the applied pulses is directly related to the direction of motor shafts rotation. The speed of the motor shafts rotation is directly related to the frequency of the input pulses and the length of rotation is directly related to the number of input pulses applied [39].

For every input pulse, the motor shaft turns through a specified number of degrees, called a step. Its working principle is one step rotation for one input pulse. The range of step size may vary from 0.72 degree to 90 degree. In position control application, if the number of input pulses sent to the motor is known, the actual position of the driven job can be obtained. A stepper motor differs from a conventional motor (CM) as under: a. Input to SM is in the form of electric pulses whereas input to a CM is invariably from a constant voltage source. b. A CM has a free running shaft whereas shaft of SM moves through angular steps. c. In control system applications, no feedback loop is required when SM is used but a feedback loop is required when CM is used.

d. A SM is a digital electromechanical device whereas a CM is an analog electromechanical device [40].

STEP ANGLE AND STEPS PER REVOLUTION


Movement associated with a single step, depends on the internal construction of the motor, in particular the number of teeth on the stator and the rotor. The step angle is the minimum degree of rotation associated with a single step. Step per revolution is the total number of steps needed to rotate one complete rotation or 360 degrees (e.g., 180 steps * 2 degree = 360) [31]. Since the stepper motor is not ordinary motor and has four separate coils, which have to be energized one by one in a stepwise fashion. We term them as coil A, B, C and D. At a particular instant the coil A should get supply and then after some delay the coil B should get a supply and then coil C and then coil D and so on the cycle continues. The more the delay is introduced between the energizing of the coils the lesser is the speed of the stepper motor and vice versa. For such a complex requirement of alternate supplies to the coil of stepper motor we need a special unit that will perform this operation. Here we are using a PC to perform this function.

3.7-Liquid Crystal Display


LCD Display
Liquid crystal displays (LCD) are widely used in recent years as compares to LEDs. This is due to the declining prices of LCD, the ability to display numbers, characters and graphics, incorporation of a refreshing controller into the LCD, their by relieving the CPU of the task of refreshing the LCD and also the ease of programming for characters and graphics. HD 44780 based LCDs are most commonly used. The LCD discuss in this section has the most common connector used for the Hitatchi 44780 based LCD is 14 pins in a row and modes of operation and how to program and interface with microcontroller is describes in this section.

16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1

16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1

Gnd Vcc D7 D6 D5 D4 D3 D2 D1 D0 E R/W RS Contrast Vcc Gnd

Fig 3.21 LCD Pin Description Diagram

VCC, VSS, VEE The voltage VCC and VSS provided by +5V and ground respectively while VEE is used for controlling LCD contrast. Variable voltage between Ground and Vcc is used to specify the contrast (or "darkness") of the characters on the LCD screen.

3.7.2 LCD INTERFACING WITH 8051 MICROCONTROLLER


Frequently, an 8051 program must interact with the outside world using input and output devices that communicate directly with a human being. One of the most common devices attached to an 8051 is an LCD display. Some of the most common LCDs connected to the 8051 are 16x2 and 20x2 displays. This means 16 characters per line by 2 lines and 20 characters per line by 2 lines, respectively. Fortunately, a very popular standard exists which allows us to communicate with the vast majority of LCDs regardless of their manufacturer. The standard is referred to as HD44780U, which refers to the controller chip which receives data from an external source (in this case, the 8051) and communicates directly with the LCD. The 44780 standard requires 3 control lines as well as either 4 or 8 I/O lines for the data bus. The user may select whether the LCD is to operate with a 4-bit data bus or an 8-bit data bus. If a 4-bit data bus is used the LCD will require a total

of 7 data lines (3 control lines plus the 4 lines for the data bus). If an 8-bit data bus is used the LCD will require a total of 11 data lines (3 control lines plus the 8 lines for the databus). The three control lines are referred to as EN, RS, and RW. The EN line is called "Enable." This control line is used to tell the LCD that you are sending it data. To send data to the LCD, your program should make sure this line is low (0) and then set the other two control lines and/or put data on the data bus. When the other lines are completely ready, bring EN high (1) and wait for the minimum amount of time required by the LCD datasheet (this varies from LCD to LCD), and end by bringing it low (0) again. The RS line is the "Register Select" line. When RS is low (0), the data is to be treated as a command or special instruction (such as clear screen, position cursor, etc.). When RS is high (1), the data being sent is text data which should be displayed on the screen. For example, to display the letter "T" on the screen you would set RS high. The RW line is the "Read/Write" control line. When RW is low (0), the information on the data bus is being written to the LCD. When RW is high (1), the program is effectively querying (or reading) the LCD. Only one instruction ("Get LCD status") is a read command. All others are write commands--so RW will almost always be low. Finally, the data bus consists of 4 or 8 lines (depending on the mode of operation selected by the user). In the case of an 8-bit data bus, the lines are referred to as DB0, DB1, DB2, DB3, DB4, DB5, DB6, and DB7. As we've mentioned, the LCD requires either 8 or 11 I/O lines to communicate with. For the sake of this tutorial, we are going to use an 8-bit data bus--so we'll be using 11 of the 8051's I/O pins to interface with the LCD. Let's draw a sample psuedo-schematic of how the LCD will be connected to the 8051.

DB3

EQU

P1.3

DB4

EQU

P1.4

DB5

EQU

P1.5

DB6

EQU

P1.6

DB7

EQU

P1.7

EN

EQU

P3.7

RS

EQU

P3.6

RW

EQU

P3.5

3.7.3 LCD pin description

Pin 1 2 3 4

Symbol VSS VCC VEE RS

I/O I

Description Ground +5V power supply Power supply to control contrast RS=0 to select command register, RS=1 to select data register.

5 6 7 8 9 10 11 12 13 14

R/W E PB0 PB1 DB2 DB3 DB4 DB5 DB6 DB7

I I/O I/O I/O I/O I/O I/O I/O I/O I/O

R/W=0 for write, R/W=1 for read Enable The 8 bit data bus The 8 bit data bus The 8 bit data bus The 8 bit data bus The 8 bit data bus The 8 bit data bus The 8 bit data bus The 8 bit data bus

Anda mungkin juga menyukai