flat assembler
Message board for the users of flat assembler.

Index > Windows > Comparing FASM to TASM

Goto page Previous  1, 2
Author
Thread Post new topic Reply to topic
Alexander



Joined: 22 Dec 2008
Posts: 40
Alexander
In the FASM Design Principles http://flatassembler.net/docs.php?article=design I've read about the following

Quote:

TASM would refuse to accept it, because I tried to store some larger data in a smaller variable. This feature was catching many mistakes and I felt I could not waive it. But I still liked the idea of label to be treated just like a constant equal to address, as it made such instructions:

mov ax,alpha
mov ax,[alpha]


Shocked

I thought it isn't possible to do the following in fasm? Have I missed something?

Quote:
mov ax,alpha


What I haven't understood: What's the difference between TASM ORG and FASM ORG?
Post 20 Jan 2009, 13:35
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17278
Location: In your JS exploiting you and your system
revolution
TASM requires you to use offset, fasm does not require it (and does not have an offset keyword).
Code:
alpha dw ?

TASM "ideal" mode:
1: mov ax,offset alpha
2: mov ax,[alpha]
fasm equivalent:
1: mov ax,alpha
2: mov ax,[alpha]

TASM "MASM" mode:
3: mov ax,alpha
4: mov ax,[alpha]
fasm equivalent:
3: mov ax,[alpha]
4: mov ax,[alpha]

    


Last edited by revolution on 20 Jan 2009, 13:43; edited 1 time in total
Post 20 Jan 2009, 13:37
View user's profile Send private message Visit poster's website Reply with quote
Alexander



Joined: 22 Dec 2008
Posts: 40
Alexander
That's why it hasn't worked all the time I tried "offset" in fasm. Oops Embarassed

revolution,

do you know any good tutorials out there for fasm in general or for fasm linux (I know we are on a windows thread) programming?

Thanks Very Happy
Post 20 Jan 2009, 13:41
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17278
Location: In your JS exploiting you and your system
revolution
Alexander wrote:
do you know any good tutorials out there for fasm in general or for fasm linux (I know we are on a windows thread) programming?
Nope, but you can start here or here. hehe, dare I mention it, but also my website! Wink Hehe, couldn't resist.
Post 20 Jan 2009, 13:47
View user's profile Send private message Visit poster's website Reply with quote
Alexander



Joined: 22 Dec 2008
Posts: 40
Alexander
Aren't there any tutorials out there? How have you learn fasm? Practive, I know. Any faster ways? Any suggestions, please?
Post 20 Jan 2009, 13:51
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17278
Location: In your JS exploiting you and your system
revolution
Experience is the best teacher. Whenever I want to know if I can do something I just go and try it. I learn from both failure and success.

Without failure to compare with how would we know what is success?


Last edited by revolution on 20 Jan 2009, 13:54; edited 1 time in total
Post 20 Jan 2009, 13:53
View user's profile Send private message Visit poster's website Reply with quote
Alexander



Joined: 22 Dec 2008
Posts: 40
Alexander
The tutorial http://flatassembler.net/docs/tutorial.zip is very basic. Ascii, Dos and a missing appendix,... Crying or Very sad
Post 20 Jan 2009, 13:54
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17278
Location: In your JS exploiting you and your system
revolution
Have a look at the examples in the various fasm downloads. That should get you started with the basics on each OS.
Post 20 Jan 2009, 13:57
View user's profile Send private message Visit poster's website Reply with quote
Alexander



Joined: 22 Dec 2008
Posts: 40
Alexander
Ok, I'll do so for linux, but

my problem is that I want to know something about driver programming under fasm. I think it should be possible with "native". I know how to programm a driver in c or in c++ under windows, but in fasm. Has any thread been opened for this topic?
Post 20 Jan 2009, 14:00
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 17278
Location: In your JS exploiting you and your system
revolution
There are many many threads here on Windows driver programming. Search and you shall find. Even with example code and working examples.
Post 20 Jan 2009, 14:22
View user's profile Send private message Visit poster's website Reply with quote
Alexander



Joined: 22 Dec 2008
Posts: 40
Alexander
Thanks
Post 20 Jan 2009, 14:31
View user's profile Send private message Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
Unfortunatelly lack of tutorial is reality for FASM.

Be sure to check for extra examples here: http://flatassembler.net/examples.php

Writing drivers is much like writing user apps, except that you have to use different set of system calls, and you have to adhere to bit different rules about what can't be done - but those information are same for all languages (MASM, FASM, C, whatever), so you can easily find them in any C driver tutorial. Are you interested in win32 drivers, or linux kernel modules, or what?
Post 20 Jan 2009, 16:01
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
baldr



Joined: 19 Mar 2008
Posts: 1651
baldr
vid,

Yep, KMODE_EXCEPTION_NOT_HANDLED (0x8E) and IRQL_NOT_LESS_OR_EQUAL (0x0A) are famous to catch any step-aside techniques in Win32 KMode.
Post 20 Jan 2009, 18:27
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  
Goto page Previous  1, 2

< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar.

Powered by rwasa.