; Generated by holtek-gcc v3.19, Mon Jan 06 09:49:12 2025
; 
; Configuration:
;       with long instruction
;       Single ROM, Multi-RAM
;       bits_per_rom_unit:16
;       with mp1
;       with tbhp, address(0x9)
;          Use tabrd-const
;       
; SFR address of long-instruction arch:
;    mp0 = -1,1,0
;    mp1 = 4,3,2
;    mp2 = 14,13,12
;    tbp = 9,7,8
;    acc = 5
;    pcl = 6
;    status = 10
;    bp = 11
;    intc = 32
;       
;       
; use 'tabrdc' instead of 'tabrd'
;       

#pragma translator "holtek-gcc 4.6.4" "3.19" "build 20130711"
; Rebuild 718

ir equ [2]
mp equ [3]
sbp equ [4]
acc equ [5]
bp equ [11]
tblp equ [7]
tbhp equ [9]
status equ [10]
c equ [10].0
ac equ [10].1
z equ [10].2
ov equ [10].3
cz equ [10].6
sc equ [10].7
intc equ [32]

extern ra:byte
extern rb:byte
extern rc:byte
extern rd:byte
extern re:byte
extern rf:byte
extern rg:byte
extern rh:byte
extern _Crom2Prom:near
extern _Crom2PromNext:near

RAMBANK 0 @BITDATASEC, @BITDATASEC1
@HCCINIT	.section 'data'
@HCCINIT0	.section 'data'
@BITDATASEC	 .section 'data'
@BITDATASEC1	 .section 'data'

#pragma debug scope 1 1
	extern __DELAY3:near
	extern __DELAYX3:near
	extern __DELAYX6:near
	extern __DELAYY5:near
	extern __DELAYY3:near
	extern _builtin_holtek_delay_2:byte
___adcs equ [93]
___sinc3 equ [95]
___adcr0 equ [89]
___adcr1 equ [90]
___pgac equ [83]
___modc equ [85]
___pgacs equ [84]
___pas0 equ [123]
___pwrc equ [68]
___ctrl equ [100]
___adacctrl equ [96]
___autoadcc equ [101]
___errchkc equ [102]
public _Adc24_Cfg
#pragma debug scope 2 1
#line 122 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
_Adc24_Cfg .section 'code'
_Adc24_Cfg proc
public _Adc24_Cfg_2
    local _Adc24_Cfg_2 db 7 dup(?)	; 7,0
#pragma debug struct_begin 42 ""
#pragma debug field 0 8 "sampleRate"
#pragma debug field 0 8 "gain"
#pragma debug field 0 8 "channel"
#pragma debug field 0 8 "dataSkip"
#pragma debug field 0 8 "dataAvgCnt"
#pragma debug field 0 8 "autoWriteNum"
#pragma debug field 0 8 "errCheck"
#pragma debug struct_end
#pragma debug variable 42 2 _Adc24_Cfg_2+0 "cfg"
	mov a,_Adc24_Cfg_2[1]
	mov rc,a
	mov a,_Adc24_Cfg_2[2]
	mov rb,a
	mov a,_Adc24_Cfg_2[5]
	mov ra,a
#line 124 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_Adc24_Cfg_2[0]
	sub a,0
	sz z
	jmp _L3
	sub a,(1)-(0)
	sz z
	jmp _L4
#line 124 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_Adc24_Cfg_2[0]
	sub a,2
	sz z
	jmp _L5
	sub a,(3)-(2)
	sz z
	jmp _L6
	mov a,_Adc24_Cfg_2[0]
	sub a,4
	sz z
	jmp _L7
	sub a,(5)-(4)
	sz z
	jmp _L8
	mov a,_Adc24_Cfg_2[0]
	sub a,6
	sz z
	jmp _L9
	sub a,(7)-(6)
	sz z
	jmp _L10
	mov a,_Adc24_Cfg_2[0]
	sub a,8
	sz z
	jmp _L11
	sub a,(9)-(8)
	sz z
	jmp _L12
	mov a,_Adc24_Cfg_2[0]
	sub a,10
	sz z
	jmp _L13
	sub a,(11)-(10)
	sz z
	jmp _L14
	mov a,_Adc24_Cfg_2[0]
	sub a,12
	sz z
	jmp _L15
	sub a,(13)-(12)
	sz z
	jmp _L16
	mov a,_Adc24_Cfg_2[0]
	sub a,14
	sz z
	jmp _L17
	sub a,(15)-(14)
	sz z
	jmp _L18
	mov a,_Adc24_Cfg_2[0]
	sub a,16
	sz z
	jmp _L19
	sub a,(17)-(16)
	sz z
	jmp _L20
	mov a,_Adc24_Cfg_2[0]
	sub a,18
	sz z
	jmp _L21
	sub a,(19)-(18)
	sz z
	jmp _L22
	mov a,_Adc24_Cfg_2[0]
	sub a,20
	sz z
	jmp _L23
	sub a,(21)-(20)
	sz z
	jmp _L24
	mov a,_Adc24_Cfg_2[0]
	sub a,22
	sz z
	jmp _L25
	sub a,(23)-(22)
	sz z
	jmp _L26
	mov a,_Adc24_Cfg_2[0]
	sub a,24
	sz z
	jmp _L27
	sub a,(25)-(24)
	sz z
	jmp _L28
	mov a,_Adc24_Cfg_2[0]
	sub a,26
	snz z
	jmp _L2
