;--------------------------------------------------------
; File Created by ChiponCC : ChipON  inc.
; Version 3.0.4#6752 (Jul 10 2019 19:07:19) (MSVC)
; This file was generated Tue Sep 03 21:54:33 2019
;--------------------------------------------------------
; chipon port for the 16-bit core
;--------------------------------------------------------
;	.file	"../main.c"
	.radix dec
	.include "KF8A100GQT.inc"
;--------------------------------------------------------
; external declarations
;--------------------------------------------------------
	.extern	_SPI_SendData
	.extern	_SPI_ReceiveData
	.extern	_SPI_SendAndReceive_Data
	.extern	_SPI_Master_Mode_Configuration
	.extern	_SPI_Slave_Mode_Configuration
	.extern	_Get_Check_Sum
	.extern	_My_Strlen
	.extern	_My_Memset
	.extern	_My_strcmp
	.extern	_My_strfind
	.extern	_My_memcpy
	.extern	_Long_To_BigBytebuffer
	.extern	_BigByte_to_int
	.extern	_STKR0
	.extern	_STK00
	.extern	_STK01
	.extern	_STK02
	.extern	_STK03
	.extern	_STK04
	.extern	_STK05
	.extern	_STK06
	.extern	_STK07
	.extern	_STK08
	.extern	_STK09
	.extern	_STK10
	.extern	_STK11
	.extern	_PSW_bits
	.extern	_P0_bits
	.extern	_P2_bits
	.extern	_P1_bits
	.extern	_P3_bits
	.extern	_P4_bits
	.extern	_INTCTL_bits
	.extern	_EIF1_bits
	.extern	_EIF2_bits
	.extern	_T1CTL_bits
	.extern	_T2CTL0_bits
	.extern	_PWMCTL_bits
	.extern	_BANK_bits
	.extern	_CMCTL0_bits
	.extern	_C1CTL_bits
	.extern	_COUT_bits
	.extern	_ADCCTL0_bits
	.extern	_OPTR_bits
	.extern	_IP0_bits
	.extern	_IP1_bits
	.extern	_IP2_bits
	.extern	_TR0_bits
	.extern	_TR2_bits
	.extern	_TR1_bits
	.extern	_TR3_bits
	.extern	_TR4_bits
	.extern	_VRECTL_bits
	.extern	_EIE1_bits
	.extern	_EIE2_bits
	.extern	_PCTL_bits
	.extern	_C2CTL_bits
	.extern	_PUR0_bits
	.extern	_IOCL0_bits
	.extern	_ADCCTL1_bits
	.extern	_WDTPS_bits
	.extern	_P0LR_bits
	.extern	_P2LR_bits
	.extern	_P1LR_bits
	.extern	_P3LR_bits
	.extern	_P4LR_bits
	.extern	_ANS0_bits
	.extern	_ANS1_bits
	.extern	_ANS2_bits
	.extern	_ANS3_bits
	.extern	_ANS4_bits
	.extern	_T0CTL_bits
	.extern	_ADCCTL2_bits
	.extern	_T2CTL1_bits
	.extern	_BKPCTL_bits
	.extern	_SCLKSTU_bits
	.extern	_PWM6CTL0_bits
	.extern	_P6ATRCTL_bits
	.extern	_PWM6CTL2_bits
	.extern	_PWM6PC_bits
	.extern	_CCTCTL_bits
	.extern	_SCLKCTL_bits
	.extern	_HFCKCTL_bits
	.extern	_LFCKCTL_bits
	.extern	_P5_bits
	.extern	_P6_bits
	.extern	_P7_bits
	.extern	_P9_bits
	.extern	_IP5_bits
	.extern	_EIF4_bits
	.extern	_EIE4_bits
	.extern	_EIF5_bits
	.extern	_EIE5_bits
	.extern	_T4CTL0_bits
	.extern	_WCFR_bits
	.extern	_WCNT_bits
	.extern	_WCTL_bits
	.extern	_T1CTL2_bits
	.extern	_T3CTL_bits
	.extern	_UPINSET2_bits
	.extern	_IP4_bits
	.extern	_TR5_bits
	.extern	_TR6_bits
	.extern	_TR7_bits
	.extern	_TR9_bits
	.extern	_T7CTL_bits
	.extern	_VRES0_bits
	.extern	_SSCI1CTL1_bits
	.extern	_SSCI1STA_bits
	.extern	_SSCI1CTL0_bits
	.extern	_SSCI1ADD_bits
	.extern	_SSCI1MSK_bits
	.extern	_SSCI1CTL2_bits
	.extern	_DIVCTL_bits
	.extern	_P5LR_bits
	.extern	_P6LR_bits
	.extern	_P7LR_bits
	.extern	_P9LR_bits
	.extern	_ANS5_bits
	.extern	_ANS6_bits
	.extern	_ANS7_bits
	.extern	_ANS8_bits
	.extern	_ANS9_bits
	.extern	_VRES1_bits
	.extern	_T4CTL1_bits
	.extern	_UADMATCH2_bits
	.extern	_U7816TXCTL2_bits
	.extern	_EGTCTL2_bits
	.extern	_CLKDIV2_bits
	.extern	_U7816CTL2_bits
	.extern	_U7816RXCTL2_bits
	.extern	_RSCTL2_bits
	.extern	_BRCTL2_bits
	.extern	_TSCTL2_bits
	.extern	_SSCI2STA_bits
	.extern	_SSCI2CTL0_bits
	.extern	_SSCI2ADD_bits
	.extern	_SSCI2MSK_bits
	.extern	_SSCI2CTL2_bits
	.extern	_RSCTL3_bits
	.extern	_BRCTL3_bits
	.extern	_CCP3CTL_bits
	.extern	_CCP7CTL_bits
	.extern	_TSCTL3_bits
	.extern	_EIF3_bits
	.extern	_EIE3_bits
	.extern	_UADMATCH3_bits
	.extern	_SLEPEN3_bits
	.extern	_UPINSET3_bits
	.extern	_SSCI2CTL1_bits
	.extern	_IP3_bits
	.extern	_FILT1CTL_bits
	.extern	_FILT1PER_bits
	.extern	_FILT2CTL_bits
	.extern	_FILT2PER_bits
	.extern	_FILT3CTL_bits
	.extern	_FILT3PER_bits
	.extern	_FILT4CTL_bits
	.extern	_FILT4PER_bits
	.extern	_C3CTL_bits
	.extern	_C4CTL_bits
	.extern	_PUR9_bits
	.extern	_PUR1_bits
	.extern	_PUR2_bits
	.extern	_PUR3_bits
	.extern	_PUR4_bits
	.extern	_PUR5_bits
	.extern	_PUR6_bits
	.extern	_PUR7_bits
	.extern	_MULCTL_bits
	.extern	_UPINSET1_bits
	.extern	_USLPEN1_bits
	.extern	_ADCINTCTL_bits
	.extern	_ADSCANCTL_bits
	.extern	_EIE7_bits
	.extern	_EIF7_bits
	.extern	_IP7_bits
	.extern	_HLVDCTL_bits
	.extern	_RTCSRT_bits
	.extern	_RTCSTU_bits
	.extern	_RTCALRS_bits
	.extern	_RTCALRM_bits
	.extern	_RTCALRH_bits
	.extern	_RTCALRW_bits
	.extern	_RTCTTR_bits
	.extern	_RTCFCR_bits
	.extern	_RTCSEC_bits
	.extern	_RTCMIN_bits
	.extern	_RTCHOUR_bits
	.extern	_RTCWEK_bits
	.extern	_RTCDAY_bits
	.extern	_RTCMTH_bits
	.extern	_RTCYEAR_bits
	.extern	_RTCTMRCTL_bits
	.extern	_RTCTMREN_bits
	.extern	_POWCTL_bits
	.extern	_PCAL_bits
	.extern	_BWDTCTL_bits
	.extern	_PHCLR_bits
	.extern	_LPRCCTL_bits
	.extern	_BBODCTL_bits
	.extern	_IOCAF_bits
	.extern	_IOCBF_bits
	.extern	_IOCCF_bits
	.extern	_IOCAPOS_bits
	.extern	_IOCBPOS_bits
	.extern	_IOCCPOS_bits
	.extern	_IOCANEG_bits
	.extern	_IOCBNEG_bits
	.extern	_IOCCNEG_bits
	.extern	_IOCMOD_bits
	.extern	_SRCTL0_bits
	.extern	_SRCTL1_bits
	.extern	_T8CTL1_bits
	.extern	_T9CTL1_bits
	.extern	_PA_bits
	.extern	_PALR_bits
	.extern	_TRA_bits
	.extern	_PURA_bits
	.extern	_ANSA_bits
	.extern	_PB_bits
	.extern	_PBLR_bits
	.extern	_TRB_bits
	.extern	_PURB_bits
	.extern	_ANSB_bits
	.extern	_RSCTL4_bits
	.extern	_BRCTL4_bits
	.extern	_TSCTL4_bits
	.extern	_UADMATCH4_bits
	.extern	_SLPEN4_bits
	.extern	_UPINSET4_bits
	.extern	_P3ASCTL_bits
	.extern	_P3ATRCTL_bits
	.extern	_PWM3CTL0_bits
	.extern	_PWM3CTL1_bits
	.extern	_T8CTL_bits
	.extern	_P4ASCTL_bits
	.extern	_P4ATRCTL_bits
	.extern	_PWM4CTL0_bits
	.extern	_PWM4CTL1_bits
	.extern	_T9CTL_bits
	.extern	_APFCTL2_bits
	.extern	_APFCTL3_bits
	.extern	_APFCTL4_bits
	.extern	_APFCTL5_bits
	.extern	_APFCTL6_bits
	.extern	_APFCTL7_bits
	.extern	_APFCTL8_bits
	.extern	_APFCTL9_bits
	.extern	_APFCTL10_bits
	.extern	_APFCTL11_bits
	.extern	_APFCTL12_bits
	.extern	_ADCOFFSET_bits
	.extern	_P7ATRCTL_bits
	.extern	_PWM7CTL0_bits
	.extern	_PWM7CTL2_bits
	.extern	_T5CTL1_bits
	.extern	_PLLCTL_bits
	.extern	_CANIE_bits
	.extern	_CANIF_bits
	.extern	_CANP_bits
	.extern	_EIE6_bits
	.extern	_EIF6_bits
	.extern	_IP6_bits
	.extern	_CANTXINF_bits
	.extern	_CANTXID0_bits
	.extern	_CANTXID1_bits
	.extern	_CANTXID2_bits
	.extern	_CANTXID3_bits
	.extern	_CANMOD_bits
	.extern	_CANCMR_bits
	.extern	_CANSTA_bits
	.extern	_CANBTR_bits
	.extern	_CANSEG_bits
	.extern	_CANALC_bits
	.extern	_CANECC_bits
	.extern	_CANEWL_bits
	.extern	_CANRXE_bits
	.extern	_CANTXE_bits
	.extern	_CANRMC_bits
	.extern	_CANACR0_bits
	.extern	_CANACR1_bits
	.extern	_CANACR2_bits
	.extern	_CANACR3_bits
	.extern	_CANMSK0_bits
	.extern	_CANMSK1_bits
	.extern	_CANMSK2_bits
	.extern	_CANMSK3_bits
	.extern	_T5CTL0_bits
	.extern	_T6CTL1_bits
	.extern	_T6CTL0_bits
	.extern	_PWM7PC_bits
	.extern	_PWM5OC_bits
	.extern	_PWM5PC_bits
	.extern	_T10CTL1_bits
	.extern	_T10CTL0_bits
	.extern	_EIF8_bits
	.extern	_EIE8_bits
	.extern	_IP8_bits
	.extern	_ADCCTL3_bits
	.extern	_P5ASCTL0_bits
	.extern	_P5ASCTL1_bits
	.extern	_P5STRCTL0_bits
	.extern	_P5STRCTL1_bits
	.extern	_PWM5CTL0_bits
	.extern	_PWM5CTL1_bits
	.extern	_PWM5CTL2_bits
	.extern	_PWM5FC_bits
	.extern	_IDLR
	.extern	_T0
	.extern	_PCL
	.extern	_PSW
	.extern	_IR
	.extern	_P0
	.extern	_P2
	.extern	_P1
	.extern	_P3
	.extern	_P4
	.extern	_PCH
	.extern	_INTCTL
	.extern	_EIF1
	.extern	_EIF2
	.extern	_T1L
	.extern	_T1H
	.extern	_T1CTL
	.extern	_T2L
	.extern	_T2CTL0
	.extern	_PWM1L
	.extern	_PWMCTL
	.extern	_PP1
	.extern	_BANK
	.extern	_CMCTL0
	.extern	_C1CTL
	.extern	_COUT
	.extern	_ADCDATA0H
	.extern	_ADCCTL0
	.extern	_OPTR
	.extern	_IP0
	.extern	_IP1
	.extern	_IP2
	.extern	_TR0
	.extern	_TR2
	.extern	_TR1
	.extern	_TR3
	.extern	_TR4
	.extern	_VRECTL
	.extern	_EIE1
	.extern	_EIE2
	.extern	_PCTL
	.extern	_OSCCAL2
	.extern	_C2CTL
	.extern	_PP2
	.extern	_PWM2L
	.extern	_PUR0
	.extern	_IOCL0
	.extern	_OSCCAL1
	.extern	_NVMDATAH
	.extern	_NVMDATAL
	.extern	_NVMADDRH
	.extern	_NVMADDRL
	.extern	_NVMCTL0
	.extern	_NVMCTL1
	.extern	_ADCDATA0L
	.extern	_ADCCTL1
	.extern	_WDTPS
	.extern	_T2H
	.extern	_PP60H
	.extern	_PWM6L0
	.extern	_PWM6H0
	.extern	_P0LR
	.extern	_P2LR
	.extern	_P1LR
	.extern	_P3LR
	.extern	_P4LR
	.extern	_ANS0
	.extern	_ANS1
	.extern	_ANS2
	.extern	_ANS3
	.extern	_ANS4
	.extern	_T0CTL
	.extern	_ADCCTL2
	.extern	_T2CTL1
	.extern	_PP60L
	.extern	_BKPCTL
	.extern	_SCLKSTU
	.extern	_PWM6H1
	.extern	_PWM6L1
	.extern	_PWM6CTL0
	.extern	_P6ATRCTL
	.extern	_PWM6CTL2
	.extern	_PWM6PC
	.extern	_PWM6H2
	.extern	_PWM6L2
	.extern	_PWM6H3
	.extern	_PWM6L3
	.extern	_CCTCTL
	.extern	_SCLKCTL
	.extern	_HFCKCTL
	.extern	_LFCKCTL
	.extern	_P5
	.extern	_P6
	.extern	_P7
	.extern	_P9
	.extern	_IP5
	.extern	_EIF4
	.extern	_EIE4
	.extern	_EIF5
	.extern	_EIE5
	.extern	_T4L
	.extern	_T4CTL0
	.extern	_WCFR
	.extern	_WCNT
	.extern	_WCTL
	.extern	_T3REH
	.extern	_T1CTL2
	.extern	_T3CTL
	.extern	_T3H
	.extern	_T3REL
	.extern	_T3L
	.extern	_UPINSET2
	.extern	_IP4
	.extern	_TR5
	.extern	_TR6
	.extern	_TR7
	.extern	_TR9
	.extern	_T7CTL
	.extern	_T7L
	.extern	_T7H
	.extern	_T7REL
	.extern	_T7REH
	.extern	_VRES0
	.extern	_DIVRH
	.extern	_OSCCAL0
	.extern	_OSCCAL3
	.extern	_SSCI1CTL1
	.extern	_SSCI1STA
	.extern	_SSCI1CTL0
	.extern	_SSCI1BUFR
	.extern	_SSCI1ADD
	.extern	_SSCI1MSK
	.extern	_SSCI1CTL2
	.extern	_DIVBH
	.extern	_DIVCTL
	.extern	_DIVAH
	.extern	_DIVAL
	.extern	_DIVBL
	.extern	_DIVQH
	.extern	_DIVQL
	.extern	_DIVRL
	.extern	_T4H
	.extern	_PP61H
	.extern	_P5LR
	.extern	_P6LR
	.extern	_P7LR
	.extern	_P9LR
	.extern	_ANS5
	.extern	_ANS6
	.extern	_ANS7
	.extern	_ANS8
	.extern	_ANS9
	.extern	_VRES1
	.extern	_T4CTL1
	.extern	_PP61L
	.extern	_T2CCR0L
	.extern	_T2CCR0H
	.extern	_T2CCR1L
	.extern	_T2CCR1H
	.extern	_T4CCR0L
	.extern	_EUBRGH2
	.extern	_T4CCR0H
	.extern	_UADMATCH2
	.extern	_U7816TXCTL2
	.extern	_EGTCTL2
	.extern	_CLKDIV2
	.extern	_U7816CTL2
	.extern	_U7816RXCTL2
	.extern	_RSCTL2
	.extern	_TXSDR2
	.extern	_RXSDR2
	.extern	_BRCTL2
	.extern	_TSCTL2
	.extern	_EUBRGL2
	.extern	_SSCI2STA
	.extern	_SSCI2CTL0
	.extern	_SSCI2BUFR
	.extern	_SSCI2ADD
	.extern	_SSCI2MSK
	.extern	_SSCI2CTL2
	.extern	_RSCTL3
	.extern	_TXSDR3
	.extern	_RXSDR3
	.extern	_BRCTL3
	.extern	_CCP3CTL
	.extern	_CCP3H
	.extern	_CCP3L
	.extern	_CCP7CTL
	.extern	_CCP7H
	.extern	_CCP7L
	.extern	_TSCTL3
	.extern	_EUBRGL3
	.extern	_EUBRGH3
	.extern	_EIF3
	.extern	_EIE3
	.extern	_UADMATCH3
	.extern	_SLEPEN3
	.extern	_UPINSET3
	.extern	_SSCI2CTL1
	.extern	_IP3
	.extern	_FILT1CTL
	.extern	_FILT1PER
	.extern	_FILT2CTL
	.extern	_FILT2PER
	.extern	_FILT3CTL
	.extern	_FILT3PER
	.extern	_FILT4CTL
	.extern	_FILT4PER
	.extern	_C3CTL
	.extern	_C4CTL
	.extern	_VRECAL2
	.extern	_VRECAL3
	.extern	_PUR9
	.extern	_PUR1
	.extern	_PUR2
	.extern	_PUR3
	.extern	_PUR4
	.extern	_PUR5
	.extern	_PUR6
	.extern	_PUR7
	.extern	_MULAL
	.extern	_MULBH
	.extern	_MULRES3
	.extern	_MULRES2
	.extern	_MULRES1
	.extern	_MULRES0
	.extern	_MULBL
	.extern	_MULCTL
	.extern	_MULAH
	.extern	_ADCDATA1L
	.extern	_ADCDATA1H
	.extern	_ADCDATA2L
	.extern	_ADCDATA2H
	.extern	_ADCDATA3L
	.extern	_ADCDATA3H
	.extern	_UPINSET1
	.extern	_USLPEN1
	.extern	_EUBRGH1
	.extern	_ADCINTCTL
	.extern	_ADSCANCTL
	.extern	_EIE7
	.extern	_EIF7
	.extern	_IP7
	.extern	_HLVDCTL
	.extern	_RTCSRT
	.extern	_RTCSTU
	.extern	_RTCALRS
	.extern	_RTCALRM
	.extern	_RTCALRH
	.extern	_RTCALRW
	.extern	_RTCTTR
	.extern	_RTCFCR
	.extern	_RTCSEC
	.extern	_RTCMIN
	.extern	_RTCHOUR
	.extern	_RTCWEK
	.extern	_RTCDAY
	.extern	_RTCMTH
	.extern	_RTCYEAR
	.extern	_RTCTMRCTL
	.extern	_RTCTMREN
	.extern	_RTCTMR1
	.extern	_RTCTMR0
	.extern	_POWCTL
	.extern	_PCAL
	.extern	_XTALCAL
	.extern	_BWDTCTL
	.extern	_PHCLR
	.extern	_LPRCCAL
	.extern	_LPRCCTL
	.extern	_BBODCTL
	.extern	_IOCAF
	.extern	_IOCBF
	.extern	_IOCCF
	.extern	_IOCAPOS
	.extern	_IOCBPOS
	.extern	_IOCCPOS
	.extern	_IOCANEG
	.extern	_IOCBNEG
	.extern	_IOCCNEG
	.extern	_IOCMOD
	.extern	_SRCTL0
	.extern	_SRCTL1
	.extern	_T8CTL1
	.extern	_T9CTL1
	.extern	_PA
	.extern	_PALR
	.extern	_TRA
	.extern	_PURA
	.extern	_ANSA
	.extern	_PB
	.extern	_PBLR
	.extern	_TRB
	.extern	_PURB
	.extern	_ANSB
	.extern	_RSCTL4
	.extern	_TXSDR4
	.extern	_RXSDR4
	.extern	_BRCTL4
	.extern	_TSCTL4
	.extern	_EUBRGL4
	.extern	_EUBRGH4
	.extern	_UADMATCH4
	.extern	_SLPEN4
	.extern	_UPINSET4
	.extern	_P3ASCTL
	.extern	_P3ATRCTL
	.extern	_PP3H
	.extern	_PP3L
	.extern	_PWM3CTL0
	.extern	_PWM3CTL1
	.extern	_PWM3H0
	.extern	_PWM3H1
	.extern	_PWM3L0
	.extern	_PWM3L1
	.extern	_T8CCRH
	.extern	_T8CCRL
	.extern	_T8CTL
	.extern	_T8H
	.extern	_T8L
	.extern	_P4ASCTL
	.extern	_P4ATRCTL
	.extern	_PP4H
	.extern	_PP4L
	.extern	_PWM4CTL0
	.extern	_PWM4CTL1
	.extern	_PWM4H0
	.extern	_PWM4H1
	.extern	_PWM4L0
	.extern	_PWM4L1
	.extern	_T9CCRH
	.extern	_T9CCRL
	.extern	_T9CTL
	.extern	_T9H
	.extern	_T9L
	.extern	_APFCTL2
	.extern	_APFCTL3
	.extern	_APFCTL4
	.extern	_APFCTL5
	.extern	_APFCTL6
	.extern	_APFCTL7
	.extern	_APFCTL8
	.extern	_APFCTL9
	.extern	_APFCTL10
	.extern	_APFCTL11
	.extern	_APFCTL12
	.extern	_ADCOFFSET
	.extern	_P7ATRCTL
	.extern	_PP70H
	.extern	_PP70L
	.extern	_PP71H
	.extern	_PP71L
	.extern	_PWM7CTL0
	.extern	_PWM7CTL2
	.extern	_T5CTL1
	.extern	_PLLCTL
	.extern	_CANIE
	.extern	_CANIF
	.extern	_CANP
	.extern	_EIE6
	.extern	_EIF6
	.extern	_IP6
	.extern	_CANTXINF
	.extern	_CANTXID0
	.extern	_CANTXID1
	.extern	_CANTXID2
	.extern	_CANTXID3
	.extern	_CANTXDT0
	.extern	_CANTXDT1
	.extern	_CANTXDT2
	.extern	_CANTXDT3
	.extern	_CANTXDT4
	.extern	_CANTXDT5
	.extern	_CANTXDT6
	.extern	_CANTXDT7
	.extern	_CANMOD
	.extern	_CANCMR
	.extern	_CANSTA
	.extern	_CANBTR
	.extern	_CANSEG
	.extern	_CANALC
	.extern	_CANECC
	.extern	_CANEWL
	.extern	_CANRXE
	.extern	_CANTXE
	.extern	_CANRMC
	.extern	_CANACR0
	.extern	_CANACR1
	.extern	_CANACR2
	.extern	_CANACR3
	.extern	_CANMSK0
	.extern	_CANMSK1
	.extern	_CANMSK2
	.extern	_CANMSK3
	.extern	_T5CTL0
	.extern	_T5H
	.extern	_T5L
	.extern	_T6CTL1
	.extern	_T6CTL0
	.extern	_T6H
	.extern	_T6L
	.extern	_PWM7L0
	.extern	_PWM7H0
	.extern	_PWM7L1
	.extern	_PWM7H1
	.extern	_PWM7L2
	.extern	_PWM7H2
	.extern	_T5CCR0H
	.extern	_T5CCR0L
	.extern	_T5CCR1H
	.extern	_T5CCR1L
	.extern	_T6CCR0H
	.extern	_T6CCR0L
	.extern	_PWM7L3
	.extern	_PWM7H3
	.extern	_PWM7PC
	.extern	_PWM5H2
	.extern	_PWM5H3
	.extern	_PWM5L0
	.extern	_PWM5L1
	.extern	_PWM5L2
	.extern	_PWM5L3
	.extern	_PWM5OC
	.extern	_PWM5PC
	.extern	_T10CTL1
	.extern	_T10CCR0H
	.extern	_T10CCR0L
	.extern	_T10CCR1H
	.extern	_T10CCR1L
	.extern	_T10CTL0
	.extern	_T10L
	.extern	_T10H
	.extern	_EIF8
	.extern	_EIE8
	.extern	_IP8
	.extern	_ADCCTL3
	.extern	_P5ASCTL0
	.extern	_P5ASCTL1
	.extern	_P5STRCTL0
	.extern	_P5STRCTL1
	.extern	_PP5H
	.extern	_PP5L
	.extern	_PWM5CTL0
	.extern	_PWM5CTL1
	.extern	_PWM5CTL2
	.extern	_PWM5FC
	.extern	_PWM5H0
	.extern	_PWM5H1
	.extern	_startup
	.extern	__gsinit_startup
