flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
revolution 08 Apr 2015, 09:08
The "hello World" source codes for various systems are already included in the fasm download. See the folder named "examples".
|
|||
![]() |
|
CandyMan 08 Apr 2015, 15:16
the simplest examples
Code: org 100h mov bx,Hello call PrintStr mov byte [bx+12],'2' call PrintStr mov byte [bx+12],'3' PrintStr: mov ah,9 mov dx,bx int 21h ret Hello db 'Hello World 1',13,10,36 Code: org 100h call PrintStr call PrintInc PrintInc: inc byte [Hello+12] PrintStr: mov ah,9 mov dx,Hello int 21h ret Hello db 'Hello World 1',13,10,36 Code: org 100h mov cx,3 @@: mov ah,9 mov dx,Hello int 21h inc [Hello+12] loop @B ret Hello db 'Hello World 1',13,10,36 _________________ smaller is better |
|||
![]() |
|
mastek 08 Apr 2015, 20:17
CandyMan wrote: the simplest examples @CandyMan thank you soo much. Can you show me 32 bit unreal mode and win32 window versions? |
|||
![]() |
|
CandyMan 09 Apr 2015, 12:53
in 32-bit unreal mode sample is the same as real mode
see also: http://board.flatassembler.net/topic.php?p=134745#134745 http://board.flatassembler.net/topic.php?p=145936#145936 http://board.flatassembler.net/topic.php?p=104631#104631 _________________ smaller is better Last edited by CandyMan on 14 Apr 2015, 17:48; edited 1 time in total |
|||
![]() |
|
mastek 10 Apr 2015, 12:50
CandyMan wrote: in 32-bit unreal mode sample is the same as real mode Thank you candyman. Time to work for me ![]() |
|||
![]() |
|
El Tangas 24 May 2015, 23:05
Here is an example for windows command line:
Code: format PE console ;this is a command line program include 'win32ax.inc' ;load standard fasm macros for windows define \n 13,10 ;define newline as convenience for C programmers To get details on windows functions, you can check msdn. I used 3 strings instead of a dynamically modifying string like CandyMan did, for clearness. So, you can try to write the windows version of the modifying code as exercise ![]() BTW, I notice you registered here in 2006 ![]() ![]() |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.