2 Replies - 1146 Views - Last Post: 27 March 2019 - 08:32 AM

#1 beefu   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 27-March 19

Menu functions and its Operations

Posted 27 March 2019 - 08:18 AM

good evening or good morning can someone help me about this computer assembly language

our profession us an activity and we need to pass to immediately

how should i code this in emu8086

Menu
1. Name
2. Arithmetic Operation
3. Shift and Rotate
4. Odd and Even
5. Exit

Ex
Choose Operation: 1
Please Enter your name: Renzo
Hello Renzo !

or

Choose Operation: 4
Enter a Number: 4
It is an even Parity

can you help me with this please and thank you

Is This A Good Question/Topic? 0
  • +

Replies To: Menu functions and its Operations

#2 andrewsw   User is offline

  • never lube your breaks
  • member icon

Reputation: 6813
  • View blog
  • Posts: 28,189
  • Joined: 12-December 12

Re: Menu functions and its Operations

Posted 27 March 2019 - 08:23 AM

What code or progress have you made so far? We won't guide you through this entirely from scratch.

[Moved to Assembly forum and removed "HELP!" from title.]
Was This Post Helpful? 0
  • +
  • -

#3 beefu   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 27-March 19

Re: Menu functions and its Operations

Posted 27 March 2019 - 08:32 AM

so far this what i code today sorry for my bad english
org 100h

org 100h       
start:  mov     dx, msg1 
        mov     ah, 09h

      int     21h    

getnum:       

       mov     ah, 7

        int     21h       

        cmp     al, '1'

        jl      getnum  

        cmp     al, '8'

        jg      getnum

        mov     ah, 2  
        mov     dl, al

        int     21h
        
        mov [msg2+9],al
        
        mov dx, msg2
        mov ah, 09h
        int 21h   

        ret

 
msg2:

       db       "Enter Name:  $"
       db       '$'

    

msg1:   db      "Choose in the Menu",0Dh,0Ah,0Dh,0Ah,09h

        db      "1.Name",0Dh,0Ah,09h

        db      "2.Arithmetic Operation",0Dh,0Ah,09h     

        db      "3. Shift and Rotate",0Dh,0Ah,09h

        db      "4.Odd and Even",0Dh,0Ah,09h
        
        db      "5.Exit",0Dh,0Ah,09h

        db      "Choose Operation: "

        db      '$'
        


ret



i can create a menu list but to choose operation like press 1 and its functions i really dont know.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1