#line 167 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,16
	mov [89],a
	jmp _L38
_L21:
#line 159 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	clr [89]
	jmp _L38
_L22:
#line 160 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,2
	mov [89],a
_L38:
	mov a,16
	mov [90],a
	jmp _L2
_L23:
#line 161 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,4
	mov [89],a
	jmp _L38
_L24:
#line 162 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,6
	mov [89],a
	jmp _L38
_L25:
#line 163 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,8
	mov [89],a
	jmp _L38
_L26:
#line 164 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,10
	mov [89],a
	jmp _L38
_L27:
#line 165 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,12
	mov [89],a
	jmp _L38
_L28:
#line 166 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,14
	mov [89],a
	jmp _L38
_L3:
#line 169 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	clr [89]
	jmp _L40
_L4:
#line 170 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,2
	mov [89],a
	jmp _L40
_L5:
#line 171 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	clr [89]
	jmp _L39
_L6:
#line 172 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,4
	mov [89],a
	jmp _L40
_L7:
#line 173 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,2
	mov [89],a
	jmp _L39
_L8:
#line 174 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,6
	mov [89],a
	jmp _L40
_L9:
#line 175 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,4
	mov [89],a
	jmp _L39
_L10:
#line 176 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,8
	mov [89],a
	jmp _L40
_L11:
#line 177 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,6
	mov [89],a
	jmp _L39
_L12:
#line 178 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,10
	mov [89],a
	jmp _L40
_L13:
#line 179 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,8
	mov [89],a
	jmp _L39
_L14:
#line 180 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,12
	mov [89],a
	jmp _L40
_L15:
#line 181 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,10
	mov [89],a
	jmp _L39
_L16:
#line 182 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,14
	mov [89],a
	jmp _L40
_L17:
#line 183 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,12
	mov [89],a
	jmp _L39
_L18:
#line 184 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,16
	mov [89],a
_L40:
	clr [90]
	jmp _L2
_L19:
#line 185 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,14
	mov [89],a
	jmp _L39
_L20:
#line 186 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,31
	mov [93],a
	mov a,144
	mov [95],a
	mov a,16
	mov [89],a
_L39:
	mov a,64
	mov [90],a
_L2:
#line 194 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,rc
	mov [83],a
#line 195 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,rc
	sub a,128
	snz z
	jmp _L30
#line 197 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [85].1
#line 198 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [85].0
	jmp _L31
_L30:
#line 202 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [85].1
#line 203 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [85].0
_L31:
#line 207 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,rb
	mov [84],a
#line 208 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,rb
	sub a,221
	snz z
	jmp _L32
#line 210 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [123].7
	set [123].6
#line 211 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [123].3
	set [123].2
_L32:
#line 213 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [68].3
#line 214 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[84]
	sub a,188
	snz z
	jmp _L33
#line 216 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [68].3
_L33:
#line 220 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_Adc24_Cfg_2[3]
	mov [100],a
#line 223 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_Adc24_Cfg_2[4]
	mov [96],a
#line 226 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	snz ra
	jmp _L34
#line 228 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	dec ra
	mov a,ra
	add a,ra
	mov [101],a
_L34:
#line 232 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_Adc24_Cfg_2[6]
	mov [102],a
	ret