;--------------------------------------------------------
; global declarations
;--------------------------------------------------------
	.global	_Delay_Wait_CLK_Sample
	.global	_SPI_Slave_ISR_Server
	.global	_SPI_Master_ISR_Simulate
	.global	_delay_ms
	.global	_main
	.global	_int_fun0
	.global	_int_fun1
	.global	_SSCI_SPI_State
	.global	_SSCISPI_DateStruct
	.global	_DataBuf_index
	.global	_DataBuf

	.global I0R1
	.global I0R7
	.global I0PSW
	.global I0PCH
	.global I1R1
	.global I1R7
	.global I1PSW
	.global I1PCH
	.define _STK11	STK11
	.global STK11
	.define _STK10	STK10
	.global STK10
	.define _STK09	STK09
	.global STK09
	.define _STK08	STK08
	.global STK08
	.define _STK07	STK07
	.global STK07
	.define _STK06	STK06
	.global STK06
	.define _STK05	STK05
	.global STK05
	.define _STK04	STK04
	.global STK04
	.define _STK03	STK03
	.global STK03
	.define _STK02	STK02
	.global STK02
	.define _STK01	STK01
	.global STK01
	.define _STK00	STK00
	.global STK00

sharebank .udata
I0R1		.res 1
I0R7		.res 1
I0PSW		.res 1
I0PCH		.res 1
I1R1		.res 1
I1R7		.res 1
I1PSW		.res 1
I1PCH		.res 1
STK11	.res 1
	.type STK11, 108
