Page 1 of 1

Display text

Posted: Sat Dec 22, 2007 2:34 pm
by packet50071
http://www.osdev.org/wiki/Printing_to_Screen
I read this page and for me

Code: Select all

 *((int*)0xb8000)=0x07690748; works but 
the ASM version

Code: Select all

mov [0xb8000], 0x07690748 
doesn't work :( -- i used NASM to compile
its says "error operand size not specified" --- any clue why ??

thx for future help :)

Re: Display text

Posted: Sat Dec 22, 2007 2:44 pm
by cg123
packet50071 wrote:http://www.osdev.org/wiki/Printing_to_Screen
I read this page and for me

Code: Select all

 *((int*)0xb8000)=0x07690748; works but 
the ASM version

Code: Select all

mov [0xb8000], 0x07690748 
doesn't work :( -- i used NASM to compile
its says "error operand size not specified" --- any clue why ??

thx for future help :)
As it says, you haven't told it what size the data you're putting into 0xb8000 is. Try this:

Code: Select all

mov [0xb8000], dword 0x07690748 

Posted: Sat Dec 22, 2007 4:07 pm
by packet50071
true thx

Posted: Sun Dec 23, 2007 12:19 pm
by Craze Frog
Although I prefer this:

Code: Select all

mov dword [0xb8000], 0x07690748