_Adc24_Cfg endp
#line 232 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
#pragma debug scope 1 1
public _Adc24_Enable
#pragma debug scope 3 1
#line 239 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
_Adc24_Enable .section 'code'
_Adc24_Enable proc
public _Adc24_Enable_2
    local _Adc24_Enable_2 db 7 dup(?)	; 7,0
#pragma debug struct_begin 43 ""
#pragma debug field 0 8 "sampleRate"
#pragma debug field 0 8 "gain"
#pragma debug field 0 8 "channel"
#pragma debug field 0 8 "dataSkip"
#pragma debug field 0 8 "dataAvgCnt"
#pragma debug field 0 8 "autoWriteNum"
#pragma debug field 0 8 "errCheck"
#pragma debug struct_end
#pragma debug variable 43 3 _Adc24_Enable_2+0 "cfg"
#line 241 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	snz _Adc24_Enable_2[5]
	jmp _L43
#line 243 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [85].0
	clr [85].3
	clr [90].2
	set [101].7
	clr [96].6
	jmp _L44
_L43:
#line 247 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [85].3
#line 248 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [85].2
	set [85].2
	clr [85].2
	clr [90].2
	clr [101].7
	clr [90].1
_L44:
#line 250 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[4]
	clr _adc24SourceData[5]
#line 251 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[6].0
	ret
_Adc24_Enable endp
#line 251 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
#pragma debug scope 1 1
public _Adc24_Disable
#pragma debug scope 4 1
#line 258 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
_Adc24_Disable .section 'code'
_Adc24_Disable proc
#line 259 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[6].0
#line 260 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[4]
	clr _adc24SourceData[5]
#line 261 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [85].0
	clr [85].3
	ret
_Adc24_Disable endp
#line 261 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
#pragma debug scope 1 1
___adrl_avg equ [97]
___adrm_avg equ [98]
___adrh_avg equ [99]
___adrl equ [86]
___adrm equ [87]
___adrh equ [88]
public _Adc24_Poling
#pragma debug scope 5 1
#line 265 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
_Adc24_Poling .section 'code'
_Adc24_Poling proc
#line 266 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	snz [96].6
	jmp _L47
#line 268 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	inc _adc24SourceData[4]
	sz z
	inc _adc24SourceData[5]
#line 270 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,3
	sub a,_adc24SourceData[4]
	mov a,0
	sbc a,_adc24SourceData[5]
	sz c
	jmp _L48
#line 273 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [90].2
#line 274 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[0]
#line 275 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[97]
	mov _adc24SourceData[1],a
#line 276 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[98]
	mov _adc24SourceData[2],a
#line 277 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[99]
	mov _adc24SourceData[3],a
#line 278 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [90].2
#line 279 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_adc24SourceData[1]
	mov _adc24SourceData[0],a
	mov a,_adc24SourceData[2]
	mov _adc24SourceData[1],a
	mov a,_adc24SourceData[3]
	mov _adc24SourceData[2],a
	clr _adc24SourceData[3]
	sz _adc24SourceData[2].7
	set _adc24SourceData[3]
#line 280 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set _adc24SourceData[6].0
_L48:
#line 282 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [96].6
_L47:
#line 284 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	snz [90].1
	jmp _L46
#line 287 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	inc _adc24SourceData[4]
	sz z
	inc _adc24SourceData[5]
#line 289 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,3
	sub a,_adc24SourceData[4]
	mov a,0
	sbc a,_adc24SourceData[5]
	sz c
	jmp _L50
#line 292 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [90].2
#line 293 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[0]
#line 294 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[86]
	mov _adc24SourceData[1],a
#line 295 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[87]
	mov _adc24SourceData[2],a
#line 296 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[88]
	mov _adc24SourceData[3],a
#line 297 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [90].2
#line 298 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_adc24SourceData[1]
	mov _adc24SourceData[0],a
	mov a,_adc24SourceData[2]
	mov _adc24SourceData[1],a
	mov a,_adc24SourceData[3]
	mov _adc24SourceData[2],a
	clr _adc24SourceData[3]
	sz _adc24SourceData[2].7
	set _adc24SourceData[3]
#line 299 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set _adc24SourceData[6].0
_L50:
#line 301 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [90].1
_L46:
	ret
_Adc24_Poling endp
#line 301 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
#pragma debug scope 1 1
public _ADC_ISR
#pragma debug scope 6 1
#line 311 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
@ADC_ISR_code .section at 12 'code'
ifdef INTERRUPT_DELAY
	nop
