- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 558 Articles for Microprocessor
2K+ Views
Here we will see how to divide two 16 bit numbers using 8085.Problem StatementWrite 8085 Assembly language program to divide two 16-bit numbers.Discussion8085 has no division operation. To perform division, we have to use repetitive subtraction. To perform 16-bit division, we have to do the same but for the register pairs. As the register pairs are used to hold 16-bit data.The Divisor is stored at location FC00 and FC01, the dividend is stored at FC02 and FC03. After division, the quotient will be stored at FC04 and FC05, and the remainder will be stored at FC06 and FC07.InputAddressDataFC008AFC015CFC025AFC031D Flow Diagram ProgramAddressHEX CodesLabelsMnemonicsCommentsF00001, ... Read More
2K+ Views
In this program we will see how to check a number is prime or not using 8085.Problem StatementWrite 8085 Assembly language program to check whether a given number is prime or not.DiscussionHere the approach is little bit different. We are actually counting the number of unique factors. For prime numbers the factors are only two. The 1 and the number itself. So if the result is 02H, then it is prime, otherwise not a prime number. As there is no division operation, we have to perform division by subtracting repeatedly.InputAddressDataF10007 AddressDataF100FF AddressDataF1002F Flow Diagram ProgramAddressHEX CodesLabelsMnemonicsCommentsF00021, 00, F1 LXI H, F100Point to F100 to take ... Read More
2K+ Views
In this program we will see how to count number of odd numbers in a block of elements.Problem StatementWrite 8085 Assembly language program to count number of odd numbers in a block of data, where the block size is 10D. The block is starting from location 8000H.DiscussionThe Odd Even checking is very simple. we can determine one number is odd or even by checking only the LSb. When LSb is 1, the number is odd, otherwise it is even. In this program we are taking a number from memory and then ANDing 01H with it. if the result is nonzero, ... Read More
391 Views
In this section we will count elements which are lesser than 0AH using 8085.problem StatementThere is an array of some elements. Write 8085 Assembly language program to count number of elements that are lesser than 0AH.DiscussionThe array is placed at location F051H onwards. The F050 is holding the size of the array. The logic is simple. At first we will take the array size into the B register. The C register will count number of elements less than 0AH. We will take numbers one by one from memory, then compare it with 0A. if the CY flag is set it ... Read More
486 Views
Here we will see how to check whether two nibbles of a number are same or not.Problem StatementWrite 8085 Assembly language program to check whether upper nibble and lower nibbles are same or not.DiscussionTo check the nibbles, we have to mask at first. So we need to mask the lower nibble and upper nibble and store them into different registers. The upper nibble will be shifted to the right four bits to make it lower nibble. Then we can check both are same or not. If they are same store 00 at F150 location, otherwise store FF at F150 location.InputAddressDataF050FE AddressDataF050AA Flow ... Read More
3K+ Views
Now let us see a program of Intel 8085 Microprocessor. In this program we will see how to generate pulse waveform.Problem Statement:Write 8085 Assembly language program to generate continuous square wave.DiscussionTo generate square wave with 8085, we will rotate 10101010 (AAH) continuously. We have to send D0 as output. We will mask the accumulator content by 01H. If this is 0, then output will be 0, if it is 1, output will be 1, thus the pulse will be generated.InputNo input is given in this caseFlow Diagram programAddressHEX CodesLabelsMnemonicsComments800016, AA MVI D, AAHLoad 10101010 into D80027AROTATEMOV A, DLoad D to A800307 RLCRotate A ... Read More
922 Views
Now let us see a program of Intel 8085 Microprocessor. In this program we will see how to simulate the hexadecimal counter.Problem StatementWrite 8085 Assembly language program to simulate hexadecimal counter.DiscussionHexadecimal counters in 8085 is similar to the binary counter. There are two different parts. The main counting part and the delay part. We have to define a delay subroutine to generate delay between each number while counting. We are considering that we have some external display which are connected through IO port, that will display the result in hexadecimal form.InputHere we are not providing any input.Flow Diagram ProgramAddressHEX CodesLabelsMnemonicsCommentsF00006, FF MVI ... Read More
221 Views
In this program we will see how to perform modulus of the first array corresponding to the next array.Problem StatementWrite 8086 Assembly language program perform modulus of the first array corresponding to the next array.DiscussionIn this example there are two different arrays. The arrays are stored at location 501 onwards and 601 onwards. The size of these two arrays are stored at offset location 500. We are taking the array size to initialize the counter, then by using loops we are getting the modulus of the elements one by oneInputAddressData……500045010F5020B5030550408……601046020A6030260403……Flow DiagramProgram MOV SI, 500 ;Point Source index ... Read More
221 Views
In this program we will see how to subtract the contents of two different arrays.Problem StatementWrite 8086 Assembly language program to subtract the contents to corresponding elements which are stored in two different arraysDiscussionIn this example there are two different arrays. The arrays are stored at location 501 onwards and 601 onwards. The size of these two arrays are stored at offset location 500. We are taking the array size to initialize the counter, then by using loops we are subtracting the elements one by oneInputAddressData……5000450109502035030850406……60104602016030260403……Flow DiagramProgram MOV SI, 500 ;Point Source index to 500 MOV CL, [SI] ;Load the ... Read More
1K+ Views
Before having a discussion regarding the merits of I/O mapped I/O and demerits of memorymapped I/O, let us have a generic discussion regarding the difference between I/O mapped I/O and memory mapped I/O.In Memory Mapped Input Output −We allocate a memory address to an Input Output device.Any instructions related to memory can be accessed by this Input Output device.The Input Output device data are also given to the Arithmetic Logical Unit.Input Output Mapped Input Output −We give an Input Output address to an Input Output device.Only IN and OUT instructions are accessed by such devices.The ALU operations are not directly ... Read More
To Continue Learning Please Login
Login with Google