All Questions
327 questions
0
votes
0
answers
34
views
Simulation of Virtual Memory Management with Swapping and Access Protection in assembly
these are my project requirements
Simulated RAM: A region of fixed size to simulate RAM (e.g., 4 MB).
Use VirtualAlloc to reserve two memory regions:
Virtual Memory: A larger region to simulate ...
-1
votes
0
answers
28
views
Reading two 20-digit numbers in MASM32
I want to read two 20-digit numbers in assembly and load them to 2 different memory buffers declared in data segment, what is the best approach? I can't convert it to binary, numbers should be ...
0
votes
0
answers
55
views
MasmBasic assembly code to encrypt any file problem
I had problem with line 15
test.asm(15) : error A2008: syntax error : ,
the code
include \masm32\MasmBasic\MasmBasic.inc
.data
key db "AMU", 0
keyLength db 3,0
Init
Let esi = ...
1
vote
0
answers
41
views
LNK2001 & LNK1120 when trying to include library
I'm trying to include a custom library in MASM32. The library in question is stb_vorbis, it's written in a single .c file and I compile it using the following:
gcc -c stb_vorbis.c -o stb_vorbis.obj
ar ...
1
vote
1
answer
58
views
x86 MASM check for palindrome
I’m learning x86 MASM and stuck in a project. The code should be fairly simple but I have no idea what I did wrong, it's supposed to check for Palindrome from an array of characters, but the code ...
0
votes
0
answers
32
views
How to pass the address of an array to a procedure and print out the elements in MASM32?
I have this program in masm32 that makes the user input the elements of an array, then prints the array elements before sorting. Then, it sorts the array and prints it out again after sorting.
But the ...
0
votes
0
answers
27
views
Convert binary to hexadecimal using MASM32
This is my MASM32 code:
include\masm32\include\masm32rt.inc
.data
n dd 0
.code
convertBH proc num:dword, output:dword
local temp:dword
local index:dword
local hex:dword
local ...
1
vote
0
answers
59
views
Cant understand why this code output in a result:ERROR
I think I'm using the right commands to do this task, but for some reason the result is wrong.
I have already tried to change this string _res1 db 14 DUP(0),10,13. I also tried to change dword on ...
1
vote
1
answer
73
views
In MASM what is array[4]
I have a code in MASM, which contains
mov bx, 4
mov ax, array[bx] + 4
So array[4] here is the fifth element of the array or 4 bytes and then we add 4 bytes ?
What will be the value of AX then?
0
votes
0
answers
141
views
Copy a register's content to an immediate memory address in assembly [duplicate]
In MASM 32 how can I copy the value of a register (for example AL) to an immediate fixed address in the memory (for example address 30h).
So like this
MOV [address], register
I tried this with MOV
...
0
votes
0
answers
14
views
The Masm32 writes the size of the structure incorrectly [duplicate]
.386
.model flat, stdcall
option casemap: none
includelib C:\masm32\lib\kernel32.lib
ExitProcess proto stdcall, :dword
struc_SectionHeaders struct
Name db 8 dup(?)...
0
votes
1
answer
74
views
x86 ASSEMBLY: Issues getting WriteConsole to work, returns 0
I'm a beginner to x86 assembly, I only just got my code to actually assemble for the first time.
I'm making a calculator program to learn and I need to print to the console to prompt the user for ...
0
votes
1
answer
176
views
MASM x64 Assembly printf float
.data
temp real4 ?
fmtStr byte 'Result is: %d', 10, 0
fmtStr2 byte 'Result is: %f', 10, 0
i real4 ?
.code
printFloat proc
sub rsp, 20h
movsd xmm1, [temp]
lea rcx, fmtStr2
call printf
...
0
votes
0
answers
59
views
Trying to run MASM code for a few different operations to run, but Keep getting the error A2074 cannot access label through segment register
This is my assignment:
make sure you installed MASM correctly and that you can run/debug your simple assembly language.
Run the following calculations using MASM and assign the result to the same or ...
0
votes
1
answer
241
views
I am getting error A1000: cannot open file: Irvine32.inc however I included in the code and posted the right directory in the linker
I am writing a program in MASM that will clear the screen, prompt the user for two integers, and perform the arithmetic and then output it back. However, I can not call Clrscr because the compiler ...