endif
	mov r1,a
	mov a,status
ifndef INTERRUPT_DELAY
	mov r2,a
endif
	jmp _ADC_ISR
#pragma debug scope 1 1
@dummy12 proc
	call _ADC_ISR
@dummy12 endp
#pragma debug scope 7 1
_ADC_ISR .section 'code'
_ADC_ISR proc
ifdef INTERRUPT_DELAY
	mov r2,a
endif
#line 312 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	snz [96].6
	jmp _L58
#line 314 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	inc _adc24SourceData[4]
	sz z
	inc _adc24SourceData[5]
#line 316 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,3
	sub a,_adc24SourceData[4]
	mov a,0
	sbc a,_adc24SourceData[5]
	sz c
	jmp _L59
#line 319 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [90].2
#line 320 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[0]
#line 321 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[97]
	mov _adc24SourceData[1],a
#line 322 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[98]
	mov _adc24SourceData[2],a
#line 323 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[99]
	mov _adc24SourceData[3],a
#line 324 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [90].2
#line 325 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_adc24SourceData[1]
	mov _adc24SourceData[0],a
	mov a,_adc24SourceData[2]
	mov _adc24SourceData[1],a
	mov a,_adc24SourceData[3]
	mov _adc24SourceData[2],a
	clr _adc24SourceData[3]
	sz _adc24SourceData[2].7
	set _adc24SourceData[3]
#line 326 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set _adc24SourceData[6].0
_L59:
#line 328 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [96].6
_L58:
#line 330 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	snz [90].1
	jmp _L57
#line 333 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	inc _adc24SourceData[4]
	sz z
	inc _adc24SourceData[5]
#line 335 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,3
	sub a,_adc24SourceData[4]
	mov a,0
	sbc a,_adc24SourceData[5]
	sz c
	jmp _L61
#line 338 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set [90].2
#line 339 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr _adc24SourceData[0]
#line 340 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[86]
	mov _adc24SourceData[1],a
#line 341 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[87]
	mov _adc24SourceData[2],a
#line 342 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,[88]
	mov _adc24SourceData[3],a
#line 343 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [90].2
#line 344 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	mov a,_adc24SourceData[1]
	mov _adc24SourceData[0],a
	mov a,_adc24SourceData[2]
	mov _adc24SourceData[1],a
	mov a,_adc24SourceData[3]
	mov _adc24SourceData[2],a
	clr _adc24SourceData[3]
	sz _adc24SourceData[2].7
	set _adc24SourceData[3]
#line 345 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	set _adc24SourceData[6].0
_L61:
#line 347 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
	clr [90].1
_L57:
	mov a,r2
	mov status,a
	mov a,r1
	reti
_ADC_ISR endp

#line 347 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
#pragma debug scope 1 1
#line 114 "d:\d200\product\git\bh66f2455_evm_cgm\2.code\bh66f2455_driver\driver\Adc24.c"
public _adc24SourceData
@HCCINIT0_adc24SourceData .section 'data'
_adc24SourceData	db 7 dup(0)
#pragma debug struct_begin 44 ""
#pragma debug field 0 8 "byteLow"
#pragma debug field 0 8 "byteMid"
#pragma debug field 0 8 "byteHigh"
#pragma debug field 0 8 "byteRes"
#pragma debug struct_end
#pragma debug union_begin 45 ""
#pragma debug field 2 44 "byte"
#pragma debug field 0 13 "adcData"
#pragma debug union_end
#pragma debug struct_begin 46 ""
#pragma debug field 21 8 0 1 "isReady" ;0,1
#pragma debug struct_end
#pragma debug union_begin 47 ""
#pragma debug field 2 46 "b"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug struct_begin 48 ""
#pragma debug field 3 45 "data"
#pragma debug field 0 12 "samplingCnt"
#pragma debug field 3 47 "flag"
#pragma debug struct_end
#pragma debug variable 48 1 _adc24SourceData "adc24SourceData"