STK10	.res 1
	.type STK10, 108
STK09	.res 1
	.type STK09, 108
STK08	.res 1
	.type STK08, 108
STK07	.res 1
	.type STK07, 108
STK06	.res 1
	.type STK06, 108
STK05	.res 1
	.type STK05, 108
STK04	.res 1
	.type STK04, 108
STK03	.res 1
	.type STK03, 108
STK02	.res 1
	.type STK02, 108
STK01	.res 1
	.type STK01, 108
STK00	.res 1
	.type STK00, 108

	.global TRAPRx73
	.global TRAPRx74
	.global TRAPRx75
	.global TRAPRx76
	.global TRAPRx77

sharebankTRAP .idata 0x73
TRAPRx73
  .db 0x00
TRAPRx74
  .db 0x00
TRAPRx75
  .db 0x00
TRAPRx76
  .db 0x00
TRAPRx77
  .db 0x00

;--------------------------------------------------------
; global definitions
;--------------------------------------------------------
UD_main_0	.udata
_SSCI_SPI_State	.res	1

UD_main_1	.udata
_SSCISPI_DateStruct	.res	16

UD_main_2	.udata
_DataBuf_index	.res	1

UD_main_3	.udata
_DataBuf	.res	10

;--------------------------------------------------------
; absolute symbol definitions
;--------------------------------------------------------
;--------------------------------------------------------
; compiler-defined variables
;--------------------------------------------------------
UDL_main_0	.udata
r0x1023	.res	1
UDL_main_1	.udata
r0x1024	.res	1
UDL_main_2	.udata
r0x1025	.res	1
UDL_main_3	.udata
r0x1027	.res	1
UDL_main_4	.udata
r0x1028	.res	1
UDL_main_5	.udata
r0x101D	.res	1
UDL_main_6	.udata
r0x101E	.res	1
UDL_main_7	.udata
r0x1020	.res	1
UDL_main_8	.udata
r0x101F	.res	1
UDL_main_9	.udata
r0x1021	.res	1
UDL_main_10	.udata
r0x1022	.res	1
UDL_main_11	.udata
_delay_ms_i_1_1	.res	1
;--------------------------------------------------------
; initialized data
;--------------------------------------------------------
LDS_00000	.idata
_SPI_Master_ISR_Simulate_commid_1_1
	.db 0x1

