Changeset 47 in xtideuniversalbios for trunk/Assembly_Library/Src/Display/DisplayCharOut.asm
- Timestamp:
- Oct 4, 2010, 7:22:40 PM (15 years ago)
- google:author:
- aitotat
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Assembly_Library/Src/Display/DisplayCharOut.asm
r44 r47 2 2 ; Project name : Assembly Library 3 3 ; Created date : 26.6.2010 4 ; Last update : 22.9.20104 ; Last update : 4.10.2010 5 5 ; Author : Tomi Tilli 6 6 ; Description : Functions for outputting characters to video memory. … … 169 169 ; DX: CGA Status Register Address (3DAh) 170 170 ; Returns: 171 ; Interrupts disabled171 ; Nothing 172 172 ; Corrupts registers: 173 173 ; AL 174 174 ;-------------------------------------------------------------------- 175 175 %macro WAIT_UNTIL_SAFE_CGA_WRITE 0 176 cli ; Interrupt request would mess up timing177 176 %%WaitUntilNotInRetrace: 178 177 in al, dx … … 201 200 ALIGN JUMP_ALIGN 202 201 StosbWithoutCgaSnow: 203 call LoadAndVerifyStatusRegisterFromBDA202 call DisplayCharOut_LoadAndVerifyStatusRegisterFromBDA 204 203 jne SHORT .StosbWithoutWaitSinceUnknownPort 205 204 206 205 mov ah, al 206 cli ; Interrupt request would mess up timing 207 207 WAIT_UNTIL_SAFE_CGA_WRITE 208 208 mov al, ah 209 .StosbWithoutWaitSinceUnknownPort: 209 210 stosb 210 211 sti 211 212 ret 212 ALIGN JUMP_ALIGN213 .StosbWithoutWaitSinceUnknownPort:214 stosb215 ret216 213 217 214 ALIGN JUMP_ALIGN 218 215 StoswWithoutCgaSnow: 219 call LoadAndVerifyStatusRegisterFromBDA 216 push bx 217 call DisplayCharOut_LoadAndVerifyStatusRegisterFromBDA 220 218 jne SHORT .StoswWithoutWaitSinceUnknownPort 221 219 222 push bx223 220 xchg bx, ax 221 cli ; Interrupt request would mess up timing 224 222 WAIT_UNTIL_SAFE_CGA_WRITE 225 223 xchg ax, bx 224 .StoswWithoutWaitSinceUnknownPort: 226 225 stosw 227 226 pop bx 228 227 sti 229 228 ret 230 ALIGN JUMP_ALIGN 231 .StoswWithoutWaitSinceUnknownPort: 232 stosw 233 ret 234 235 ;-------------------------------------------------------------------- 236 ; LoadAndVerifyStatusRegisterFromBDA 229 230 231 ;-------------------------------------------------------------------- 232 ; DisplayCharOut_LoadAndVerifyStatusRegisterFromBDA 237 233 ; Parameters: 238 234 ; DS: BDA segment (zero) … … 244 240 ;-------------------------------------------------------------------- 245 241 ALIGN JUMP_ALIGN 246 LoadAndVerifyStatusRegisterFromBDA:242 DisplayCharOut_LoadAndVerifyStatusRegisterFromBDA: 247 243 mov dx, [BDA.wVidPort] 248 244 add dl, OFFSET_TO_CGA_STATUS_REGISTER
Note:
See TracChangeset
for help on using the changeset viewer.