@HCCINIT .section 'data'
#pragma debug struct_begin 49 "__pwrc_bits"
#pragma debug field 21 8 0 3 ;0,3
#pragma debug field 21 8 0 1 "__vdetecten" ;3,1
#pragma debug field 21 8 0 4 ;4,4
#pragma debug struct_end
#pragma debug union_begin 50 ""
#pragma debug field 2 49 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 50 1 ___pwrc "__pwrc" 1
#pragma debug struct_begin 51 "__pgac_bits"
#pragma debug field 21 8 0 1 "__pgs0" ;0,1
#pragma debug field 21 8 0 1 "__pgs1" ;1,1
#pragma debug field 21 8 0 1 "__pgs2" ;2,1
#pragma debug field 21 8 0 1 "__ags" ;3,1
#pragma debug field 21 8 0 1 "__inx0" ;4,1
#pragma debug field 21 8 0 1 "__inx1" ;5,1
#pragma debug field 21 8 0 1 "__inis" ;6,1
#pragma debug field 21 8 0 1 ;7,1
#pragma debug struct_end
#pragma debug union_begin 52 ""
#pragma debug field 2 51 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 52 1 ___pgac "__pgac" 1
#pragma debug struct_begin 53 "__pgacs_bits"
#pragma debug field 21 8 0 1 "__chsp0" ;0,1
#pragma debug field 21 8 0 1 "__chsp1" ;1,1
#pragma debug field 21 8 0 1 "__chsp2" ;2,1
#pragma debug field 21 8 0 1 "__chsp3" ;3,1
#pragma debug field 21 8 0 1 "__chsn0" ;4,1
#pragma debug field 21 8 0 1 "__chsn1" ;5,1
#pragma debug field 21 8 0 1 "__chsn2" ;6,1
#pragma debug field 21 8 0 1 "__chsn3" ;7,1
#pragma debug struct_end
#pragma debug union_begin 54 ""
#pragma debug field 2 53 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 54 1 ___pgacs "__pgacs" 1
#pragma debug struct_begin 55 "__modc_bits"
#pragma debug field 21 8 0 1 "__pgaen" ;0,1
#pragma debug field 21 8 0 1 "__pgabps" ;1,1
#pragma debug field 21 8 0 1 "__adrst" ;2,1
#pragma debug field 21 8 0 1 "__aden" ;3,1
#pragma debug field 21 8 0 4 ;4,4
#pragma debug struct_end
#pragma debug union_begin 56 ""
#pragma debug field 2 55 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 56 1 ___modc "__modc" 1
#pragma debug variable 8 1 ___adrl "__adrl" 1
#pragma debug variable 8 1 ___adrm "__adrm" 1
#pragma debug variable 8 1 ___adrh "__adrh" 1
#pragma debug struct_begin 57 "__adcr0_bits"
#pragma debug field 21 8 0 1 ;0,1
#pragma debug field 21 8 0 1 "__ador0" ;1,1
#pragma debug field 21 8 0 1 "__ador1" ;2,1
#pragma debug field 21 8 0 1 "__ador2" ;3,1
#pragma debug field 21 8 0 1 "__ador3" ;4,1
#pragma debug field 21 8 0 3 ;5,3
#pragma debug struct_end
#pragma debug union_begin 58 ""
#pragma debug field 2 57 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 58 1 ___adcr0 "__adcr0" 1
#pragma debug struct_begin 59 "__adcr1_bits"
#pragma debug field 21 8 0 1 ;0,1
#pragma debug field 21 8 0 1 "__eoc" ;1,1
#pragma debug field 21 8 0 1 "__adcdl" ;2,1
#pragma debug field 21 8 0 1 ;3,1
#pragma debug field 21 8 0 1 "__flmsps" ;4,1
#pragma debug field 21 8 0 1 "__flms0" ;5,1
#pragma debug field 21 8 0 1 "__flms1" ;6,1
#pragma debug field 21 8 0 1 "__flms2" ;7,1
#pragma debug struct_end
#pragma debug union_begin 60 ""
#pragma debug field 2 59 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 60 1 ___adcr1 "__adcr1" 1
#pragma debug struct_begin 61 "__adcs_bits"
#pragma debug field 21 8 0 1 "__adck0" ;0,1
#pragma debug field 21 8 0 1 "__adck1" ;1,1
#pragma debug field 21 8 0 1 "__adck2" ;2,1
#pragma debug field 21 8 0 1 "__adck3" ;3,1
#pragma debug field 21 8 0 1 "__adck4" ;4,1
#pragma debug field 21 8 0 3 ;5,3
#pragma debug struct_end
#pragma debug union_begin 62 ""
#pragma debug field 2 61 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 62 1 ___adcs "__adcs" 1
#pragma debug struct_begin 63 "__sinc3_bits"
#pragma debug field 21 8 0 1 "__r_ckchop" ;0,1
#pragma debug field 21 8 0 1 "__r_filsel" ;1,1
#pragma debug field 21 8 0 1 "__cmpcp0" ;2,1
#pragma debug field 21 8 0 1 "__cmpcp1" ;3,1
#pragma debug field 21 8 0 1 "__modcp0" ;4,1
#pragma debug field 21 8 0 1 "__modcp1" ;5,1
#pragma debug field 21 8 0 1 "__pgacp0" ;6,1
#pragma debug field 21 8 0 1 "__pgacp1" ;7,1
#pragma debug struct_end
#pragma debug union_begin 64 ""
#pragma debug field 2 63 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 64 1 ___sinc3 "__sinc3" 1
#pragma debug struct_begin 65 "__adacctrl_bits"
#pragma debug field 21 8 0 1 "__adacc0" ;0,1
#pragma debug field 21 8 0 1 "__adacc1" ;1,1
#pragma debug field 21 8 0 1 "__adacc2" ;2,1
#pragma debug field 21 8 0 3 ;3,3
#pragma debug field 21 8 0 1 "__eoca" ;6,1
#pragma debug field 21 8 0 1 "__adavgen" ;7,1
#pragma debug struct_end
#pragma debug union_begin 66 ""
#pragma debug field 2 65 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 66 1 ___adacctrl "__adacctrl" 1
#pragma debug variable 8 1 ___adrl_avg "__adrl_avg" 1
#pragma debug variable 8 1 ___adrm_avg "__adrm_avg" 1
#pragma debug variable 8 1 ___adrh_avg "__adrh_avg" 1
#pragma debug struct_begin 67 "__ctrl_bits"
#pragma debug field 21 8 0 5 ;0,5
#pragma debug field 21 8 0 1 "__addsk0" ;5,1
#pragma debug field 21 8 0 1 "__addsk1" ;6,1
#pragma debug field 21 8 0 1 "__ctrlen" ;7,1
#pragma debug struct_end
#pragma debug union_begin 68 ""
#pragma debug field 2 67 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 68 1 ___ctrl "__ctrl" 1
#pragma debug struct_begin 69 "__autoadcc_bits"
#pragma debug field 21 8 0 1 "__bufrst" ;0,1
#pragma debug field 21 8 0 1 "__wrnum0" ;1,1
#pragma debug field 21 8 0 1 "__wrnum1" ;2,1
#pragma debug field 21 8 0 1 "__wrnum2" ;3,1
#pragma debug field 21 8 0 1 "__wrnum3" ;4,1
#pragma debug field 21 8 0 1 "__wrnum4" ;5,1
#pragma debug field 21 8 0 1 ;6,1
#pragma debug field 21 8 0 1 "__autoadcen" ;7,1
#pragma debug struct_end
#pragma debug union_begin 70 ""
#pragma debug field 2 69 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 70 1 ___autoadcc "__autoadcc" 1
#pragma debug struct_begin 71 "__errchkc_bits"
#pragma debug field 21 8 0 6 ;0,6
#pragma debug field 21 8 0 1 "__errchkrst" ;6,1
#pragma debug field 21 8 0 1 "__errchken" ;7,1
#pragma debug struct_end
#pragma debug union_begin 72 ""
#pragma debug field 2 71 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 72 1 ___errchkc "__errchkc" 1
#pragma debug struct_begin 73 "__pas0_bits"
#pragma debug field 21 8 0 1 "__pas00" ;0,1
#pragma debug field 21 8 0 1 "__pas01" ;1,1
#pragma debug field 21 8 0 1 "__pas02" ;2,1
#pragma debug field 21 8 0 1 "__pas03" ;3,1
#pragma debug field 21 8 0 1 "__pas04" ;4,1
#pragma debug field 21 8 0 1 "__pas05" ;5,1
#pragma debug field 21 8 0 1 "__pas06" ;6,1
#pragma debug field 21 8 0 1 "__pas07" ;7,1
#pragma debug struct_end
#pragma debug union_begin 74 ""
#pragma debug field 2 73 "bits"
#pragma debug field 0 8 "byte"
#pragma debug union_end
#pragma debug variable 74 1 ___pas0 "__pas0" 1
extern r1:byte
extern r2:byte

; 
; Generated by holtek-gcc v3.19, Mon Jan 06 09:49:12 2025
; Rebuild 718
; end of file