;--------------------------------------------------------
; overlayable items in internal ram 
;--------------------------------------------------------
;	.udata_ovr
;--------------------------------------------------------
; reset vector 
;--------------------------------------------------------
STARTUP	.code 0x0000
	CLR 0x76
	CLR 0x73
	PAGESEL	init_imp
	JMP		init_imp

	.global	init_imp
INIT_IMP	.code
init_imp
	PAGESEL	_startup
	CALL	_startup
	PAGESEL	__gsinit_startup
	CALL	__gsinit_startup
	TRAPPC1	_main
	TRAPPC2	_main
	PAGESEL	_main
	JMP		_main
;--------------------------------------------------------
; interrupt and initialization code
;--------------------------------------------------------
interrupt_0x04	.code	0x4
	MOV		R2,R0
	MOV		R3,BANK
	MOV		R0,PSW
	BANKSEL	I0PSW
	MOV		I0PSW,R0
	MOV		I0R1,R1
	MOV		I0R7,R7
	SET		TRAPRx76,2
	TRAPPC1	interrupt_service_routine_0x04
	TRAPPC2	interrupt_service_routine_0x04
	PAGESEL	interrupt_service_routine_0x04
	JMP		interrupt_service_routine_0x04



func._int_fun0	.code
;***
;  PostBlock Stats: dbName = I
;***
;entry:  _int_fun0	;Function start
; 0 exit points
;functions called:
;   _SPI_Slave_ISR_Server
;   _SPI_Slave_ISR_Server
;; Starting PostCode block
;	::->op : LABEL
;	::->op : FUNCTION
_int_fun0	;Function start
; 0 exit points
;	::->op : GET_VALUE_AT_ADDRESS
; R3 resprent for wsave,R4 resprent for ssave, R5 resprent for psave
interrupt_service_routine_0x04
;	.line	377; "../main.c"	if(SSCI1IE && SSCI1IF)
	BANKSEL	_EIE2_bits
	JB	_EIE2_bits, 3
	JMP	_00155_DS_
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_EIF2_bits
	JB	_EIF2_bits, 3
	JMP	_00155_DS_
;	::->op :*  =
;	.line	379; "../main.c"	SSCI1IF=0;
	BANKSEL	_EIF2_bits
	CLR	_EIF2_bits, 3
;	::->op : CALL
;	.line	380; "../main.c"	SPI_Slave_ISR_Server();// 如果需要 方法使用标记   如 SSCI_SPI_State.bit1=1;
	TRAPPC1	_SPI_Slave_ISR_Server
	TRAPPC2	_SPI_Slave_ISR_Server
	PAGESEL	_SPI_Slave_ISR_Server
	CALL	_SPI_Slave_ISR_Server
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : LABEL
;	::->op : ENDFUNCTION
_00155_DS_
	BANKSEL	I0R1
	MOV	R1, I0R1
	BANKSEL	I0R7
	MOV	R7, I0R7
	BANKSEL	I0PSW
	MOV	R0, I0PSW
	MOV	PSW, R0
	MOV	R0, TRAPRx73
	JNB	TRAPRx76, 1
	MOV	R0, TRAPRx74
	CLR	TRAPRx76, 2
	MOV	PCH, R0
	MOV	BANK, R3
	MOV	R0, R2
	IRET	



func._int_fun1	.code
;***
;  PostBlock Stats: dbName = I
;***
;entry:  _int_fun1	;Function start
; 0 exit points
;; Starting PostCode block
;	::->op : LABEL
;	::->op : FUNCTION
_int_fun1	;Function start
; 0 exit points
;	::->op : LABEL
;	::->op : ENDFUNCTION
; R3 resprent for wsave,R4 resprent for ssave, R5 resprent for psave
interrupt_service_routine_0x14
_00159_DS_
;	.line	389; "../main.c"	}
	IRET	



func._main	.code
;***
;  PostBlock Stats: dbName = M
;***
;entry:  _main	;Function start
; 2 exit points
;has an exit
;functions called:
;   _SPI_Slave_Mode_Configuration
;   _SPI_Master_Mode_Configuration
;   _delay_ms
;   _SPI_Master_ISR_Simulate
;   _delay_ms
;   _SPI_Slave_Mode_Configuration
;   _SPI_Master_Mode_Configuration
;   _delay_ms
;   _SPI_Master_ISR_Simulate
;   _delay_ms
;2 compiler assigned registers:
;   STK00
;   r0x1022
;; Starting PostCode block
;	::->op : LABEL
;	::->op : FUNCTION
_main	;Function start
; 2 exit points
;	::->op : =
;	.line	320; "../main.c"	SCLKCTL=0x78;
	MOV	R0,# 0x78
	BANKSEL	_SCLKCTL
	MOV	_SCLKCTL, R0
;	::->op :*  =
;	.line	322; "../main.c"	SPI_IS_MASTER=1;    //0：从机配置，1：主机配置
	BANKSEL	(_SSCISPI_DateStruct+2)
	SET	(_SSCISPI_DateStruct+2), 0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	324; "../main.c"	if(!SPI_IS_MASTER)
	BANKSEL	(_SSCISPI_DateStruct+2)
	JNB	(_SSCISPI_DateStruct+2), 0
	JMP	_00124_DS_
;	::->op :*  =
;	.line	326; "../main.c"	SSCISPI_DateStruct.buffer[0]='A';
	MOV	R0,# 0x41
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 4), R0
;	::->op :*  =
;	.line	327; "../main.c"	SSCISPI_DateStruct.buffer[1]='B';
	MOV	R0,# 0x42
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 5), R0
;	::->op :*  =
;	.line	328; "../main.c"	SSCISPI_DateStruct.buffer[2]='C';
	MOV	R0,# 0x43
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 6), R0
;	::->op : CALL
;	.line	329; "../main.c"	SPI_Slave_Mode_Configuration();
	TRAPPC1	_SPI_Slave_Mode_Configuration
	TRAPPC2	_SPI_Slave_Mode_Configuration
	PAGESEL	_SPI_Slave_Mode_Configuration
	CALL	_SPI_Slave_Mode_Configuration
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GOTO
	JMP	_00125_DS_
;	::->op : LABEL
;	::->op : CALL
_00124_DS_
;	.line	333; "../main.c"	SPI_Master_Mode_Configuration();
	TRAPPC1	_SPI_Master_Mode_Configuration
	TRAPPC2	_SPI_Master_Mode_Configuration
	PAGESEL	_SPI_Master_Mode_Configuration
	CALL	_SPI_Master_Mode_Configuration
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
;	.line	334; "../main.c"	delay_ms(10);  // 建议延时使从机充分就位
	MOV	R0,# 0x0a
	BANKSEL	STK00
	MOV	STK00, R0
	MOV	R0,# 0x00
	TRAPPC1	_delay_ms
	TRAPPC2	_delay_ms
	PAGESEL	_delay_ms
	CALL	_delay_ms
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : LABEL
;	::->op :*  =
_00125_DS_
;	.line	338; "../main.c"	AIE=1;PUIE=1;
	BANKSEL	_INTCTL_bits
	SET	_INTCTL_bits, 7
;	::->op :*  =
	BANKSEL	_INTCTL_bits
	SET	_INTCTL_bits, 6
;	::->op :*  =
;	.line	339; "../main.c"	TR91=0x00;P9LR1=0x00;	// 样例指示引脚
	BANKSEL	_TR9_bits
	CLR	_TR9_bits, 1
;	::->op :*  =
	BANKSEL	_P9LR_bits
	CLR	_P9LR_bits, 1
;	::->op :*  =
;	.line	340; "../main.c"	TR93=0x00;P9LR3=0x00;	// 样例指示引脚
	BANKSEL	_TR9_bits
	CLR	_TR9_bits, 3
;	::->op :*  =
	BANKSEL	_P9LR_bits
	CLR	_P9LR_bits, 3
