
_interrupt:

;USB_GSM.c,16 :: 		void interrupt() {
;USB_GSM.c,17 :: 		USB_Interrupt_Proc();
	CALL        _USB_Interrupt_Proc+0, 0
;USB_GSM.c,18 :: 		}
L_end_interrupt:
L__interrupt7:
	RETFIE      1
; end of _interrupt

_main:

;USB_GSM.c,20 :: 		void main() {
;USB_GSM.c,21 :: 		OSCCON = 0b01110000; //8MHz
	MOVLW       112
	MOVWF       OSCCON+0 
;USB_GSM.c,22 :: 		PLLEN_bit = 1; //Enable PLL (now 48MHz)
	BSF         PLLEN_bit+0, BitPos(PLLEN_bit+0) 
;USB_GSM.c,23 :: 		TRISD = 0b00000000;
	CLRF        TRISD+0 
;USB_GSM.c,24 :: 		LATD = 0b00000000;
	CLRF        LATD+0 
;USB_GSM.c,25 :: 		UART1_Init(9600);
	BSF         BAUDCON+0, 3, 0
	MOVLW       4
	MOVWF       SPBRGH+0 
	MOVLW       225
	MOVWF       SPBRG+0 
	BSF         TXSTA+0, 2, 0
	CALL        _UART1_Init+0, 0
;USB_GSM.c,26 :: 		HID_Enable(&USBin,&USBout); // Enable HID communication
	MOVLW       _USBin+0
	MOVWF       FARG_HID_Enable_readbuff+0 
	MOVLW       hi_addr(_USBin+0)
	MOVWF       FARG_HID_Enable_readbuff+1 
	MOVLW       _USBout+0
	MOVWF       FARG_HID_Enable_writebuff+0 
	MOVLW       hi_addr(_USBout+0)
	MOVWF       FARG_HID_Enable_writebuff+1 
	CALL        _HID_Enable+0, 0
;USB_GSM.c,28 :: 		while (1) {
L_main0:
;USB_GSM.c,29 :: 		if (HID_Read() != 0) {
	CALL        _HID_Read+0, 0
	MOVF        R0, 0 
	XORLW       0
	BTFSC       STATUS+0, 2 
	GOTO        L_main2
;USB_GSM.c,30 :: 		UART1_Write_Text(USBin);
	MOVLW       _USBin+0
	MOVWF       FARG_UART1_Write_Text_uart_text+0 
	MOVLW       hi_addr(_USBin+0)
	MOVWF       FARG_UART1_Write_Text_uart_text+1 
	CALL        _UART1_Write_Text+0, 0
;USB_GSM.c,31 :: 		LATD++;
	MOVF        LATD+0, 0 
	ADDLW       1
	MOVWF       R0 
	MOVF        R0, 0 
	MOVWF       LATD+0 
;USB_GSM.c,32 :: 		}
L_main2:
;USB_GSM.c,33 :: 		pos = 0;
	CLRF        _pos+0 
;USB_GSM.c,34 :: 		while (UART1_Data_Ready()) {
L_main3:
	CALL        _UART1_Data_Ready+0, 0
	MOVF        R0, 1 
	BTFSC       STATUS+0, 2 
	GOTO        L_main4
;USB_GSM.c,35 :: 		USBout[pos] = UART1_Read();
	MOVLW       _USBout+0
	MOVWF       FLOC__main+0 
	MOVLW       hi_addr(_USBout+0)
	MOVWF       FLOC__main+1 
	MOVF        _pos+0, 0 
	ADDWF       FLOC__main+0, 1 
	BTFSC       STATUS+0, 0 
	INCF        FLOC__main+1, 1 
	CALL        _UART1_Read+0, 0
	MOVFF       FLOC__main+0, FSR1
	MOVFF       FLOC__main+1, FSR1H
	MOVF        R0, 0 
	MOVWF       POSTINC1+0 
;USB_GSM.c,36 :: 		pos++;
	INCF        _pos+0, 1 
;USB_GSM.c,37 :: 		}
	GOTO        L_main3
L_main4:
;USB_GSM.c,38 :: 		if (pos > 0) {
	MOVF        _pos+0, 0 
	SUBLW       0
	BTFSC       STATUS+0, 0 
	GOTO        L_main5
;USB_GSM.c,39 :: 		USBout[pos] = 0;
	MOVLW       _USBout+0
	MOVWF       FSR1 
	MOVLW       hi_addr(_USBout+0)
	MOVWF       FSR1H 
	MOVF        _pos+0, 0 
	ADDWF       FSR1, 1 
	BTFSC       STATUS+0, 0 
	INCF        FSR1H, 1 
	CLRF        POSTINC1+0 
;USB_GSM.c,40 :: 		HID_Write(&USBout, 64);
	MOVLW       _USBout+0
	MOVWF       FARG_HID_Write_writebuff+0 
	MOVLW       hi_addr(_USBout+0)
	MOVWF       FARG_HID_Write_writebuff+1 
	MOVLW       64
	MOVWF       FARG_HID_Write_len+0 
	CALL        _HID_Write+0, 0
;USB_GSM.c,41 :: 		}
L_main5:
;USB_GSM.c,42 :: 		}
	GOTO        L_main0
;USB_GSM.c,43 :: 		}
L_end_main:
	GOTO        $+0
; end of _main
