|
|
- Diane Sharp
- 7 years ago
- Views:
Transcription
1 SSN COLLEGE OF ENGINEERING DEPARTMENT OF ELECTRICAL & ELECTRONICS ENGINEERING LAB MANUAL EE2356 MICROPROCESSOR & MICRO CONTROLLER LABORATORY DEC 2010-APRIL 2011
2 Expt.No. Name of the experiment 1 Arithmetic operations using 8085 Microprocessor. 2a 2b Sorting of numbers (Ascending & descending) using 8085 Microprocessor. Number conversions (BCD HEX, HEX BCD). 3 Arithmetic operations using 8086 Microprocessor. 4a 4b Interfacing 8 bit ADC Converter with 8085 Microprocessor. Interfacing 8 bit DAC Converter with 8085 Microprocessor. 5 Traffic Light controller using 8085 Microprocessor. 6a Square Wave Generation using b Serial Data Transmission using Interfacing 8279 with 8085 microprocessor 8 8 bit Arithmetic operations using 8051 Microcontroller. 9 Finding the smallest and largest number in an array of numbers using 8051 Microcontroller 10 Interfacing 8 bit DAC Converter with 8051 Microcontroller 11 Interfacing of Stepper Motor with 8051 Microcontroller 12 Interfacing Traffic Light Controller using 8051
3 EXPT 1 ARITHMETIC OPERATIONS USING 8085 AIM: To write the assembly language programs for performing the following arithmetic operations: a) 16 bit binary addition. b) 16 bit binary subtraction. c) 16 bit binary multiplication. d) 16 bit binary division. APPARATUS REQUIRED: Microprocessor kit, Power supply. PROBLEM STATEMENT: Write an ALP in 8085 µp to add and subtract two 16-bit binary numbers stored in the memory locations 4100 & 4101 and 4102 & 4103 and store the result starting from the memory location 4105H. Also provide an instruction in the above program to observe the carry also and store the carry in the memory location 4104H. ALGORITHM: 16 BIT ADDITION: 1 Start. 1. Enter the two 16 bit data in two register pairs HL and DE. 2. Initialize a carry counter register B to zero. 3. Add the contents of register pairs. 4. If a carry is generated, increment the carry counter B. 5. Store the Carry in the B register and the sum, which is in the register pair HL in the memory. 6. Stop.
4 16 BIT SUBTRACTION: 1. Start. 2. Get the two 16 bit data in two of the register pairs. 3. Subtract the Low Order Byte of data1 from that of the data Subtract the How Order Byte of data1 along with borrow from that of the data2. 5. Store the result in memory. 6. Stop. PROBLEM STATEMENT: Write an ALP in 8085 µp to multiply two 16-bit binary numbers stored in the memory locations 4100(LOB) & 4101(HOB) and 4102(LOB) & 4103(HOB) and store the result in the memory location 4104H & 4105H.Write instructions for performing 16-bit division also. 16 BIT MULTIPLICATION. 1. Start. 2. Initialize BC register pair to store the Carry. 3. Store the data 1 and data 2 in DE register pair and SP register. 4. Initialize the HL register pair to zero, to store the result. 5. Multiply by repeated addition of data 1 data 2 times. 6. If carry flag is set during addition., increment the carry register pair. 7. Store the product available in HL pair in memory. 8. Store the contents of the BC register pair which is the carry in memory. 9. Stop BIT DIVISION 1. Start. 1. Store the dividend in HL register pair. 2. Store the divisor in BC register pair 3. Initialize the DE register pair to zero, to carry the quotient. 4. Perform repeated subtraction of divisor from dividend till the dividend is less than the divisor. 5. For every subtraction done, keep on incrementing the quotient register pair DE. 6. Store the remainder pair in memory. 7. Store the quotient in memory.
5 8. Stop. FLOW CHART 16-BIT ADDITION 16-BIT SUBTRACTION INITIALISE CARRY REGISTER LOAD THE TWO NUMBERS LOAD TWO S. IN REGISTER PAIRS ADD THE TWO NUMBERS ANY CARRY INCREMENT CARRY REGISTER STORE THE RESULT INTIALIZE BORROW REGISTER SUBTRACT THE TWO NUMBERS ANY BORROW? INCREMENT CARRY REGISTER STORE THE RESULT
6 16-BIT MULTIPLICATION 16-BIT DIVISION GET MULTIPLIER AND MULTIPLICAND IN REGISTER PAIRS LOAD DIVISOR & DIVIDEND QUOTIENT = 0 PRODUCT=0000 REG. PAIR = REG. PAIR + MULTIPLICAND MULTIPLIER = MULTIPLIER 1 IS MULTIPLIER = 0? DIVIDEND = DIVIDEND DIVISOR QUOTIENT = QUOTIENT + 1 IS DIVIDEND < DIVISOR STORE QUOTIENT STORE REGISTER PAIR
7 EXPT 2 SORTING of NUMBERS USING 8085 (ASCENDING AND DESCENDING ORDER) AIM: To write an Assembly Language Program (ALP) to sort a given array of numbers in ascending and descending order. APPARATUS REQUIRED: Microprocessor kit, Power supply. PROBLEM STATEMENT: An array of length 10 is stored from the location starting from 5000H. Sort it into descending and ascending orders and store the resultant starting from the location 5300H. ALGORITHM: SORTING IN ASCENDING ORDER: a. Start. b. Load the array count in a register. Initialize a carry flag FF to zero. c. Get the first two numbers. d. Compare the numbers and swap them if necessary so that the two numbers are in ascending order. If swapping is done, set the carry flag FF. e. Repeat the steps c and d till the array is completed. f. Repeat the steps c, d and e till carry flag FF remains Reset. f. Stop SORTING IN DESCENDING ORDER: a. Start. b. Load the array count in a register. Initialize a Carry Flag FF to zero. c. Get the first two numbers.
8 d. Compare the numbers and swap them so that the two numbers are in descending order. And set the Carry Flag FF. e. Repeat steps c and d till the array is completed. f. Repeat the steps c, d and e till the Carry Flag FF remains Reset. g. Stop. FLOW CHART: ASCENDING ORDER DESCENDING ORDER INITIALIZE POINTER COUNT = COUNT 1 FLAG = 0 IS POINTER POINTER + 1 TEMP = POINTER POINTER = POINTER + 1 POINTER + 1 = TEMP FLAG=FLAG+1 POINTER = POINTER +1 COUNT = COUNT + 1 INITIALIZE POINTER COUNT = COUNT 1 FLAG = 0 IS POINTER POINTER + 1 TEMP = POINTER POINTER = POINTER + 1 POINTER + 1 = TEMP FLAG=FLAG+1 POINTER = POINTER +1 COUNT = COUNT + 1 IS COUNT = 0 IS COUNT = 0 IS FLAG = 0 IS FLAG = 0
9 EXPT 2b NUMBER CONVERSIONS USING 8085 (BCD TO HEXA AND HEXA TO BCD) AIM: To write an Assembly language program for converting a two digit BCD number (maximum of 99) to hexadecimal and to convert a hexadecimal number (maximum of FFH) to BCD. ALGORITHM: CONVERSION OF BCD TO HEXADECIMAL: 1. Start. 2. Separate the given 8 - bit packed BCD number into two 4 bit unpacked BCD nibbles(bcd1 and BCD2). 3. Multiply BCD2 the most significant nibble, by Add BCD1 to the answer from step3. 5. Store the result and Stop. CONVERSION OF BCD TO HEXADECIMAL: 1. Start. 2. Read the hexadecimal number. 3. Initialize a memory location to store the number of 100 s. Find the number of 100 s and store it in the memory. 4. Find the number of 10 s from the remainder and store it in the next memory location. 5. The remainder now contains the number of 1 s and store it in the next memory location. 7. Stop.
10 FLOW CHART: BCD TO HEX HEXA TO BCD GET MOST SIGNIFICANT DIGIT(MSD) GET DATA CARRY =0 HUNDREDS =0 TENS=0 MSD = MSD x 10 HEX DATA = MSD + LSD (LEAST SIGNIFICANT DIGIT) STORE HEX DATA HUNDREDS =HUNDREDS + 1 TENS = TENS + 1 DATA =DATA -100 IS CARRY =1? DATA =DATA +100 DATA =DATA - 10 IS CARRY = 1? DATA =DATA -10 UNITS =DATA STORE HUNDREDS, TENS, UNITS
11 EXPT : 4 A INTERFACING 8 BIT ADC CONVERTER USING 8085 Aim: To obtain the digital output corresponding to the analog input. Apparatus Required: 1. Microprocessor 8085 Trainer Kit 2. Display Interface Kit 3. Flat Cable Connector 4. Power Supply +5 V Algorithm: 1. Start 2. Initialize control word of 8255 to enable ports A, B as output ports and port C as output port. 3. Initialize accumulator 4. Send contents of accumulator to DAC through port A 5. Obtain comparator output to port c. 6. If accumulator =0 go to step 5else goto step 9 7. Decrement contents of accumulator 8. Go to step 4 9. Call display subroutine to display digital output 10. Stop.
12 Flowchart ACTIVATE THE 8255 CONTROLLER INITIALIZE ACCUMULATOR SEND CONTENTS OF ACCUMULATOR TO DAC THROUGH PORT A OBTAIN COMPARATOR OUTPUT TO PORT C IS ACCUMULATOR = 0? DECREMENT CONTENTS OF ACCUMULATOR CALL DISPLAY SUBROUTINE TO DISPLAY DIGITAL OUTPUT
13 EXPT : 4 B INTERFACING 8 BIT DAC CONVERTER USING 8085 AIM:- microprocessor trainer kit. To generate different types of waveforms by interfacing a DAC with a EQUIPMENT REQUIRED Intel 8085 based MPS 85 2 trainer kit, DAC interface card, 26 pin flat cable connector, CRO with probe. ALGORITHM:- SQUARE WAVE FORM 1. Initialize the control word register i.e., 8255 as input port. 2. Send 00 to port A of Call delay subroutine 4. Send FF to port A of Call delay subroutine 6. Repeat the step 2 onwards. SAW TOOTH WAVE FORM 1. Initialize the control word register. 2. Initialize the accumulator content 3. Send to port A of Increment the accumulator content 5. If zero flag is not set then repeat the step 3 onwards, otherwise repeat the step 2 onwards.
14 FLOW CHART: Square Waveform: Saw tooth Waveform: ACTIVATE THE 8255 CONTROLLER ACTIVATE THE 8255 CONTROLLER SEND 00 TO PORT A ACC = 00 CALL DISPLAY SUBROUTINE SEND FF TO PORT CALL DISPLAY SUBROUTINE SEND ACC TO PORT A ACC = ACC + 1 IF Z =0
15 EXPT. :5 TRAFFIC LIGHT CONTROLLER USING 8085 MICROPROCESSOR AIM:- To write an Assembly language Programme for traffic light controller. EQUIPMENT REQUIRED 8085 microprocessor kit and Power Supply. ALGORITHM:- 1. Start. 2. Write the control word to initialize 8255.Obtain the data for each direction and store in the memory. 3. Initialize a counter to indicate the number of directions. 4. Initialize HL Pair to the starting address of the data.. 5. Check the result. 6. Decrement the counter and repeat step 3 till counter becomes zero. 7. Stop.
16 FLOW CHART TRAFFIC CONTROLLER Write control word to initialize 8255 Initialize a counter. Initialize HL pair to 9000h Call Display Program Introduce a Delay of 4 Seconds Call Display Program Introduce a Delay of 4 Sec. Decrement the counter COUNTER = 0? Call Display Program Introduce a Delay Of 4 Sec.
17 FLOW CHART DISPLAY PROGRAM DISPLAY SEND CONTROL WORD TO ACC FROM MEMORY OUTPUT THE DATA TO A PORT INCREMENT HL REG. PAIR CONTENT SEND CONTROL WORD TO ACC FROM MEMORY OUTPUT THE DATA TO A PORT INCREMENT HL REG. PAIR CONTENT SEND CONTROL WORD FROM MEMORY TO ACC. OUTPUT THE DATA TO PORT C INCREMENT HL REG. PAIR CONTENT RETURN
18 EXPT.. : 6 A SQUARE WAVE GENERATION USING 8254 AIM: To interface 8254 with 8085 microprocessor and generate a square wave ALGORITHM 1. Start 2. Write control word to initialize 8254 in mode 3 3. Load the LSB of the count and output in channel 0 4. Load the MSB of the count and output in channel 0 5. Stop. FLOW CHART Write control word to initialize 8254 in mode 3 Output the LSB and MSB of the count in channel 0
19 EXPT.. : 6 B SERIAL DATA TRANSMISSION USING 8251 AIM: To interface 8251 with 8085 microprocessor and to check the transmission and reception of a character. ALGORITHM For transmitting the data 1. Start 2. Write control word to initialize 8254 in mode 3 3. Load the LSB of the count and output in channel 0 4. Load the MSB of the count and output in channel 0 5. Write mode instruction word and command instruction word for Output the data to be transmitted to data register and enable an interrupt. For Receiving the data 7. Read the data from the data register 8. Store the data to a memory location 9. Stop
20 FLOW CHART For transmitting the data Write control word to initialize 8254 in mode 3 Output the LSB and MSB of the count in channel 0 Write mode instruction word and command instruction word for 8251 Output the data in data register
21 FLOW CHART For receiving the data Read the data from data register Store the data in memory location
22 EXPT.. : 7 INTERFACING 8279 WITH 8085 MICROPROCESSOR AIM: To interface 8279 with 8085 microprocessor and display the rolling message HELP US ALGORITHM 5. Start 6. Load the HL pair with the starting address of the message to be displayed and initialize a counter. 7. Initialize Output the data from memory to the data register 9. Call delay. 10. Increment the pointer and decrement the counter. 11. Repeat until counter becomes Stop.
23 FLOW CHART Load the HL pair with the starting address of the message to be displayed and initialize a counter. Initialize 8279 and Output the data from memory to the data register No Call Delay SUBROUTINE Increment the pointer Decrement the counter Is the counter value 0 Yes
24 i. e x e EXPT 8 8 BIT ARITHMETIC OPERATIONS USING 8051 AIM: To write the assembly language programs for performing the following arithmetic operations: a) 8 bit binary addition. b) 8 bit binary subtraction. c) 8 bit binary multiplication. d) 8 bit binary division. APPARATUS REQUIRED: Microcontroller kit. PROBLEM STATEMENT: Write an ALP in 8051 µc to perform 8-bit arithmetic operations for the numbers stored in the memory location 4500H and 4501H and store the result in the memory location 4600H.Also provide an instruction in the above program to consider the carry also and store the carry in the memory location 4601H. ALGORITHMS: 8 BIT ADDITION: 1. Start 2. Initialize carry register to zero. 3. Store data 1 in accumulator. 4. Store date 2 in B register. 5. Load the data pointer with external memory address 6. Add the contents of B register to that of the accumulator. 7. If a carry is generated, increment the carry counter. 8. Store the contents of the Accumulator, which is the sum in memory. 9. Move the carry register contents to Accumulator and store the same in memory. 10. Stop.
25 8 BIT SUBTRACTION: 1. Start 2. Initialize Barrow register to zero. 3. Store data 1 in accumulator and date 2 in B register respectively. 4. Subtract the contents of B register to that of the accumulator. 5. Load the data pointer with external memory address 6. If a borrow is generated, increment the borrow counter. 7. Store the contents of the Accumulator, which is the difference in memory. 8. Move the barrow register contents to Accumulator and store the same in memory. 9. Stop. 8 BIT MULTIPLICATION: 1. Start. 2. Store data 1 in register Accumulator. 3. Store data 2 in register B. 4. Load the data pointer with external memory address 5. Multiply A and B register 6. Move the A and B register contents to the memory 7. Stop. 8 BIT DIVISION: 1. Start. 2. Store data 1 in register Accumulator. 3. Store data 2 in register B. 4. Load the data pointer with external memory address 5. Divide A and B register 6. Move the A and B register contents to the memory 7. Stop.
26 FLOWCHART: 8-BIT ADDITION 8-BIT SUBTRACTION SET UP COUNTER (CARRY) SET UP COUNTER (CARRY) GET FIRST OPERAND TO B GET SECOND OPERAND TO A A = A + B IS THERE ANY CARRY STORE THE SUM COUNTER = COUNTER + 1 GET FIRST OPERAND TO A SUBTRACT SECOND OPERAND FROM MEMORY ANY CARRY? STORE THE DIFFERENCE STORE THE CARRY COUNTER = COUNTER + 1 STORE THE CARRY
27 8-BIT MULTIPLICATION 8-BIT DIVISION GET MULTIPLIER IN A AND MULTIPLICAND IN B register GET DIVIDEND IN A AND DIVISOR IN B register Multiply the content of A and B register Load Data Pointer with External Memory Address Move the content of A and B to external Address Divide the content of A and B register Load Data Pointer with External Memory Address Move the content of A and B to external Address
28 EXPT 9 FINDING THE SMALLEST AND LARGEST NUMBER IN AN ARRAY OF NUMBERS USING 8051 AIM: To write Assembly Language Programs (ALP) to find the maximum and minimum of an array of numbers. APPARATUS REQUIRED: Microcontroller Kit PROBLEM STATEMENT: An array of length 10 is stored from the location starting from 4600H. Sort it into descending and ascending orders and store the resultant starting from the location 4700H. ALGORITHM: FINDING THE SMALLEST NUMBER OF THE ARRAY: 1. Start. 2. Load the array count in a register. 3. Get the first two numbers. 4. Compare the numbers and swap them if necessary so that the two numbers are in descending order. 5. Repeat the steps 3 and 4 till the array is completed. 6. Repeat the steps 3, 4 and5 and store the smallest number.. 7. Stop
29 FINDING THE LARGEST NUMBER OF THE ARRAY: 1. Start. 2. Load the array count in a register. 3. Get the first two numbers. 4. Compare the numbers and swap them so that the two numbers are in ascending order. 5. Repeat steps 3 and 4 till the array is completed. 6. Repeat the steps 3, 4 and 5 and store the largest number as the result in memory. 7. Stop.
30 FLOW CHART: FINDING THE MINIMUM AND MAXIMUM NUMBER OF AN ARRAY INITIALIZE POINTER COUNT = COUNT 1 INITIALIZE POINTER COUNT = COUNT 1 IS POINTER POINTER + 1 TEMP = POINTER POINTER = POINTER + 1 POINTER + 1 = TEMP POINTER = POINTER +1 COUNT = COUNT + 1 IS COUNT = 0 IS POINTER POINTER + 1 TEMP = POINTER POINTER = POINTER + 1 POINTER + 1 = TEMP POINTER = POINTER +1 COUNT = COUNT + 1 IS COUNT = 0 STORE THE POINTER RESULT STORE THE POINTER RESULT
31 EXPT. : 10 INTERFACING DAC CONVERTER USING 8051 AIM:- To generate different types of waveforms by interfacing a DAC with a microcontroller. EQUIPMENT REQUIRED Intel 8051 based MPS 85 2 trainer kit, DAC interface card, 26 pin flat cable connector, CRO with probe. ALGORITHM:- SQUARE WAVE FORM 1. Initialize the control word register i.e., 8255 as input port. 2. Send 00 to port A of Call delay subroutine 4. Send FF to port A of Call delay subroutine 6. Repeat the step 2 onwards. SAW TOOTH WAVE FORM 1. Initialize the control word register. 2. Initialize the accumulator content 3. Send to port A of Increment the accumulator content 5. If zero flag is not set then repeat the step 3 onwards, otherwise repeat the step 2 onwards.
32 FLOW CHART: Square Waveform: Saw tooth Waveform: ACTIVATE THE 8255 CONTROLLER ACTIVATE THE 8255 CONTROLLER SEND 00 TO PORT A CALL DISPLAY SUBROUTINE SEND FF TO PORT CALL DISPLAY SUBROUTINE ACC = 00 SEND ACC TO PORT A ACC = ACC + 1 IF Z =0
33
LABORATORY MANUAL EE0310 MICROPROCESSOR & MICROCONTROLLER LAB
LABORATORY MANUAL EE0310 MICROPROCESSOR & MICROCONTROLLER LAB DEPARTMENT OF ELECTRICAL & ELECTRONICS ENGINEERING FACULTY OF ENGINEERING & TECHNOLOGY SRM UNIVERSITY, Kattankulathur 603 203 1 LIST OF EXEPRIMENTS
More informationDEPARTMENT OF COMPUTER SCIENCE & ENGINEERING Question Bank Subject Name: EC6504 - Microprocessor & Microcontroller Year/Sem : II/IV
DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING Question Bank Subject Name: EC6504 - Microprocessor & Microcontroller Year/Sem : II/IV UNIT I THE 8086 MICROPROCESSOR 1. What is the purpose of segment registers
More information8085 MICROPROCESSOR PROGRAMS
8085 MICROPROCESSOR PROGRAMS 1 ADDITION OF TWO 8 BIT NUMBERS AIM: To perform addition of two 8 bit numbers using 8085. ALGORITHM: 1) Start the program by loading the first data into Accumulator. 2) Move
More informationPROGRAMMABLE LOGIC CONTROLLERS Unit code: A/601/1625 QCF level: 4 Credit value: 15 TUTORIAL OUTCOME 2 Part 1
UNIT 22: PROGRAMMABLE LOGIC CONTROLLERS Unit code: A/601/1625 QCF level: 4 Credit value: 15 TUTORIAL OUTCOME 2 Part 1 This work covers part of outcome 2 of the Edexcel standard module. The material is
More informationInterfacing Analog to Digital Data Converters
Converters In most of the cases, the PIO 8255 is used for interfacing the analog to digital converters with microprocessor. We have already studied 8255 interfacing with 8086 as an I/O port, in previous
More informationMICROPROCESSOR. Exclusive for IACE Students www.iace.co.in iacehyd.blogspot.in Ph: 9700077455/422 Page 1
MICROPROCESSOR A microprocessor incorporates the functions of a computer s central processing unit (CPU) on a single Integrated (IC), or at most a few integrated circuit. It is a multipurpose, programmable
More information8051 MICROCONTROLLER COURSE
8051 MICROCONTROLLER COURSE Objective: 1. Familiarization with different types of Microcontroller 2. To know 8051 microcontroller in detail 3. Programming and Interfacing 8051 microcontroller Prerequisites:
More information3. Convert a number from one number system to another
3. Convert a number from one number system to another Conversion between number bases: Hexa (16) Decimal (10) Binary (2) Octal (8) More Interest Way we need conversion? We need decimal system for real
More informationMICROPROCESSOR AND MICROCOMPUTER BASICS
Introduction MICROPROCESSOR AND MICROCOMPUTER BASICS At present there are many types and sizes of computers available. These computers are designed and constructed based on digital and Integrated Circuit
More informationLSN 2 Number Systems. ECT 224 Digital Computer Fundamentals. Department of Engineering Technology
LSN 2 Number Systems Department of Engineering Technology LSN 2 Decimal Number System Decimal number system has 10 digits (0-9) Base 10 weighting system... 10 5 10 4 10 3 10 2 10 1 10 0. 10-1 10-2 10-3
More information2011, The McGraw-Hill Companies, Inc. Chapter 3
Chapter 3 3.1 Decimal System The radix or base of a number system determines the total number of different symbols or digits used by that system. The decimal system has a base of 10 with the digits 0 through
More informationM6800. Assembly Language Programming
M6800 Assembly Language Programming 1 3. MC6802 MICROPROCESSOR MC6802 microprocessor runs in 1MHz clock cycle. It has 64 Kbyte memory address capacity using 16-bit addressing path (A0-A15). The 8-bit data
More information8-bit RISC Microcontroller. Application Note. AVR236: CRC Check of Program Memory
AVR236: CRC Check of Program Memory Features CRC Generation and Checking of Program Memory Supports all AVR Controllers with LPM Instruction Compact Code Size, 44 Words (CRC Generation and CRC Checking)
More informationMicrocontroller Basics A microcontroller is a small, low-cost computer-on-a-chip which usually includes:
Microcontroller Basics A microcontroller is a small, low-cost computer-on-a-chip which usually includes: An 8 or 16 bit microprocessor (CPU). A small amount of RAM. Programmable ROM and/or flash memory.
More informationNumber Systems. Introduction / Number Systems
Number Systems Introduction / Number Systems Data Representation Data representation can be Digital or Analog In Analog representation values are represented over a continuous range In Digital representation
More informationCPEN 214 - Digital Logic Design Binary Systems
CPEN 4 - Digital Logic Design Binary Systems C. Gerousis Digital Design 3 rd Ed., Mano Prentice Hall Digital vs. Analog An analog system has continuous range of values A mercury thermometer Vinyl records
More informationDecimal to Binary Conversion
Decimal to Binary Conversion A tool that makes the conversion of decimal values to binary values simple is the following table. The first row is created by counting right to left from one to eight, for
More informationOct: 50 8 = 6 (r = 2) 6 8 = 0 (r = 6) Writing the remainders in reverse order we get: (50) 10 = (62) 8
ECE Department Summer LECTURE #5: Number Systems EEL : Digital Logic and Computer Systems Based on lecture notes by Dr. Eric M. Schwartz Decimal Number System: -Our standard number system is base, also
More informationZ80 Instruction Set. Z80 Assembly Language
75 Z80 Assembly Language The assembly language allows the user to write a program without concern for memory addresses or machine instruction formats. It uses symbolic addresses to identify memory locations
More informationIntroduction to Microcontrollers
Introduction to Microcontrollers Motorola M68HC11 Specs Assembly Programming Language BUFFALO Topics of Discussion Microcontrollers M68HC11 Package & Pinouts Accumulators Index Registers Special Registers
More informationEE 261 Introduction to Logic Circuits. Module #2 Number Systems
EE 261 Introduction to Logic Circuits Module #2 Number Systems Topics A. Number System Formation B. Base Conversions C. Binary Arithmetic D. Signed Numbers E. Signed Arithmetic F. Binary Codes Textbook
More informationMACHINE ARCHITECTURE & LANGUAGE
in the name of God the compassionate, the merciful notes on MACHINE ARCHITECTURE & LANGUAGE compiled by Jumong Chap. 9 Microprocessor Fundamentals A system designer should consider a microprocessor-based
More information8085 INSTRUCTION SET
DATA TRANSFER INSTRUCTIONS Opcode Operand Description 8085 INSTRUCTION SET INSTRUCTION DETAILS Copy from source to destination OV Rd, Rs This instruction copies the contents of the source, Rs register
More informationNumber and codes in digital systems
Number and codes in digital systems Decimal Numbers You are familiar with the decimal number system because you use them everyday. But their weighted structure is not understood. In the decimal number
More informationBinary Numbers. Binary Octal Hexadecimal
Binary Numbers Binary Octal Hexadecimal Binary Numbers COUNTING SYSTEMS UNLIMITED... Since you have been using the 10 different digits 0, 1, 2, 3, 4, 5, 6, 7, 8, and 9 all your life, you may wonder how
More information150127-Microprocessor & Assembly Language
Chapter 3 Z80 Microprocessor Architecture The Z 80 is one of the most talented 8 bit microprocessors, and many microprocessor-based systems are designed around the Z80. The Z80 microprocessor needs an
More informationELEG3924 Microprocessor Ch.7 Programming In C
Department of Electrical Engineering University of Arkansas ELEG3924 Microprocessor Ch.7 Programming In C Dr. Jingxian Wu wuj@uark.edu OUTLINE 2 Data types and time delay I/O programming and Logic operations
More informationModbus RTU Communications RX/WX and MRX/MWX
15 Modbus RTU Communications RX/WX and MRX/MWX In This Chapter.... Network Slave Operation Network Master Operation: RX / WX Network Master Operation: DL06 MRX / MWX 5 2 D0 Modbus Network Slave Operation
More information1 Classical Universal Computer 3
Chapter 6: Machine Language and Assembler Christian Jacob 1 Classical Universal Computer 3 1.1 Von Neumann Architecture 3 1.2 CPU and RAM 5 1.3 Arithmetic Logical Unit (ALU) 6 1.4 Arithmetic Logical Unit
More informationGoals. Unary Numbers. Decimal Numbers. 3,148 is. 1000 s 100 s 10 s 1 s. Number Bases 1/12/2009. COMP370 Intro to Computer Architecture 1
Number Bases //9 Goals Numbers Understand binary and hexadecimal numbers Be able to convert between number bases Understand binary fractions COMP37 Introduction to Computer Architecture Unary Numbers Decimal
More informationBinary Representation. Number Systems. Base 10, Base 2, Base 16. Positional Notation. Conversion of Any Base to Decimal.
Binary Representation The basis of all digital data is binary representation. Binary - means two 1, 0 True, False Hot, Cold On, Off We must be able to handle more than just values for real world problems
More informationComputer Science 281 Binary and Hexadecimal Review
Computer Science 281 Binary and Hexadecimal Review 1 The Binary Number System Computers store everything, both instructions and data, by using many, many transistors, each of which can be in one of two
More informationCS201: Architecture and Assembly Language
CS201: Architecture and Assembly Language Lecture Three Brendan Burns CS201: Lecture Three p.1/27 Arithmetic for computers Previously we saw how we could represent unsigned numbers in binary and how binary
More informationNUMBER SYSTEMS. 1.1 Introduction
NUMBER SYSTEMS 1.1 Introduction There are several number systems which we normally use, such as decimal, binary, octal, hexadecimal, etc. Amongst them we are most familiar with the decimal number system.
More informationDigital System Design Prof. D Roychoudhry Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur
Digital System Design Prof. D Roychoudhry Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur Lecture - 04 Digital Logic II May, I before starting the today s lecture
More informationModbus Protocol. PDF format version of the MODBUS Protocol. http://www.http://www.modicon.com/techpubs/toc7.html. The original was found at:
Modbus Protocol PDF format version of the MODBUS Protocol The original was found at: http://www.http://www.modicon.com/techpubs/toc7.html (In case of any discrepancies, that version should be considered
More informationLecture 11: Number Systems
Lecture 11: Number Systems Numeric Data Fixed point Integers (12, 345, 20567 etc) Real fractions (23.45, 23., 0.145 etc.) Floating point such as 23. 45 e 12 Basically an exponent representation Any number
More informationASCII and BCD Arithmetic. Chapter 11 S. Dandamudi
ASCII and BCD Arithmetic Chapter 11 S. Dandamudi Outline Representation of Numbers ASCII representation BCD representation» Unpacked BCD» Packed BCD Processing ASCII numbers» ASCII addition» ASCII subtraction»
More informationTable 1 below is a complete list of MPTH commands with descriptions. Table 1 : MPTH Commands. Command Name Code Setting Value Description
MPTH: Commands Table 1 below is a complete list of MPTH commands with descriptions. Note: Commands are three bytes long, Command Start Byte (default is 128), Command Code, Setting value. Table 1 : MPTH
More informationPART B QUESTIONS AND ANSWERS UNIT I
PART B QUESTIONS AND ANSWERS UNIT I 1. Explain the architecture of 8085 microprocessor? Logic pin out of 8085 microprocessor Address bus: unidirectional bus, used as high order bus Data bus: bi-directional
More informationThe string of digits 101101 in the binary number system represents the quantity
Data Representation Section 3.1 Data Types Registers contain either data or control information Control information is a bit or group of bits used to specify the sequence of command signals needed for
More informationC Programming. for Embedded Microcontrollers. Warwick A. Smith. Postbus 11. Elektor International Media BV. 6114ZG Susteren The Netherlands
C Programming for Embedded Microcontrollers Warwick A. Smith Elektor International Media BV Postbus 11 6114ZG Susteren The Netherlands 3 the Table of Contents Introduction 11 Target Audience 11 What is
More informationBinary Representation
Binary Representation The basis of all digital data is binary representation. Binary - means two 1, 0 True, False Hot, Cold On, Off We must tbe able to handle more than just values for real world problems
More informationMICROPROCESSOR BCA IV Sem MULTIPLE CHOICE QUESTIONS
MICROPROCESSOR BCA IV Sem MULTIPLE CHOICE QUESTIONS 1) Which is the microprocessor comprises: a. Register section b. One or more ALU c. Control unit 2) What is the store by register? a. data b. operands
More informationAN617. Fixed Point Routines FIXED POINT ARITHMETIC INTRODUCTION. Thi d t t d ith F M k 4 0 4. Design Consultant
Thi d t t d ith F M k 4 0 4 Fixed Point Routines AN617 Author: INTRODUCTION Frank J. Testa Design Consultant This application note presents an implementation of the following fixed point math routines
More informationPROBLEMS (Cap. 4 - Istruzioni macchina)
98 CHAPTER 2 MACHINE INSTRUCTIONS AND PROGRAMS PROBLEMS (Cap. 4 - Istruzioni macchina) 2.1 Represent the decimal values 5, 2, 14, 10, 26, 19, 51, and 43, as signed, 7-bit numbers in the following binary
More informationUseful Number Systems
Useful Number Systems Decimal Base = 10 Digit Set = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9} Binary Base = 2 Digit Set = {0, 1} Octal Base = 8 = 2 3 Digit Set = {0, 1, 2, 3, 4, 5, 6, 7} Hexadecimal Base = 16 = 2
More information8-bit Microcontroller. Application. Note. AVR204: BCD Arithmetics. Features. Introduction. 16-bit Binary to 5-digit BCD Conversion bin2bcd16
AVR204: BCD Arithmetics Features Conversion 16 Bits 5 Digits, 8 Bits 2 Digits 2-digit Addition and Subtraction Superb Speed and Code Density Runable Example Program Introduction This application note lists
More informationLecture 8: Binary Multiplication & Division
Lecture 8: Binary Multiplication & Division Today s topics: Addition/Subtraction Multiplication Division Reminder: get started early on assignment 3 1 2 s Complement Signed Numbers two = 0 ten 0001 two
More informationCDA 3200 Digital Systems. Instructor: Dr. Janusz Zalewski Developed by: Dr. Dahai Guo Spring 2012
CDA 3200 Digital Systems Instructor: Dr. Janusz Zalewski Developed by: Dr. Dahai Guo Spring 2012 Outline Data Representation Binary Codes Why 6-3-1-1 and Excess-3? Data Representation (1/2) Each numbering
More informationDigital Design. Assoc. Prof. Dr. Berna Örs Yalçın
Digital Design Assoc. Prof. Dr. Berna Örs Yalçın Istanbul Technical University Faculty of Electrical and Electronics Engineering Office Number: 2318 E-mail: siddika.ors@itu.edu.tr Grading 1st Midterm -
More informationMEP Y9 Practice Book A
1 Base Arithmetic 1.1 Binary Numbers We normally work with numbers in base 10. In this section we consider numbers in base 2, often called binary numbers. In base 10 we use the digits 0, 1, 2, 3, 4, 5,
More information(Refer Slide Time: 00:01:16 min)
Digital Computer Organization Prof. P. K. Biswas Department of Electronic & Electrical Communication Engineering Indian Institute of Technology, Kharagpur Lecture No. # 04 CPU Design: Tirning & Control
More informationMBP_MSTR: Modbus Plus Master 12
Unity Pro MBP_MSTR 33002527 07/2011 MBP_MSTR: Modbus Plus Master 12 Introduction This chapter describes the MBP_MSTR block. What s in this Chapter? This chapter contains the following topics: Topic Page
More informationMonitoring of Intravenous Drip Rate
Monitoring of Intravenous Drip Rate Vidyadhar V. Kamble, Prem C. Pandey, Chandrashekar P. Gadgil, and Dinesh S. Choudhary Abstract A drip rate meter, for monitoring intravenous infusion, is developed using
More information8254 PROGRAMMABLE INTERVAL TIMER
PROGRAMMABLE INTERVAL TIMER Y Y Y Compatible with All Intel and Most Other Microprocessors Handles Inputs from DC to 10 MHz 8 MHz 8254 10 MHz 8254-2 Status Read-Back Command Y Y Y Y Y Six Programmable
More informationDivide: Paper & Pencil. Computer Architecture ALU Design : Division and Floating Point. Divide algorithm. DIVIDE HARDWARE Version 1
Divide: Paper & Pencil Computer Architecture ALU Design : Division and Floating Point 1001 Quotient Divisor 1000 1001010 Dividend 1000 10 101 1010 1000 10 (or Modulo result) See how big a number can be
More informationENTTEC Pixie Driver API Specification
ENTTEC Pixie Driver API Specification Purpose This document specifies the interface requirements for PC based application programs to use the ENTTEC Pixie Driver board to drive RGB or RGBW type LED strips.
More informationBCD (ASCII) Arithmetic. Where and Why is BCD used? Packed BCD, ASCII, Unpacked BCD. BCD Adjustment Instructions AAA. Example
BCD (ASCII) Arithmetic We will first look at unpacked BCD which means strings that look like '4567'. Bytes then look like 34h 35h 36h 37h OR: 04h 05h 06h 07h x86 processors also have instructions for packed
More informationTimer A (0 and 1) and PWM EE3376
Timer A (0 and 1) and PWM EE3376 General Peripheral Programming Model Each peripheral has a range of addresses in the memory map peripheral has base address (i.e. 0x00A0) each register used in the peripheral
More informationProgrammer s Model = model of µc useful to view hardware during execution of software instructions
HC12/S12 Programmer s Model Programmer s Model = model of µc useful to view hardware during execution of software instructions Recall: General Microcontroller/Computer Architecture note: Control Unit &
More informationA single register, called the accumulator, stores the. operand before the operation, and stores the result. Add y # add y from memory to the acc
Other architectures Example. Accumulator-based machines A single register, called the accumulator, stores the operand before the operation, and stores the result after the operation. Load x # into acc
More informationDAC Digital To Analog Converter
DAC Digital To Analog Converter DAC Digital To Analog Converter Highlights XMC4000 provides two digital to analog converters. Each can output one analog value. Additional multiple analog waves can be generated
More information4 Character 5x7 LED Matrix Display
Mini project report on 4 Character 5x7 LED Matrix Display Submitted by Agarwal Vikas, MTech II, CEDT K.Sreenivasulu M.E (Micro) II, CEDT CENTRE FOR ELECTRONICS DESIGN AND TECHNOLOGY INDIAN INSTITUTE OF
More informationNotes on Assembly Language
Notes on Assembly Language Brief introduction to assembly programming The main components of a computer that take part in the execution of a program written in assembly code are the following: A set of
More informationSystems I: Computer Organization and Architecture
Systems I: Computer Organization and Architecture Lecture 2: Number Systems and Arithmetic Number Systems - Base The number system that we use is base : 734 = + 7 + 3 + 4 = x + 7x + 3x + 4x = x 3 + 7x
More informationNumber Conversions Dr. Sarita Agarwal (Acharya Narendra Dev College,University of Delhi)
Conversions Dr. Sarita Agarwal (Acharya Narendra Dev College,University of Delhi) INTRODUCTION System- A number system defines a set of values to represent quantity. We talk about the number of people
More informationLecture N -1- PHYS 3330. Microcontrollers
Lecture N -1- PHYS 3330 Microcontrollers If you need more than a handful of logic gates to accomplish the task at hand, you likely should use a microcontroller instead of discrete logic gates 1. Microcontrollers
More informationBINARY CODED DECIMAL: B.C.D.
BINARY CODED DECIMAL: B.C.D. ANOTHER METHOD TO REPRESENT DECIMAL NUMBERS USEFUL BECAUSE MANY DIGITAL DEVICES PROCESS + DISPLAY NUMBERS IN TENS IN BCD EACH NUMBER IS DEFINED BY A BINARY CODE OF 4 BITS.
More informationThe Answer to the 14 Most Frequently Asked Modbus Questions
Modbus Frequently Asked Questions WP-34-REV0-0609-1/7 The Answer to the 14 Most Frequently Asked Modbus Questions Exactly what is Modbus? Modbus is an open serial communications protocol widely used in
More informationData Acquisition Module with I2C interface «I2C-FLEXEL» User s Guide
Data Acquisition Module with I2C interface «I2C-FLEXEL» User s Guide Sensors LCD Real Time Clock/ Calendar DC Motors Buzzer LED dimming Relay control I2C-FLEXEL PS2 Keyboards Servo Motors IR Remote Control
More informationDS1621 Digital Thermometer and Thermostat
Digital Thermometer and Thermostat www.dalsemi.com FEATURES Temperature measurements require no external components Measures temperatures from 55 C to +125 C in 0.5 C increments. Fahrenheit equivalent
More informationChapter 2. Binary Values and Number Systems
Chapter 2 Binary Values and Number Systems Numbers Natural numbers, a.k.a. positive integers Zero and any number obtained by repeatedly adding one to it. Examples: 100, 0, 45645, 32 Negative numbers A
More informationWhy using ATmega16? University of Wollongong Australia. 7.1 Overview of ATmega16. Overview of ATmega16
s schedule Lecture 7 - C Programming for the Atmel AVR School of Electrical, l Computer and Telecommunications i Engineering i University of Wollongong Australia Week Lecture (2h) Tutorial (1h) Lab (2h)
More informationDS1621 Digital Thermometer and Thermostat
www.maxim-ic.com FEATURES Temperature measurements require no external components Measures temperatures from -55 C to +125 C in 0.5 C increments. Fahrenheit equivalent is -67 F to 257 F in 0.9 F increments
More informationADS9850 Signal Generator Module
1. Introduction ADS9850 Signal Generator Module This module described here is based on ADS9850, a CMOS, 125MHz, and Complete DDS Synthesizer. The AD9850 is a highly integrated device that uses advanced
More informationModicon Modbus Protocol Reference Guide. PI MBUS 300 Rev. J
Modicon Modbus Protocol Reference Guide PI MBUS 300 Rev. J 1 Modicon Modbus Protocol Reference Guide PI MBUS 300 Rev. J June 1996 MODICON, Inc., Industrial Automation Systems One High Street North Andover,
More informationETEC 2301 Programmable Logic Devices. Chapter 10 Counters. Shawnee State University Department of Industrial and Engineering Technologies
ETEC 2301 Programmable Logic Devices Chapter 10 Counters Shawnee State University Department of Industrial and Engineering Technologies Copyright 2007 by Janna B. Gallaher Asynchronous Counter Operation
More informationPublication 0300129-02 Rev. C SIEMENS. (S5 Communications) Reference
Publication 0300129-02 Rev. C SIEMENS (S5 Communications) Reference IMPORTANT NOTES 1. READ ALL OF THE INFORMATION CONTAINED IN THIS MANUAL BEFORE YOU INSTALL THE PRODUCT. 2. The information contained
More informationAUTOMATIC NIGHT LAMP WITH MORNING ALARM USING MICROPROCESSOR
AUTOMATIC NIGHT LAMP WITH MORNING ALARM USING MICROPROCESSOR INTRODUCTION This Project "Automatic Night Lamp with Morning Alarm" was developed using Microprocessor. It is the Heart of the system. The sensors
More informationDigital To Analog Converter with Sine Wave Output
Digital To Analog Converter with Sine Wave Output Overview In this Lab we will build a resistive ladder network and use the BASIC Stamp to generate the digital data for the D/A conversions. PBASIC will
More informationSPROG DCC Decoder Programmer
SPROG DCC Decoder Programmer Operating Manual Firmware Version 3.4 April 2004 2004 Andrew Crosland web: http://www.sheerstock.fsnet.co.uk/dcc/sprog e-mail: dcc@sheerstock.fsnet.co.uk Disclaimer You build,
More informationCOMPSCI 210. Binary Fractions. Agenda & Reading
COMPSCI 21 Binary Fractions Agenda & Reading Topics: Fractions Binary Octal Hexadecimal Binary -> Octal, Hex Octal -> Binary, Hex Decimal -> Octal, Hex Hex -> Binary, Octal Animation: BinFrac.htm Example
More informationplc numbers - 13.1 Encoded values; BCD and ASCII Error detection; parity, gray code and checksums
plc numbers - 3. Topics: Number bases; binary, octal, decimal, hexadecimal Binary calculations; s compliments, addition, subtraction and Boolean operations Encoded values; BCD and ASCII Error detection;
More informationSection 1.4 Place Value Systems of Numeration in Other Bases
Section.4 Place Value Systems of Numeration in Other Bases Other Bases The Hindu-Arabic system that is used in most of the world today is a positional value system with a base of ten. The simplest reason
More informationU:\montages\dominique\servo\moteur_AV_AR\program\moteur_AV_AR.asm jeudi 28 avril 2011 10:32
Norton Junior Moteur PWM AV - AR pour SLE BRESSUIRE PORTA ------------------------------------------------------- 0 = Entrée Servo 1 = PWM moteur 2 = Strap mode 3 = 4 = 5 = Relay AV - AR $Include 'C:\pemicro\ics08qtqyz\qtqy_registers.inc'
More informationMicrotronics technologies Mobile: 99707 90092
For more Project details visit: http://www.projectsof8051.com/rfid-based-attendance-management-system/ Code Project Title 1500 RFid Based Attendance System Synopsis for RFid Based Attendance System 1.
More informationPseudo code Tutorial and Exercises Teacher s Version
Pseudo code Tutorial and Exercises Teacher s Version Pseudo-code is an informal way to express the design of a computer program or an algorithm in 1.45. The aim is to get the idea quickly and also easy
More informationKCPSM6 Instruction Set
KPSM6 Instruction Set aaa : 2-bit address to FFF kk : 8-bit constant to FF pp : 8-bit port ID to FF p : 4-bit port ID to F ss : 8-bit scratch pad location to FF x : Register within bank s to sf y : Register
More informationisppac-powr1220at8 I 2 C Hardware Verification Utility User s Guide
November 2005 Introduction Application Note AN6067 The isppac -POWR1220AT8 device from Lattice is a full-featured second-generation Power Manager chip. As part of its feature set, this device supports
More informationSoftware Manual RS232 Laser Merge Module. Document # SU-256521-09 Rev A
Laser Merge Module Document # SU-256521-09 Rev A The information presented in this document is proprietary to Spectral Applied Research Inc. and cannot be used for any purpose other than that for which
More informationPOCKET SCOPE 2. The idea 2. Design criteria 3
POCKET SCOPE 2 The idea 2 Design criteria 3 Microcontroller requirements 3 The microcontroller must have speed. 3 The microcontroller must have RAM. 3 The microcontroller must have secure Flash. 3 The
More informationLecture 3 Addressing Modes, Instruction Samples, Machine Code, Instruction Execution Cycle
Lecture 3 Addressing Modes, Instruction Samples, Machine Code, Instruction Execution Cycle Contents 3.1. Register Transfer Notation... 2 3.2. HCS12 Addressing Modes... 2 1. Inherent Mode (INH)... 2 2.
More informationeztcp Technical Document Modbus/TCP of eztcp Caution: Specifications of this document may be changed without prior notice for improvement.
eztcp Technical Document Modbus/TCP of eztcp Version 1.3 Caution: Specifications of this document may be changed without prior notice for improvement. Sollae Systems Co., Ltd. http://www.sollae.co.kr Contents
More informationARM Thumb Microcontrollers. Application Note. Software ISO 7816 I/O Line Implementation. Features. Introduction
Software ISO 7816 I/O Line Implementation Features ISO 7816-3 compliant (direct convention) Byte reception and transmission with parity check Retransmission on error detection Automatic reception at the
More informationNTE2053 Integrated Circuit 8 Bit MPU Compatible A/D Converter
NTE2053 Integrated Circuit 8 Bit MPU Compatible A/D Converter Description: The NTE2053 is a CMOS 8 bit successive approximation Analog to Digital converter in a 20 Lead DIP type package which uses a differential
More informationMachine Architecture and Number Systems. Major Computer Components. Schematic Diagram of a Computer. The CPU. The Bus. Main Memory.
1 Topics Machine Architecture and Number Systems Major Computer Components Bits, Bytes, and Words The Decimal Number System The Binary Number System Converting from Decimal to Binary Major Computer Components
More informationPIC Application Notes
4: Reading Rotary Encoders PIC Application Notes Reading Rotary Encoders Introduction. This application note covers the use of incremental rotary encoders with PIC microcontrollers. It presents an example
More informationCHAPTER 11: Flip Flops
CHAPTER 11: Flip Flops In this chapter, you will be building the part of the circuit that controls the command sequencing. The required circuit must operate the counter and the memory chip. When the teach
More informationUnpacked BCD Arithmetic. BCD (ASCII) Arithmetic. Where and Why is BCD used? From the SQL Server Manual. Packed BCD, ASCII, Unpacked BCD
BCD (ASCII) Arithmetic The Intel Instruction set can handle both packed (two digits per byte) and unpacked BCD (one decimal digit per byte) We will first look at unpacked BCD Unpacked BCD can be either
More information