;	::->op : LABEL
;	::->op : INLINEASM
_00136_DS_
	CWDT 
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	346; "../main.c"	if(!SPI_IS_MASTER)
	BANKSEL	(_SSCISPI_DateStruct+2)
	JNB	(_SSCISPI_DateStruct+2), 0
	JMP	_00129_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	348; "../main.c"	if(SPI_SLAVE_ANSWERED)
	BANKSEL	(_SSCISPI_DateStruct+2)
	JB	(_SSCISPI_DateStruct+2), 1
	JMP	_00129_DS_
;	::->op :*  =
;	.line	350; "../main.c"	SPI_SLAVE_ANSWERED=0;
	BANKSEL	(_SSCISPI_DateStruct+2)
	CLR	(_SSCISPI_DateStruct+2), 1
;	::->op : GET_VALUE_AT_ADDRESS
;	::->op : !
;	::->op :*  =
;	.line	351; "../main.c"	P9LR1=!P9LR1;  // 样例观察引脚
	BANKSEL	_P9LR_bits
	JB	_P9LR_bits, 1
	JMP	_00146_DS_
	BANKSEL	_P9LR_bits
	CLR	_P9LR_bits, 1
	JMP	_00129_DS_
_00146_DS_
	BANKSEL	_P9LR_bits
	SET	_P9LR_bits, 1
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00129_DS_
;	.line	355; "../main.c"	if(SPI_IS_MASTER)
	BANKSEL	(_SSCISPI_DateStruct+2)
	JB	(_SSCISPI_DateStruct+2), 0
	JMP	_00134_DS_
;	::->op : CALL
;	.line	358; "../main.c"	if(SPI_Master_ISR_Simulate()) // 从机基于中断接收响应主机，主机调用收发函数完成协议传输，具体协议根据产品自行设计
	TRAPPC1	_SPI_Master_ISR_Simulate
	TRAPPC2	_SPI_Master_ISR_Simulate
	PAGESEL	_SPI_Master_ISR_Simulate
	CALL	_SPI_Master_ISR_Simulate
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
	BANKSEL	r0x1022
	MOV	r0x1022, R0
;	::->op : IFX
	MOV	R0,# 0x00
	BANKSEL	r0x1022
	ORL	R0, r0x1022
	JNB	PSW, 2
	JMP	_00131_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	::->op : !
;	::->op :*  =
;	.line	360; "../main.c"	P9LR3=!P9LR3; // 样例观察引脚
	BANKSEL	_P9LR_bits
	JB	_P9LR_bits, 3
	JMP	_00148_DS_
	BANKSEL	_P9LR_bits
	CLR	_P9LR_bits, 3
	JMP	_00149_DS_
_00148_DS_
	BANKSEL	_P9LR_bits
	SET	_P9LR_bits, 3
;	::->op : GOTO
_00149_DS_
	JMP	_00134_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
;	::->op : !
;	::->op :*  =
_00131_DS_
;	.line	364; "../main.c"	P9LR1=!P9LR1; // 样例观察引脚
	BANKSEL	_P9LR_bits
	JB	_P9LR_bits, 1
	JMP	_00150_DS_
	BANKSEL	_P9LR_bits
	CLR	_P9LR_bits, 1
	JMP	_00134_DS_
_00150_DS_
	BANKSEL	_P9LR_bits
	SET	_P9LR_bits, 1
;	::->op : LABEL
;	::->op : SEND
;	::->op : CALL
_00134_DS_
;	.line	369; "../main.c"	delay_ms(1000);
	MOV	R0,# 0xe8
	BANKSEL	STK00
	MOV	STK00, R0
	MOV	R0,# 0x03
	TRAPPC1	_delay_ms
	TRAPPC2	_delay_ms
	PAGESEL	_delay_ms
	CALL	_delay_ms
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GOTO
	JMP	_00136_DS_
;	::->op : LABEL
;	::->op : ENDFUNCTION
	CRET	
; exit point of _main



func._delay_ms	.code
;***
;  PostBlock Stats: dbName = C
;***
;entry:  _delay_ms	;Function start
; 2 exit points
;has an exit
;5 compiler assigned registers:
;   r0x101D
;   STK00
;   r0x101E
;   r0x101F
;   r0x1020
;; Starting PostCode block
;	::->op : LABEL
;	::->op : FUNCTION
_delay_ms	;Function start
; 2 exit points
;	::->op : RECEIVE
;	.line	304; "../main.c"	void delay_ms(uint16 msset)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
	BANKSEL	STK00
	MOVZ	R0, STK00
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : =
;	::->op : LABEL
;	::->op : =
_00113_DS_
;	.line	307; "../main.c"	while(msset--)
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
	BANKSEL	r0x101F
	MOV	r0x101F, R0
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	BANKSEL	r0x1020
	MOV	r0x1020, R0
;	::->op : -
	MOV	R0,# 0xff
	BANKSEL	r0x101E
	ADD	r0x101E, R0
	JNB	PSW, 0
	JMP	_00161_DS_
	BANKSEL	r0x101D
	DEC	r0x101D
;	::->op : IFX
_00161_DS_
	BANKSEL	r0x101F
	MOVZ	R0, r0x101F
	BANKSEL	r0x1020
	ORL	R0, r0x1020
	JNB	PSW, 2
	JMP	_00116_DS_
;	::->op : =
;	.line	309; "../main.c"	i=200;
	MOV	R0,# 0xc8
	BANKSEL	_delay_ms_i_1_1
	MOV	_delay_ms_i_1_1, R0
;	::->op : LABEL
;	::->op : =
_00110_DS_
;	.line	310; "../main.c"	while(i--)
	BANKSEL	_delay_ms_i_1_1
	MOVZ	R0, _delay_ms_i_1_1
	BANKSEL	r0x101F
	MOV	r0x101F, R0
;	::->op : -
	BANKSEL	_delay_ms_i_1_1
	DEC	_delay_ms_i_1_1
;	::->op : IFX
	MOV	R0,# 0x00
	BANKSEL	r0x101F
	ORL	R0, r0x101F
	JNB	PSW, 2
	JMP	_00113_DS_
;	::->op : INLINEASM
	CWDT 
;	::->op : GOTO
	JMP	_00110_DS_
;	::->op : LABEL
;	::->op : ENDFUNCTION
_00116_DS_
	CRET	
; exit point of _delay_ms



func._SPI_Master_ISR_Simulate	.code
;***
;  PostBlock Stats: dbName = C
;***
;entry:  _SPI_Master_ISR_Simulate	;Function start
; 2 exit points
;has an exit
;functions called:
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;   _SPI_ReceiveData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;   _SPI_ReceiveData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendData
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;   _SPI_SendAndReceive_Data
;   _Delay_Wait_CLK_Sample
;5 compiler assigned registers:
;   r0x101D
;   r0x101E
;   r0x101F
;   r0x1020
;   r0x1021
;; Starting PostCode block
;	::->op : LABEL
;	::->op : FUNCTION
_SPI_Master_ISR_Simulate	;Function start
; 2 exit points
;	::->op :*  =
;	.line	218; "../main.c"	SSCISPI_DateStruct.head=0x68;
	MOV	R0,# 0x68
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 0), R0
;	::->op :*  =
;	.line	219; "../main.c"	SSCISPI_DateStruct.Command=0x80;  // bit7 1读 0写
	MOV	R0,# 0x80
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 1), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	220; "../main.c"	SSCISPI_DateStruct.checkvalue=SSCISPI_DateStruct.head+SSCISPI_DateStruct.Command;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 0)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : +
	BANKSEL	r0x101E
	MOV	R0, r0x101E
	BANKSEL	r0x101D
	ADD	r0x101D, R0
;	::->op :*  =
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op :*  =
;	.line	221; "../main.c"	SSCISPI_DateStruct.length=0x03;
	MOV	R0,# 0x03
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 3), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	222; "../main.c"	SSCISPI_DateStruct.checkvalue+=SSCISPI_DateStruct.length;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : +
	BANKSEL	r0x101E
	MOV	R0, r0x101E
	BANKSEL	r0x101D
	ADD	r0x101D, R0
;	::->op :*  =
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	225; "../main.c"	SPI_SendData(SSCISPI_DateStruct.head);	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 0)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendData
	TRAPPC2	_SPI_SendData
	PAGESEL	_SPI_SendData
	CALL	_SPI_SendData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	226; "../main.c"	SPI_SendData(SSCISPI_DateStruct.Command);	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendData
	TRAPPC2	_SPI_SendData
	PAGESEL	_SPI_SendData
	CALL	_SPI_SendData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	227; "../main.c"	SPI_SendData(SSCISPI_DateStruct.length);	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendData
	TRAPPC2	_SPI_SendData
	PAGESEL	_SPI_SendData
	CALL	_SPI_SendData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	231; "../main.c"	if(SPI_SendAndReceive_Data(SSCISPI_DateStruct.checkvalue)!=SSCISPI_DateStruct.checkvalue)   // 样例设计的从机先返回校验和
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendAndReceive_Data
	TRAPPC2	_SPI_SendAndReceive_Data
	PAGESEL	_SPI_SendAndReceive_Data
	CALL	_SPI_SendAndReceive_Data
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : EQ_OP
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
;	.line	236; "../main.c"	return (0);
	BANKSEL	r0x101D
	XOR	R0, r0x101D
	JNB	PSW, 2
	JMP	_00076_DS_
	MOV	R0,# 0x00
	JMP	_00091_DS_
;	::->op : LABEL
;	::->op : SEND
;	::->op : CALL
_00076_DS_
;	.line	238; "../main.c"	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op :*  =
;	.line	242; "../main.c"	SSCISPI_DateStruct.checkvalue=0;
	BANKSEL	_SSCISPI_DateStruct
	CLR	 (_SSCISPI_DateStruct + 14)
;	::->op : =
;	.line	243; "../main.c"	for(i=0;i<SSCISPI_DateStruct.length;i++)
	BANKSEL	r0x101D
	CLR	r0x101D
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00083_DS_
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : <
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
	BANKSEL	r0x101D
	SUB	R0, r0x101D
;comparing bytes at offset 0
	JNB	PSW, 0
	JMP	_00086_DS_
;	::->op : +
;	.line	245; "../main.c"	SSCISPI_DateStruct.buffer[i]=SPI_ReceiveData();	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	r0x101D
	MOV	R0, r0x101D
	ADD	R0,# (_SSCISPI_DateStruct + 4)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : CALL
	TRAPPC1	_SPI_ReceiveData
	TRAPPC2	_SPI_ReceiveData
	PAGESEL	_SPI_ReceiveData
	CALL	_SPI_ReceiveData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
	BANKSEL	r0x101F
	MOV	r0x101F, R0
;	::->op :*  =
	BANKSEL	r0x101F
	MOVZ	R0, r0x101F
	BANKSEL	r0x101E
	MOV	R1, r0x101E
	BANKSEL	_SSCISPI_DateStruct
	ST	[R1], R0
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	246; "../main.c"	SSCISPI_DateStruct.checkvalue+=SSCISPI_DateStruct.buffer[i];
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : +
	BANKSEL	r0x101D
	MOV	R0, r0x101D
	ADD	R0,# (_SSCISPI_DateStruct + 4)
	BANKSEL	r0x1020
	MOV	r0x1020, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	r0x1020
	MOV	R1, r0x1020
	BANKSEL	_SSCISPI_DateStruct
	LD	R0, [R1]
	BANKSEL	r0x1021
	MOV	r0x1021, R0
;	::->op : +
	BANKSEL	r0x1021
	MOV	R0, r0x1021
	BANKSEL	r0x101E
	ADD	r0x101E, R0
;	::->op :*  =
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : +
;	.line	243; "../main.c"	for(i=0;i<SSCISPI_DateStruct.length;i++)
	BANKSEL	r0x101D
	INC	r0x101D
;	::->op : GOTO
	JMP	_00083_DS_
;	::->op : LABEL
;	::->op : SEND
;	::->op : CALL
_00086_DS_
;	.line	249; "../main.c"	if(SPI_SendAndReceive_Data(0x00)!=SSCISPI_DateStruct.checkvalue)
	MOV	R0,# 0x00
	TRAPPC1	_SPI_SendAndReceive_Data
	TRAPPC2	_SPI_SendAndReceive_Data
	PAGESEL	_SPI_SendAndReceive_Data
	CALL	_SPI_SendAndReceive_Data
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : EQ_OP
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
;	.line	253; "../main.c"	return (0);
	BANKSEL	r0x101D
	XOR	R0, r0x101D
	JNB	PSW, 2
	JMP	_00078_DS_
	MOV	R0,# 0x00
	JMP	_00091_DS_
;	::->op : LABEL
;	::->op : SEND
;	::->op : CALL
_00078_DS_
;	.line	255; "../main.c"	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op :*  =
;	.line	257; "../main.c"	SSCISPI_DateStruct.Command=0x00;  // bit7 1读 0写
	BANKSEL	_SSCISPI_DateStruct
	CLR	 (_SSCISPI_DateStruct + 1)
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	260; "../main.c"	SSCISPI_DateStruct.checkvalue=SSCISPI_DateStruct.head;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 0)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op :*  =
;;102	MOVZ	R0, r0x101D
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	261; "../main.c"	SPI_SendData(SSCISPI_DateStruct.head);	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 0)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendData
	TRAPPC2	_SPI_SendData
	PAGESEL	_SPI_SendData
	CALL	_SPI_SendData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	262; "../main.c"	SSCISPI_DateStruct.checkvalue+=SSCISPI_DateStruct.Command;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : +
	BANKSEL	r0x101E
	MOV	R0, r0x101E
	BANKSEL	r0x101D
	ADD	r0x101D, R0
;	::->op :*  =
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	263; "../main.c"	SPI_SendData(SSCISPI_DateStruct.Command);	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendData
	TRAPPC2	_SPI_SendData
	PAGESEL	_SPI_SendData
	CALL	_SPI_SendData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	264; "../main.c"	SSCISPI_DateStruct.checkvalue+=SSCISPI_DateStruct.length;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : +
	BANKSEL	r0x101E
	MOV	R0, r0x101E
	BANKSEL	r0x101D
	ADD	r0x101D, R0
;	::->op :*  =
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	265; "../main.c"	SPI_SendData(SSCISPI_DateStruct.length);	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendData
	TRAPPC2	_SPI_SendData
	PAGESEL	_SPI_SendData
	CALL	_SPI_SendData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : =
;	.line	267; "../main.c"	for(i=0;i<SSCISPI_DateStruct.length;i++)
	BANKSEL	r0x101D
	CLR	r0x101D
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00087_DS_
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : <
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
	BANKSEL	r0x101D
	SUB	R0, r0x101D
;comparing bytes at offset 0
	JNB	PSW, 0
	JMP	_00090_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	269; "../main.c"	SSCISPI_DateStruct.checkvalue+=SSCISPI_DateStruct.buffer[i];
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : +
	BANKSEL	r0x101D
	MOV	R0, r0x101D
	ADD	R0,# (_SSCISPI_DateStruct + 4)
	BANKSEL	r0x1020
	MOV	r0x1020, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	r0x1020
	MOV	R1, r0x1020
	BANKSEL	_SSCISPI_DateStruct
	LD	R0, [R1]
	BANKSEL	r0x1021
	MOV	r0x1021, R0
;	::->op : +
	BANKSEL	r0x1021
	MOV	R0, r0x1021
	BANKSEL	r0x101E
	ADD	r0x101E, R0
;	::->op :*  =
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : +
;	.line	270; "../main.c"	SPI_SendData(SSCISPI_DateStruct.buffer[i]);	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	BANKSEL	r0x101D
	MOV	R0, r0x101D
	ADD	R0,# (_SSCISPI_DateStruct + 4)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	r0x101E
	MOV	R1, r0x101E
	BANKSEL	_SSCISPI_DateStruct
	LD	R0, [R1]
	BANKSEL	r0x101F
	MOV	r0x101F, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101F
	MOVZ	R0, r0x101F
	TRAPPC1	_SPI_SendData
	TRAPPC2	_SPI_SendData
	PAGESEL	_SPI_SendData
	CALL	_SPI_SendData
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : +
;	.line	267; "../main.c"	for(i=0;i<SSCISPI_DateStruct.length;i++)
	BANKSEL	r0x101D
	INC	r0x101D
;	::->op : GOTO
	JMP	_00087_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00090_DS_
;	.line	273; "../main.c"	if(SPI_SendAndReceive_Data(SSCISPI_DateStruct.checkvalue)!=SSCISPI_DateStruct.checkvalue)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : SEND
;	::->op : CALL
	BANKSEL	r0x101D
	MOVZ	R0, r0x101D
	TRAPPC1	_SPI_SendAndReceive_Data
	TRAPPC2	_SPI_SendAndReceive_Data
	PAGESEL	_SPI_SendAndReceive_Data
	CALL	_SPI_SendAndReceive_Data
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : EQ_OP
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
;	.line	278; "../main.c"	return (0);
	BANKSEL	r0x101D
	XOR	R0, r0x101D
	JNB	PSW, 2
	JMP	_00080_DS_
	MOV	R0,# 0x00
	JMP	_00091_DS_
;	::->op : LABEL
;	::->op : SEND
;	::->op : CALL
_00080_DS_
;	.line	280; "../main.c"	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : SEND
;	::->op : CALL
;	.line	282; "../main.c"	if(SPI_SendAndReceive_Data(0x00)!=SSCISPI_DateStruct.checkvalue)
	MOV	R0,# 0x00
	TRAPPC1	_SPI_SendAndReceive_Data
	TRAPPC2	_SPI_SendAndReceive_Data
	PAGESEL	_SPI_SendAndReceive_Data
	CALL	_SPI_SendAndReceive_Data
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
	BANKSEL	r0x101D
	MOV	r0x101D, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x101E
	MOV	r0x101E, R0
;	::->op : EQ_OP
	BANKSEL	r0x101E
	MOVZ	R0, r0x101E
;	.line	287; "../main.c"	return (0);
	BANKSEL	r0x101D
	XOR	R0, r0x101D
	JNB	PSW, 2
	JMP	_00082_DS_
	MOV	R0,# 0x00
	JMP	_00091_DS_
;	::->op : LABEL
;	::->op : SEND
;	::->op : CALL
_00082_DS_
;	.line	289; "../main.c"	Delay_Wait_CLK_Sample(50); // 给予从机响应时间
	MOV	R0,# 0x32
	TRAPPC1	_Delay_Wait_CLK_Sample
	TRAPPC2	_Delay_Wait_CLK_Sample
	PAGESEL	_Delay_Wait_CLK_Sample
	CALL	_Delay_Wait_CLK_Sample
	TRAPPC1	$+2
	TRAPPC2	$+1
	PAGESEL	$
;	::->op : RETURN
;	.line	294; "../main.c"	return (1);
	MOV	R0,# 0x01
