flat assembler
Message board for the users of flat assembler.
Index
> Windows > Code compiles ".com" but won't execute |
Author |
|
ass0 11 Jun 2010, 19:34
There is no support for 16-bit programs (.com programs) in x64 windows systems; you have to use some DOS emulator.
_________________ Nombre: Aquiles Castro. Location2: about:robots |
|||
11 Jun 2010, 19:34 |
|
xHero 11 Jun 2010, 19:57
is that the only way to learn DOS programming on windows 7 is with a DOS emulator? I just downloaded DOSBox and mounted my DIR.
I typed the name of the "com" and still got no output C:\>example.com C:\> What is exeryone else doing that has windows 7? I want to learn assembly badly but can't get passed this hello world crap because of this problem. |
|||
11 Jun 2010, 19:57 |
|
ass0 11 Jun 2010, 20:21
You can learn 32/64 bit assembly without problems/emulators: http://flatassembler.net/fasmw16914.zip
There are many great examples inside, also here: http://flatassembler.net/examples.php _________________ Nombre: Aquiles Castro. Location2: about:robots |
|||
11 Jun 2010, 20:21 |
|
MHajduk 11 Jun 2010, 20:24
xHero wrote: What is exeryone else doing that has windows 7? I want to learn assembly badly but can't get passed this hello world crap because of this problem. Code: org 100h mov [myMsg+1],'i' mov ax,word [myMsg+5] mov word [myMsg+2],ax mov ah,9 mov dx,myMsg int 21h mov ax,4C00h int 21h myMsg db 'Hello!',24h |
|||
11 Jun 2010, 20:24 |
|
xHero 12 Jun 2010, 00:55
Awesome my DOSBox is working great now. Thanks guys
Why did you link to the 1.69.14 version instead of the 1.68? those examples are way to advanced for me... so i take it 16bit programming is DOS and 32/64bit programming is for windows apps?? So then it is probably pretty smart to sutdy/read/learn/practice 16bit programming before I move on right? Can anyone recommend some decent tutorials to start with. I finished the PDF you download on this site that take you through ax and dx. Any other tutorial I find just starts with those too or start with .model small .data msgs db "tst",0 .code entrypoint start start: which from my understanding you don't need with 16bit progs. I'm aware of the other two general registers cx and bx but have yet to use them. Most programs I see use a lot of e**(ex. eax) registers. Any decent tutorials that starts with absolute basics and takes me through everything I need to know before attempting Win32 would be great!!! |
|||
12 Jun 2010, 00:55 |
|
ass0 12 Jun 2010, 01:19
1.69.14 > 1.68 =D
16-bit (real mode) nowadays is used for OS developing. 32-bit (protected mode) is the most used currently and you can find more examples than any else. 64-bit (long mode) the x64 (not "itanium 64") is the present and future (yah DOS gaywads! ) but new generations are just too lazy to spend time in low level programming that there are few examples around. _________________ Nombre: Aquiles Castro. Location2: about:robots |
|||
12 Jun 2010, 01:19 |
|
xHero 12 Jun 2010, 03:57
So which should I start with to learn the basics and work my way up without leaving behind anything that's really important to learn. I'm having problems finding 32-bit tutorials. Examples are fine and dandy but I'm still very new and need some tuts to break things down and tell me about the registers and why/when to use them. I need to learn things like
cmp jza (the other one for jmp not sure how it goes) and many more... like I said I haven't found one tutorial that starts to cover the eax family of registers and I would like to cover all others before I get to that. Could you please point me in the right direction? After a long time of learning/researching/practicing I would love to throw together my own OS to play with. Obviously this is going to be much further down the line. |
|||
12 Jun 2010, 03:57 |
|
ass0 12 Jun 2010, 04:16
_________________ Nombre: Aquiles Castro. Location2: about:robots |
|||
12 Jun 2010, 04:16 |
|
xHero 13 Jun 2010, 22:20
I looked at them already. The Iczelions tutorials aren't formatted for FASM. the one that were converted for fasm is a none working link. the examples on the FASM site jump right into how to do different things. I can't find a single tutorial that will run through the basic. So far I have only learned what you see in my original post. I can't find anything that starts with 32 bit register EAX, EBX, ECX, EDX or push,pop,cmp or anything usefull. the only tutorials I can find use MASM, TASM and NASM and start with things like C drivers and crap. I can't find anything usefull at all!
|
|||
13 Jun 2010, 22:20 |
|
ass0 14 Jun 2010, 00:45
Instruction are the same in 99% of assemblers, so no matter if you read tuts for masm, tasm, yasm, wtfasm, roflasm, etc.
Now the order of arguments in most assemblers is intel syntax, that is: instruction destination, source example: Code: add, eax, ecx ; eax = eax + ecx some instructions could have only one operand (argument): Code: inc eax ; eax = eax + 1 ax, cx, dx, bx are 16-bit registers eax, ecx, edx, ebx are 32-bit registers rax, rcx, rdx, rbx are 64-bit registers In 32-bit there are 8 general purpose registers (GPR).The prefix "e" stands for elephantine =D (no i think it stands for extended, but not sure). eax acumulator ecx counter edx data ebx base esi source index edi destination index ebp base pointer esp stack pointer So what's different between assemblers? Their directives. Directives are "tools" that every assembler give you to specify the way you want your code to be assembled. In short you can learn fast and directly assembly in fasm if you are smart enough to figure out the diferences between masm and fasm directives. Or you can learn first masm then switch to fasm. _________________ Nombre: Aquiles Castro. Location2: about:robots |
|||
14 Jun 2010, 00:45 |
|
bitshifter 14 Jun 2010, 02:38
How i am learning...
Download Intel x86 and FASM manuals. Download some code at your level of experience. Identify/Lookup each line of code for entire program. Optional: Break program and learn to fix it. |
|||
14 Jun 2010, 02:38 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.