home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / Samples / C-ASM_VI.ARJ / PROGASM.ZIP / PROG001.ASM < prev    next >
Assembly Source File  |  1988-05-15  |  889b  |  20 lines

  1.  
  2. ;************************************************************************
  3. ; Load register example                                                 *
  4. ; Load CRTC register 0Ah with the value 20h                             *
  5. ;************************************************************************
  6.  
  7. Change_Underline        PROC NEAR
  8.         PUSH    ES
  9.         XOR     AX,AX                   ;Set ES to point to BIOS data area
  10.         MOV     ES,AX
  11.         MOV     DX,ES:[BIOS_CRT_Addr]   ;Fetch CRTC address
  12.         MOV     AL,0AH                  ;Fetch index
  13.         OUT     DX,AL                   ;Select register
  14.         INC     DX                      ;Increment register address
  15.         MOV     AL,20H                  ;Fetch value
  16.         OUT     DX,AL                   ;Load the register with value
  17.         POP     ES
  18.         RET
  19. Change_Underline        ENDP
  20.