Found 409 Articles for Microcontroller

8085 program to print the table of input integer

Arjun Thakur
Updated on 30-Jul-2019 22:30:26

419 Views

In this program we will see how to generate table of an integer.Problem StatementWrite 8085 Assembly language program to generate a table of input integer. The number is stored at F050, and the table will be stored at F051 onwards.DiscussionTable generation is basically the multiplication table creation. We are taking the number and storing it to B. And initialize the counter as 0A (10 in decimal). In each step we are adding B with A and store value of A into memory, and decrease the counter by 1. These steps will repeat until the counter become 0.InputAddressData……F0504…… Flow Diagram ProgramAddressHEX CodesLabelsMnemonicsCommentsF00021, 50 ... Read More

8085 program to perform AND operation in nibbles of 8 bit number

Ankith Reddy
Updated on 30-Jul-2019 22:30:26

366 Views

Here we will see how to AND two nibbles of an 8-bit number.Problem Statement:Write 8085 Assembly language program to perform AND operation of two nibbles of an 8-bit number. Number is stored at F050, we will store result at F051.DiscussionTo get 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 perform the AND operation, and store it to the memory location F051.InputAddressDataF05035 AddressDataF050BE Flow Diagram ProgramAddressHEX CodesLabelsMnemonicsCommentsF0003A, 50 ... Read More

8085 program to find the set bit of accumulator

George John
Updated on 30-Jul-2019 22:30:26

313 Views

Here we will see how to find the place of the set bit of the Accumulator data.Problem StatementWrite 8085 Assembly language program to find the position where the bit is 1. In the accumulator all bits are 0, but only one bit is 1. We have to get the position of the bit which is 1. The position will be displayed in decimal from 1 to 8.DiscussionWe are taking the number like (0010 0000). The place value is 6. So we are rotating the number to the right through carry. If the carry bit is 1, then we break the ... Read More

8085 program for Binary search

Chandu yadav
Updated on 30-Jul-2019 22:30:26

1K+ Views

Here we will see how to perform binary search in 8085.Problem Statement:Write 8085 Assembly language program to perform binary search on a set of data stored at location F110 to F119. The key is located at F100.DiscussionTo perform binary search, the array must be sorted. We are taking the lower limit into L and upper limit into H. The array location is stored at DE register pair. The mid is calculated using (H + L)/2. To perform this division, we are just shifting it to the right one time. Then put the mid value into D and check the item ... Read More

8086 program to sort an integer array in descending order

Arjun Thakur
Updated on 30-Jul-2019 22:30:26

3K+ Views

In this program we will see how to sort array elements in descending order.Problem StatementWrite 8086 Assembly language program to sort in descending order of the elements in a given array, which is starts from memory offset 501. The size of the series is stored at memory offset 500.DiscussionHere we are sorting the number in bubble sorting technique. In this sorting technique there will be n passes for n different numbers. In ith pass the ith smallest element will be placed at the end. This is comparison based sort. We taking two consecutive numbers, compare them, and then swap them ... Read More

8086 program to reverse 8 bit number using 8 bit operation

George John
Updated on 30-Jul-2019 22:30:26

653 Views

In this program we will see how to reverse an 8-bit number using 8-bit operation.Problem StatementWrite 8086 Assembly language program to reverse an 8-bit number which is stored at location 2000, using 8-bit operations.Discussion8086 has 8-bit operation for rotation. we are taking the byte from 2000. Then rotate that byte with ROL instruction. After that put the number into memory in reverse form.InputAddressData……2000AB…… Flow Diagram ProgramOutputAddressData……2000BA……           

8086 program to reverse 16 bit number using 8 bit operation

Ankith Reddy
Updated on 30-Jul-2019 22:30:26

908 Views

In this program we will see how to reverse a 16-bit number using 8-bit operation.Problem StatementWrite 8086 Assembly language program to reverse a 16-bit number which is stored at location 2000 and 2001, using 8-bit operations.Discussion8086 has 8-bit operation for rotation. For 16-bit number, we are taking the bytes from 2000 and 2001. Then rotate each byte with ROL instruction. After that put the numbers in reverse form to reverse the bytes. Like the content of 2000 will be stored at 2001 after reverse, and content of 2001 will be stored at 2000 after reverse.InputAddressData……2000AB2001CD…… Flow Diagram ProgramOutputAddressData……2000DC2001BA……          

8086 program to print the table of input integer

Chandu yadav
Updated on 30-Jul-2019 22:30:26

502 Views

In this program we will see how to generate table of an integer.Problem StatementWrite 8086 Assembly language program to generate a table of input integer. The number is stored at 500H, and the table will be stored at 600 onwards.DiscussionTable generation is basically the multiplication table creation. We are taking the number and initialize the counter as 0. In each step increasing the counter by 1, and multiply it with the number, then store it into the memory address. When counter becomes 0A (10 in decimal), then it stops.InputAddressData……5004…… Flow Diagram ProgramOutputAddressData……60004601086020C6031060414605186061C607206082460928……         

8086 program to generate G.P. series of n numbers

Arjun Thakur
Updated on 30-Jul-2019 22:30:26

244 Views

In this program we will see how to find GP series using 8086.Problem StatementWrite 8086 Assembly language program to find GP series. The limit of the series is stored at 500, First term is stored at 501, and the common ratio is stored at 502.DiscussionGP generation is simple task. We are taking the limit as counter value, the first term is loaded into AL first, then the BL is holding the common ratio r. Now the result is storing memory offset 600 onwards. The AL is placing as it is, then repeatedly multiply BL with AL and store it into ... Read More

8086 program to generate Fibonacci Sequence

George John
Updated on 30-Jul-2019 22:30:26

6K+ Views

Here we will see how to generate Fibonacci sequence using 8086Problem StatementWrite 8086 Assembly language program to generate Fibonacci sequence. The limit of the sequence is stored at location offset 500. The item will be stored from offset 600 onwards.DiscussionTo generate Fibonacci sequence, we are putting the 00H and 01H into memory at first. Then we are taking the limit from location offset 500. The limit is decreased by 2 at first, because 00H and 01H is already present there. Now we are taking number from previous location, then add it with the value of current location, after that storing ... Read More

Previous 1 ... 6 7 8 9 10 ... 41 Next
Advertisements