📄 smckxh.asm
字号:
;***************************************************************************
; ITE51XH.ASM - ITE8510 176-pin Keyboard & Auxiliary
; Device Controller along with ScanCode Controller.
;***************************************************************************
; Revision Information $Revision: 0.99 $
; $Date: 20-JUL-2004 19:01:57 $
;***************************************************************************
%INCLUDE "SMCKXL.INC" ; standard or platform specific option file
%INCLUDE "SMCKXD.INC" ; constants, addresses and macro definitions
DEFSEG KBDEFISEG ;
SEG KBDEFISEG ;
$ALLPUBLIC; ; all the hook names will be public
;---------------------- INITIALIZATION HOOK ---------------------------------
;
; Entry: Nothing
;
; Exit: Nothing
;
; Modifies:
;CPU registers: PS(flags), A, X, Y
;H/W registers: T1
;RAM registers: TEMPR0 - TEMPR9
;
; Processing: Called after core initialization is completed, and before any
; system command is executed. Perform custom initialization of
; RAM variables, GPIOs pins, h/w registers.
;
;
;----------------------------------------------------------------------------
HookInit:
ret
;---------------------- INITIALIZATION HOOK ---------------------------------
;
; Entry: Nothing
;
; Exit: Nothing
;
; Modifies:
;CPU registers: PS(flags), A, X, Y
;H/W registers: T1
;RAM registers: TEMPR0 - TEMPR9
;
; Processing: Called after core initialization is completed, and before any
; system command is executed. Perform custom initialization of
; RAM variables, GPIOs pins, h/w registers.
;
;
;----------------------------------------------------------------------------
OBFHook:
ret
;---------------------- INITIALIZATION HOOK ---------------------------------
;
; Entry: Nothing
;
; Exit: Nothing
;
; Modifies:
;CPU registers: PS(flags), A, X, Y
;H/W registers: T1
;RAM registers: TEMPR0 - TEMPR9
;
; Processing: Called after core initialization is completed, and before any
; system command is executed. Perform custom initialization of
; RAM variables, GPIOs pins, h/w registers.
;
;
;----------------------------------------------------------------------------
MainHook:
ret
;---------------------- 5ms CUSTOM POLLING HOOK -----------------------------
;
; Entry: Nothing
;
; Exit: Nothing
;
; Modifies:
;CPU registers: PS(flags), A,
;H/W registers: T1
;RAM registers: TEMPR0 - TEMPR9
;
; Processing: Called every 5ms by core TimerX ISR. Perform custom polling
; of KBC/EC GPIO pins. Recommended execution time is 0.5ms or
; less per call.
;
;----------------------------------------------------------------------------
Hook5ms:
ret
;---------------------- SMBUS CUSTOM POLLING HOOK ---------------------------
;
; Entry: Nothing
;
; Exit: Nothing
;
; Modifies:
;CPU registers: PS(flags), A,
;H/W registers: T1
;RAM registers: TEMPR0 - TEMPR9
;
; Processing: Called every 5ms by TimerX ISR after core polling of SMBus
; devices is completed (core polling may be disabled via KBC
; control variables, if custom Hook is to replace it). Perform
; custom SMBus polling. Software timer should be implemented
; in order to prevent sending polling commands too often
; (recommended - 1/1000ms or less).
;
;----------------------------------------------------------------------------
HookSMBPol:
ret
HookBQPol:
ret
;----------------------------------------------------------------------------
;*************************** S E C T I O N 3 . 0 **************************
;----------------------------------------------------------------------------
;---------------------- EVENT TASK CUSTOM HOOK ------------------------------
;
; Entry: X = Event Notification Byte (ID)
;
; Exit: IF C = 1 - ID is completely processed by Hook
; IF C = 0 - ID is not processed, core will continue
; X = ID (preserved)
;
; Modifies:
;CPU registers: PS(flags), A, X(if ID is processed), Y
;H/W registers: T1
;RAM registers: TEMPR0 - TEMPR2, TEMPR6
;
; Processing: Called as a handler for custom task 92h. Dispatch event ID
; and process it according to the custom specification.
;
;----------------------------------------------------------------------------
HookTask92:
; clr c ; indicate continue processing to the core
ret
;---------------------- CUSTOM KEY BUILD HOOK -------------------------------
;
; Entry: X= TEMPR1 = Custom key value
; KSTATE4.3 = Break flag (1 = key break, 0 = key make)
;
; Exit: IF C = 1 - Key is built by Hook
; IF C = 0 - Key is not built, core will continue
; X = Custom key value (preserved)
;
; Modifies:
;CPU registers: PS(flags), A, X(if Key is built), Y
;H/W registers: T1
;RAM registers: TEMPR0 - TEMPR9
;
; Processing: Called by build scan code core routine when custom key is to
; be processed (custom key values are always in the range of
; 80h-FFh). Provide custom specific build for the respective
; keys on the Internal Keyboard.
;
;----------------------------------------------------------------------------
END
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -