_main:
;HID_Read_Write_Polling.c,31 :: 		void main(void){
SUB	SP, SP, #4
;HID_Read_Write_Polling.c,33 :: 		int Count = 0;
MOVW	R0, #0
STRH	R0, [SP, #0]
;HID_Read_Write_Polling.c,34 :: 		GPIO_Digital_Output(&GPIOB_BASE, _GPIO_PINMASK_ALL); // Set PORTA as digital output
MOVW	R1, #65535
MOVW	R0, #lo_addr(GPIOB_BASE+0)
MOVT	R0, #hi_addr(GPIOB_BASE+0)
BL	_GPIO_Digital_Output+0
;HID_Read_Write_Polling.c,35 :: 		GPIOB_ODR = 0;
MOVS	R1, #0
MOVW	R0, #lo_addr(GPIOB_ODR+0)
MOVT	R0, #hi_addr(GPIOB_ODR+0)
STR	R1, [R0, #0]
;HID_Read_Write_Polling.c,37 :: 		HID_Enable(&readbuff,&writebuff);
MOVW	R1, #lo_addr(_writebuff+0)
MOVT	R1, #hi_addr(_writebuff+0)
MOVW	R0, #lo_addr(_readbuff+0)
MOVT	R0, #hi_addr(_readbuff+0)
BL	_HID_Enable+0
;HID_Read_Write_Polling.c,39 :: 		while(1){
L_main0:
;HID_Read_Write_Polling.c,40 :: 		USB_Polling_Proc();               // Call this routine periodically
BL	_USB_Polling_Proc+0
;HID_Read_Write_Polling.c,41 :: 		kk = HID_Read();
BL	_HID_Read+0
MOVW	R1, #lo_addr(_kk+0)
MOVT	R1, #hi_addr(_kk+0)
STRB	R0, [R1, #0]
;HID_Read_Write_Polling.c,42 :: 		if(kk != 0){
CMP	R0, #0
IT	EQ
BEQ	L_main2
;HID_Read_Write_Polling.c,43 :: 		for(cnt=0;cnt<64;cnt++)
MOVS	R1, #0
MOVW	R0, #lo_addr(_cnt+0)
MOVT	R0, #hi_addr(_cnt+0)
STRB	R1, [R0, #0]
L_main3:
MOVW	R0, #lo_addr(_cnt+0)
MOVT	R0, #hi_addr(_cnt+0)
LDRB	R0, [R0, #0]
CMP	R0, #64
IT	CS
BCS	L_main4
;HID_Read_Write_Polling.c,44 :: 		writebuff[cnt]=readbuff[cnt];
MOVW	R3, #lo_addr(_cnt+0)
MOVT	R3, #hi_addr(_cnt+0)
LDRB	R1, [R3, #0]
MOVW	R0, #lo_addr(_writebuff+0)
MOVT	R0, #hi_addr(_writebuff+0)
ADDS	R2, R0, R1
MOV	R0, R3
LDRB	R1, [R0, #0]
MOVW	R0, #lo_addr(_readbuff+0)
MOVT	R0, #hi_addr(_readbuff+0)
ADDS	R0, R0, R1
LDRB	R0, [R0, #0]
STRB	R0, [R2, #0]
;HID_Read_Write_Polling.c,43 :: 		for(cnt=0;cnt<64;cnt++)
MOV	R0, R3
LDRB	R0, [R0, #0]
ADDS	R0, R0, #1
STRB	R0, [R3, #0]
;HID_Read_Write_Polling.c,44 :: 		writebuff[cnt]=readbuff[cnt];
IT	AL
BAL	L_main3
L_main4:
;HID_Read_Write_Polling.c,46 :: 		writebuff[0] = ++Count;
LDRSH	R0, [SP, #0]
ADDS	R1, R0, #1
STRH	R1, [SP, #0]
MOVW	R0, #lo_addr(_writebuff+0)
MOVT	R0, #hi_addr(_writebuff+0)
STRB	R1, [R0, #0]
;HID_Read_Write_Polling.c,47 :: 		GPIOB_ODR = readbuff[63];
MOVW	R0, #lo_addr(_readbuff+63)
MOVT	R0, #hi_addr(_readbuff+63)
LDRB	R1, [R0, #0]
MOVW	R0, #lo_addr(GPIOB_ODR+0)
MOVT	R0, #hi_addr(GPIOB_ODR+0)
STR	R1, [R0, #0]
;HID_Read_Write_Polling.c,49 :: 		HID_Write(&writebuff,64);
MOVS	R1, #64
MOVW	R0, #lo_addr(_writebuff+0)
MOVT	R0, #hi_addr(_writebuff+0)
BL	_HID_Write+0
;HID_Read_Write_Polling.c,50 :: 		}
L_main2:
;HID_Read_Write_Polling.c,51 :: 		}
IT	AL
BAL	L_main0
;HID_Read_Write_Polling.c,52 :: 		}
L_end_main:
L__main_end_loop:
B	L__main_end_loop
; end of _main
