كود:
; ADDRESS OPCODE ASM
; ----------------------------------------------
$0000 $28D9 GOTO _main
$0004 $ _delay_22us:
;delays.pbas,13 :: sub procedure Delay_22us()
;delays.pbas,14 :: Delay_us(22)
$0004 $3007 MOVLW 7
$0005 $1303 BCF STATUS, RP1
$0006 $1283 BCF STATUS, RP0
$0007 $00FA MOVWF STACK_10
$0008 $0BFA DECFSZ STACK_10, F
$0009 $2808 GOTO $-1
$000A $ delays_L_2:
$000A $0008 RETURN
$000B $ _mul_32x32_u:
$000B $1303 BCF STATUS, RP1
$000C $1283 BCF STATUS, RP0
;Math.ppas,1570 ::
;Math.ppas,1578 ::
$000D $3022 MOVLW 34
;Math.ppas,1579 ::
$000E $00FC MOVWF STACK_12
;Math.ppas,1580 ::
$000F $01F8 CLRF STACK_8
;Math.ppas,1581 ::
$0010 $01F9 CLRF STACK_9
;Math.ppas,1582 ::
$0011 $01FA CLRF STACK_10
;Math.ppas,1584 ::
$0012 $01FB CLRF STACK_11
;Math.ppas,1588 ::
$0013 $ _NEXT:
;Math.ppas,1589 ::
$0013 $03FC DECF STACK_12, F
;Math.ppas,1590 ::
$0014 $1903 BTFSC STATUS, Z
;Math.ppas,1591 ::
$0015 $2841 GOTO _EXIT2
;Math.ppas,1593 ::
$0016 $1003 BCF STATUS, C
;Math.ppas,1602 ::
$0017 $ _LOOP:
;Math.ppas,1603 ::
$0017 $0CFB RRF STACK_11, F
;Math.ppas,1604 ::
$0018 $0CFA RRF STACK_10, F
;Math.ppas,1605 ::
$0019 $0CF9 RRF STACK_9, F
;Math.ppas,1606 ::
$001A $0CF8 RRF STACK_8, F
;Math.ppas,1607 ::
$001B $0CF3 RRF STACK_3, F
;Math.ppas,1608 ::
$001C $0CF2 RRF STACK_2, F
;Math.ppas,1609 ::
$001D $0CF1 RRF STACK_1, F
;Math.ppas,1614 ::
$001E $0CF0 RRF STACK_0, F
;Math.ppas,1615 ::
$001F $1C03 BTFSS STATUS, C
;Math.ppas,1616 ::
$0020 $2813 GOTO _NEXT
;Math.ppas,1617 ::
$0021 $03FC DECF STACK_12, F
;Math.ppas,1618 ::
$0022 $1903 BTFSC STATUS, Z
;Math.ppas,1625 ::
$0023 $2833 GOTO _EXIT1
;Math.ppas,1626 ::
$0024 $0874 MOVF STACK_4, W
;Math.ppas,1627 ::
$0025 $07F8 ADDWF STACK_8, F
;Math.ppas,1628 ::
$0026 $0875 MOVF STACK_5, W
;Math.ppas,1629 ::
$0027 $1803 BTFSC STATUS, C
;Math.ppas,1630 ::
$0028 $0F75 INCFSZ STACK_5, W
;Math.ppas,1631 ::
$0029 $07F9 ADDWF STACK_9, F
;Math.ppas,1632 ::
$002A $0876 MOVF STACK_6, W
;Math.ppas,1633 ::
$002B $1803 BTFSC STATUS, C
;Math.ppas,1634 ::
$002C $0F76 INCFSZ STACK_6, W
;Math.ppas,1635 ::
$002D $07FA ADDWF STACK_10, F
;Math.ppas,1636 ::
$002E $0877 MOVF STACK_7, W
;Math.ppas,1637 ::
$002F $1803 BTFSC STATUS, C
;Math.ppas,1638 ::
$0030 $0F77 INCFSZ STACK_7, W
;Math.ppas,1640 ::
$0031 $07FB ADDWF STACK_11, F
;Math.ppas,1642 ::
$0032 $2817 GOTO _LOOP
;Math.ppas,1647 ::
$0033 $ _EXIT1:
;Math.ppas,1648 ::
$0033 $0874 MOVF STACK_4, W
;Math.ppas,1649 ::
$0034 $07F8 ADDWF STACK_8, F
;Math.ppas,1650 ::
$0035 $0875 MOVF STACK_5, W
;Math.ppas,1651 ::
$0036 $1803 BTFSC STATUS, C
;Math.ppas,1652 ::
$0037 $0F75 INCFSZ STACK_5, W
;Math.ppas,1653 ::
$0038 $07F9 ADDWF STACK_9, F
;Math.ppas,1654 ::
$0039 $0876 MOVF STACK_6, W
;Math.ppas,1655 ::
$003A $1803 BTFSC STATUS, C
;Math.ppas,1656 ::
$003B $0F76 INCFSZ STACK_6, W
;Math.ppas,1657 ::
$003C $07FA ADDWF STACK_10, F
;Math.ppas,1658 ::
$003D $0877 MOVF STACK_7, W
;Math.ppas,1659 ::
$003E $1803 BTFSC STATUS, C
;Math.ppas,1660 ::
$003F $0F77 INCFSZ STACK_7, W
;Math.ppas,1663 ::
$0040 $07FB ADDWF STACK_11, F
;Math.ppas,1664 ::
$0041 $ _EXIT2:
;Math.ppas,1665 ::
$0041 $ Math_L_13:
;Math.ppas,1666 ::
$0041 $0008 RETURN
$0042 $ _adc_read:
;ADClib_A_C.ppas,12 ::
;ADClib_A_C.ppas,13 ::
$0042 $1303 BCF STATUS, RP1
$0043 $1283 BCF STATUS, RP0
$0044 $019F CLRF ADCON0, 1
;ADClib_A_C.ppas,14 ::
$0045 $30C0 MOVLW 192
$0046 $049F IORWF ADCON0, 1
;ADClib_A_C.ppas,15 ::
$0047 $3040 MOVLW 64
$0048 $1683 BSF STATUS, RP0
$0049 $041F IORWF ADCON1, 0
$004A $00F0 MOVWF STACK_0
$004B $0870 MOVF STACK_0, 0
$004C $009F MOVWF ADCON1
;ADClib_A_C.ppas,17 ::
$004D $3080 MOVLW 128
$004E $0470 IORWF STACK_0, 0
$004F $009F MOVWF ADCON1
;ADClib_A_C.ppas,18 ::
$0050 $1283 BCF STATUS, RP0
$0051 $082C MOVF FARG_ADC_read, 0
$0052 $00F0 MOVWF STACK_0
$0053 $0DF0 RLF STACK_0, 1
$0054 $1070 BCF STACK_0, 0
$0055 $0DF0 RLF STACK_0, 1
$0056 $1070 BCF STACK_0, 0
$0057 $0DF0 RLF STACK_0, 1
$0058 $1070 BCF STACK_0, 0
$0059 $0870 MOVF STACK_0, 0
$005A $049F IORWF ADCON0, 1
;ADClib_A_C.ppas,19 ::
$005B $141F BSF ADCON0, 0
;ADClib_A_C.ppas,20 ::
$005C $2004 CALL _delay_22us
;ADClib_A_C.ppas,21 ::
$005D $151F BSF ADCON0, 2
;ADClib_A_C.ppas,22 ::
$005E $ ADClib_A_C_L_2:
$005E $3000 MOVLW 0
$005F $191F BTFSC ADCON0, 2
$0060 $3001 MOVLW 1
$0061 $00F2 MOVWF STACK_2
$0062 $0872 MOVF STACK_2, 0
$0063 $3A01 XORLW 1
$0064 $1D03 BTFSS STATUS, Z
$0065 $2868 GOTO ADClib_A_C_L_3
;ADClib_A_C.ppas,23 ::
$0066 $0000 NOP
$0067 $285E GOTO ADClib_A_C_L_2
$0068 $ ADClib_A_C_L_3:
;ADClib_A_C.ppas,24 ::
$0068 $081E MOVF ADRESH, 0
$0069 $00F2 MOVWF STACK_2
$006A $01F3 CLRF STACK_2+1
$006B $0872 MOVF STACK_2, 0
$006C $00F3 MOVWF STACK_2+1
$006D $01F2 CLRF STACK_2
$006E $0872 MOVF STACK_2, 0
$006F $00AD MOVWF _adc_read_local_result
$0070 $0873 MOVF STACK_2+1, 0
$0071 $00AE MOVWF _adc_read_local_result+1
;ADClib_A_C.ppas,25 ::
$0072 $1683 BSF STATUS, RP0
$0073 $081E MOVF ADRESL, 0
$0074 $0472 IORWF STACK_2, 0
$0075 $1283 BCF STATUS, RP0
$0076 $00AD MOVWF _adc_read_local_result
$0077 $0873 MOVF STACK_2+1, 0
$0078 $00AE MOVWF _adc_read_local_result+1
$0079 $3000 MOVLW 0
$007A $04AE IORWF _adc_read_local_result+1, 1
;ADClib_A_C.ppas,26 ::
$007B $101F BCF ADCON0, 0
$007C $ ADClib_A_C_L_0:
;ADClib_A_C.ppas,27 ::
$007C $082D MOVF _adc_read_local_result, 0
$007D $00F0 MOVWF STACK_0
$007E $082E MOVF _adc_read_local_result+1, 0
$007F $00F1 MOVWF STACK_0+1
$0080 $0008 RETURN
$0081 $ _mul_32x32_s:
$0081 $1303 BCF STATUS, RP1
$0082 $1283 BCF STATUS, RP0
;Math.ppas,1675 ::
;Math.ppas,1680 ::
$0083 $01FD CLRF STACK_13
;Math.ppas,1683 ::
$0084 $ _IF_FIRST:
;Math.ppas,1684 ::
$0084 $1FF3 BTFSS STACK_3, 7
;Math.ppas,1686 ::
$0085 $2893 GOTO _IF_SECOND
;Math.ppas,1691 ::
$0086 $ _INVERCE_FIRST:
;Math.ppas,1692 ::
$0086 $09F0 COMF STACK_0, F
;Math.ppas,1693 ::
$0087 $09F1 COMF STACK_1, F
;Math.ppas,1694 ::
$0088 $09F2 COMF STACK_2, F
;Math.ppas,1701 ::
$0089 $09F3 COMF STACK_3, F
;Math.ppas,1702 ::
$008A $0AF0 INCF STACK_0, F
;Math.ppas,1703 ::
$008B $1903 BTFSC STATUS, Z
;Math.ppas,1704 ::
$008C $0AF1 INCF STACK_1, F
;Math.ppas,1705 ::
$008D $1903 BTFSC STATUS, Z
;Math.ppas,1706 ::
$008E $0AF2 INCF STACK_2, F
;Math.ppas,1707 ::
$008F $1903 BTFSC STATUS, Z
;Math.ppas,1708 ::
$0090 $0AF3 INCF STACK_3, F
;Math.ppas,1709 ::
$0091 $3081 MOVLW 129
;Math.ppas,1711 ::
$0092 $07FD ADDWF STACK_13, F
;Math.ppas,1714 ::
$0093 $ _IF_SECOND:
;Math.ppas,1715 ::
$0093 $1FF7 BTFSS STACK_7, 7
;Math.ppas,1717 ::
$0094 $28A1 GOTO _MULT
;Math.ppas,1722 ::
$0095 $ _INBERSE_SECOND:
;Math.ppas,1723 ::
$0095 $09F4 COMF STACK_4, F
;Math.ppas,1724 ::
$0096 $09F5 COMF STACK_5, F
;Math.ppas,1725 ::
$0097 $09F6 COMF STACK_6, F
;Math.ppas,1732 ::
$0098 $09F7 COMF STACK_7, F
;Math.ppas,1733 ::
$0099 $0AF4 INCF STACK_4, F
;Math.ppas,1734 ::
$009A $1903 BTFSC STATUS, Z
;Math.ppas,1735 ::
$009B $0AF5 INCF STACK_5, F
;Math.ppas,1736 ::
$009C $1903 BTFSC STATUS, Z
;Math.ppas,1737 ::
$009D $0AF6 INCF STACK_6, F
;Math.ppas,1738 ::
$009E $1903 BTFSC STATUS, Z
;Math.ppas,1739 ::
$009F $0AF7 INCF STACK_7, F
;Math.ppas,1741 ::
$00A0 $0AFD INCF STACK_13, F
;Math.ppas,1742 ::
$00A1 $ _MULT:
;Math.ppas,1744 ::
$00A1 $200B CALL _mul_32x32_u
;Math.ppas,1748 ::
$00A2 $1C7D BTFSS STACK_13, 0
;Math.ppas,1754 ::
$00A3 $28BB GOTO _EXIT
;Math.ppas,1755 ::
$00A4 $09F0 COMF STACK_0, F
;Math.ppas,1756 ::
$00A5 $09F1 COMF STACK_1, F
;Math.ppas,1757 ::
$00A6 $09F2 COMF STACK_2, F
;Math.ppas,1763 ::
$00A7 $09F3 COMF STACK_3, F
;Math.ppas,1764 ::
$00A8 $09F8 COMF STACK_8, F
;Math.ppas,1765 ::
$00A9 $09F9 COMF STACK_9, F
;Math.ppas,1766 ::
$00AA $09FA COMF STACK_10, F
;Math.ppas,1776 ::
$00AB $09FB COMF STACK_11, F
;Math.ppas,1777 ::
$00AC $0AF0 INCF STACK_0, F
;Math.ppas,1778 ::
$00AD $1903 BTFSC STATUS, Z
;Math.ppas,1779 ::
$00AE $0AF1 INCF STACK_1, F
;Math.ppas,1780 ::
$00AF $1903 BTFSC STATUS, Z
;Math.ppas,1781 ::
$00B0 $0AF2 INCF STACK_2, F
;Math.ppas,1782 ::
$00B1 $1903 BTFSC STATUS, Z
;Math.ppas,1783 ::
$00B2 $0AF3 INCF STACK_3, F
;Math.ppas,1784 ::
$00B3 $1903 BTFSC STATUS, Z
;Math.ppas,1785 ::
$00B4 $0AF8 INCF STACK_8, F
;Math.ppas,1786 ::
$00B5 $1903 BTFSC STATUS, Z
;Math.ppas,1787 ::
$00B6 $0AF9 INCF STACK_9, F
;Math.ppas,1788 ::
$00B7 $1903 BTFSC STATUS, Z
;Math.ppas,1789 ::
$00B8 $0AFA INCF STACK_10, F
;Math.ppas,1790 ::
$00B9 $1903 BTFSC STATUS, Z
;Math.ppas,1791 ::
$00BA $0AFB INCF STACK_11, F
;Math.ppas,1792 ::
$00BB $ _EXIT:
;Math.ppas,1793 ::
$00BB $ Math_L_14:
;Math.ppas,1794 ::
$00BB $0008 RETURN
$00BC $ _div_16x16_u:
$00BC $1303 BCF STATUS, RP1
$00BD $1283 BCF STATUS, RP0
;Math.ppas,108 ::
;Math.ppas,110 ::
$00BE $01F8 CLRF STACK_8
;Math.ppas,111 ::
$00BF $01F9 CLRF STACK_9
;Math.ppas,112 ::
$00C0 $3010 MOVLW 16
;Math.ppas,113 ::
$00C1 $00FC MOVWF STACK_12
;Math.ppas,114 ::
$00C2 $0D71 RLF STACK_1, W
;Math.ppas,115 ::