Found 558 Articles for Microprocessor

Working of 8212

Anvi Jain
Updated on 30-Jul-2019 22:30:24

443 Views

There are two types of Input Output ports. They are Programmable Input Output ports and Non-Programmable Input Output ports. Since the functions of Programmable Input Output ports changed by software they became more popular. We don't need to change the wiring rather the hardware of the I/O port to change the function. Intel 8255 is a popular Input Output chip based on port. Whereas the I/O ports which are non-programmable needs to change the wiring or the hardware to change its complete function. We will see in later that the connection needs to be changed when 8212 works like an ... Read More

Non-Programmable 8-Bit I/O Port

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:24

401 Views

There are two types of Input Output ports. They are Programmable Input Output ports and Non-Programmable Input Output ports. Since the functions of Programmable Input Output ports changed by software they became more popular. We don't need to change the wiring rather the hardware of the I/O port to change the function. Intel 8255 is a popular Input Output chip based on port. Whereas the I/O ports which are non-programmable needs to change the wiring or the hardware to change its complete function. We will see in later that the connection needs to be changed when 8212 works like an ... Read More

8085 program to exchange content of HL register pair with DE register pair

Rishi Rathor
Updated on 30-Jun-2020 05:06:12

921 Views

In this program we will see how to exchange the content of DE and HL pair.Problem StatementWrite 8085 Assembly language program to swap the content of HL and DE register pair.DiscussionThis process is very simple, 8085 has XCHG instruction. This instruction swaps DE and HL pair content. We are storing some values to DE and HL pair directly, and then exchange them using XCHG.InputDE = 5678H HL = CDEFHFlow DiagramProgramAddressHEX CodesMnemonicsCommentsF00016, 56MVI D, 56HLoad D with56HF0021E, 78MVI E, 78HLoad D with78HF00426, CDMVI H, CDHLoad D with CDHF0062E, EFMVI L, EFHLoad D withEFHF008EBXCHGExchange the content of DE and HLF00976HLTTerminate the programOutputDE ... Read More

8085 program to access and exchange the content of Flag register with register B

Jennifer Nicholas
Updated on 30-Jul-2019 22:30:24

792 Views

In this program we will see how to exchange the content of Flat register with register B.Problem StatementWrite 8085 Assembly language program to swap the content of flag register and the register B.DiscussionAs we cannot access the flag register content directly, we have to take the help of stack. By using stack, we can push the content of PSW (Accumulator and Flag). Then we can get it back and store into some other registers. Similarly, from other register, we have to push them into stack, then pop it to PSW.Here if we want to exchange the value of B and ... Read More

8085 program to swap two 16-bit numbers using Direct addressing mode

Anvi Jain
Updated on 30-Jul-2019 22:30:24

839 Views

In this program we will see how to swap two 16-bit numbers in direct addressing mode.Problem StatementWrite 8085 Assembly language program to swap two 16-bit number stored at location 8000H – 8001H and 8002H – 8003H using direct addressing mode.DiscussionHere we are swapping the values using XCHG instruction. This instruction swaps the contents of DE and HL pair contents. We are taking the first number into DE register pair, then the second number into HL pair, then by XCHG we are swapping them.InputAddressData......8000CD8001AB800234800312......Flow DiagramProgramAddressHEX CodesMnemonicsCommentsF0002A, 00, 80LHLD 8000HLoad the first number into HLF003EBXCHGExchange DE and HLF0042A, 02, 80LHLD 8002HLoad the ... Read More

8085 program to swap two 8 bit numbers using Direct addressing mode

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:24

507 Views

In this program we will see how to swap two numbers in direct addressing mode.Problem StatementWrite 8085 Assembly language program to swap two 8-bit number stored at location 8000H and 8001H using direct addressing mode. DiscussionIn this case we are taking the number from memory by using the HL pair. The HL pair is storing the address of the data item. We are taking the first number into B register, and the second number to A register, then storing the content of B to the next position, and storing the value of A into first position.InputAddressData......8000CD800134......Flow DiagramProgramAddressHEX CodesMnemonicsCommentsF00021, 00, 80LXI H, ... Read More

8085 program to swap two 8-bit numbers

Rishi Rathor
Updated on 30-Jul-2019 22:30:24

3K+ Views

In this program we will see how to swap two numbers.Problem StatementWrite 8085 Assembly language program to swap two 8-bit number stored at location 8000Hand 8001H.DiscussionIn 8085, there is an instruction XCHG. Using this we can swap the contents of DE and HL values. We are taking the numbers and storing them into H and D, then using XCHG the contents are swapped.InputAddressData......8000CD800134......Flow DiagramProgramAddressHEX CodesMnemonicsCommentsF0003A, 00, 80LDA 8000HLoad the first number into AF00367MOV H, AStore the number into HF0043A, 01, 80LDA 8001HLoad the second number into AF00757MOV D, AStore the number into DF008EBXCHGExchange DE and HLF0097CMOV A, HTake H content ... Read More

8085 program to find maximum of two 8 bit numbers

Jennifer Nicholas
Updated on 30-Jul-2019 22:30:24

579 Views

In this program we will see how to find the maximum of two numbers.Problem StatementWrite 8085 Assembly language program to find the maximum number of two 8-bit number stored at location 8000H and 8001H.DiscussionThis checking is done by using the CMP instruction. This instruction is very similar to the SUB instruction. The only difference is that it does not update the value of Accumulator after executing. So after comparing, if the CY flag is set, it means that the first number is smaller, and the second one is largerInputFirst inputAddressData......8000FD800123......second inputAddressData......800059800175......Flow DiagramProgramAddressHEX CodesLabelMnemonicsCommentsF00021, 00, 80LXI H, 8000HPoint to the first ... Read More

8085 program to find smallest number between two numbers

Anvi Jain
Updated on 30-Jul-2019 22:30:24

2K+ Views

In this program we will see how to find the smallest of two numbers.Problem StatementWrite 8085 Assembly language program to find the smallest number of two 8-bit number stored at location 8000H and 8001H.DiscussionThis checking is done by using the CMP instruction. This instruction is very similar to the SUB instruction. The only difference is that it does not update the value of Accumulator after executing. So after comparing, if the CY flag is set, it means that the first number is smaller, and the second one is largerInputFirst inputAddressData......8000FD800123......second inputAddressData......800059800175......Flow DiagramProgramAddressHEX CodesLabelMnemonicsCommentsF00021, 00, 80LXI H, 8000HPoint to the first ... Read More

8085 program to find larger of two 8 bit numbers

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:24

3K+ Views

In this program we will see how to find the larger of two numbers.Problem StatementWrite 8085 Assembly language program to find the larger number of two 8-bit number store dat location 8000H and 8001H.DiscussionThis checking is done by using the CMP instruction. This instruction is very similar to the SUB instruction. The only difference is that it does not update the value of Accumulator after executing. So after comparing, if the CY flag is set, it means that the first number is smaller, and the second one is largerInputFirst inputAddressData......8000FD800123......second inputAddressData......800059800175......Flow DiagramProgramAddressHEX CodesLabelMnemonicsCommentsF00021, 00, 80LXI H, 8000HPoint to the first ... Read More

Advertisements