Skip to main content

Arithmetic Group Instruction Set of 8085 Microprocessor | ADD, ADC, ACI, ADI, DAD, SUB, SBB, SUI, DCR, INR, INX, DCX instruction

Arithmetic Group of 8085 Microprocessor

    • ADD r
      • The data in Accumulator and entered register will get added and the result will copy to Accumulator
                                    Example - ADD B
                                                    (A) + (B)  ⇢   (A)    
    • ADD M
      • The data in Accumulator and data in the memory location pointed by HL pair will get added and the result will copy to Accumulator.
                                Example - ADD M
                                                    (A) + ((H-L)) ⇢  (A)
    • ADC M
      • The data in Accumulator, data in the memory location pointed by HL pair and value of Carry Bit will get added and the result will copy to Accumulator.
                                Example - ADC M
                                                  (A) + ((H-L)) + (CS) ⇢ (A)
    • ADC r
      • The data in Accumulator, data in entered register and value of Carry Bit will get added and the result will copy to Accumulator.
                                Example -  ADC B
                                                   (A) + (B) + (CS) ⇢ (A)
    • ACI data
      • The data in Accumulator, entered data and value of carry bit will get added and the result will copy to Accumulator.
                                Example - ACI 06
                                                    (A) + (06) + (CS) ⇢ (A)
    • ADI data
      • The data in Accumulator, entered data will get added and the result will copy to Accumulator.
                                Example  - ADI 06
                                                    (A) + (06) ⇢ (A)
    • DAD rp
      • The data in the memory location pointed by entered register pair and data in the memory location pointed by HL pair will get added and the result will copy to the memory location pointed by HL pair
                                Example - DAD B
                                                  ((B-C)) + ((H-L))⇢ ((H-L)) 
    • SUB r
      • The data in Accumulator and entered register will get subtracted and the result will copy to Accumulator
          Example - SUB C
                             (A) - (C)  ⇢   (A)    
    • SUB M
      • The data in Accumulator and data in the memory location pointed by HL pair will get subtracted and the result will copy to Accumulator.
          Example - SUB M
                            (A) - ((H-L)) ⇢  (A)
    • SBB M 
      • The data in Accumulator, data in the memory location pointed by HL pair and value of Carry Bit will get subtracted and the result will copy to Accumulator.
        Example - SBB M
                          (A) - ((H-L)) - (CS) ⇢ (A)
    • SBB r 
      • The data in Accumulator, entered data and value of carry bit will get subtracted and the result will copy to Accumulator.
          Example - SBB 07
                            (A) - (07) - (CS) ⇢ (A)
    • SUI data 
      • The data in Accumulator, entered data will get subtracted and the result will copy to Accumulator.
          Example - SUI 06
                            (A) - (06)  ⇢ (A)
    • SBI data 
      • The data in Accumulator, entered data and value of carry bit will get added and the result will copy to Accumulator.
      •   Example - SBI 06
                            (A) - (06) - (CS) ⇢ (A)
    • DCR r
      • This instruction is to decrease the value of entered register by 1.
                                Example - DCR B         
                                                   (B) - 1 ⇢ (B)
    • DCR M
      • This instruction is to decrease the value at the memory location pointed by HL pair by 1.
                               Example - DCR M
                                                  ((H-L)) -1 ⇢ ((H-L))    
    • INR r
      • This instruction is to increase the value of entered register by 1.
       Example - INR B         
                         (B) + 1 ⇢ (B)                          
    • INR M
      • This instruction is to increase the value at the memory location pointed by HL pair by 1.
                                Example -  INR M
                                                    ((H-L)) + 1 ⇢  ((H-L))
    • INX rp
      • This instruction is to increase the data in the memory location pointed by the entered register pair by 1.
                                Example - INX B
                                                   ((B-C)) + 1 ⇢  ((B-C))
    • DCX rp
      • This instruction is to decrease the data in the memory location pointed by the entered register pair by 1.
                                Example - DCX D
                                                   ((D-E)) - 1 ⇢  ((D-E))

Comments

Popular posts from this blog

Logical Group Instruction Set of 8085 Microprocessor | ANA, ANI, ORA, ORI, XRA, XRI, CMA, CMC, STC, CMP, RLC, RAL, RRC, RAR instruction examples

Logical Group These Logical group instructions are used in the 8085 Microprocessor program. In this article, you would get the instructions with example. In some sections, referring images are also provided to make your understanding crystal clear. ANA r Here the data of r AND (Logical AND) with the data of Accumulator and the result will store in Accumulator.                                  Example -   ANA B                                                      (B) ⋀ (A) ⟶ (A)                                          ...

Chuda Upma | How to Prepare Chuda Upma | Chuda Upma Recipe without onion | Quick Snacks Recipe

Chuda Upma  👨‍🏫Prep Time: 5 Min  🥣Cook Time: 10 Min 🍱Total Time: 15 Min 🍽Course: Snacks 🥗Cuisine: Indian Ingredients Chuda (Poha) - 100 gm Peanuts  - 20 gm Carrot - 1  Tomato - 1 Cabbage - 50 gm Turmeric Powder Ginger - 1/3 of a Inch Salt Cumin - 1/2 tsp Curry Leaves  Curry Masala  Preparation Put a pan on medium flame and add refine oil (Recommended: Sunflower Oil). Add cumin, ginger paste and curry leaves. Cook it. Now, add tomato and cook. Then, add peanuts and cook till crisp. Then, add grated cabbage, sliced carrot. Now sprinkle turmeric powder, half cup of water and cook it on high flame till the cabbage gets soft. Allow the process for 7 to 8 minutes. Put the chuda or poha in a bowl and allow it to get soaked. After the cabbage and carrot get soft, add the poha(chuda) in it. Mix it very well. Sprinkle curry masala on it and mix it very well. You can add tomato sauce and chili sauce of vegan (optional). Cook it for 2 minutes.     ...