;	::->op : LABEL
;	::->op : ENDFUNCTION
_00091_DS_
	CRET	
; exit point of _SPI_Master_ISR_Simulate



func._SPI_Slave_ISR_Server	.code
;***
;  PostBlock Stats: dbName = C
;***
;entry:  _SPI_Slave_ISR_Server	;Function start
; 2 exit points
;has an exit
;6 compiler assigned registers:
;   r0x1023
;   r0x1024
;   r0x1025
;   r0x1026
;   r0x1027
;   r0x1028
;; Starting PostCode block
;	::->op : LABEL
;	::->op : FUNCTION
_SPI_Slave_ISR_Server	;Function start
; 2 exit points
;	::->op :*  =
;	.line	56; "../main.c"	SSCI1OV=0;// 节省判断的强制清溢出可能，根据应答设计保证不溢出即可，评估系统时可以判断溢出标志识别接收处理
	BANKSEL	_SSCI1CTL0_bits
	CLR	_SSCI1CTL0_bits, 6
;	::->op : =
;	.line	57; "../main.c"	RevDate=SSCI1BUFR;
	BANKSEL	_SSCI1BUFR
	MOVZ	R0, _SSCI1BUFR
	BANKSEL	r0x1023
	MOV	r0x1023, R0
;	::->op : GET_VALUE_AT_ADDRESS
;	::->op : !
;	::->op :*  =
;	.line	58; "../main.c"	P9LR1=!P9LR1;   // 调试时观察响应及时性，程序进入代码时间内，主机不要启动时钟，否则应答会反应不过来
	BANKSEL	_P9LR_bits
	JB	_P9LR_bits, 1
	JMP	_00069_DS_
	BANKSEL	_P9LR_bits
	CLR	_P9LR_bits, 1
	JMP	_00070_DS_
_00069_DS_
	BANKSEL	_P9LR_bits
	SET	_P9LR_bits, 1
;	::->op : GET_VALUE_AT_ADDRESS
_00070_DS_
;	.line	66; "../main.c"	if(!Is_Responses_IN_Return)
	BANKSEL	(_SSCISPI_DateStruct+2)
	JNB	(_SSCISPI_DateStruct+2), 7
	JMP	_00043_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	69; "../main.c"	if(SSCISPI_DateStruct.assistant==0)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 15)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : IFX
	MOV	R0,# 0x00
	BANKSEL	r0x1024
	ORL	R0, r0x1024
	JB	PSW, 2
	JMP	_00035_DS_
;	::->op : EQ_OP
;	.line	71; "../main.c"	if(RevDate!=0x68)  // 设计的固定起始格式
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
;	.line	73; "../main.c"	return;
	XOR	R0,# 0x68
;	.line	77; "../main.c"	SSCI1BUFR=RevDate;// 样例 观察的 返回
	JB	PSW, 2
	JMP	_00049_DS_
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op :*  =
;	.line	78; "../main.c"	SSCISPI_DateStruct.head=RevDate;  // 根据选择保存
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 0), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	79; "../main.c"	SSCISPI_DateStruct.assistant++;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 15)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : +
	BANKSEL	r0x1024
	INC	r0x1024
;	::->op :*  =
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 15), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	81; "../main.c"	SSCISPI_DateStruct.checkvalue=SSCISPI_DateStruct.head;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 0)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op :*  =
;;100	MOVZ	R0, r0x1024
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00035_DS_
;	.line	85; "../main.c"	else if(SSCISPI_DateStruct.assistant==1)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 15)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : EQ_OP
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	XOR	R0,# 0x01
	JB	PSW, 2
	JMP	_00032_DS_
;	::->op : =
;	.line	87; "../main.c"	SSCI1BUFR=RevDate;// 样例 观察的 返回
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op :*  =
;	.line	88; "../main.c"	SSCISPI_DateStruct.Command=RevDate;   //  命令编码或资源地址，这里为资源地址
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 1), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	89; "../main.c"	SSCISPI_DateStruct.assistant++;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 15)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : +
	BANKSEL	r0x1024
	INC	r0x1024
;	::->op :*  =
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 15), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	90; "../main.c"	SSCISPI_DateStruct.checkvalue+=SSCISPI_DateStruct.Command;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x1025
	MOV	r0x1025, R0
;	::->op : +
	BANKSEL	r0x1025
	MOV	R0, r0x1025
	BANKSEL	r0x1024
	ADD	r0x1024, R0
;	::->op :*  =
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	92; "../main.c"	if(SSCISPI_DateStruct.Command&0x80)      //先去看主控模式中的相关控制命令
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : BITWISEAND
	BANKSEL	r0x1024
	JB	r0x1024, 7
	JMP	_00007_DS_
;	::->op :*  =
;	.line	94; "../main.c"	Is_Command_Read=1;
	BANKSEL	(_SSCISPI_DateStruct+2)
	SET	(_SSCISPI_DateStruct+2), 6
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	95; "../main.c"	SSCISPI_DateStruct.Command=SSCISPI_DateStruct.Command&0x7F;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : BITWISEAND
	BANKSEL	r0x1024
	CLR	r0x1024, 7
;	::->op :*  =
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 1), R0
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op :*  =
_00007_DS_
;	.line	99; "../main.c"	Is_Command_Read=0;
	BANKSEL	(_SSCISPI_DateStruct+2)
	CLR	(_SSCISPI_DateStruct+2), 6
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00032_DS_
;	.line	103; "../main.c"	else if(SSCISPI_DateStruct.assistant==2)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 15)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : EQ_OP
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	XOR	R0,# 0x02
	JB	PSW, 2
	JMP	_00029_DS_
;	::->op :*  =
;	.line	107; "../main.c"	SSCISPI_DateStruct.length=RevDate;
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 3), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	108; "../main.c"	SSCISPI_DateStruct.checkvalue+=SSCISPI_DateStruct.length;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x1025
	MOV	r0x1025, R0
;	::->op : +
	BANKSEL	r0x1025
	MOV	R0, r0x1025
	BANKSEL	r0x1024
	ADD	r0x1024, R0
;	::->op :*  =
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	111; "../main.c"	if(Is_Command_Read)
	BANKSEL	(_SSCISPI_DateStruct+2)
	JB	(_SSCISPI_DateStruct+2), 6
	JMP	_00010_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	113; "../main.c"	SSCI1BUFR=SSCISPI_DateStruct.checkvalue;  // 同步返回校验和
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op :*  =
;	.line	114; "../main.c"	SSCISPI_DateStruct.assistant=3; // 数据传递偏移
	MOV	R0,# 0x03
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 15), R0
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op :*  =
_00010_DS_
;	.line	119; "../main.c"	SSCISPI_DateStruct.assistant=4;
	MOV	R0,# 0x04
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 15), R0
;	::->op : =
;	.line	120; "../main.c"	DataBuf_index=0;
	BANKSEL	_DataBuf_index
	CLR	_DataBuf_index
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00029_DS_
;	.line	124; "../main.c"	else if(SSCISPI_DateStruct.assistant==3)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 15)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : EQ_OP
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	XOR	R0,# 0x03
	JB	PSW, 2
	JMP	_00026_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	126; "../main.c"	if(RevDate==SSCISPI_DateStruct.checkvalue)							  //
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : EQ_OP
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	r0x1023
	XOR	R0, r0x1023
	JB	PSW, 2
	JMP	_00013_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	128; "../main.c"	SSCISPI_DateStruct.checkvalue=SSCISPI_DateStruct.buffer[SSCISPI_DateStruct.Command++];
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : +
	BANKSEL	r0x1024
	INCR	r0x1024
	BANKSEL	r0x1025
	MOV	r0x1025, R0
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 1), R0
;	::->op :*  =
;;103	MOVZ	R0, r0x1025
;	::->op : +
	MOV	R0,# (_SSCISPI_DateStruct + 4)
	BANKSEL	r0x1024
	ADD	r0x1024, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	r0x1024
	MOV	R1, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	LD	R0, [R1]
;;1	MOV	r0x1026, R0
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op :*  =
;;99	MOVZ	R0, r0x1026
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	129; "../main.c"	SSCI1BUFR=SSCISPI_DateStruct.checkvalue;  //
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op :*  =
;	.line	131; "../main.c"	Is_Responses_IN_Return=1;
	BANKSEL	(_SSCISPI_DateStruct+2)
	SET	(_SSCISPI_DateStruct+2), 7
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : =
_00013_DS_
;	.line	135; "../main.c"	SSCI1BUFR=0x01;  //  即使主机读取也会识别从机未应答，数据最后校验和会否决的可靠设计
	MOV	R0,# 0x01
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op :*  =
;	.line	136; "../main.c"	SSCISPI_DateStruct.assistant=0;
	BANKSEL	_SSCISPI_DateStruct
	CLR	 (_SSCISPI_DateStruct + 15)
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00026_DS_
;	.line	140; "../main.c"	else if(SSCISPI_DateStruct.assistant==4)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 15)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : EQ_OP
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	XOR	R0,# 0x04
	JB	PSW, 2
	JMP	_00049_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	142; "../main.c"	if(DataBuf_index==SSCISPI_DateStruct.length)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : EQ_OP
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_DataBuf_index
	XOR	R0, _DataBuf_index
	JB	PSW, 2
	JMP	_00021_DS_
;	::->op :*  =
;	.line	144; "../main.c"	Is_Responses_IN_Return=0; 			// 命令完成回到接收机状态
	BANKSEL	(_SSCISPI_DateStruct+2)
	CLR	(_SSCISPI_DateStruct+2), 7
