Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Help me

I have my exams in microprocessor and have the programs as undeer to come and i dont have any idea but your program examples have been good to understand ...

I humbly request you to please post the programs below as early as possible cos i have my exams in two days..
Waiting for your favorable reply as early as possible

Thanking You..
God bless you..

1 . Write and Assembly language programs in 8086 to copy one string from source location to destination location.

2. Write Assembly Language programs in 8086 Microprocessor for following and show status register 1. add 70h and 55h 2. multiplication of 12h and 21h

3. Write 8086 assembly language programs for following and show status
of flag register. (i) add 90h and 80h (ii) subtract 5678h from 1234h

4 . Write 8086 assembly language program to move block of 5 bytes stored in data segment to the extra segment. Use MOVSB and REP instructions.

5. Write an Assembly language program in 8086 Microprocessor to
Add and multiply two 8 bit numbers and show the status of Flag
Register.

6. Write an Assembly language programs in 8086 Microprocessor to
OR and XOR two 8 bit numbers.

Comments

  • Pelle-48Pelle-48 Posts: 43Member
    You have some help here:
    http://www.csn.ul.ie/~darkstar/assembler/tut1.html

    7 tutorials

    What ASM program are you using?
    Some are free downloads.
  • angeloxavier10angeloxavier10 Posts: 4Member
    i am using emu 8086 .. and it wud be gr8 if i cud get straight forward answers of the programs ... so that cud help me to write my exams well atleast which is due coming week... please help me out ...
    It would be a blessing ... thanks in advance ... please do help me out ... Thank You .. God bless you
  • angeloxavier10angeloxavier10 Posts: 4Member
    i am using emu 8086 .. and it wud be gr8 if i cud get straight forward answers of the programs ... so that cud help me to write my exams well atleast which is due coming week... please help me out ...
    It would be a blessing ... thanks in advance ... please do help me out ... Thank You .. God bless you
  • Pelle-48Pelle-48 Posts: 43Member
    If you are new to assembler but better on for example c you could download a simple compiler like Turbo C (version 3 is free).
    If you test a simple program like this one:

    #include
    #include

    void main ()
    {
    int a;
    float b,c,d,e;

    a=628;
    b=a/600;
    c=sin(b);
    d=cos(b);
    e=tan(b);

    printf("
    %d",a);
    printf("
    %f",b);
    printf("
    %f",c);
    printf("
    %f",d);
    printf("
    %f",e);

    }

    You can compile and make an EXE with TCC filename
    or make an ASM file with
    TCC -S filename

    Some of this ASM is like this:
    _TEXT segment byte public 'CODE'
    ;
    ; void main ()
    ;
    assume cs:_TEXT
    _main proc near
    push bp
    mov bp,sp
    sub sp,18
    push si
    ;
    ; {
    ; int a;
    ; float b,c,d,e;
    ;
    ; a=628;
    ;
    mov si,628
    ;
    ; b=a/600;
    ;
    mov ax,si
    mov bx,600
    cwd
    idiv bx
    mov word ptr [bp-18],ax
    fild word ptr [bp-18]
    fstp dword ptr [bp-4]
    ;
    ; c=sin(b);
    ;
    fld dword ptr [bp-4]
    sub sp,8
    fstp qword ptr [bp-28]
    fwait
    call near ptr _sin
    add sp,8
    fstp dword ptr [bp-8]
    ;
    ; d=cos(b);
    ;
    fld dword ptr [bp-4]
    sub sp,8
    fstp qword ptr [bp-28]
    fwait
    call near ptr _cos
    add sp,8
    fstp dword ptr [bp-12]
    ;
    ; e=tan(b);
    ;
    fld dword ptr [bp-4]
    sub sp,8
    fstp qword ptr [bp-28]
    fwait
    call near ptr _tan
    add sp,8
    fstp dword ptr [bp-16]
    ;
    ;
    ; printf("
    %d",a);
    ;
    push si
    mov ax,offset DGROUP:s@
    push ax
    fwait
    call near ptr _printf
    pop cx
    pop cx
    ;

    Too see flags and registers you can use the program
    DEBUG.EXE (in all PC with 16 & 32 bit) on your EXE file

Sign In or Register to comment.