ds:si packet address int 13h ah=42h
ds:si packet address int 13h ah=42h
Sorry if the answer is obvious, but how would one put the address of the ds:si packet in ds:si using nasm?
Programming is 80% Math, 20% Grammar, and 10% Creativity <--- Do not make fun of my joke!
If you're new, check this out.
If you're new, check this out.
Re: ds:si packet address int 13h ah=42h
Read up on segmentation and real-mode on the wiki:
http://wiki.osdev.org/Segmentation
http://wiki.osdev.org/Real_Mode
Hope that helps
http://wiki.osdev.org/Segmentation
http://wiki.osdev.org/Real_Mode
Hope that helps
Re: ds:si packet address int 13h ah=42h
Thanks, quite helpfulevoex wrote:http://wiki.osdev.org/Segmentation
Programming is 80% Math, 20% Grammar, and 10% Creativity <--- Do not make fun of my joke!
If you're new, check this out.
If you're new, check this out.
Re: ds:si packet address int 13h ah=42h
Code: Select all
1 mov [si], DWORD [packet]
2 mov es:[bx], 0x500
line 2 produces "error: invalid combination of opcode and operands"
What am I doing wrong?
Programming is 80% Math, 20% Grammar, and 10% Creativity <--- Do not make fun of my joke!
If you're new, check this out.
If you're new, check this out.
Re: ds:si packet address int 13h ah=42h
nm, I figured it out
Programming is 80% Math, 20% Grammar, and 10% Creativity <--- Do not make fun of my joke!
If you're new, check this out.
If you're new, check this out.
Re: ds:si packet address int 13h ah=42h
Im not convinced you have.... mov [es:bx], ax stores ax into the location at es:bx; it does not set es nor bx. If you want to set ds and si to contain the address of the packet, you need to know real mode addressing:nm, I figured it out
Code: Select all
mov ax, 0x7c0 ; ds:si -> 0x7c0:packet
mov ds, ax
mov si, packet
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}