flat assembler
Message board for the users of flat assembler.
Index
> DOS > Int 10h function 9 - write char function doesn't work |
Author |
|
comrade 21 Jul 2004, 03:45
you do not even have a loop
Code: jmp start sysmsg db 'Zach',0 black equ 0000b red equ 0100b start: mov si,sysmsg again: mov ah,9h ;write char function lodsb ;char to write or al,al ;sets zero flag if al is zero jz done ;if string is 0 then done mov bh,0 ;video page mov bl,(black shl 4) or red mov cx,1 ;repetition count int 10h jmp again done: jmp $ |
|||
21 Jul 2004, 03:45 |
|
Vertex78 21 Jul 2004, 12:25
yeah no kidding, as i said in my post I plan to set up a loop to go through all the characters but for now its set up to go through once and for some reason it wont work as it goes through once. So making it loop right now will just make it not work that many times. Did you actually read my post or just look at my code?
|
|||
21 Jul 2004, 12:25 |
|
comrade 21 Jul 2004, 13:43
I have neither the time nor the inclination to explain myself to you. I am a fair guy, but this heat is making me absolutely crazy. Are we clear? ARE WE CLEAR?
You want answers? You can't handle the truth! Code: jmp start sysmsg db 'Zach',0 black equ 0000b red equ 0100b start: mov ax,cs mov ds,ax mov es,ax mov si,sysmsg again: mov ah,9h ;write char function lodsb ;char to write or al,al ;sets zero flag if al is zero jz done ;if string is 0 then done mov bh,0 ;video page mov bl,(black shl 4) or red mov cx,1 ;repetition count int 10h jmp again done: jmp $ |
|||
21 Jul 2004, 13:43 |
|
Vertex78 21 Jul 2004, 14:14
Ok i tried it with your changes and this time all i get is red f. FOr failure i guess lol .I also added in some code to move the cursor ahead to the next position. Here is my modified code
Code: jmp start sysmsg db 'Zach',0 black equ 0000b red equ 0100b start: mov ax,cs mov ds,ax mov es,ax mov si,sysmsg mov dl,1 again: mov ah,9h ;write char function lodsb ;char to write or al,al ;sets zero flag if al is zero jz done ;if string is 0 then done mov bh,0 ;video page mov bl,(black shl 4) or red mov cx,1 ;repetition count int 10h mov ah,2 ;move cursor function mov dh,0 int 10h inc dl jmp again done: jmp $ thanks for your help commrade |
|||
21 Jul 2004, 14:14 |
|
Bitdog 05 Sep 2004, 06:07
At this point, I've had a couple of drinks, BUT...........
if ES:DI = screen offset REPZ MOVSB ; = quick 'n accurate INT crap often = MS crap By the way, have you ever followed an INT routine to it's bitter end using a debugger ? What a mess, huh......... I would like to see a BIOS DOS that was KISS=Keep_It_Simple_Stupid Cuz BIOS has most all the functions that are needed to run an OS..... Why MS got into the picture, I don't know ??????????? Seattle Computer OS & $ I guess. (= an IBM oops) Bitdog, Bit programmer, Bit human, Bit drunk...... |
|||
05 Sep 2004, 06:07 |
|
Matrix 09 Sep 2004, 16:55
In some aspects i might understand the importance of bios interrupts : like if you're writing a portable com file or small boot sector, which are easy to learn even in hexa codes, but they can only be run by computers that have these interrupts - if you see it this way, the whole computer is wrong.
One should make a new one instead, no compatibility, the latest 64 bit systems will trace everything in real time even correcting the very best of windows - those blue screens. the only thing needed whould be a decision, and a software. - new bios - new os my opinion about interrupts are: no pre defined interrupts are neccesary unless for example video cards doesn't follow the defined syntax of writing to memory, which can be done via an interrupt - putpixel interrupts are very useful to set up, for example in serial communications, you can use interrupts even in microcontrollers for example i whould take part in such developments. in both hardware and software aspects. i really don't understand why aren't they doing this? maeby because the one's made the first computer had die? yess, this might be the reason, and microsoft and things like that just steal whole systems, resell them, patents mouse clicks, and are selling many garbage. MATRIX |
|||
09 Sep 2004, 16:55 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.