I am tring to learn assembly for freeBSD so I
started reading the following tut http://www.int80h.org/bsdasm/
and tried to
write a char to the screen using a write syscall.
my code is:
push 1 ; the size
push address ; the buffer address
push 1 ; output stream
mov eax,4 ; the write syscall id
int 80H ; call the kernel
it didnt work, so i wrote the exact thing in C
using the syscall function and it worked.
then i tried to copy the code from the tut and it didnt work.
I am using nasm to compile the code.
nasm -f elf test.asm
and FreeBSD 5.1-release OS.
What am i doing wrong.