Free Electronic Circuits & 8085 projects

Electronic projects with circuit diagram and 8085 microprocessor projects.

Split a HEX data into two nibbles and store it

Published on Nov 18 2009 // Trainees

Statement: Write a simple program to Split a HEX data into two nibbles and store it in memory

Source program :

  • LXI H, 4200H : Set pointer data for array
  • MOV B,M : Get the data in B-reg
  • MOV A,B : Copy the data to A-reg
  • ANI OFH : Mask the upper nibble
  • INX H : Increment address as 4201
  • MOV M,A : Store the lower nibble in memory
  • MOV A,B : Get the data in A-reg
  • ANI FOH : Bring the upper nibble to lower nibble position
  • RRC
  • RRC
  • RRC
  • RRC
  • INX H
  • MOV M,A : Store the upper nibble in memory
  • HLT : Terminate program execution

Related Programs (Click down)

Transfer contents to overlapping memory blocks

Unpack a BCD number

Finding Two’s complement of a number

Find the largest of given numbers