;	::->op :*  =
;	.line	145; "../main.c"	SSCISPI_DateStruct.assistant=0; 	// 接收状态，回到接收起始头
	BANKSEL	_SSCISPI_DateStruct
	CLR	 (_SSCISPI_DateStruct + 15)
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	147; "../main.c"	if(RevDate==SSCISPI_DateStruct.checkvalue)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : EQ_OP
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	r0x1023
	XOR	R0, r0x1023
	JB	PSW, 2
	JMP	_00016_DS_
;	::->op : =
;	.line	149; "../main.c"	for(RevDate=0;RevDate<SSCISPI_DateStruct.length;RevDate++)
	BANKSEL	r0x1024
	CLR	r0x1024
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00045_DS_
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x1025
	MOV	r0x1025, R0
;	::->op : <
	BANKSEL	r0x1025
	MOVZ	R0, r0x1025
	BANKSEL	r0x1024
	SUB	R0, r0x1024
;comparing bytes at offset 0
	JNB	PSW, 0
	JMP	_00016_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	151; "../main.c"	SSCISPI_DateStruct.buffer[SSCISPI_DateStruct.Command+RevDate]=DataBuf[RevDate];
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x1025
	MOV	r0x1025, R0
;	::->op : +
	BANKSEL	r0x1024
	MOV	R0, r0x1024
	BANKSEL	r0x1025
	ADD	r0x1025, R0
;	::->op : +
	MOV	R0,# (_SSCISPI_DateStruct + 4)
	BANKSEL	r0x1025
	ADD	r0x1025, R0
;	::->op : +
	BANKSEL	r0x1024
	MOV	R0, r0x1024
	ADD	R0,# (_DataBuf + 0)
	BANKSEL	r0x1027
	MOV	r0x1027, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	r0x1027
	MOV	R1, r0x1027
	BANKSEL	_DataBuf
	LD	R0, [R1]
	BANKSEL	r0x1028
	MOV	r0x1028, R0
;	::->op :*  =
	BANKSEL	r0x1028
	MOVZ	R0, r0x1028
	BANKSEL	r0x1025
	MOV	R1, r0x1025
	BANKSEL	_SSCISPI_DateStruct
	ST	[R1], R0
;	::->op : +
;	.line	149; "../main.c"	for(RevDate=0;RevDate<SSCISPI_DateStruct.length;RevDate++)
	BANKSEL	r0x1024
	INC	r0x1024
;	::->op : GOTO
	JMP	_00045_DS_
;	::->op : LABEL
;	::->op :*  =
_00016_DS_
;	.line	154; "../main.c"	SPI_SLAVE_ANSWERED=1;
	BANKSEL	(_SSCISPI_DateStruct+2)
	SET	(_SSCISPI_DateStruct+2), 1
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00021_DS_
;	.line	156; "../main.c"	else if(DataBuf_index<SSCISPI_DateStruct.length)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : <
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_DataBuf_index
	SUB	R0, _DataBuf_index
;comparing bytes at offset 0
	JNB	PSW, 0
	JMP	_00018_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	158; "../main.c"	SSCISPI_DateStruct.checkvalue+=RevDate;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : +
	BANKSEL	r0x1023
	MOV	R0, r0x1023
	BANKSEL	r0x1024
	ADD	r0x1024, R0
;	::->op :*  =
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : =
;	.line	159; "../main.c"	DataBuf[DataBuf_index++]=RevDate; // 读取到缓存
	BANKSEL	_DataBuf_index
	MOVZ	R0, _DataBuf_index
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : +
	BANKSEL	_DataBuf_index
	INC	_DataBuf_index
;	::->op : +
	MOV	R0,# (_DataBuf + 0)
	BANKSEL	r0x1024
	ADD	r0x1024, R0
;	::->op :*  =
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	r0x1024
	MOV	R1, r0x1024
	BANKSEL	_DataBuf
	ST	[R1], R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	160; "../main.c"	SSCI1BUFR=SSCISPI_DateStruct.checkvalue;  // 实时返回校验和
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00018_DS_
;	.line	164; "../main.c"	SSCI1BUFR=SSCISPI_DateStruct.checkvalue;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op : GOTO
	JMP	_00049_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00043_DS_
;	.line	174; "../main.c"	if(SSCISPI_DateStruct.Command	<	SSCISPI_DateStruct.length)
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 3)
	BANKSEL	r0x1025
	MOV	r0x1025, R0
;	::->op : <
	BANKSEL	r0x1025
	MOVZ	R0, r0x1025
	BANKSEL	r0x1024
	SUB	R0, r0x1024
;comparing bytes at offset 0
	JNB	PSW, 0
	JMP	_00038_DS_
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	176; "../main.c"	DataBuf_index=SSCISPI_DateStruct.buffer[SSCISPI_DateStruct.Command++];
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 1)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : +
	BANKSEL	r0x1024
	INCR	r0x1024
	BANKSEL	r0x1025
	MOV	r0x1025, R0
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 1), R0
;	::->op :*  =
;;101	MOVZ	R0, r0x1025
;	::->op : +
	MOV	R0,# (_SSCISPI_DateStruct + 4)
	BANKSEL	r0x1024
	ADD	r0x1024, R0
;	::->op : GET_VALUE_AT_ADDRESS
	BANKSEL	r0x1024
	MOV	R1, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	LD	R0, [R1]
	BANKSEL	_DataBuf_index
	MOV	_DataBuf_index, R0
;	::->op : GET_VALUE_AT_ADDRESS
;	.line	177; "../main.c"	SSCISPI_DateStruct.checkvalue+=DataBuf_index;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	r0x1024
	MOV	r0x1024, R0
;	::->op : +
	BANKSEL	_DataBuf_index
	MOV	R0, _DataBuf_index
	BANKSEL	r0x1024
	ADD	r0x1024, R0
;	::->op :*  =
	BANKSEL	r0x1024
	MOVZ	R0, r0x1024
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op : =
;	.line	178; "../main.c"	SSCI1BUFR=DataBuf_index;
	BANKSEL	_DataBuf_index
	MOVZ	R0, _DataBuf_index
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op : GOTO
	JMP	_00039_DS_
;	::->op : LABEL
;	::->op : GET_VALUE_AT_ADDRESS
_00038_DS_
;	.line	182; "../main.c"	SSCI1BUFR=SSCISPI_DateStruct.checkvalue;
	BANKSEL	_SSCISPI_DateStruct
	MOVZ	R0,  (_SSCISPI_DateStruct + 14)
	BANKSEL	_SSCI1BUFR
	MOV	_SSCI1BUFR, R0
;	::->op :*  =
;	.line	183; "../main.c"	Is_Responses_IN_Return=0;
	BANKSEL	(_SSCISPI_DateStruct+2)
	CLR	(_SSCISPI_DateStruct+2), 7
;	::->op :*  =
;	.line	184; "../main.c"	SSCISPI_DateStruct.assistant=0;
	BANKSEL	_SSCISPI_DateStruct
	CLR	 (_SSCISPI_DateStruct + 15)
;	::->op :*  =
;	.line	186; "../main.c"	SPI_SLAVE_ANSWERED=1;
	BANKSEL	(_SSCISPI_DateStruct+2)
	SET	(_SSCISPI_DateStruct+2), 1
;	::->op :*  =
;	.line	187; "../main.c"	SPI_SLAVE_ANSWERED=0;
	BANKSEL	(_SSCISPI_DateStruct+2)
	CLR	(_SSCISPI_DateStruct+2), 1
;	::->op : LABEL
;	::->op : EQ_OP
_00039_DS_
;	.line	190; "../main.c"	if(RevDate==0x68)
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	XOR	R0,# 0x68
	JB	PSW, 2
	JMP	_00049_DS_
;	::->op :*  =
;	.line	192; "../main.c"	Is_Responses_IN_Return=0;
	BANKSEL	(_SSCISPI_DateStruct+2)
	CLR	(_SSCISPI_DateStruct+2), 7
;	::->op :*  =
;	.line	194; "../main.c"	SSCISPI_DateStruct.head=RevDate;
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 0), R0
;	::->op :*  =
;	.line	195; "../main.c"	SSCISPI_DateStruct.checkvalue=RevDate;
	BANKSEL	r0x1023
	MOVZ	R0, r0x1023
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 14), R0
;	::->op :*  =
;	.line	196; "../main.c"	SSCISPI_DateStruct.assistant=1;
	MOV	R0,# 0x01
	BANKSEL	_SSCISPI_DateStruct
	MOV	 (_SSCISPI_DateStruct + 15), R0
;	::->op : LABEL
;	::->op : ENDFUNCTION
_00049_DS_
	CRET	
; exit point of _SPI_Slave_ISR_Server



func._Delay_Wait_CLK_Sample	.code
;***
;  PostBlock Stats: dbName = C
;***
;entry:  _Delay_Wait_CLK_Sample	;Function start
; 2 exit points
;has an exit
;; Starting PostCode block
;	::->op : LABEL
;	::->op : FUNCTION
_Delay_Wait_CLK_Sample	;Function start
; 2 exit points
;	::->op : INLINEASM
	;
	;
	DECJZ R0
	JMP $-1
	
;	::->op : LABEL
;	::->op : ENDFUNCTION
	CRET	
; exit point of _Delay_Wait_CLK_Sample


;	code size estimation:
;	  728+  364 =  1092 instructions ( 2912 byte)


	.end
