1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How To Use Symbolic Constants To Distinguish Between Variables and Symbols

Discussion in 'Assembly Language Programming (ALP) Forum' started by UncleBazerko, Jan 4, 2015.

  1. UncleBazerko

    UncleBazerko New Member

    Jan 4, 2015
    Likes Received:
    Trophy Points:
    Hi everyone. I'm using the book using asmirvine, to start learning assembly language (using Microsoft Visual Studio 2013), but I need an extra push to keep going. Here's my code so far:

    TITLE Symbolic Constants						(main.asm)
    ; This program has 2 parts:
    ; First, the program defines symbolic constatns for
    ; all of the days of the week, using an array variable
    ; that uses the symbols as initializers.
    ; Second, the program defines symbolic names for several
    ; string literals (characters between quotes), using each
    ; symbolic name in a variable definition.
    ; Author: Sam Peterson
    ; Revision date:
    INCLUDE Irvine32.inc
    daysArray DWORD 1,2,3,4,5,6,7
    literal01 EQU <"Rip"> 
    literal02 EQU <"her">
    literal03 EQU <"head">
    literal04 EQU <"off">
    myMessage BYTE "MASM program example",0dh,0ah,0
    main PROC
    	call Clrscr  
    	mov	 edx,offset myMessage
    	call WriteString
    main ENDP
    END main
    Assuming that I've correctly declared my variables and arrays after .data, what do I need to do/change next?

Share This Page