PC based DC motor speed control1.doc

March 30, 2018 | Author: bhanusworld86 | Category: Rectifier, Embedded System, Microcontroller, Electric Motor, Microprocessor


Comments



Description

DC MOTOR SPEED CONTROL THROUGH PC (P.W.M TECHNIQUE) 1.INTRODUCTION This project mainly deals with the speed control of a DC Motor using a PC. The type of speed control that has been chosen here is pulse width modulation PWM. This project deals with development of DC MOTOR control using PC using PWM. 12V DC Motor drives widely use Micro controllers and The project detail design and complete hardware based high performance DC drive control system will be implemented. Most recently new requirements have arisen. These include faster torque control update with flexible design capability of motion peripherals for high performance military drive applications. Pulse width modulation type of speed control is chosen here because of high accuracy, high reliability, quick response and high efficiency. Our project deals with the types of problems that we face due to disturbances in supply voltage or load on the motor and enables us to overcome these difficulties by helping us with the appropriate software and hardware. We propose to design an embedded controller that helps us maintain the speed of the DC machine within the specific limits and a remote operate the embedded controller. Here, the pulses from the remote are sensed by sensor and are transmitted to the embedded controller. This controller contains a programmable PWM port. The output of this PWM port is used to control power delivered by a power regulating device 1 1:2 HARDWARE COMPONENTS: 1. POWERSUPPLY UNIT (TRANSFORMER, 7805 & 7812 REGULATORS, CAPACITOR 1000mf) 2. 89C52 MICROCONTROLLER 3. DC MOTOR 4. ULN 2803 DRIVER IC 5. DB 9 CONNECTOR 6. MAX 232 IC 7. Voltage regulator 7805. 8. Diode IN4007 9. Serial communication used for downloading the hex code. 10 .16X2 LCD interfacing 1:3 SOFTWARE: Soft Ware developed for this project in Embedded ‘C’ using KEIL-3.  A KEIL Cross compiler for compiling and linking the code written for AT89C52.  Serial communication software for downloading code to AT89C52.  Operating system: Windows XP 2. EMBEDDED SYSTEMS 2 2.1 DEFINITIONS: Embedded system is a combination of hardware and software, it is also named as “Firm ware”. An embedded system is a special purpose computer system, which is completely encapsulated by the device it controls. It is a computercontrolled system An embedded system is a specialized system that is a part of a larger system or machine. As a part of a larger system it largely determines its functionality. Embedded systems are electronic devices that incorporate microprocessors with in their implementations. The main purpose of the microprocessors are simplify the system design and improve flexibility. In the embedded systems, the software is often stored in a read only memory (RAM) chip. Embedded systems provide several major functions including monitoring of the analog environment by reading data from sensors and controlling actuators. Inputs (actuator) (sensor) Embedded System Outputs Figure 2.1 A real time system interacts with environment 2.2 EXAMPLES OF EMBEDDED SYSTEMS: 3 communication and office equipments and television Today's embedded systems are so inexpensive that they are used in almost every electronic product in our life. Originally they were used only for expensive industrial control applications.Embedded systems are found in wide range of application areas. they began to appear in moderately expensive applications such as automobiles. Embedded systems are often designed for mass production. Some examples of embedded systems: • Automatic Teller Machines • Cellular telephone and telephone switches • Computer network equipment • Computer printers • Disk drives • Engine controllers and antilock break controllers for automobiles • Home automation products • Handheld calculators • Household appliances • Medical equipment • Measurement equipment • Multifunction wrist watches • Multifunction printers • Mobile phones with additional capabilities • Programmable Logic Controllers 4 . but as technology brought down the cost of dedicated processors. some working registers. a clock timing circuits and interrupt circuit. An embedded product uses a microprocessor (or microcontroller) to do one task and one task only. The prime use of microprocessor is to read data perform extensive calculations on that data and store those calculations in mass storage 5 . usually Read Only Memory.3 MICROPROCESSOR AND MICROCONTROLLER: Microprocessors and microcontrollers are used in embedded system products. memory decoders and an Input/Output devices. The internal CPU architecture as well as the resultant machine level code that operates that architecture is comprehensive but as flexible as possible. Microprocessor CPU contains Arithmetic Logical Unit. a program counter. Microprocessor as the term come to be known is a general purpose digital computer central processing unit. The hardware design of microprocessor CPU is arranged so that a small or very large system can be configured around the CPU as the application demands. Although popularly known as a "computer on chip". a stack pointer. Random Access Memory. In addition special purpose devices such as interrupts. the microprocessor is in no sense a complete digital computer. To make complete microcomputer memory must add. counters may be added to relieve the CPU from time consuming counting or timing chores.2. Unlike a general purpose computer which also includes all of these devices. The prime use of microcontroller is to control the operation of machine using a fixed program that is stored in ROM that does not change over the life time of the system. The program is used by microprocessor are stored in the mass storage devices and loaded into RAM as the user directs. A microcontroller is designed for a very specific task to control a particular system.Micro suggest that the device is small and controller tells that the device is used to control objects. Input/ Output ports. process or events Microcontroller is a highly integrated chip that contains all the devices comprising a computer. interrupts. perform limited calculations on that data and control its environment based on those calculations. timers. So microcontroller is also called as "true computer on a chip". Typically this includes a CPU. RAM. A microcontrollers is a computer on a single chip . The advantages of microcontroller over microprocessor are • cost is less • speed is more • power consumption is less • compact device • external components are minimum 6 . A microcontroller is a general purpose device but one that is meant to read data.devices or display the results for user use. • Microprocessor may have one or two types of bit handling instructions microcontroller will have many. • Microcontroller can function as a computer with out addition of external devices. microcontroller may have one or two. • Microprocessor concerned with rapid movement of code and data from external address to the chip. 7 .4 MICROPROCESSOR VERSES MICROCONTROLLER: The contrast between microprocessor and microcontroller is best exemplified by the fact that: • Most microprocessor have operational codes for moving data from external memory to CPU. but microprocessor must have many additions to operate a computer. microcontroller is concerned with rapid data movement of bits with in chip.2. PC BASED DC MOTOR SPEED CONTROL BLOCK DIAGRAM MAX 232 8 0 5 2 Dc motor ULN 2803 Driver PC 8 .3. two timers. All the three microcontrollers will have the same internal architecture. 8052 has 8K ROM. There are many versions of 8051 with different speeds and amount of onchip ROM and they are all compatible with the original 8051. this microcontroller had 128 bytes of RAM. Of the three microcontrollers. 8051 has 4K ROM. 9 . this means that if you write a program for one it will run on any of them.4. two timers and 6 interrupts. three timers and 8 interrupts. two timers and 6 interrupts.MICROCONTROLLER 4:1 A BRIEF HISTORY OF 8051: In 1981. At the time it was also referred as “A SYSTEM ON A CHIP” The 8051 is an 8-bit processor meaning that the CPU can work only on 8 bits data at a time. Intel Corporation introduced an 8 bit microcontroller called 8051. There are two other members in the 8051 family of microcontrollers. Microcontroller supports both serial and parallel communication. 128 bytes of RAM. 4K bytes of chip ROM. 8051 is the most preferable. They are 8052 and 8031. • • • 8031 has 128 bytes of RAM. Data larger than 8 bits has to be broken into 8 bits pieces to be processed by the CPU. but they differ in the following aspects. The 8051 is an original member of the 8051 family. and four ports all on a single chip. 128 bytes of RAM. one serial port. The 8051 has a total of four I\O ports each 8 bit wide. 4:2 Description of 89C52 Microcontroller: The AT89C52 provides the following standard features: 8Kbytes of Flash. serial port. the AT89C52 is designed with static logic for operation down to zero frequency and supports two software selectable power saving modes.In the concerned project 8052 microcontroller is used. timer/counters. which is manufactured by ATMEL laboratories. a full duplex serial port. By combining a versatile 8-bit CPU with Flash on a monolithic chip. In addition. a six-vector two-level interrupt architecture. and interrupt system to continue functioning. and clock circuitry. The Power down Mode saves the RAM contents but freezes the oscillator. disabling all other chip functions until the next hardware reset. 32 I/O lines. 256 bytes of RAM. the Atmel AT89C52 is a powerful microcomputer which provides a highly flexible and cost effective solution to many embedded control applications. three 16-bit timer/counters. Here microcontroller used is AT89C52. The Idle Mode stops the CPU while allowing the RAM. 4:3 Features of Microcontroller (8052): • • Compatible with MCS-51 Products 8 Kbytes of In-System Reprogrammable Flash Memory 10 . onchip oscillator. timer/counters. serial port and interrupt system to continue functioning.• • • • • • • • • Endurance: 1.000 Write/Erase Cycles Fully Static Operation: 0 Hz to 24 MHz Three-Level Program Memory Lock 256 x 8-Bit Internal RAM 32 Programmable I/O Lines Three 16-Bit Timer/Counters Eight vector two level Interrupt Sources Programmable Serial Channel Low Power Idle and Power Down Modes In addition. The Power Down Mode saves the RAM contents but freezes the oscillator disabling all other chip functions until the next hardware reset. the AT89C52 is designed with static logic for operation down to zero frequency and supports two software selectable power saving modes. The Idle Mode stops the CPU while allowing the RAM. 11 . 1 Block Diagram Of 8052 12 .4:4 Block Diagram of Microcontroller: Figure 4. 2 Pin Diagram of 8952 4. The voltage source is +5v • GND : Pin 20 is the grounded 13 .4.5 Pin Configurations: Figure 4.6 Pin Description: • VCC : Pin 40 provides Supply voltage to the chip. As inputs. Port 1 also receives the low-order address bytes during Flash programming and program verification. The Port 1 output buffers can sink/source four TTL inputs. Port 0 also receives the code bytes during Flash programming. Port 0 may also be configured to be the multiplexed low-order address/data bus during accesses to external program and data memory. Port 2 pins that are 14 .Port 0: Port 0 is an 8-bit open drain bidirectional I/O port from pin 32 to 39. When 1s are written to Port 2 pins they are pulled high by the internal pull-ups and can be used as inputs. External pull-ups are required during program verification. and outputs the code bytes during program verification. The Port 2 output buffers can sink / source four TTL inputs. In this mode P0 has internal pull-ups. When 1s are written to port 0 pins. As inputs. Port 2: Port 2 is an 8-bit bidirectional I/O port with internal pull-ups from pin 21 to 28. When 1s are written to Port 1 pins they are pulled high by the internal pull-ups and can be used as inputs. the pins can be used as high-impedance inputs. As an output port each pin can sink eight TTL inputs. Port 1 pins that are externally being pulled low will source current (IIL) because of the internal pull-ups. Port 1: Port 1 is an 8-bit bidirectional I/O port with internal pull-ups from pin 1 to 8. Port 2 emits the contents of the P2 Special Function Register. During accesses to external data memory that use 8-bit addresses (MOVX @ RI). Port 3 also serves the functions of various special features of the AT89C51 as listed below: 15 . The Port 3 output buffers can sink / source four TTL inputs. Port 2 also receives the high-order address bits and some control signals during Flash programming and verification. Port 3: Port 3 is an 8-bit bidirectional I/O port with internal pull-ups from pin 10 to 17. As inputs.externally being pulled low will source current (IIL) because of the internal pull-ups. In this application it uses strong internal pull-ups when emitting 1s. Port 2 emits the high-order address byte during fetches from external program memory and during accesses to external data memory that use 16-bit addresses (MOVX @ DPTR). Port 3 pins that are externally being pulled low will source current (IIL) because of the pull-ups. When 1s are written to Port 3 pins they are pulled high by the internal pull-ups and can be used as inputs. • RST: Pin 9 is the Reset input. If desired. It is active high.Table 4. ALE operation can be disabled by setting bit 0 of SFR location 8EH. Note. that one ALE pulse is skipped during each access to external Data Memory. With the bit set. Address Latch Enable output pulse for latching the low byte of the address during accesses to external memory. ALE is active only during a MOVX or MOVC 16 .1 Special Features of 89C52 Port 3 also receives some control signals for Flash programming and programming verification. and may be used for external timing or clocking purposes. Upon applying a high pulse to this pin. In normal operation ALE is emitted at a constant rate of 1/6 the oscillator frequency. however. This pin is also the program pulse input (PROG) during Flash programming. • ALE/PROG: Address Latch is an output pin and is active high. the microcontroller will reset and terminate all activities. A high on this pin for two machine cycles while the oscillator is running resets the device. the pin is weakly pulled high. for parts that require 12-volt VPP. • XTAL2: Output from the inverting oscillator amplifier. When the AT89C52 is executing code from external program memory. PSEN is activated twice each machine cycle. however. except that two PSEN activations are skipped during each access to external data memory.7 Oscillator Characteristics: 17 . Note. EA will be internally latched on reset.instruction. • PSEN: Program Store Enable is the read strobe to external program memory. EA should be strapped to VCC for internal program executions. Setting the ALE-disable bit has no effect if the microcontroller is in external execution mode. EA must be strapped to GND in order to enable the device to fetch code from external program memory locations starting at 0000H up to FFFFH. that if lock bit 1 is programmed. • XTAL1: Input to the inverting oscillator amplifier and input to the internal clock operating circuit. • EA/VPP: External Access Enable. Otherwise. This pin also receives the 12-volt programming enable voltage (VPP) during Flash programming. 4. 3 External Clock Drive Configuration There are no requirements on the duty cycle of the external clock signal. as shown in Figure 5. XTAL2 should be left unconnected while XTAL1 is driven as shown in Figure. Either a quartz crystal or ceramic resonator may be used. respectively. To drive the device from an external clock source.3.1 Figure: crystal connections Figure: 4. of an inverting amplifier which can be configured for use as an on chip oscillator. since the input to the internal clocking circuitry is through a divide-by two flip- 18 .XTAL1 and XTAL2 are the input and output.4. The type of operation is selected by bit C/T2 in the SFR T2CON. Table: 4. TH2 and TL2. Timer 2 has three operating modes: capture.2. but minimum and maximum voltage high and low time specifications must be observed. In this function. the TL2 register is incremented every machine cycle. Since a machine cycle consists of 12 oscillator periods.flop. the external input is sampled during S5P2 of every machine cycle. and baud rate generator. When the 19 .8. as shown in Table 5. the count rate is 1/12 of the oscillator frequency. 4. The modes are selected by bits in T2CON.1 Timer 2 Operating Modes In the Counter function. In the Timer function.8 TIMERS: Timer 0 and 1: Timer 0 and Timer 1 in the AT89C52 operate the same way as Timer 0 and Timer 1 in the AT89C51. Timer 2: Timer 2 is a 16-bit Timer/Counter that can operate as either a timer or an event counter. the register is incremented in response to a 1-to-0 transition at its corresponding external input pin. auto-reload (up or down counting). Timer 2 consists of two 8-bit registers. T2. 1. Since two machine cycles (24 oscillator periods) are required to recognize a 1-to-0 transition. To ensure that a given level is sampled at least once before it changes. but it should for at least one full machine to ensure that a given level is sampled at least once before it changes Interrupts: The AT89C52 has a total of six interrupt vectors: two external interrupts (INT0 and INT1). the level should be held for at least one full machine cycle. three timer interrupts (Timers 0. The new count value appears in the register during S3P1 of the cycle following the one in which the transition was detected. the maximum count rate is 1/24 of the oscillator frequency. and 2).samples show a high in one cycle and a low in the next cycle. There are no restrictions on the duty cycle of external input signal.4 Interrupts source 20 . the count is incremented. These interrupts are all shown in Figure. and the serial port interrupt. Figure: 4. In the AT89C51. Neither of these flags is cleared by hardware when the service routine is vectored 21 . bit position IE. EA.6 is unimplemented. Note that Table 3 shows that bit position IE. 4. User software should not write 1s to these bit positions.2 Table 3 Interrupts Enable Register: Timer 2 interrupt is generated by the logical OR of bits TF2 and EXF2 in register T2CON. since they may be used in future AT89 products.5 is also unimplemented.8. IE also contains a global disable bit. which disables all interrupts at once.Each of these interrupt sources can be individually enabled or disabled by setting or clearing a bit in Special Function Register IE. On-chip hardware inhibits access to internal RAM in this event. the device normally resumes program execution. TF0 and TF1. is set at S2P2 and is polled in the same cycle in which the timer overflows. from where it left off. up to two machine cycles before the internal reset algorithm takes control. Idle Mode: In idle mode. The Timer 0 and Timer 1 flags.to. The content of the on-chip RAM and all the special functions registers remain unchanged during this mode. To eliminate the possibility of an unexpected write to a port pin when Idle is terminated by reset. the service routine may have to determine whether it was TF2 or EXF2 that generated the interrupt. Power down Mode: 22 . and that bit will have to be cleared in software. TF2. the Timer 2 flag. The idle mode can be terminated by any enabled interrupt or by a hardware reset. The values are then polled by the circuitry in the next cycle. In fact. It should be noted that when idle is terminated by a hardware reset. are set at S5P2 of the cycle in which the timers overflow. the CPU puts itself to sleep while all the on-chip peripherals remain active. However. The mode is invoked by software. the instruction following the one that invokes Idle should not be one that writes to a port pin or to external memory. but access to the port pins is not inhibited. Table 4. The only exit from power down is a hardware reset. The reset should not be activated before VCC is restored to its normal operating level and must be held active long enough to allow the oscillator to restart and stabilize.8. and the instruction that invokes power down is the last instruction executed.8. the latch initializes to a random value.3 Status of External Pins during Idle and Power down Mode Program Memory Lock Bits: On the chip are three lock bits which can be left unprogrammed (U) or can be programmed (P) to obtain the additional features listed in the table 4. the logic level at the EA pin is sampled and latched during reset. It is necessary that the latched value of EA be in agreement with the current logic level at that pin in order for the device to function properly. 23 .3 When lock bit 1 is programmed. The on-chip RAM and Special Function Registers retain their values until the power down mode is terminated.In the power down mode the oscillator is stopped. and holds that value until reset is activated. Reset redefines the SFRs but does not change the on-chip RAM. If the device is powered up without a reset. Table 4.8.4 Lock Bit Protection Modes Programming the Flash: The AT89C51 is normally shipped with the on-chip Flash memory array in the erased state (that is, contents = FFH) and ready to be programmed. The programming interface accepts either a high-voltage (12-volt) or a low-voltage (VCC) program enable signal. The low voltage programming mode provides a convenient way to program the AT89C51 inside the user’s system, while the high-voltage programming mode is compatible with conventional third party Flash or EPROM programmers. The AT89C51 is shipped with either the high-voltage or low voltage programming mode enabled. The respective top-side marking and device signature codes are listed in the following table. Table: 4.8.5 5 Top side marking and Device Signature Codes 24 The AT89C52 code memory array is programmed byte-by-byte in either programming mode. To program any non-blank byte in the on-chip Flash Memory, the entire memory must be erased using the Chip Erase Mode. Programming Algorithm: Before programming the AT89C52, the address, data and control signals should be set up according to the Flash programming mode table and Figures 3 and 4. To program the AT89C52, take the following steps. 1. Input the desired memory location on the address lines. 2. Input the appropriate data byte on the data lines. 3. Activate the correct combination of control signals. 4. Raise EA/VPP to 12 V for the high-voltage programming mode. 5. Pulse ALE/PROG once to program a byte in the Flash array or the lock bits. The byte-write cycle is self-timed and typically takes no more than 1.5 ms. Repeat steps 1 through 5, changing the address and data for the entire array or until the end of the object file is reached. Data Polling: The AT89C52 features Data Polling to indicate the end of a write cycle. During a write cycle, an attempted read of the last byte written will result in the complement of the written datum on PO.7. Once the write cycle has been completed, true data are valid on all outputs, and the next cycle may begin. Data Polling may begin any time after a write cycle has been initiated. 25 Ready/Busy: The progress of byte programming can also be monitored by the RDY/BSY output signal. P3.4 is pulled low after ALE goes high during programming to indicate BUSY. P3.4 is pulled high again when programming is done to indicate READY. Program Verify: If lock bits LB1 and LB2 have not been programmed, the programmed code data can be read back via the address and data lines for verification. The lock bits cannot be verified directly. Verification of the lock bits is achieved by observing that their features are enabled. Chip Erase: The entire Flash array is erased electrically by using the proper combination of control signals and by holding ALE/PROG low for 10 ms. The code array is written with all "1"s. The chip erase operation must be executed before the code memory can be re-programmed. Reading the Signature Bytes: The signature bytes are read by the same procedure as a normal verification of locations 030H, 031H, and 032H, except that P3.6 and P3.7 must be pulled to a logic low. The values returned are as follows. (030H) = 1EH indicates manufactured by Atmel (031H) = 51H indicates 89C51 26 8. will automatically time itself to completion. The write operation cycle is self-timed and once initiated.6 Flash programming modes 27 .(032H) = FFH indicates 12 V programming (032H) = 05H indicates 5 V programming Programming Interface: Every code byte in the Flash array can be written and the entire array can be erased by using the appropriate combination of control signals. 4. The standard 78XX is also called as monolithic voltage regulators. POWER SUPPLY UNIT DC power supply is the soul of electronic circuits. For that we have chosen fixed IC voltage regulators to maintain constant voltage with out any fluctuations to convert A. We are using IC 7805 and IC 7812 with properly designed filter circuit.18 and 24V.C into D.C we are using step down transformer of 12v. +5V and +12V. the last two numbers (XX) indicate the o/p voltage.5. so we should be very cautious while designing power supply. which are having three terminals. 28 .In our system we need two separate voltages i. current/voltage boosting and floating operation for high voltage application. relatively inexpensive and are available with features such as programmable o/p. it’s having the o/p voltage options such as 5. IC 78XX: These are fixed voltage regulators. 6. positive voltage regulators. In 78XX.15.e. So to get such voltages we ate going for the fixed IC voltage regulators. These are versatile.12. 8. 3. It is intended for use as fixed voltage-regulator in a wide range of applications FEATURES: 1.1 78XX 2 C1 C2 Where input capacitor C1 is used to cancel the inductive effects due to long distribution leads and the o/p capacitor C2 improves the transient response. ABSOLUTE MAXIMUM RATINGS: 1. Power supply: 29 .8 Amps. Input voltage: Max-35V OC Operating Temperature: -20 c to 80 c Internal power dissipation: Internally limited. Internal thermal over load protection. Internal short circuit current limiting.No external components are required. 2. 4. Maximum current output: 0. 2 . 3. A power supply can by broken down into a series of blocks. Here we are using a center-tap transformer whose output will be sinusoidal with 36volts peak to peak value. 12v regulated supply can also be produced by suitable selection of the individual elements. Each of the blocks is described in detail below and the power supplies made from these blocks are described below with a circuit diagram and a graph of their output: Transformer: A transformer steps down high voltage AC mains to low voltage AC. Most are designed to convert high voltage AC mains electricity to a suitable low voltage supply for electronics circuits and other devices.1 Block Diagram of a Regulated Power Supply System Similarly. 30 . each of which performs a particular function. For example a 5V regulated supply can be shown as below Fig:5.There are many types of power supply. 31 . It is not suitable for electronic circuits unless they include a rectifier and a smoothing capacitor. here we use a bridge rectifier. Thus a bi-directional wave is converted into unidirectional. The conducting diodes D2 and D4 will be in series with the load resistance RL and hence the current flows through R L in the same direction as in the previous half cycle. The ac input voltage is applied to the diagonally opposite ends of the bridge. but the DC output is varying. Rectifier: A rectifier converts AC to DC. The Bridge rectifier is a circuit. The load resistance is connected between the other two ends of the bridge. The circuit has four diodes connected to form a bridge. D1 and D3 remain OFF. For the positive half cycle of the input ac voltage. heaters and special AC motors. The Bridge rectifier circuit is shown in the figure. diodes D1 and D3 conduct. For the negative half cycle of the input ac voltage. which converts an ac voltage to dc voltage using both half cycles of the input ac voltage. whereas diodes D2 and D4 remain in the OFF state. The transformer output is given to the rectifier circuit.Fig: Output Waveform of transformer The low voltage AC output is suitable for lamps. The conducting diodes will be in series with the load resistance R L and hence the load current flows through RL. diodes D2 and D4 conduct whereas. There are several types of rectifiers. Smoothing is also named as filtering. heaters and standard motors. The ripple voltage is defined as the deviation of the load voltage from its DC value.5. Smoothing: The smoothing block smoothes the DC from varying greatly to a small ripple.2 Fig the output waveform of the rectifier is shown as below The varying DC output is suitable for lamps. It is not suitable for electronic circuits unless they include a smoothing capacitor. Filtering is frequently effected by shunting the load with a capacitor. The action of this system depends on the fact that the capacitor 32 . In this way. and the ripple is considerably decreased.3 The waveform of the rectified output after smoothing is given below: Regulator: 33 .stores energy during the conduction period and delivers this energy to the loads during the no conducting period. the time during which the current passes through the load is prolonging Ted. The action of the capacitor is shown with the help of waveform. Fig: 5. Zener diode is an example of fixed regulator which is shown here. output and high impedance). They include a hole for attaching a heat sink if necessary.Regulator eliminates ripple by setting DC output to a fixed voltage. REGULATOR 34 . Negative voltage regulators are also available Many of the fixed voltage regulator ICs has 3 leads (input. 12 and 15V) or variable output voltages.Voltage regulator ICs are available with fixed (typically 5. Through the use of high-resolution counters. PWM THE TECHNIQUE PWM is a way of digitally encoding analog signal levels. Given a sufficient bandwidth. the duty cycle of a square wave is modulated to encode a specific analog signal level. Many micro controllers include PWM controllers. the full DC supply is either fully on or fully off. For example. The duty cycle is the ratio of the on-time to the period. any analog value can be encoded with PWM. each of which has a selectable ontime and period. at any given instant of time. 35 . Microchip’s PIC16C67 includes two. The on time is the time during which the DC supply is applied to the load and the off time is the period during which that supplies is switched off. The voltage or current source is supplied to the analog load by means of a repeating series of and off pulse.Transformer + Rectifier + Smoothing + Regulator: 6. The PWM signal is still digital because. the software need only increase the duty cycle of the PWM output. a brake is a device that clamps down hard on something in many brakes. ranging from measurement and communication to power control and conversion. The signal remains digital all the way from the processor to the controlled system. the more pressure the brake will exert. The output of a PWM controller could be connected to a switch between the supply and the brake to produce more stopping power. As a concrete example consider a PWM-controlled brake.2 APPLICATIONS OF PWM: PWM is employed in a wide variety of applications. space saving. noise immunity is yet another benefit of choosing PWM over analog control and is the principal reason PWM is sometimes used for communication. 36 . the amount of clamping pressure is controlled with an analog input signal. By keeping the signal No digital-to –analog conversion is digital.6.1 ADVANTAGES OF PWM: PWM is economical. 6. To put it simply. The more voltage or current that’s applied to the brake. necessary. 37 . There are some special IC chips made by many manufacturers for data communications. Computers transfer data in two ways: parallel and serial. Serial data communication uses two methods. These chips are commonly referred to as UART (universal asynchronous receiver-transmitter) and USART (universal synchronous asynchronous receiver transmitter).7 .1 INTRODUCTION: When a processor communicates with the outside world.Serial communication between PC and Microcontroller 7. The synchronous method transfers data at a time while the asynchronous transfers a single byte at a time. In parallel data transfers. often more lines are used to transfer data to a device and 8 bit data path is expensive. The serial communication transfer uses only a single data line instead of the 8 bit data line of parallel communication which makes the data transfer not only cheaper but also makes it possible for two computers located in two different cities to communicate over telephone. it provides data in byte sized chunks. asynchronous and synchronous. The AT89C51 chip has a built in UART. such as ASCII characters. The RS232 cables are generally referred to as DB-9 connector. each character is placed between start and stop bits. the data. making -3 to +3 undefined. To allow the compatibility among data communication equipment made by various manufacturers. and interfacing standard called RS232 was set by the Electronics industries Association in 1960. In RS232. its input and output voltage levels are not TTL compatible.In asynchronous method. Today RS232 is the most widely used I/O interfacing standard. For this reason. We have a total of 10 bits for a character: 8 bits for the ASCII code and 1 bit each for the start and stop bits. DB-9P refers to the plug connector (male) and DB-9S is for the socket 38 . since the standard was set long before the advent of the TTL logic family. are packed in between a start and stop bit. while a 0 bit is represented +3 to +25 V. MAX232 ICs are commonly referred to as line drivers. In data framing of asynchronous communications. In labeling. to connect any RS232 to a microcontroller system we must use voltage converters such as MAX232 to connect the TTL logic levels to RS232 voltage levels and vice versa. This standard is used in PCs and numerous types of equipment. The rate of serial data transfer communication is stated in bps or it can be called as baud rate. This is called framing. However. a 1 bit is represented by -3 to -25V. Many PCs use one each of the DB-25 and DB-9 RS232 connectors. These two pins are called TXD and RXD and are part of the port3 (P3. respectively. Both COM ports have RS232 type connectors. The T1 in pin is the TTL side and is connected to TXD of the microcontroller. 486 and Pentium) microprocessors normally have two COM ports. therefore they require a line driver to make them RS232 compatible. TXD. The AT89C51 has two pins that are used specifically for transferring and receiving data serially.1). RXD. Many of the pins of the RS232 connector are used for handshaking signals. The MAX232 has two sets of line drivers for receiving and transferring data. The COM ports are designated as COM1 and COM2. and ground. while TI out is the RS232 side that is connected to the RXD pin of the DB9 connector. In MAX232 that the TI line driver has a designation of T1 in and T1 out on pin numbers 11 and 14. 386. We can connect the serial port to the COM 2 port of a PC for serial communication experiments. We use a DB9 connector in our arrangement. One such line driver is the MAX232 chip. 80286. The simplest connection between a PC and microcontroller requires a minimum of three pin. IBM PC/ compatible computers based on x86(8086. They are bypassed since they are not supported by the 8051 UART chip. These pins are TTL compatible. T1 and R1 are used for TXD and RXD of the 89c51 and the second set is left unused. One advantage of MAX232 chip is that it uses a +5v power source which is the same as the source voltage for the at89c51.0 and P3. The line drivers for TXD are called T1 and T2 while the line drivers for RXD are designated as R1 and R2. 39 .connector (female). 8.To allow data transfer between PC and the microcontroller system without any error. this module aids in the movement of the arm through steppers. 40 . high current Darlington arrays feature continuous load current ratings. The series ULN20XX high voltage. ULN DC MOTOR DRIVER ULN is mainly suited for interfacing between low-level circuits and multiple peripheral power loads.turn decodes the coding and conveys the necessary data to the stepper motor. The driving circuitry in. we must make sure that the baud rate of the 8051 system matches the baud rate of the PC’s COM port. The driver makes use of the ULN2003 driver IC. The device has base resistors. solenoids. Typical loads include relays. depending on ambient temperature and number of drivers turned on. incandescent displays and heaters. simultaneously typical power loads totaling over 230w can be controlled. magnetic print hammers. hence the device can drive inductive loads with minimum extra components. each capable of driving 500mA of current. multiplexed LED. stepper motors. All the emitters are tied together and brought out to a separate terminal. Output protection diodes are included. which contains an array of 7 power Darlington arrays. At an approximate duty cycle. 41 . allowing direct connection to any common logic family. 1 The main features of ULN2003 are as follows: 1. Seven Darlington per package 2. DC MOTOR DC motors are configured in many types and sizes. A motor consists of a rotor and a permanent magnetic field stator. 9. including brush less. Outputs can be paralleled for high current TTL/CMOS/DTL compatible inputs 5. and gear motor types.1.8. The magnetic field is maintained using either permanent magnets or electromagnetic windings. Output current 500ma per driver (600ma peak) Output voltage 50v 3. Dual In-Line plastic package or small-Outline IC package. DC motors are most commonly used in variable speed and torque. Motion and controls cover a wide range of components that in 42 . Integrated suppression diodes for inductive loads 4. Inputs pinned opposite outputs to simplify layout. servo. Transient protected outputs 6. slides and guides. and gear motor) and DC motors (brush less. while like polarities (North and North. drive components. slip rings. operation is based on simple electromagnetism. universal. Let's start by looking at a simple 2-pole DC electric motor (here red represents a magnet or winding with a "North" polarization. This family includes AC motor types (single and multiphase motors. positioning stages. power transmission (mechanical). stepper and air motors. solenoids. and motor contactors and starters. orientation position sensing. The internal configuration of a DC motor is designed to harness the magnetic interaction between a current-carrying conductor and an external magnetic field to generate rotational motion. clutches and brakes. springs. Integrated motion control. synchronous. limit switches. linear position sensing. opposite (North and South) polarities attract. controls and drives. Motors are the devices that provide the actual speed and torque in a drive system. As you are well aware of from playing with magnets as a kid. servo motors. and gear motor) as well as linear. In any electric motor.some way are used to generate and/or control motion. linear actuators. A current-carrying conductor generates a magnetic field. while green represents a magnet or winding with a "South" polarization). pneumatics and pneumatic components. servo motor. Areas within this category include bearings and bushings. induction. linear and rotary motion components. 43 . seals. it will experience a force proportional to the current in the conductor. motors (both AC and DC motors). when this is then placed in an external magnetic field. encoders and resolves. and to the strength of the external magnetic field. South and South) repel. the rotation reverses the direction of current through the rotor winding. armature). this avoids "dead spots" in the commutator. it will get "stuck" there. commutator. In particular. there is a moment where the commutator shorts out the power supply (i. as well as two or more permanent magnet pole pieces. and energize the next winding. and the rotor will rotate until it is almost aligned with the stator's field magnets. field magnet(s).Every DC motor has six basic parts -. The stator is the stationary part of the motor -. and brushes. leading to a "flip" of the rotor's magnetic field. with a two-pole motor. the polarities of the energized winding and the stator magnet(s) are misaligned.a.e. As the rotor reaches alignment. though. both brushes 44 . The rotor consists of windings (generally on a core).with the rotor inside the stator (field) magnets.axle.. stator. Given our example two-pole motor. and driving it to continue rotating. DC motors will always have more than two poles (three is a very common number). commutator contacts. The rotor (together with the axle and attached commutator) rotates with respect to the stator. the brushes move to the next commutator contacts.k. You can imagine how with our example two-pole motor.. the external magnetic field is produced by high-strength permanent magnets1.this includes the motor casing. the windings being electrically connected to the commutator. The above diagram shows a common motor layout -. In most common DC motors (and all that Beamers will see). rotor (a. In real life. and rotor windings are such that when power is applied. if the rotor is exactly at the middle of its rotation (perfectly aligned with the field magnets). Meanwhile. The geometry of the brushes. let's tinker with the workings of one via an interactive animation (JavaScript required): You'll notice a few things from this -.touch both commutator contacts simultaneously). waste energy. We'll see more about the effects of this later. as the next coil's field will rapidly charge up (this occurs within a few microsecond). As each brush transitions from one commutator contact to the next. one pole is fully energized at a time (but two others are "partially" energized). So since most small DC motors are of a three-pole design.namely. but in the meantime you can see that this is a direct result of the coil windings' series wiring: 45 . This would be bad for the power supply. Yet another disadvantage of such a simple motor is that it would exhibit a high amount of torque” ripple" (the amount of torque it could produce is cyclic with the position of the rotor). and damage motor components as well. one coil's field will rapidly collapse. Furthermore. Keil development tools for the 46 . as well as requiring the destruction of a perfectly good motor. modular design allows the software designer to limit the required changes whenever a module needs to be modified or extended. The user interface is the set of functions that allow the interaction between the user and the software application. This is a basic 3-pole dc motor. than by just opening one up. Unfortunately this is tedious work. The functional separation main issue is to isolate as much as possible the application itself from the user interface and the underlying hardware. with 2 brushes and three commutator contacts. The Keil 8051 Development Tools are designed to solve the complex problems facing embedded software developers.There's probably no better way to see how an average dc motor is put together.   After compiling and debugging process. all in source code. with simulation.8051 Microcontroller Architecture support every level of software developer and learning about embedded software development. Simulation helps in understanding hardware configurations and avoids time wasted on setup problems.1 Features of keil C:  When starting a new program. and memory options depending on the selections. simply select the microcontroller from the Device Database and the µVision sets all compilers. linker. Interrupts. I/O Ports.  47 . Numerous example programs are included to help getting started with the most popular embedded 8051 devices. The Keil µVision provides Debugger which accurately simulates on-chip peripherals (UART. keil C comes with many function libraries. A/D Converter. machine level I/O 9. we can write and test applications before target hardware is available. and PWM Modules) of your 8051 device. D/A Converter. SPI. Additionally. keil C is an integrated development system for writing embedded software. It supports realtime programming. the program will execute in the run state and the result can be observed physically or through the configurations made depending on selections made. assembler. which connects to PC’s parallel port. PROM and Flash memory. The LabTool-48UXP features a 48-pin universal pin driver and an expandable TTL pin driver. MAX. EPLD. microprocessors and high density memory chips. sophisticated embedded applications. The keil c µVision compiler helps you create robust. GAL. PEEL. CPLD. The keilc µVision Debugger accurately simulates a complete microcontroller including peripherals and enables application testing without target hardware. EPROM. The LabTool-48XP can read this 48 . MACH. It supports over 7000 different devices. It can detect poor pin contact and incorrect insertion. Many EPROM and Flash memories have a built-in device and manufacturer ID. pLSI.2 PROGRAMMING THE CHIP: The chip can be programmed using INTELLIGENT UNIVERSAL PROGRAMMER from Advantech.Keil development tools for microcontrollers are easy to learn and use. series EPROM. microprocessors. The LabTool-48XP is developed for both laboratory and massproduction applications. 9. yet powerful enough for the most demanding embedded applications. The LabTool-48XP performs device insertion and contact checks before it programs each device. including PAL. an on-board processor lets it handle todays (and tomorrows) complicated DIP-type silicon PLDs. thus saving expensive chip damage due to operator error. 3V & 1. Windows XP & • • • • • NT • 3 years hardware warranty. making it useful when working with secondhand chips and devices that have had their part number removed.8V Devices Less that 2 seconds per M bit Programming speed No adapter required for DIL devices up to 48-pin. Windows 2000. 9. Supports 5V.3 FEATURES OF IUP: • • High Speed USB port interface. 49 .2. 3. 48-pin universal pin driver and current limit Device insertion / continuity check Supports Windows 95/98.1 Intelligent Universal Programmer 9.information. 2.• FREE software updates via the web. we could have used transistors as drivers. The four leads of the stator winding are controlled by the four bits of the 8051 port (p1. for example one 44 pin PLCC adapter will • • • • • • • program 44 pin memory and micro devices. However.4 Driving a dc motor: 1. 50 . Instead of the uln2003a.3). since the 8051 lacks sufficient current to drive the stepper motor windings. Serialization for Memory and Micro's Memory buffer H / L byte swap Project file save and load function User Selectable verify VCC with one or two-pass verify voltage Automatic file format detection and conversion Pin swapping table provided for all adapters Universal adapters. One reason that the uln2003a is preferable to the use of transistors as drivers is that the uln2003 has as internal diode to take care of back emf. 9. we must use a driver such as uln2003a to energize the stator. notice that if transistors are used as drivers.0-p1. we must also use diodes to take care of inductive current generated when the coil is turned off. However. Figure 10. electrically conductive film or back plane is put up on the rear glass sheet. JHD 162A Liquid Crystal Display (16x2). which is shown in Figure 3.1. an electric field is created in the region under the segment. The is electric field changes the transmission of light through the region under the segment film.1 Liquid Crystal Display Description: In this project. When a voltage is applied between a segment and the back plane. A transparent.LIQUID CRYSTAL DISPLAY UNIT (LCD) Introduction: Liquid Crystal Displays are created by sandwiching a thin (10-12 micro mm) layer of a liquid crystal fluid between two glass plates. is interfaced with the CPU.10.9. The transparent sections of the conductive film in the shape of the desired characters are coated on the front glass plate. 10.1 JHD 162A Liquid Crystal Display The features of JHD 162A LCD is as follows: • 16 Characters x 2 Lines 51 . LCD's are invaluable for displaying status messages and 52 .1. If the LCD is having Backlight. The pin description of the JHD 162A LCD without backlight is as shown in Table 2. then it will have two more pins with pin numbers 15 & 16 connected to VCC and GND respectively. making the application much more user friendly and impressive. 1->0 I 0/1 0/1 0/1 0/1 0/1 0/1 0/1 I/O Data bus line 0 (LSB) I/O Data bus line 1 I/O Data bus line 2 I/O Data bus line 3 I/O Data bus line 4 I/O Data bus line 5 I/O Data bus line 6 14 DB7 0/1 I/O Data bus line 7 (MSB) Table 10.2 Pin assignment for <= 80 character displays An LCD allows an application to output a very specific message (or prompt) to the user.• 5x7DotswithCursor • Built-in controller • +5v Power Supply • 1/16 Duty Circle.13. Pin number 1 2 3 4 5 6 7 8 9 10 11 12 13 Symbol Level I/O Function Vss Vcc Vee RS R/W E DB0 DB1 DB2 DB3 DB4 DB5 DB6 0/1 0/1 I I Power supply (GND) Power supply (+5V) Contrast adjust 0= Instruction input 1 = Data input 0 = Write to LCD module 1 = Read from LCD module Enable signal 1. The "E" clock is used to initiate the data transfer within the LCD.3 below: 53 . Sending parallel data either as 4 or 8 bits are the two primary modes of operation. The blinking function is very rarely used because it is pretty obnoxious. This cursor can be moved or be made invisible to blink. 4bit mode requires minimum 6 bits. they have a reputation of being difficult to hook up and get to work. just the top 4-bits (DB4-7) are written as shown in the Figure 10. While there are secondary considerations and modes deciding how to send the data to the LCD is more critical decision to be made for an LCD interface application.1. This specifies where the next data character is to be written. ASCII-input LCDs even though they have these advantages. If the 4-bit mode is used. 4-bit mode is best used when the speed required in an application and at least 10 I/O pins are available. The ASCII code to be displayed is 8 bits long and is sent to the LCD either 4 or 8 bits at time. two nibbles of data (sent high 4 bits then low 4 bits with an E clock pulse with each nibble) are sent to make up a full 8-bit transfer.information during application debug. Both of these actions have resulted in alphanumeric LCDs that range in size from 8 characters to 80 (arranged as 40 b 2 or 20 b 4) and are interchangeable. To wire a Microcontroller to an LCD 4-bit mode. Most alphanumeric LCD's use a common controller chip and a common connector interface. without requiring hardware or software changes. In the LCD there is a cursor. 8-bit mode could be used with a shift register. the byte at the current LCD cursor position can be read or written When the bit is reset.1. 54 . but a ninth bit (which will be used as R/S) will be required.3 Data Transfer using a 4-Bit Interface Using a shift register so that a minimum of three I/O pins is required can further reduce this. either an instruction is being sent to the LCD or the execution status of the last instruction is read back (whether it has completed or not). The display contains two internal byte-wide registers. one for command (RS=0) and the second for the characters to be displayed (RS=1). The display contains two internal byte-wide registers.Figure 10. If the bit is set. The R/S bit is used to select whether data or an instruction is being transferred between the Microcontroller and the LCD. It also contains a user programmed RAM area (the character RAM) that can be programmed to generate a desired character that can be formed using a dot matrix. one for command (RS=0) and the second for characters to be displayed (RS=1). Second.2 to 3. This condition must be tested before sending a new command to the LCD. the hex command byte 80 will be used to signify that the display RAM address 00h is chosen.3. A slightly more complicated LCD display (4 lines* 40 characters) is currently being used in medical diagnostic systems to run a very familiar program. Examples for Busy Flag testing using both 4-bit and 8-bit interfaces are shown in figures 10.2 respectively. the LCD's cursor must be moved to the LCD address where the character is to be displayed. The display takes varying amounts of time to accomplish the functions. In addition to busy flag polling.3 LCD Busy Flag Polling: The LCD will not accept new commands while it is busy with some internal operation. The BF bit in this instruction is the busy flag. First. the actual character must be written to the cursor in order to store it in the DDRAM at the cursor's location. 10. The "Busy Flag/Address Read" instruction should be used for this purpose.To distinguish between these two data areas.1 and 10. This is performed with the "CGRAM/DDRAM Data Write" command. LCD is ready for the next command. 10.one can begin to display messages on the LCD by sending the correct instructions to it. This is done with the "DDRAM Address Set" command. When BF is 0. Getting the LCD to display text is a two-step process. LCD bit 7 is monitored for a long high (bus) to ensure the display is not over written. Port 1 is used to furnish the commands or data byte and ports 3. LCD controller is busy. this instruction is used to determine where the address of the LCD cursor is.2 Getting The LCD To Display Text: After successfully initializing the LCD and turning the display ON.3.4 furnish register select and read/write levels. 55 . When this bit is 1. Figure 10. 56 .1 Example of busy flag testing using a 4-bit interface.3.3.2 Example of busy flag testing using an 8-bit interface.Figure 10. Character Generator RAM (CGRAM) has been added to the LCD for this purpose.2P3. Before a custom character can be used it must be created.7 lines to D0-D7 lines of LCD. Each of these dots can be turned either ON or OFF when a character is being displayed. Each character that can be displayed by the LCD is composed of a 5 x 8 grid of pixels or dots. R/W and RS pins respectively. Similarly Port3 pins (P3. 10. in order for the LCD controller to display a character.4 Defining LCD Custom Characters: One of the nice features of the LCD is that it allows for the creation and use of up to eight unique. it must have a definition of which of the character dots need to be turned ON.e.10. 57 . Port1 pins of 89s52 are used to read and write the data from LCD by interfacing P0. Therefore.P0.0 .4) are connected to control pins of LCD i. user-defined characters. the JHD 162A LCD is interfaced with the 89s52 Microcontroller.5 Interfacing of LCD with 89s52 Microcontroller : In this project. E. sbit motor12=P2^7. PROJECT CODE #include<reg52. void serial_int(void)interrupt 4 { if(RI) { RI = 0. if(vall == 'A') { flag=0. } if(vall == 'B') { flag=0. void cmd_lcd(unsigned char). } if(vall == 'C') {flag=0. keypress=1. void display_lcd(unsigned char *).H> //////////////////////////////////////////////// #define lcd P0 ///////////////////////////////////////////////// void init_lcd(void). keypress=3. /////////////////////////////////////////////////////////////////////////// unsigned char a. void pwm(unsigned int). keypress=2.h> #include <STDIO.11. unsigned char flag.unsigned int keypress. void config(unsigned int value). vall = SBUF. 58 . bit receive=0. void delay_ms(unsigned int). void lcd_data(unsigned char). } if(vall == 'D') { flag=0. unsigned char vall. 59 . TMOD = 0x20. init_lcd(). cmd_lcd(0x80). } if(vall == 'E') { flag=0. keypress=6. display_lcd("SPEED CONTROLLING "). init_lcd(). display_lcd("PC BASED DC MOTOR"). IE = 0x92. TR1 = 1. cmd_lcd(0xC0). } if(vall == 'F') { flag=0. } } } void main(void) { motor12=0. TL0=0x00.keypress=4. delay_ms(1000). keypress=5. TH0=0x00. TH1 = 0xFD. //cmd_lcd(0x01). init_lcd(). motor12=0. SCON = 0x50. if(flag==0) { cmd_lcd(0x01). config(1). config(70). config(100). display_lcd("Motor rotating"). display_lcd("with max speed"). motor12=0. d=0. } break. cmd_lcd(0x80). motor12=0. case 3: 60 . flag++. flag++. pwm(keypress).d=0. config(30). case 2: motor12=1. display_lcd("with Med speed"). cmd_lcd(0x80). if(flag==0) { cmd_lcd(0x01). cmd_lcd(0xc0). } } void pwm(unsigned int d) { switch (d) { case 1: motor12=1. cmd_lcd(0xc0).while(1) { //delay_ms(100). } break. display_lcd("Motor rotating"). config(60). display_lcd("with Low 2speed"). flag++.d=0. motor12=0.motor12=1. display_lcd("Motor rotating"). cmd_lcd(0xc0). cmd_lcd(0x80). motor12=0. config(40). if(flag==0) { cmd_lcd(0x01).d=0. cmd_lcd(0xc0). case 4: motor12=1.d=0. if(flag==0) { cmd_lcd(0x01). display_lcd("Motor rotating"). display_lcd("with Low 1 speed"). } break. config(40). cmd_lcd(0x80). cmd_lcd(0x80). 61 . config(60). display_lcd("with Low 3speed"). motor12=0. } break. flag++. cmd_lcd(0xc0). display_lcd("Motor rotating"). case 5: motor12=1. if(flag==0) { cmd_lcd(0x01). config(20). } break. flag++. config(80). motor12=0. lcd = 0. //cmd_lcd(0xc0). config(00).. if(flag==0) { cmd_lcd(0x01). 62 . delay_ms(10). cmd_lcd(0x06). //display_lcd("with Low 3speed"). cmd_lcd(0x01). } void cmd_lcd(unsigned char c) { lcd = ((c & 0xf0) | 0x08). lcd = ((c<<4)|0x08). } } void config(unsigned int value ) { unsigned int I . config(00). delay_ms(2). } break. cmd_lcd(0x80). display_lcd("Motor stop"). break. cmd_lcd(0x0c). default: break. while(value) { I = 115. } } /////////////////////////////////////////////////////////////// void init_lcd(void) { cmd_lcd(0x28). lcd = 0. while(I >0) I -.case 6: motor12=0.d=0. value--. flag++. lcd = ((c<<4)|0x0a).j<500. lcd = 0. delay_ms(2). } void delay_ms(unsigned int i) { unsigned int j.} void lcd_data(unsigned char c) { lcd = ((c&0xf0)|0x0a). while(I -->0) { for(j=0. lcd = 0. } void display_lcd(unsigned char *s) { while(*s) lcd_data(*s++).j++). } } 12. RESULT 63 . PROJECT CIRCUIT DIAGRAM: 64 . 13.BIBILIOGRAPHY REFERENCES: BOOKS: 65 . The 8051 Microcontroller Architecture.com LIST OF FIGURES Fig No.GAONKR 2.EMBEDDEDSYSTEMS. WWW.1. 66 . Figure.8051 free projectsinfo.COM 2.GOOGLEARCH. www.COM 4.CHIP. DATA SHEETS OF VARIOUS IC’S 3 . WWW.S.COM 3. WWW. 8051 MANUAL WEB SITE: 1. WWW. Page N o.COM 5.VISUALBASIC. Programming & Applications …… Kenneth J Ayala 4. MICRO CONTROLLERS BY RAMESH.
Copyright © 2024 DOKUMEN.SITE Inc.