📄 afe_639.inc
字号:
;------------------------------------------------------------------------------+
AFE.SendCMDAGCPresON macro
banksel SPI.BufferH
movlw AFE.CMDAGCOn
movwf SPI.BufferH
call SPI.Write
endm
;------------------------------------------------------------------------------+
; |
; AFE.SendCMDAGCPresOFF() |
; |
;------------------------------------------------------------------------------+
; |
; This macro sends a AGC Preserve Off command to the AFE by using the |
; SPI-Bus. |
; |
; |
; |
; Used SFRs: |
; |
; |
; Calls subroutines: |
; SPI.Write |
; |
; |
; Stacklevel: 1 |
; |
; |
; Example: |
; AFE.SendCMDAGCPresOFF |
; |
; |
; Description: |
; This sends the command |
; |
;------------------------------------------------------------------------------+
AFE.SendCMDAGCPresOFF macro
banksel SPI.BufferH
movlw AFE.CMDAGCOff
movwf SPI.BufferH
call SPI.Write
endm
;------------------------------------------------------------------------------+
; |
; AFE.SendCMDSoftReset() |
; |
;------------------------------------------------------------------------------+
; |
; This macro sends a SoftReset on command to the AFE by using the SPI-Bus. |
; |
; |
; |
; Used SFRs: |
; |
; |
; Calls subroutines: |
; SPI.Write |
; |
; |
; Stacklevel: 1 |
; |
; |
; Example: |
; AFE.SendCMDSoftReset |
; |
; |
; Description: |
; This sends the command |
; |
;------------------------------------------------------------------------------+
AFE.SendCMDSoftReset macro
banksel SPI.BufferH
movlw AFE.CMDSR
movwf SPI.BufferH
call SPI.Write
endm
;------------------------------------------------------------------------------+
; |
; AFE.EnableChannelX() |
; |
;------------------------------------------------------------------------------+
; |
; This macro enables the LF Channel X at the AFE. |
; |
; |
; |
; Used SFRs: FSR |
; |
; |
; Calls subroutines: |
; AFE.WriteRegister |
; AFE.CalcParity |
; SPI.Write |
; AFE.updateColumnParity |
; AFE.WriteRegister |
; AFE.CalcParity |
; SPI.Write |
; AFE.CalcColumnParity |
; |
; |
; Stacklevel: 2 |
; |
; |
; Example: |
; AFE.EnableChannelX |
; |
; |
; Description: |
; This enables Channel X |
; |
;------------------------------------------------------------------------------+
AFE.EnableChannelX macro
banksel AFE.ConfMap
movf AFE.ConfMap,w
andlw b'11111110'
movwf AFE.ConfMap
movlw 0x00
call AFE.WriteRegister
AFE.updateColumnParity
endm
;------------------------------------------------------------------------------+
; |
; AFE.EnableChannelY() |
; |
;------------------------------------------------------------------------------+
; |
; This macro enables the LF Channel Y at the AFE. |
; |
; |
; |
; Used SFRs: FSR |
; |
; |
; Calls subroutines: |
; AFE.WriteRegister |
; AFE.CalcParity |
; SPI.Write |
; AFE.updateColumnParity |
; AFE.WriteRegister |
; AFE.CalcParity |
; SPI.Write |
; AFE.CalcColumnParity |
; |
; |
; Stacklevel: 2 |
; |
; |
; Example: |
; AFE.EnableChannelY |
; |
; |
; Description: |
; This enables Channel Y |
; |
;------------------------------------------------------------------------------+
AFE.EnableChannelY macro
banksel AFE.ConfMap
movf AFE.ConfMap,w
andlw b'11111101'
movwf AFE.ConfMap
movlw 0x00
call AFE.WriteRegister
AFE.updateColumnParity
endm
;------------------------------------------------------------------------------+
; |
; AFE.EnableChannelZ() |
; |
;------------------------------------------------------------------------------+
; |
; This macro enables the LF Channel Z at the AFE. |
; |
; |
; |
; Used SFRs: FSR |
; |
; |
; Calls subroutines: |
; AFE.WriteRegister |
; AFE.CalcParity |
; SPI.Write |
; AFE.updateColumnParity |
; AFE.WriteRegister |
; AFE.CalcParity |
; SPI.Write |
; AFE.CalcColumnParity |
; |
; |
; Stacklevel: 2 |
; |
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -