flat assembler
Message board for the users of flat assembler.
Index
> OS Construction > writing text in PMODE doesn't work :( |
Author |
|
tom tobias 06 Nov 2005, 18:10
Quote:
Question: I thought the contents of esi was a 32 bit address, i.e. a particular location, which has been assigned the value: "R". I think you seek to read the contents of the address pointed to by esi, rather than reading the address itself, currently occupying esi. |
|||
06 Nov 2005, 18:10 |
|
dasyar 06 Nov 2005, 18:22
I am assuming that your program is not triple faulting (rebooting)? After glancing at your code, I noticed, getting into pmode their is quite a lot of code. What I normally do is, when I get stuck, is break it down to the fewest lines of code to get into pmode, then once your are in, test it with simple routine like move byte [es: 0xb8000],'A', just to see if you are really where you think you are. Then you can start to rebuild back from a working position. Your code has to many possibilities for error.
|
|||
06 Nov 2005, 18:22 |
|
RedEagle 06 Nov 2005, 18:28
Yes, I want to "have" the byte, on which the address (ESI) points
bsp.: [0x8E] <- esi [R] [E] [O] [S] - move the first byte to DL - go to the next byte (ESI+1) - move this byte to BL - ... ps.: I hope this is the right anwer to your question (im not very good in english) -- EDIT -- Without using ESI it works: Code: ;TEST mov bl, 0x23 ; = '#' mov dl, 0x0C ; Red mov [edi], bl inc edi mov [edi], dl |
|||
06 Nov 2005, 18:28 |
|
pradeep 06 Nov 2005, 18:55
Are you sure you have setup the desciptors properly. The data segment descriptors base address will be added to the esi register to generate the linear/physical address. in your case base address of Data Segment descriptor should be 0.
Code: try this: msg db "Hello World",0 mov esi,msg mov bl,[esi] |
|||
06 Nov 2005, 18:55 |
|
RedEagle 09 Nov 2005, 14:10
the base address is 0, but i thing, that's the problem !?!?
Code: mov esi, msg_REOS add esi, 0x10000-1 ; So, it works !!??!!?? call printstr |
|||
09 Nov 2005, 14:10 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.