///////////////////////////////////////////////////////////////////////////////
//                                                                            /
// IAR 8051 C/C++ Compiler V7.30B/W32                   21/Jun/2010  17:06:51 /
// Copyright 2004-2007 IAR Systems. All rights reserved.                      /
//                                                                            /
//    Core               =  plain                                             /
//    Code model         =  banked                                            /
//    Data model         =  large                                             /
//    Calling convention =  xdata reentrant                                   /
//    Constant location  =  data                                              /
//    Dptr setup         =  1,16                                              /
//    Source file        =  C:\Texas Instruments\ZStack-1.4.3-1.2.1\Component /
//                          s\mt\MTEL.c                                       /
//    Command line       =  -f "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Proje /
//                          cts\zstack\Project\Location\CC2430DB\..\..\..\Too /
//                          ls\CC2430DB\f8wCoord.cfg" (-DCPU32MHZ             /
//                          -DFORCE_MAC_NEAR -DROOT=__near_func               /
//                          -DMAC_CFG_APP_PENDING_QUEUE=TRUE                  /
//                          -DZDO_COORDINATOR -DRTR_NWK -DBLINK_LEDS          /
//                          "-DCONST=const __code" -DGENERIC=__generic) -f    /
//                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects /
//                          \zstack\Project\Location\CC2430DB\..\..\..\Tools\ /
//                          CC2430DB\f8wConfig.cfg" (-DSECURE=1               /
//                          -DDEFAULT_CHANLIST=0x04000000                     /
//                          -DZDAPP_CONFIG_PAN_ID=0x00FF                      /
//                          -DNWK_START_DELAY=100 -DEXTENDED_JOINING_RANDOM_M /
//                          ASK=0x007F -DBEACON_REQUEST_DELAY=100             /
//                          -DBEACON_REQ_DELAY_MASK=0x00FF                    /
//                          -DROUTE_EXPIRY_TIME=30 -DAPSC_ACK_WAIT_DURATION_P /
//                          OLLED=3000 -DNWK_INDIRECT_MSG_TIMEOUT=7           /
//                          -DMAX_RREQ_ENTRIES=10 -DAPSC_MAX_FRAME_RETRIES=3  /
//                          -DNWK_MAX_DATA_RETRIES=2                          /
//                          -DMAX_POLL_FAILURE_RETRIES=2 -DMAX_BCAST=9        /
//                          -DAPS_MAX_GROUPS=16 -DMAX_RTG_ENTRIES=20          /
//                          -DNWK_MAX_BINDING_ENTRIES=10                      /
//                          -DMAX_BINDING_CLUSTER_IDS=5                       /
//                          "-DDEFAULT_KEY={0x02, 0x03, 0x05, 0x07, 0x09,     /
//                          0x0B, 0x0D, 0x0F, 0x00, 0x02, 0x04, 0x06, 0x08,   /
//                          0x0A, 0x0C, 0x0D}" -DRFD_RCVC_ALWAYS_ON=FALSE     /
//                          -DPOLL_RATE=1000 -DQUEUED_POLL_RATE=100           /
//                          -DRESPONSE_POLL_RATE=100) -DREJOIN_POLL_RATE=440  /
//                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Componen /
//                          ts\mt\MTEL.c" -D CC2430EB -D ZTOOL_P1 -D          /
//                          LOCATION_DONGLE -D MT_TASK -D xNV_RESTORE -D      /
//                          INT_HEAP_LEN=4608 -D HAL_UART_BIG_TX_BUF=1 -D     /
//                          SPI_MGR_DEFAULT_MAX_TX_BUFF=1024 -D               /
//                          SPI_MGR_DEFAULT_OVERFLOW=1 -lC "C:\Texas          /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\LocDongle\List\" -lA      /
//                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects /
//                          \zstack\Project\Location\CC2430DB\LocDongle\List\ /
//                          " --diag_suppress Pe001,Pa010 --diag_remark       /
//                          pe550 -o "C:\Texas Instruments\ZStack-1.4.3-1.2.1 /
//                          \Projects\zstack\Project\Location\CC2430DB\LocDon /
//                          gle\Obj\" -e --require_prototypes -z9             /
//                          --no_code_motion --debug --core=plain             /
//                          --dptr=16,1 --data_model=large                    /
//                          --code_model=banked --calling_convention=xdata_re /
//                          entrant --place_constants=data --nr_virtual_regs  /
//                          8 -I "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Pro /
//                          jects\zstack\Project\Location\CC2430DB\" -I       /
//                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects /
//                          \zstack\Project\Location\CC2430DB\..\SOURCE\" -I  /
//                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects /
//                          \zstack\Project\Location\CC2430DB\..\..\..\ZMAIN\ /
//                          TI2430DB\" -I "C:\Texas                           /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\WXL\INCLUDE\" /
//                           -I "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Proj /
//                          ects\zstack\Project\Location\CC2430DB\..\..\..\.. /
//                          \..\COMPONENTS\MT\" -I "C:\Texas                  /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \HAL\INCLUDE\" -I "C:\Texas                       /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \HAL\TARGET\CC2430EB\" -I "C:\Texas               /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \OSAL\MCU\CCSOC\" -I "C:\Texas                    /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \OSAL\INCLUDE\" -I "C:\Texas                      /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \STACK\AF\" -I "C:\Texas                          /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \STACK\NWK\" -I "C:\Texas                         /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \STACK\SEC\" -I "C:\Texas                         /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \STACK\SYS\" -I "C:\Texas                         /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \STACK\ZDO\" -I "C:\Texas                         /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \ZMAC\F8W\" -I "C:\Texas                          /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \ZMAC\" -I "C:\Texas Instruments\ZStack-1.4.3-1.2 /
//                          .1\Projects\zstack\Project\Location\CC2430DB\..\. /
//                          .\..\..\..\COMPONENTS\SERVICES\SADDR\" -I         /
//                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects /
//                          \zstack\Project\Location\CC2430DB\..\..\..\..\..\ /
//                          COMPONENTS\SERVICES\SDATA\" -I "C:\Texas          /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \MAC\INCLUDE\" -I "C:\Texas                       /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \MAC\HIGH_LEVEL\" -I "C:\Texas                    /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \MAC\LOW_LEVEL\SRF03\" -I "C:\Texas               /
//                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Pr /
//                          oject\Location\CC2430DB\..\..\..\..\..\COMPONENTS /
//                          \MAC\LOW_LEVEL\SRF03\SINGLE_CHIP\" -I             /
//                          "C:\Program Files\IAR Systems\Embedded Workbench  /
//                          4.0 Evaluation version\8051\INC\" -I "C:\Program  /
//                          Files\IAR Systems\Embedded Workbench 4.0          /
//                          Evaluation version\8051\INC\CLIB\"                /
//    List file          =  C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects\ /
//                          zstack\Project\Location\CC2430DB\LocDongle\List\M /
//                          TEL.s51                                           /
//                                                                            /
//                                                                            /
///////////////////////////////////////////////////////////////////////////////

        NAME MTEL

        RTMODEL "__calling_convention", "xdata_reentrant"
        RTMODEL "__code_model", "banked"
        RTMODEL "__core", "plain"
        RTMODEL "__data_model", "large"
        RTMODEL "__dptr_size", "16"
        RTMODEL "__extended_stack", "disabled"
        RTMODEL "__location_for_constants", "data"
        RTMODEL "__number_of_dptrs", "1"
        RTMODEL "__rt_version", "1"

        RSEG DOVERLAY:DATA:NOROOT(0)
        RSEG IOVERLAY:IDATA:NOROOT(0)
        RSEG ISTACK:IDATA:NOROOT(0)
        RSEG PSTACK:XDATA:NOROOT(0)
        RSEG XSTACK:XDATA:NOROOT(0)

        EXTERN ??MTProcessAppMsg?relay
        EXTERN ??MTProcessAppRspMsg?relay
        EXTERN ??MTProcessLedControl?relay
        EXTERN ??MT_BuildAndSendZToolResponse?relay
        EXTERN ??MT_BuildSPIMsg?relay
        EXTERN ??MT_ProcessCommand?relay
        EXTERN ??MT_ProcessDebugMsg?relay
        EXTERN ??MT_ProcessDebugStr?relay
        EXTERN ??MT_ProcessGetDeviceInfo?relay
        EXTERN ??MT_ProcessGetNV?relay
        EXTERN ??MT_ProcessGetNvInfo?relay
        EXTERN ??MT_ProcessSerialCommand?relay
        EXTERN ??MT_ProcessSetNV?relay
        EXTERN ??MT_RAMRead?relay
        EXTERN ??MT_RAMWrite?relay
        EXTERN ??MT_Reset?relay
        EXTERN ??MT_ReverseBytes?relay
        EXTERN ??MT_SendErrorNotification?relay
        EXTERN ?ALLOC_XSTACK8
        EXTERN ?BANKED_ENTER_XDATA
        EXTERN ?BANKED_LEAVE_XDATA
        EXTERN ?BDISPATCH
        EXTERN ?BRET
        EXTERN ?DEALLOC_XSTACK8
        EXTERN ?L_ADD
        EXTERN ?L_MOV_TO_X
        EXTERN ?L_MOV_X
        EXTERN ?L_SHL
        EXTERN ?PUSH_XSTACK8_X_TWO
        EXTERN ?PUSH_XSTACK_I_THREE
        EXTERN ?PUSH_XSTACK_I_TWO
        EXTERN ?UC_SWITCH_SPARSE
        EXTERN ?UL_DIV_MOD
        EXTERN ?UL_SHR
        EXTERN ?US_SWITCH_DENSE
        EXTERN ?V0
        EXTERN ?XSP
        EXTERN ?XSTACK_DISP0_8
        EXTERN __INIT_XDATA_I
        EXTERN __INIT_XDATA_Z

        PUBLIC ??MTProcessAppMsg?relay
        FUNCTION ??MTProcessAppMsg?relay,0203H
        PUBLIC ??MTProcessAppRspMsg?relay
        FUNCTION ??MTProcessAppRspMsg?relay,0203H
        PUBLIC ??MTProcessLedControl?relay
        FUNCTION ??MTProcessLedControl?relay,0203H
        PUBLIC ??MT_BuildAndSendZToolCB?relay
        FUNCTION ??MT_BuildAndSendZToolCB?relay,0203H
        PUBLIC ??MT_BuildAndSendZToolResponse?relay
        FUNCTION ??MT_BuildAndSendZToolResponse?relay,0203H
        PUBLIC ??MT_BuildSPIMsg?relay
        FUNCTION ??MT_BuildSPIMsg?relay,0203H
        PUBLIC ??MT_IndReset?relay
        FUNCTION ??MT_IndReset?relay,0203H
        PUBLIC ??MT_ProcessCommand?relay
        FUNCTION ??MT_ProcessCommand?relay,0203H
        PUBLIC ??MT_ProcessDebugMsg?relay
        FUNCTION ??MT_ProcessDebugMsg?relay,0203H
        PUBLIC ??MT_ProcessDebugStr?relay
        FUNCTION ??MT_ProcessDebugStr?relay,0203H
        PUBLIC ??MT_ProcessEvent?relay
        FUNCTION ??MT_ProcessEvent?relay,0203H
        PUBLIC ??MT_ProcessGetDeviceInfo?relay
        FUNCTION ??MT_ProcessGetDeviceInfo?relay,0203H
        PUBLIC ??MT_ProcessGetNV?relay
        FUNCTION ??MT_ProcessGetNV?relay,0203H
        PUBLIC ??MT_ProcessGetNvInfo?relay
        FUNCTION ??MT_ProcessGetNvInfo?relay,0203H
        PUBLIC ??MT_ProcessSerialCommand?relay
        FUNCTION ??MT_ProcessSerialCommand?relay,0203H
        PUBLIC ??MT_ProcessSetNV?relay
        FUNCTION ??MT_ProcessSetNV?relay,0203H
        PUBLIC ??MT_RAMRead?relay
        FUNCTION ??MT_RAMRead?relay,0203H
        PUBLIC ??MT_RAMWrite?relay
        FUNCTION ??MT_RAMWrite?relay,0203H
        PUBLIC ??MT_Reset?relay
        FUNCTION ??MT_Reset?relay,0203H
        PUBLIC ??MT_ReverseBytes?relay
        FUNCTION ??MT_ReverseBytes?relay,0203H
        PUBLIC ??MT_SendErrorNotification?relay
        FUNCTION ??MT_SendErrorNotification?relay,0203H
        PUBLIC ??MT_SendSPIRespMsg?relay
        FUNCTION ??MT_SendSPIRespMsg?relay,0203H
        PUBLIC ??MT_SetDebugThreshold?relay
        FUNCTION ??MT_SetDebugThreshold?relay,0203H
        PUBLIC ??MT_TaskInit?relay
        FUNCTION ??MT_TaskInit?relay,0203H
        PUBLIC MTProcessAppMsg
        FUNCTION MTProcessAppMsg,021203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 21, STACK
        PUBLIC MTProcessAppRspMsg
        FUNCTION MTProcessAppRspMsg,021203H
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME XSTACK, 12, STACK
        PUBLIC MTProcessLedControl
        FUNCTION MTProcessLedControl,021203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 2, STACK
        PUBLIC MTVersionString
        PUBLIC MT_BuildAndSendZToolCB
        FUNCTION MT_BuildAndSendZToolCB,021203H
        ARGFRAME XSTACK, 0, STACK
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 19, STACK
        PUBLIC MT_BuildAndSendZToolResponse
        FUNCTION MT_BuildAndSendZToolResponse,021203H
        ARGFRAME XSTACK, 37, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME XSTACK, 18, STACK
        PUBLIC MT_BuildSPIMsg
        FUNCTION MT_BuildSPIMsg,021203H
        ARGFRAME XSTACK, 27, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 17, STACK
        PUBLIC MT_IndReset
        FUNCTION MT_IndReset,021203H
        ARGFRAME XSTACK, 0, STACK
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 13, STACK
        PUBLIC MT_ProcessCommand
        FUNCTION MT_ProcessCommand,0a1203H
        ARGFRAME XSTACK, 10, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 14, STACK
        PUBLIC MT_ProcessDebugMsg
        FUNCTION MT_ProcessDebugMsg,021203H
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 27, STACK
        PUBLIC MT_ProcessDebugStr
        FUNCTION MT_ProcessDebugStr,021203H
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME XSTACK, 14, STACK
        PUBLIC MT_ProcessEvent
        FUNCTION MT_ProcessEvent,021203H
        ARGFRAME XSTACK, 0, STACK
        LOCFRAME XSTACK, 10, STACK
        PUBLIC MT_ProcessGetDeviceInfo
        FUNCTION MT_ProcessGetDeviceInfo,021203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 19, STACK
        PUBLIC MT_ProcessGetNV
        FUNCTION MT_ProcessGetNV,021203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 20, STACK
        PUBLIC MT_ProcessGetNvInfo
        FUNCTION MT_ProcessGetNvInfo,021203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 26, STACK
        PUBLIC MT_ProcessSerialCommand
        FUNCTION MT_ProcessSerialCommand,0a1203H
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 39, STACK
        PUBLIC MT_ProcessSetNV
        FUNCTION MT_ProcessSetNV,021203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME XSTACK, 14, STACK
        PUBLIC MT_RAMRead
        FUNCTION MT_RAMRead,0203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 3, STACK
        PUBLIC MT_RAMWrite
        FUNCTION MT_RAMWrite,0203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 3, STACK
        PUBLIC MT_Reset
        FUNCTION MT_Reset,080203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME XSTACK, 12, STACK
        PUBLIC MT_ReverseBytes
        FUNCTION MT_ReverseBytes,0203H
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 12, STACK
        PUBLIC MT_SendErrorNotification
        FUNCTION MT_SendErrorNotification,021203H
        ARGFRAME XSTACK, 10, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 13, STACK
        PUBLIC MT_SendSPIRespMsg
        FUNCTION MT_SendSPIRespMsg,021203H
        ARGFRAME XSTACK, 0, STACK
        LOCFRAME ISTACK, 1, STACK
        LOCFRAME XSTACK, 17, STACK
        PUBLIC MT_SetDebugThreshold
        FUNCTION MT_SetDebugThreshold,0203H
        ARGFRAME XSTACK, 0, STACK
        LOCFRAME ISTACK, 2, STACK
        PUBLIC MT_TaskID
        PUBLIC MT_TaskInit
        FUNCTION MT_TaskInit,021203H
        ARGFRAME XSTACK, 0, STACK
        LOCFRAME ISTACK, 2, STACK
        PUBWEAK WDCTL
        PUBWEAK _A_IEN0
        PUBWEAK __Constant_3e8
        PUBWEAK __Constant_53544159
        PUBLIC debugCompId
        PUBLIC debugThreshold
        PUBLIC longvar
        PUBWEAK mboxMsg
        PUBLIC save_cmd
        PUBLIC temp_glob_ptr1
        PUBLIC temp_glob_ptr2
        
        CFI Names cfiNames0
        CFI StackFrame CFA_SP SP DATA
        CFI StackFrame CFA_PSP16 PSP16 XDATA
        CFI StackFrame CFA_XSP16 XSP16 XDATA
        CFI StaticOverlayFrame CFA_IOVERLAY IOVERLAY
        CFI StaticOverlayFrame CFA_DOVERLAY DOVERLAY
        CFI Resource `PSW.CY`:1, `B.BR0`:1, `B.BR1`:1, `B.BR2`:1, `B.BR3`:1
        CFI Resource `B.BR4`:1, `B.BR5`:1, `B.BR6`:1, `B.BR7`:1, `VB.BR8`:1
        CFI Resource `VB.BR9`:1, `VB.BR10`:1, `VB.BR11`:1, `VB.BR12`:1
        CFI Resource `VB.BR13`:1, `VB.BR14`:1, `VB.BR15`:1, VB:8, B:8, A:8
        CFI Resource PSW:8, DPL0:8, DPH0:8, R0:8, R1:8, R2:8, R3:8, R4:8, R5:8
        CFI Resource R6:8, R7:8, V0:8, V1:8, V2:8, V3:8, V4:8, V5:8, V6:8, V7:8
        CFI Resource SP:8, PSPH:8, PSPL:8, PSP16:16, XSPH:8, XSPL:8, XSP16:16
        CFI VirtualResource ?RET:24
        CFI Resource ?BRET_EXT:8
        CFI VirtualResource ?RET_HIGH:8, ?RET_LOW:8
        CFI ResourceParts PSP16 PSPH, PSPL
        CFI ResourceParts XSP16 XSPH, XSPL
        CFI ResourceParts ?RET ?BRET_EXT, ?RET_HIGH, ?RET_LOW
        CFI EndNames cfiNames0
        
        CFI Common cfiCommon0 Using cfiNames0
        CFI CodeAlign 1
        CFI DataAlign -1
        CFI ReturnAddress ?RET CODE
        CFI CFA_DOVERLAY Used
        CFI CFA_IOVERLAY Used
        CFI CFA_SP SP+-3
        CFI CFA_PSP16 PSP16+0
        CFI CFA_XSP16 XSP16+0
        CFI `PSW.CY` SameValue
        CFI `B.BR0` SameValue
        CFI `B.BR1` SameValue
        CFI `B.BR2` SameValue
        CFI `B.BR3` SameValue
        CFI `B.BR4` SameValue
        CFI `B.BR5` SameValue
        CFI `B.BR6` SameValue
        CFI `B.BR7` SameValue
        CFI `VB.BR8` SameValue
        CFI `VB.BR9` SameValue
        CFI `VB.BR10` SameValue
        CFI `VB.BR11` SameValue
        CFI `VB.BR12` SameValue
        CFI `VB.BR13` SameValue
        CFI `VB.BR14` SameValue
        CFI `VB.BR15` SameValue
        CFI VB SameValue
        CFI B Undefined
        CFI A Undefined
        CFI PSW SameValue
        CFI DPL0 SameValue
        CFI DPH0 SameValue
        CFI R0 Undefined
        CFI R1 Undefined
        CFI R2 Undefined
        CFI R3 Undefined
        CFI R4 Undefined
        CFI R5 Undefined
        CFI R6 SameValue
        CFI R7 SameValue
        CFI V0 SameValue
        CFI V1 SameValue
        CFI V2 SameValue
        CFI V3 SameValue
        CFI V4 SameValue
        CFI V5 SameValue
        CFI V6 SameValue
        CFI V7 SameValue
        CFI PSPH Undefined
        CFI PSPL Undefined
        CFI XSPH Undefined
        CFI XSPL Undefined
        CFI ?RET Concat
        CFI ?BRET_EXT Frame(CFA_SP, 3)
        CFI ?RET_HIGH Frame(CFA_SP, 2)
        CFI ?RET_LOW Frame(CFA_SP, 1)
        CFI EndCommon cfiCommon0
        
        
        CFI Common cfiCommon1 Using cfiNames0
        CFI CodeAlign 1
        CFI DataAlign -1
        CFI ReturnAddress ?RET CODE
        CFI CFA_DOVERLAY Used
        CFI CFA_IOVERLAY Used
        CFI CFA_SP SP+-2
        CFI CFA_PSP16 PSP16+0
        CFI CFA_XSP16 XSP16+0
        CFI `PSW.CY` SameValue
        CFI `B.BR0` SameValue
        CFI `B.BR1` SameValue
        CFI `B.BR2` SameValue
        CFI `B.BR3` SameValue
        CFI `B.BR4` SameValue
        CFI `B.BR5` SameValue
        CFI `B.BR6` SameValue
        CFI `B.BR7` SameValue
        CFI `VB.BR8` SameValue
        CFI `VB.BR9` SameValue
        CFI `VB.BR10` SameValue
        CFI `VB.BR11` SameValue
        CFI `VB.BR12` SameValue
        CFI `VB.BR13` SameValue
        CFI `VB.BR14` SameValue
        CFI `VB.BR15` SameValue
        CFI VB SameValue
        CFI B SameValue
        CFI A SameValue
        CFI PSW SameValue
        CFI DPL0 SameValue
        CFI DPH0 SameValue
        CFI R0 SameValue
        CFI R1 SameValue
        CFI R2 SameValue
        CFI R3 SameValue
        CFI R4 SameValue
        CFI R5 SameValue
        CFI R6 SameValue
        CFI R7 SameValue
        CFI V0 SameValue
        CFI V1 SameValue
        CFI V2 SameValue
        CFI V3 SameValue
        CFI V4 SameValue
        CFI V5 SameValue
        CFI V6 SameValue
        CFI V7 SameValue
        CFI PSPH Undefined
        CFI PSPL Undefined
        CFI XSPH Undefined
        CFI XSPL Undefined
        CFI ?RET Concat
        CFI ?BRET_EXT SameValue
        CFI ?RET_HIGH Frame(CFA_SP, 2)
        CFI ?RET_LOW Frame(CFA_SP, 1)
        CFI EndCommon cfiCommon1
        
SPIMgr_Init         SYMBOL "SPIMgr_Init"
osal_msg_receive    SYMBOL "osal_msg_receive"
osal_memcpy         SYMBOL "osal_memcpy"
SPIMgr_CalcFCS      SYMBOL "SPIMgr_CalcFCS"
osal_mem_alloc      SYMBOL "osal_mem_alloc"
HalUARTWrite        SYMBOL "HalUARTWrite"
osal_mem_free       SYMBOL "osal_mem_free"
osal_msg_allocate   SYMBOL "osal_msg_allocate"
osal_msg_send       SYMBOL "osal_msg_send"
osal_msg_deallocate SYMBOL "osal_msg_deallocate"
osal_nv_item_len    SYMBOL "osal_nv_item_len"
osal_nv_write       SYMBOL "osal_nv_write"
osal_memset         SYMBOL "osal_memset"
osal_nv_read        SYMBOL "osal_nv_read"
NLME_GetShortAddr   SYMBOL "NLME_GetShortAddr"
AssocMakeList       SYMBOL "AssocMakeList"
NLME_GetProtocolVersion SYMBOL "NLME_GetProtocolVersion"
osal_strlen         SYMBOL "osal_strlen"
osal_GetSystemClock SYMBOL "osal_GetSystemClock"
OnBoard_SendKeys    SYMBOL "OnBoard_SendKeys"
HalLedSet           SYMBOL "HalLedSet"
afFindEndPointDesc  SYMBOL "afFindEndPointDesc"
??AssocMakeList?relay SYMBOL "?relay", AssocMakeList
??HalLedSet?relay   SYMBOL "?relay", HalLedSet
??HalUARTWrite?relay SYMBOL "?relay", HalUARTWrite
??NLME_GetProtocolVersion?relay SYMBOL "?relay", NLME_GetProtocolVersion
??NLME_GetShortAddr?relay SYMBOL "?relay", NLME_GetShortAddr
??OnBoard_SendKeys?relay SYMBOL "?relay", OnBoard_SendKeys
??SPIMgr_CalcFCS?relay SYMBOL "?relay", SPIMgr_CalcFCS
??SPIMgr_Init?relay SYMBOL "?relay", SPIMgr_Init
??afFindEndPointDesc?relay SYMBOL "?relay", afFindEndPointDesc
??osal_GetSystemClock?relay SYMBOL "?relay", osal_GetSystemClock
??osal_mem_alloc?relay SYMBOL "?relay", osal_mem_alloc
??osal_mem_free?relay SYMBOL "?relay", osal_mem_free
??osal_memcpy?relay SYMBOL "?relay", osal_memcpy
??osal_memset?relay SYMBOL "?relay", osal_memset
??osal_msg_allocate?relay SYMBOL "?relay", osal_msg_allocate
??osal_msg_deallocate?relay SYMBOL "?relay", osal_msg_deallocate
??osal_msg_receive?relay SYMBOL "?relay", osal_msg_receive
??osal_msg_send?relay SYMBOL "?relay", osal_msg_send
??osal_nv_item_len?relay SYMBOL "?relay", osal_nv_item_len
??osal_nv_read?relay SYMBOL "?relay", osal_nv_read
??osal_nv_write?relay SYMBOL "?relay", osal_nv_write
??osal_strlen?relay SYMBOL "?relay", osal_strlen
MTProcessAppMsg     SYMBOL "MTProcessAppMsg"
??MTProcessAppMsg?relay SYMBOL "?relay", MTProcessAppMsg
MTProcessAppRspMsg  SYMBOL "MTProcessAppRspMsg"
??MTProcessAppRspMsg?relay SYMBOL "?relay", MTProcessAppRspMsg
MTProcessLedControl SYMBOL "MTProcessLedControl"
??MTProcessLedControl?relay SYMBOL "?relay", MTProcessLedControl
MT_BuildAndSendZToolCB SYMBOL "MT_BuildAndSendZToolCB"
??MT_BuildAndSendZToolCB?relay SYMBOL "?relay", MT_BuildAndSendZToolCB
MT_BuildAndSendZToolResponse SYMBOL "MT_BuildAndSendZToolResponse"
??MT_BuildAndSendZToolResponse?relay SYMBOL "?relay", MT_BuildAndSendZToolResponse
MT_BuildSPIMsg      SYMBOL "MT_BuildSPIMsg"
??MT_BuildSPIMsg?relay SYMBOL "?relay", MT_BuildSPIMsg
MT_IndReset         SYMBOL "MT_IndReset"
??MT_IndReset?relay SYMBOL "?relay", MT_IndReset
MT_ProcessCommand   SYMBOL "MT_ProcessCommand"
??MT_ProcessCommand?relay SYMBOL "?relay", MT_ProcessCommand
MT_ProcessDebugMsg  SYMBOL "MT_ProcessDebugMsg"
??MT_ProcessDebugMsg?relay SYMBOL "?relay", MT_ProcessDebugMsg
MT_ProcessDebugStr  SYMBOL "MT_ProcessDebugStr"
??MT_ProcessDebugStr?relay SYMBOL "?relay", MT_ProcessDebugStr
MT_ProcessEvent     SYMBOL "MT_ProcessEvent"
??MT_ProcessEvent?relay SYMBOL "?relay", MT_ProcessEvent
MT_ProcessGetDeviceInfo SYMBOL "MT_ProcessGetDeviceInfo"
??MT_ProcessGetDeviceInfo?relay SYMBOL "?relay", MT_ProcessGetDeviceInfo
MT_ProcessGetNV     SYMBOL "MT_ProcessGetNV"
??MT_ProcessGetNV?relay SYMBOL "?relay", MT_ProcessGetNV
MT_ProcessGetNvInfo SYMBOL "MT_ProcessGetNvInfo"
??MT_ProcessGetNvInfo?relay SYMBOL "?relay", MT_ProcessGetNvInfo
MT_ProcessSerialCommand SYMBOL "MT_ProcessSerialCommand"
??MT_ProcessSerialCommand?relay SYMBOL "?relay", MT_ProcessSerialCommand
MT_ProcessSetNV     SYMBOL "MT_ProcessSetNV"
??MT_ProcessSetNV?relay SYMBOL "?relay", MT_ProcessSetNV
MT_RAMRead          SYMBOL "MT_RAMRead"
??MT_RAMRead?relay  SYMBOL "?relay", MT_RAMRead
MT_RAMWrite         SYMBOL "MT_RAMWrite"
??MT_RAMWrite?relay SYMBOL "?relay", MT_RAMWrite
MT_Reset            SYMBOL "MT_Reset"
??MT_Reset?relay    SYMBOL "?relay", MT_Reset
MT_ReverseBytes     SYMBOL "MT_ReverseBytes"
??MT_ReverseBytes?relay SYMBOL "?relay", MT_ReverseBytes
MT_SendErrorNotification SYMBOL "MT_SendErrorNotification"
??MT_SendErrorNotification?relay SYMBOL "?relay", MT_SendErrorNotification
MT_SendSPIRespMsg   SYMBOL "MT_SendSPIRespMsg"
??MT_SendSPIRespMsg?relay SYMBOL "?relay", MT_SendSPIRespMsg
MT_SetDebugThreshold SYMBOL "MT_SetDebugThreshold"
??MT_SetDebugThreshold?relay SYMBOL "?relay", MT_SetDebugThreshold
MT_TaskInit         SYMBOL "MT_TaskInit"
??MT_TaskInit?relay SYMBOL "?relay", MT_TaskInit

        EXTERN SPIMgr_Init
        FUNCTION SPIMgr_Init,0202H
        ARGFRAME ISTACK, 2, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 0, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_msg_receive
        FUNCTION osal_msg_receive,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 10, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_memcpy
        FUNCTION osal_memcpy,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 21, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN SPIMgr_CalcFCS
        FUNCTION SPIMgr_CalcFCS,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_mem_alloc
        FUNCTION osal_mem_alloc,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 22, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN HalUARTWrite
        FUNCTION HalUARTWrite,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 25, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_mem_free
        FUNCTION osal_mem_free,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 22, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_msg_allocate
        FUNCTION osal_msg_allocate,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 25, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_msg_send
        FUNCTION osal_msg_send,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 18, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_msg_deallocate
        FUNCTION osal_msg_deallocate,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 25, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_nv_item_len
        FUNCTION osal_nv_item_len,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 37, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_nv_write
        FUNCTION osal_nv_write,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 39, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_memset
        FUNCTION osal_memset,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 22, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_nv_read
        FUNCTION osal_nv_read,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 26, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN NLME_GetShortAddr
        FUNCTION NLME_GetShortAddr,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN AssocMakeList
        FUNCTION AssocMakeList,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN NLME_GetProtocolVersion
        FUNCTION NLME_GetProtocolVersion,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_strlen
        FUNCTION osal_strlen,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN ZMacSetReq
        FUNCTION ZMacSetReq,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN ZMacGetReq
        FUNCTION ZMacGetReq,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN osal_GetSystemClock
        FUNCTION osal_GetSystemClock,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN OnBoard_SendKeys
        FUNCTION OnBoard_SendKeys,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN HalLedSet
        FUNCTION HalLedSet,0202H
        ARGFRAME ISTACK, 2, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 0, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN afFindEndPointDesc
        FUNCTION afFindEndPointDesc,0202H
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 18, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        EXTERN ??AssocMakeList?relay
        FUNCTION ??AssocMakeList?relay,00H
        EXTERN ??HalLedSet?relay
        FUNCTION ??HalLedSet?relay,00H
        EXTERN ??HalUARTWrite?relay
        FUNCTION ??HalUARTWrite?relay,00H
        EXTERN ??NLME_GetProtocolVersion?relay
        FUNCTION ??NLME_GetProtocolVersion?relay,00H
        EXTERN ??NLME_GetShortAddr?relay
        FUNCTION ??NLME_GetShortAddr?relay,00H
        EXTERN ??OnBoard_SendKeys?relay
        FUNCTION ??OnBoard_SendKeys?relay,00H
        EXTERN ??SPIMgr_CalcFCS?relay
        FUNCTION ??SPIMgr_CalcFCS?relay,00H
        EXTERN ??SPIMgr_Init?relay
        FUNCTION ??SPIMgr_Init?relay,00H
        EXTERN ??afFindEndPointDesc?relay
        FUNCTION ??afFindEndPointDesc?relay,00H
        EXTERN ??osal_GetSystemClock?relay
        FUNCTION ??osal_GetSystemClock?relay,00H
        EXTERN ??osal_mem_alloc?relay
        FUNCTION ??osal_mem_alloc?relay,00H
        EXTERN ??osal_mem_free?relay
        FUNCTION ??osal_mem_free?relay,00H
        EXTERN ??osal_memcpy?relay
        FUNCTION ??osal_memcpy?relay,00H
        EXTERN ??osal_memset?relay
        FUNCTION ??osal_memset?relay,00H
        EXTERN ??osal_msg_allocate?relay
        FUNCTION ??osal_msg_allocate?relay,00H
        EXTERN ??osal_msg_deallocate?relay
        FUNCTION ??osal_msg_deallocate?relay,00H
        EXTERN ??osal_msg_receive?relay
        FUNCTION ??osal_msg_receive?relay,00H
        EXTERN ??osal_msg_send?relay
        FUNCTION ??osal_msg_send?relay,00H
        EXTERN ??osal_nv_item_len?relay
        FUNCTION ??osal_nv_item_len?relay,00H
        EXTERN ??osal_nv_read?relay
        FUNCTION ??osal_nv_read?relay,00H
        EXTERN ??osal_nv_write?relay
        FUNCTION ??osal_nv_write?relay,00H
        EXTERN ??osal_strlen?relay
        FUNCTION ??osal_strlen?relay,00H
        EXTERN devState

// C:\Texas Instruments\ZStack-1.4.3-1.2.1\Components\mt\MTEL.c
//    1 /**************************************************************************************************
//    2   Filename:       MTEL.c
//    3   Revised:        $Date: 2007-12-07 14:27:57 -0800 (Fri, 07 Dec 2007) $
//    4   Revision:       $Revision: 16045 $
//    5 
//    6   Description:    MonitorTest Event Loop functions. Everything in the MonitorTest Task.
//    7 
//    8 
//    9   Copyright 2004-2007 Texas Instruments Incorporated. All rights reserved.
//   10 
//   11   IMPORTANT: Your use of this Software is limited to those specific rights
//   12   granted under the terms of a software license agreement between the user
//   13   who downloaded the software, his/her employer (which must be your employer)
//   14   and Texas Instruments Incorporated (the "License").  You may not use this
//   15   Software unless you agree to abide by the terms of the License. The License
//   16   limits your use, and you acknowledge, that the Software may not be modified,
//   17   copied or distributed unless embedded on a Texas Instruments microcontroller
//   18   or used solely and exclusively in conjunction with a Texas Instruments radio
//   19   frequency transceiver, which is integrated into your product.  Other than for
//   20   the foregoing purpose, you may not use, reproduce, copy, prepare derivative
//   21   works of, modify, distribute, perform, display or sell this Software and/or
//   22   its documentation for any purpose.
//   23 
//   24   YOU FURTHER ACKNOWLEDGE AND AGREE THAT THE SOFTWARE AND DOCUMENTATION ARE
//   25   PROVIDED “AS IS?WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED,
//   26   INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY, TITLE,
//   27   NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL
//   28   TEXAS INSTRUMENTS OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER CONTRACT,
//   29   NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR OTHER
//   30   LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
//   31   INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE
//   32   OR CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT
//   33   OF SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
//   34   (INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
//   35 
//   36   Should you have any questions regarding your right to use this Software,
//   37   contact Texas Instruments Incorporated at www.TI.com.
//   38 **************************************************************************************************/
//   39 
//   40 #if defined( MT_TASK )
//   41 
//   42 /*********************************************************************
//   43  * INCLUDES
//   44  */
//   45 #include "ZComDef.h"
//   46 #include "OnBoard.h"

        ASEGN SFR_AN:DATA:NOROOT,0a8H
// union <unnamed> volatile __sfr _A_IEN0
_A_IEN0:
        DS 1

        ASEGN SFR_AN:DATA:NOROOT,0c9H
// unsigned char volatile __sfr WDCTL
WDCTL:
        DS 1

        ASEGN XDATA_AN:XDATA:NOROOT,0e000H
// mboxMsg_t __xdata mboxMsg
mboxMsg:
        DS 8

        RSEG XDATA_I:XDATA:NOROOT(0)
        DATA
`?<Constant "1.00 (F8W1.4.3)">`:
        DS 16
        REQUIRE `?<Initializer for <Constant "1.00 (F8W1.4.3)">`
        REQUIRE __INIT_XDATA_I

        RSEG XDATA_I:XDATA:NOROOT(0)
        DATA
`?<Constant "1.10 (F8W1.4.3)">`:
        DS 16
        REQUIRE `?<Initializer for <Constant "1.10 (F8W1.4.3)">`
        REQUIRE __INIT_XDATA_I
//   47 #include "OSAL.h"
//   48 #include "OSAL_Memory.h"
//   49 #include "OSAL_Nv.h"
//   50 #include "MTEL.h"
//   51 #include "DebugTrace.h"
//   52 #include "ZMAC.h"
//   53 
//   54 #if !defined ( NONWK )
//   55   #include "NLMEDE.h"
//   56   #include "nwk_bufs.h"
//   57   #include "ZDObject.h"
//   58   #include "ssp.h"
//   59   #include "nwk_util.h"
//   60 #endif
//   61 
//   62 #if defined( MT_MAC_FUNC ) || defined( MT_MAC_CB_FUNC )
//   63   #include "MT_MAC.h"
//   64 #endif
//   65 #if defined( MT_NWK_FUNC ) || defined( MT_NWK_CB_FUNC )
//   66   #include "MT_NWK.h"
//   67   #include "nwk.h"
//   68   #include "nwk_bufs.h"
//   69 #endif
//   70 #if defined( MT_AF_FUNC ) || defined( MT_AF_CB_FUNC )
//   71   #include "MT_AF.h"
//   72 #endif
//   73 #if defined( MT_USER_TEST_FUNC )
//   74   #include "AF.h"
//   75 #endif
//   76 #if defined( MT_ZDO_FUNC )
//   77   #include "MT_ZDO.h"
//   78 #endif
//   79 #if defined (MT_SAPI_FUNC)
//   80 	#include "MT_SAPI.h"
//   81 #endif
//   82 #if defined( APP_TP )
//   83  #include "TestProfile.h"
//   84 #endif
//   85 #if defined( APP_TP2 )
//   86  #include "TestProfile2.h"
//   87 #endif
//   88 
//   89 #if defined(APP_TGEN)
//   90   #include "TrafficGenApp.h"
//   91 #endif
//   92 #if defined(APP_DEBUG)
//   93 	#include "DebugApp.h"
//   94 #endif
//   95 #if defined (NWK_TEST)
//   96 	#include "HWTTApp.h"
//   97 #endif
//   98 
//   99 /* HAL */
//  100 #include "hal_uart.h"
//  101 #include "hal_led.h"
//  102 #include "hal_key.h"
//  103 #include "hal_mailbox.h"
//  104 #include "SPIMgr.h"
//  105 
//  106 /*********************************************************************
//  107  * MACROS
//  108  */
//  109 #define MTEL_DEBUG_INFO( nParams, p1, p2, p3 ) DEBUG_INFO( COMPID_MTEL, nParams, p1, p2, p3 )
//  110 
//  111 #if defined( EXTERNAL_RAM )
//  112   #define IS_MEM_VALID( Addr )  \ 
//  113         /* Check for valid internal RAM address. */\ 
//  114     ( ( (((Addr) >= MCU_RAM_BEG) && ((Addr) <= MCU_RAM_END)) ||  \ 
//  115         /* Check for valid external RAM address. */\ 
//  116         (((Addr) >= EXT_RAM_BEG) && ((Addr) <= EXT_RAM_END)) ) ? TRUE : FALSE )
//  117 #else
//  118   #define IS_MEM_VALID( Addr )  \ 
//  119         /* Check for valid internal RAM address. */\ 
//  120     ( ( ((Addr) >= MCU_RAM_BEG) && ((Addr) <= MCU_RAM_END) ) ? TRUE : FALSE )
//  121 #endif
//  122 
//  123 /*********************************************************************
//  124  * CONSTANTS
//  125  */
//  126 
//  127 #ifdef ZPORT
//  128 const char *MTVersionString[] = {"1.00 (F8W1.4.3-ZP)", "1.10 (F8W1.4.3-ZP)"};
//  129 #else

        RSEG XDATA_I:XDATA:NOROOT(0)
        DATA
//  130 const char *MTVersionString[] = {"1.00 (F8W1.4.3)", "1.10 (F8W1.4.3)"};
MTVersionString:
        DS 4
        REQUIRE `?<Initializer for MTVersionString>`
        REQUIRE __INIT_XDATA_I

        RSEG XDATA_I:XDATA:NOROOT(0)
        DATA
__Constant_3e8:
        DS 4
        REQUIRE `?<Initializer for __Constant_3e8>`
        REQUIRE __INIT_XDATA_I

        RSEG XDATA_I:XDATA:NOROOT(0)
        DATA
__Constant_53544159:
        DS 4
        REQUIRE `?<Initializer for __Constant_53544159>`
        REQUIRE __INIT_XDATA_I
//  131 #endif
//  132 
//  133 /*********************************************************************
//  134  * TYPEDEFS
//  135  */
//  136 
//  137 /*********************************************************************
//  138  * GLOBAL VARIABLES
//  139  */

        RSEG XDATA_Z:XDATA:NOROOT(0)
//  140 byte MT_TaskID;
MT_TaskID:
        DS 1
        REQUIRE __INIT_XDATA_Z

        RSEG XDATA_Z:XDATA:NOROOT(0)
//  141 byte debugThreshold;
debugThreshold:
        DS 1
        REQUIRE __INIT_XDATA_Z

        RSEG XDATA_Z:XDATA:NOROOT(0)
//  142 byte debugCompId;
debugCompId:
        DS 1
        REQUIRE __INIT_XDATA_Z
//  143 

        RSEG XDATA_Z:XDATA:NOROOT(0)
//  144 UINT16 save_cmd;
save_cmd:
        DS 2
        REQUIRE __INIT_XDATA_Z
//  145 
//  146 //DEBUG

        RSEG XDATA_Z:XDATA:NOROOT(0)
//  147 uint32 longvar;
longvar:
        DS 4
        REQUIRE __INIT_XDATA_Z

        RSEG XDATA_Z:XDATA:NOROOT(0)
//  148 uint16 *temp_glob_ptr1;
temp_glob_ptr1:
        DS 2
        REQUIRE __INIT_XDATA_Z

        RSEG XDATA_Z:XDATA:NOROOT(0)
//  149 uint16 *temp_glob_ptr2;
temp_glob_ptr2:
        DS 2
        REQUIRE __INIT_XDATA_Z
//  150 
//  151 /*********************************************************************
//  152  * EXTERNAL VARIABLES
//  153  */
//  154 
//  155 /*********************************************************************
//  156  * EXTERNAL FUNCTIONS
//  157  */
//  158 extern unsigned int mac_sim_eventLoop( void );
//  159 
//  160 #ifdef MACSIM
//  161   // Used to pass Zignet message
//  162   extern void MACSIM_TranslateMsg( byte *buf, byte bLen );
//  163 #endif
//  164 
//  165 /*********************************************************************
//  166  * LOCAL VARIABLES
//  167  */
//  168 
//  169 /*********************************************************************
//  170  * LOCAL FUNCTIONS
//  171  */
//  172 void MT_MsgQueueInit( void );
//  173 void MT_ProcessCommand( mtOSALSerialData_t *msg );
//  174 void MT_ProcessSerialCommand( byte *msg );
//  175 byte MT_RAMRead( UINT16 addr, byte *pData );
//  176 byte MT_RAMWrite( UINT16 addr , byte val );
//  177 void MT_ProcessDebugMsg( mtDebugMsg_t *pData );
//  178 void MT_ProcessDebugStr( mtDebugStr_t *pData );
//  179 byte MT_SetDebugThreshold( byte comp_id, byte threshold );
//  180 void MT_SendErrorNotification( byte err );
//  181 void MT_ResetMsgQueue( void );
//  182 byte MT_QueueMsg( byte *msg , byte len );
//  183 void MT_ProcessQueue( void );
//  184 void MT_SendSPIRespMsg( byte ret, uint16 cmd_id, byte msgLen, byte respLen);
//  185 void MT_Reset(byte typID);
//  186 byte MT_ProcessSetNV( byte *pData );
//  187 void MT_ProcessGetNV( byte *pData );
//  188 void MT_ProcessGetNvInfo( void );
//  189 void MT_ProcessGetDeviceInfo( void );
//  190 byte MTProcessAppMsg( byte *pData, byte len );
//  191 void MTProcessAppRspMsg( byte *pData, byte len );
//  192 
//  193 #if (defined HAL_LED) && (HAL_LED == TRUE)
//  194 byte MTProcessLedControl( byte *pData );
//  195 #endif
//  196 
//  197 #if defined ( MT_USER_TEST_FUNC )
//  198 void MT_ProcessAppUserCmd( byte *pData );
//  199 #endif
//  200 
//  201 /*********************************************************************
//  202  * @fn      MT_TaskInit
//  203  *
//  204  * @brief
//  205  *
//  206  *   MonitorTest Task Initialization.  This function is put into the
//  207  *   task table.
//  208  *
//  209  * @param   byte task_id - task ID of the MT Task
//  210  *
//  211  * @return  void
//  212  *
//  213  *********************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  214 void MT_TaskInit( byte task_id )
MT_TaskInit:
        CFI Block cfiBlock0 Using cfiCommon0
        CFI Function MT_TaskInit
//  215 {
        FUNCALL MT_TaskInit, SPIMgr_Init
        LOCFRAME ISTACK, 2, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 0, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 2, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 0, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        PUSH    DPL
        CFI DPL0 Frame(CFA_SP, 4)
        CFI CFA_SP SP+-4
        PUSH    DPH
        CFI DPH0 Frame(CFA_SP, 5)
        CFI CFA_SP SP+-5
        ; Saved register size: 2
        ; Auto size: 0
//  216   MT_TaskID = task_id;
        MOV     A,R1
        MOV     DPTR,#MT_TaskID
        MOVX    @DPTR,A
//  217 
//  218   debugThreshold = 0;
        CLR     A
        MOV     DPTR,#debugThreshold
        MOVX    @DPTR,A
//  219   debugCompId = 0;
        MOV     DPTR,#debugCompId
        MOVX    @DPTR,A
//  220 
//  221   // Initialize the Serial port
//  222   SPIMgr_Init();
        ; Setup parameters for call to function SPIMgr_Init
        LCALL   ??SPIMgr_Init?relay
//  223 
//  224 } /* MT_TaskInit() */
        LJMP    ?Subroutine23 & 0xFFFF
        CFI EndBlock cfiBlock0
//  225 
//  226 #ifdef ZTOOL_PORT
//  227 /*********************************************************************
//  228  * @fn      MT_IndReset()
//  229  *
//  230  * @brief   Sends a ZTOOL "reset response" message.
//  231  *
//  232  * @param   None
//  233  *
//  234  * @return  None
//  235  *
//  236  *********************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  237 void MT_IndReset( void )
MT_IndReset:
        CFI Block cfiBlock1 Using cfiCommon0
        CFI Function MT_IndReset
//  238 {
        FUNCALL MT_IndReset, MT_BuildAndSendZToolResponse
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 13, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 13, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xa
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 10)
        ; Saved register size: 10
        ; Auto size: 1
        MOV     A,#-0x1
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 11)
//  239 
//  240   byte rsp = 0;  // Reset type==0 indicates Z-Stack reset
        CLR     A
        LCALL   ?Subroutine3 & 0xFFFF
//  241 
//  242   // Send out Reset Response message
//  243   MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + sizeof( rsp )),
//  244                                 (SPI_RESPONSE_BIT | SPI_CMD_SYS_RESET),
//  245                                 sizeof( rsp ), &rsp );
??CrossCallReturnLabel_8:
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 13)
        MOV     R4,#0x1
        MOV     R2,#0x5
        LJMP    ?Subroutine24 & 0xFFFF
        CFI EndBlock cfiBlock1
//  246 }
//  247 #endif
//  248 
//  249 /*********************************************************************
//  250  * @fn      MT_ProcessEvent
//  251  *
//  252  * @brief
//  253  *
//  254  *   MonitorTest Task Event Processor.  This task is put into the
//  255  *   task table.
//  256  *
//  257  * @param   byte task_id - task ID of the MT Task
//  258  * @param   UINT16 events - event(s) for the MT Task
//  259  *
//  260  * @return  void
//  261  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  262 UINT16 MT_ProcessEvent( byte task_id, UINT16 events )
MT_ProcessEvent:
        CFI Block cfiBlock2 Using cfiCommon0
        CFI Function MT_ProcessEvent
//  263 {
        FUNCALL MT_ProcessEvent, MT_SendErrorNotification
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 10, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 10, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessEvent, MT_ProcessCommand
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 10, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 10, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessEvent, osal_msg_receive
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 10, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 10, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xa
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 10)
        ; Saved register size: 10
        ; Auto size: 0
        MOV     A,R2
        MOV     R6,A
        MOV     A,R3
        MOV     R7,A
//  264   uint8 *msg_ptr;
//  265 
//  266   // Could be multiple events, so switch won't work
//  267 
//  268   if ( events & SYS_EVENT_MSG )
        MOV     A,#-0x80
        ANL     A,R7
        MOV     R1,A
        CLR     A
        JNZ     ??MT_ProcessEvent_0
        MOV     A,R1
??MT_ProcessEvent_0:
        JNZ     ??MT_ProcessEvent_1
//  269   {
//  270     while ( (msg_ptr = osal_msg_receive( MT_TaskID )) )
//  271     {
//  272       MT_ProcessCommand( (mtOSALSerialData_t *)msg_ptr );
//  273     }
//  274 
//  275     // Return unproccessed events
//  276     return (events ^ SYS_EVENT_MSG);
//  277   }
//  278 
//  279 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  280   if ( events & MT_ZTOOL_SERIAL_RCV_BUFFER_FULL )
        MOV     A,R6
        ANL     A,#0x4
        JZ      ??MT_ProcessEvent_2
//  281   {
//  282     // Do sometype of error processing
//  283     MT_SendErrorNotification(RECEIVE_BUFFER_FULL);
        ; Setup parameters for call to function MT_SendErrorNotification
        MOV     R1,#0x2
        LCALL   ??MT_SendErrorNotification?relay
//  284 
//  285     // Return unproccessed events
//  286     return (events ^ MT_ZTOOL_SERIAL_RCV_BUFFER_FULL);
        MOV     A,#0x4
        XRL     A,R6
        MOV     R2,A
        MOV     A,R7
??MT_ProcessEvent_3:
        MOV     R3,A
        SJMP    ??MT_ProcessEvent_4
//  287   }
??MT_ProcessEvent_5:
        ; Setup parameters for call to function MT_ProcessCommand
        LCALL   ??MT_ProcessCommand?relay
??MT_ProcessEvent_1:
        ; Setup parameters for call to function osal_msg_receive
        MOV     DPTR,#MT_TaskID
        MOVX    A,@DPTR
        MOV     R1,A
        LCALL   ??osal_msg_receive?relay
        MOV     A,R2
        JNZ     ??MT_ProcessEvent_6
        MOV     A,R3
??MT_ProcessEvent_6:
        JNZ     ??MT_ProcessEvent_5
        MOV     A,R6
        MOV     R2,A
        MOV     A,#-0x80
        XRL     A,R7
        SJMP    ??MT_ProcessEvent_3
//  288 #endif
//  289 
//  290   // Discard or make more handlers
//  291   return 0;
??MT_ProcessEvent_2:
        MOV     R2,#0x0
        MOV     R3,#0x0
??MT_ProcessEvent_4:
        LJMP    ??Subroutine24_1 & 0xFFFF
        CFI EndBlock cfiBlock2
//  292 
//  293 } /* MT_ProcessEvent() */
//  294 
//  295 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  296 /*********************************************************************
//  297  * @fn      MT_BuildSPIMsg
//  298  *
//  299  * @brief
//  300  *
//  301  *   Format an SPI message.
//  302  *
//  303  * @param   UINT16 cmd - command id
//  304  * @param   byte *msg - pointer to message buffer
//  305  * @param   byte dataLen - length of data field
//  306  * @param   byte *pData - pointer to data field
//  307  *
//  308  * @return  void
//  309  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  310 void MT_BuildSPIMsg( UINT16 cmd, byte *msg, byte dataLen, byte *pData )
MT_BuildSPIMsg:
        CFI Block cfiBlock3 Using cfiCommon0
        CFI Function MT_BuildSPIMsg
//  311 {
        FUNCALL MT_BuildSPIMsg, osal_memcpy
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 17, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 17, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_BuildSPIMsg, SPIMgr_CalcFCS
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xe
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 14)
        ; Saved register size: 14
        ; Auto size: 0
        MOV     A,R4
        MOV     R6,A
        MOV     A,R5
        MOV     R7,A
        MOV     ?V0 + 3,R1
        MOV     A,#0xe
        LCALL   ?XSTACK_DISP0_8
        MOVX    A,@DPTR
        MOV     ?V0 + 0,A
        INC     DPTR
        MOVX    A,@DPTR
        MOV     ?V0 + 1,A
//  312   byte *msgPtr;
//  313 
//  314   *msg++ = SOP_VALUE;
        MOV     A,#0x2
        MOV     DPL,R6
        MOV     DPH,R7
        MOVX    @DPTR,A
        INC     DPTR
        MOV     R6,DPL
        MOV     R7,DPH
//  315 
//  316   msgPtr = msg;
        MOV     ?V0 + 4,R6
        MOV     ?V0 + 5,R7
//  317 
//  318   *msg++ = (byte)(HI_UINT16( cmd ));
        MOV     A,R3
        MOVX    @DPTR,A
        INC     DPTR
//  319   *msg++ = (byte)(LO_UINT16( cmd ));
        MOV     A,R2
        MOVX    @DPTR,A
        INC     DPTR
//  320 
//  321   if ( pData )
        MOV     A,?V0 + 0
        JNZ     ??MT_BuildSPIMsg_0
        MOV     A,?V0 + 1
??MT_BuildSPIMsg_0:
        JZ      ??MT_BuildSPIMsg_1
//  322   {
//  323     *msg++ = dataLen;
        MOV     A,R1
        MOVX    @DPTR,A
        INC     DPTR
        INC     R6
        INC     R6
        INC     R6
        MOV     R7,DPH
//  324 
//  325     msg = osal_memcpy( msg, pData, dataLen );
        ; Setup parameters for call to function osal_memcpy
        MOV     ?V0 + 2,#0x0
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_THREE
        CFI CFA_XSP16 add(XSP16, 17)
        MOV     A,R1
        MOV     R4,A
        MOV     R5,#0x0
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        LCALL   ??osal_memcpy?relay
        MOV     A,#0x3
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 14)
        MOV     ?V0 + 0,R2
        MOV     ?V0 + 1,R3
        MOV     R6,?V0 + 0
        MOV     R7,?V0 + 1
        SJMP    ??MT_BuildSPIMsg_2
//  326   }
//  327   else
//  328     *msg++ = 0;
??MT_BuildSPIMsg_1:
        CLR     A
        MOVX    @DPTR,A
        INC     DPTR
        INC     R6
        INC     R6
        INC     R6
        MOV     R7,DPH
//  329 
//  330   *msg = SPIMgr_CalcFCS( msgPtr, (byte)(3 + dataLen) );
??MT_BuildSPIMsg_2:
        ; Setup parameters for call to function SPIMgr_CalcFCS
        MOV     A,#0x3
        ADD     A,?V0 + 3
        MOV     R1,A
        MOV     R2,?V0 + 4
        MOV     R3,?V0 + 5
        LCALL   ??SPIMgr_CalcFCS?relay
        MOV     A,R1
        MOV     DPL,R6
        MOV     DPH,R7
        MOVX    @DPTR,A
//  331 }
        LJMP    ??Subroutine25_1 & 0xFFFF
        CFI EndBlock cfiBlock3
//  332 #endif
//  333 
//  334 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  335 /*********************************************************************
//  336  * @fn      MT_BuildAndSendZToolResponse
//  337  *
//  338  * @brief
//  339  *
//  340  *   Build and send a ZTOOL msg
//  341  *
//  342  * @param   byte err
//  343  *
//  344  * @return  void
//  345  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  346 void MT_BuildAndSendZToolResponse( byte msgLen, uint16 cmd,
MT_BuildAndSendZToolResponse:
        CFI Block cfiBlock4 Using cfiCommon0
        CFI Function MT_BuildAndSendZToolResponse
//  347                                    byte dataLen, byte *pData )
//  348 {
        FUNCALL MT_BuildAndSendZToolResponse, osal_mem_alloc
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_BuildAndSendZToolResponse, MT_BuildSPIMsg
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 18, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 18, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_BuildAndSendZToolResponse, HalUARTWrite
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_BuildAndSendZToolResponse, osal_mem_free
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0x10
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        ; Saved register size: 16
        ; Auto size: 0
        MOV     ?V0 + 2,R1
        MOV     ?V0 + 6,R2
        MOV     ?V0 + 7,R3
        MOV     ?V0 + 3,R4
        MOV     A,#0x10
        LCALL   ?XSTACK_DISP0_8
        MOVX    A,@DPTR
        MOV     ?V0 + 0,A
        INC     DPTR
        MOVX    A,@DPTR
        MOV     ?V0 + 1,A
//  349   byte *msg_ptr;
//  350 
//  351   // Get a message buffer to build response message
//  352   msg_ptr = osal_mem_alloc( msgLen );
        ; Setup parameters for call to function osal_mem_alloc
        MOV     A,R1
        MOV     R2,A
        MOV     R3,#0x0
        LCALL   ??osal_mem_alloc?relay
        MOV     ?V0 + 4,R2
        MOV     ?V0 + 5,R3
        MOV     R6,?V0 + 4
        MOV     R7,?V0 + 5
//  353   if ( msg_ptr )
        MOV     A,R6
        JNZ     ??MT_BuildAndSendZToolResponse_0
        MOV     A,R7
??MT_BuildAndSendZToolResponse_0:
        JZ      ??CrossCallReturnLabel_44
//  354   {
//  355 #ifdef SPI_MGR_DEFAULT_PORT
//  356     MT_BuildSPIMsg( cmd, msg_ptr, dataLen, pData );
        ; Setup parameters for call to function MT_BuildSPIMsg
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 18)
        MOV     R1,?V0 + 3
        MOV     A,R6
        MOV     R4,A
        MOV     A,R7
        MOV     R5,A
        MOV     R2,?V0 + 6
        MOV     R3,?V0 + 7
        LCALL   ?Subroutine16 & 0xFFFF
??CrossCallReturnLabel_49:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 16)
//  357     HalUARTWrite ( SPI_MGR_DEFAULT_PORT, msg_ptr, msgLen );
        ; Setup parameters for call to function HalUARTWrite
        MOV     R4,?V0 + 2
        LCALL   ?Subroutine13 & 0xFFFF
//  358 #endif
//  359     osal_mem_free( msg_ptr );
//  360   }
//  361 }
??CrossCallReturnLabel_44:
        SJMP    ??Subroutine26_0
        CFI EndBlock cfiBlock4

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine26:
        CFI Block cfiBlock5 Using cfiCommon0
        CFI NoFunction
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 22)
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI Invalid
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 16)
        CFI Valid
??Subroutine26_0:
        MOV     R7,#0x8
        LJMP    ?BANKED_LEAVE_XDATA
        CFI EndBlock cfiBlock5

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine13:
        CFI Block cfiCond6 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_44
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        CFI Block cfiCond7 Using cfiCommon0
        CFI (cfiCond7) NoFunction
        CFI (cfiCond7) Conditional ??CrossCallReturnLabel_45
        CFI (cfiCond7) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond7) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond7) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond7) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond7) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond7) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond7) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond7) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond7) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond7) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond7) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond7) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond7) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond7) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond7) CFA_SP SP+0
        CFI (cfiCond7) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiPicker8 Using cfiCommon1
        CFI (cfiPicker8) NoFunction
        CFI (cfiPicker8) Picker
        MOV     R5,#0x0
        CFI Block cfiCond9 Using cfiCommon0
        CFI (cfiCond9) NoFunction
        CFI (cfiCond9) Conditional ??CrossCallReturnLabel_46
        CFI (cfiCond9) R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond9) VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond9) V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond9) V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond9) V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond9) V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond9) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond9) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond9) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond9) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond9) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond9) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond9) CFA_SP SP+0
        CFI (cfiCond9) CFA_XSP16 add(XSP16, 12)
??Subroutine13_0:
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        MOV     R1,#0x0
        LCALL   ??HalUARTWrite?relay
        ; Setup parameters for call to function osal_mem_free
        ; Setup parameters for call to function osal_mem_free
        ; Setup parameters for call to function osal_mem_free
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        LCALL   ??osal_mem_free?relay
        RET
        CFI EndBlock cfiCond6
        CFI EndBlock cfiCond7
        CFI EndBlock cfiPicker8
        CFI EndBlock cfiCond9
//  362 #endif
//  363 
//  364 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  365 /*********************************************************************
//  366  * @fn      MT_BuildAndSendZToolCB
//  367  *
//  368  * @brief
//  369  *
//  370  *   Build and send a ZTOOL Callback msg
//  371  *
//  372  * @param   len - length of data portion of the message
//  373  *
//  374  * @return  void
//  375  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  376 void MT_BuildAndSendZToolCB( uint16 callbackID, byte len, byte *pData )
MT_BuildAndSendZToolCB:
        CFI Block cfiBlock10 Using cfiCommon0
        CFI Function MT_BuildAndSendZToolCB
//  377 {
        FUNCALL MT_BuildAndSendZToolCB, osal_msg_allocate
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_BuildAndSendZToolCB, osal_memcpy
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 19, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 19, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_BuildAndSendZToolCB, osal_msg_send
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0x10
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        ; Saved register size: 16
        ; Auto size: 0
        MOV     A,R2
        MOV     R6,A
        MOV     A,R3
        MOV     R7,A
        MOV     ?V0 + 0,R1
        MOV     ?V0 + 6,R4
        MOV     ?V0 + 7,R5
//  378   byte msgLen;
//  379   mtOSALSerialData_t *msgPtr;
//  380   byte *msg;
//  381 
//  382   msgLen = sizeof ( mtOSALSerialData_t ) + SPI_0DATA_MSG_LEN + len;
//  383 
//  384   msgPtr = (mtOSALSerialData_t *)osal_msg_allocate( msgLen );
        ; Setup parameters for call to function osal_msg_allocate
        MOV     A,#0x9
        LCALL   ?Subroutine14 & 0xFFFF
//  385   if ( msgPtr )
??CrossCallReturnLabel_87:
        JNZ     ??MT_BuildAndSendZToolCB_0
        MOV     A,R3
??MT_BuildAndSendZToolCB_0:
        JZ      ??MT_BuildAndSendZToolCB_1
//  386   {
//  387     msgPtr->hdr.event = CB_FUNC;
        MOV     A,#0x4
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    @DPTR,A
//  388     msgPtr->msg = (uint8 *)(msgPtr+1);
        MOV     A,R2
        ADD     A,#0x2
        MOV     R0,A
        MOV     A,R3
        ADDC    A,#0x0
        MOV     R1,A
        MOV     A,R2
        ADD     A,#0x4
        MOV     R2,A
        MOV     A,R3
        ADDC    A,#0x0
        MOV     R3,A
        MOV     DPL,R0
        MOV     DPH,R1
        MOV     A,R2
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R3
        MOVX    @DPTR,A
//  389     msg = msgPtr->msg;
        MOV     DPL,R0
        MOV     DPH,R1
        MOVX    A,@DPTR
        MOV     R2,A
//  390 
//  391     //First byte is used as the event type for MT
//  392     *msg++ = SOP_VALUE;
        MOV     A,#0x2
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    @DPTR,A
        INC     DPTR
//  393     *msg++ = HI_UINT16( callbackID );
        MOV     A,R7
        MOVX    @DPTR,A
        INC     DPTR
//  394     *msg++ = LO_UINT16( callbackID );
        MOV     A,R6
        MOVX    @DPTR,A
        INC     DPTR
//  395     *msg++ = len;
        MOV     A,?V0 + 0
        MOVX    @DPTR,A
        INC     DPTR
        MOV     R2,DPL
        MOV     R3,DPH
//  396 
//  397     //Fill up the data bytes
//  398     osal_memcpy( msg, pData, len );
        ; Setup parameters for call to function osal_memcpy
        MOV     ?V0 + 4,?V0 + 6
        MOV     ?V0 + 5,?V0 + 7
        MOV     ?V0 + 6,#0x0
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_THREE
        CFI CFA_XSP16 add(XSP16, 19)
        MOV     R4,?V0 + 0
        MOV     R5,#0x0
        LCALL   ??osal_memcpy?relay
        MOV     A,#0x3
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 16)
//  399 
//  400     osal_msg_send( MT_TaskID, (uint8 *)msgPtr );
        ; Setup parameters for call to function osal_msg_send
        MOV     R2,?V0 + 2
        MOV     R3,?V0 + 3
        MOV     DPTR,#MT_TaskID
        MOVX    A,@DPTR
        MOV     R1,A
        LCALL   ??osal_msg_send?relay
//  401   }
//  402 }
??MT_BuildAndSendZToolCB_1:
        LJMP    ??Subroutine26_0 & 0xFFFF
        CFI EndBlock cfiBlock10
//  403 #endif
//  404 
//  405 /*********************************************************************
//  406  * @fn      MT_ProcessCommand
//  407  *
//  408  * @brief
//  409  *
//  410  *   Process Event Messages.
//  411  *
//  412  * @param   byte *msg - pointer to event message
//  413  *
//  414  * @return
//  415  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  416 void MT_ProcessCommand( mtOSALSerialData_t *msg )
MT_ProcessCommand:
        CFI Block cfiBlock11 Using cfiCommon0
        CFI Function MT_ProcessCommand
//  417 {
        FUNCALL MT_ProcessCommand, MT_ProcessSerialCommand
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessCommand, MT_ProcessDebugMsg
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessCommand, MT_ProcessDebugStr
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessCommand, SPIMgr_CalcFCS
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessCommand, HalUARTWrite
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessCommand, MTProcessAppRspMsg
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessCommand, osal_msg_deallocate
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xe
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 14)
        ; Saved register size: 14
        ; Auto size: 0
        MOV     ?V0 + 0,R2
        MOV     ?V0 + 1,R3
//  418   byte deallocate;
//  419 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  420   byte *msg_ptr;
//  421   byte len;
//  422 
//  423   // A little setup for AF, CB_FUNC and MT_SYS_APP_RSP_MSG
//  424   msg_ptr = msg->msg;
        MOV     DPL,R2
        MOV     DPH,R3
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        MOV     R6,A
        INC     DPTR
        MOVX    A,@DPTR
        MOV     R7,A
//  425 #endif // ZTOOL
//  426 
//  427   deallocate = true;
//  428 
//  429   // Use the first byte of the message as the command ID
//  430   switch ( msg->hdr.event )
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        LCALL   ?UC_SWITCH_SPARSE
`?<Jumptable for MT_ProcessCommand>_0`:
        DATA
        DB        0
        DB        5
        DB        1
        DW        ??MT_ProcessCommand_0
        DB        2
        DW        ??MT_ProcessCommand_1
        DB        4
        DW        ??MT_ProcessCommand_2
        DB        6
        DW        ??MT_ProcessCommand_3
        DB        36
        DW        ??MT_ProcessCommand_4
        DW        ??MT_ProcessCommand_5
        CODE
//  431   {
//  432 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  433     case CMD_SERIAL_MSG:
//  434       MT_ProcessSerialCommand( msg->msg );
??MT_ProcessCommand_0:
        ; Setup parameters for call to function MT_ProcessSerialCommand
        MOV     DPL,R2
        MOV     DPH,R3
        INC     DPTR
        INC     DPTR
        LCALL   ??Subroutine8_0 & 0xFFFF
??CrossCallReturnLabel_25:
        LCALL   ??MT_ProcessSerialCommand?relay
        SJMP    ??MT_ProcessCommand_5
//  435       break;
//  436 
//  437     case CMD_DEBUG_MSG:
//  438       MT_ProcessDebugMsg( (mtDebugMsg_t *)msg );
??MT_ProcessCommand_1:
        ; Setup parameters for call to function MT_ProcessDebugMsg
        LCALL   ??MT_ProcessDebugMsg?relay
        SJMP    ??MT_ProcessCommand_5
//  439       break;
//  440 
//  441     case CMD_DEBUG_STR:
//  442       MT_ProcessDebugStr( (mtDebugStr_t *)msg );
??MT_ProcessCommand_3:
        ; Setup parameters for call to function MT_ProcessDebugStr
        LCALL   ??MT_ProcessDebugStr?relay
        SJMP    ??MT_ProcessCommand_5
//  443       break;
//  444 
//  445     case CB_FUNC:
//  446       /*
//  447         Build SPI message here instead of redundantly calling MT_BuildSPIMsg
//  448         because we have copied data already in the allocated message
//  449       */
//  450 
//  451       /* msg_ptr is the beginning of the intended SPI message */
//  452       len = SPI_0DATA_MSG_LEN + msg_ptr[DATALEN_FIELD];
??MT_ProcessCommand_2:
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        ADD     A,#0x5
        MOV     ?V0 + 2,A
//  453 
//  454       /*
//  455         FCS goes to the last byte in the message and is calculated over all
//  456         the bytes except FCS and SOP
//  457       */
//  458       msg_ptr[len-1] = SPIMgr_CalcFCS( msg_ptr + 1 , (byte)(len-2) );
        ; Setup parameters for call to function SPIMgr_CalcFCS
        MOV     A,#-0x2
        ADD     A,?V0 + 2
        MOV     R1,A
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        MOV     R2,DPL
        MOV     R3,DPH
        LCALL   ??SPIMgr_CalcFCS?relay
        MOV     A,R1
        PUSH    A
        CFI CFA_SP SP+-1
        MOV     ?V0 + 4,?V0 + 2
        MOV     A,R6
        ADD     A,?V0 + 4
        MOV     R0,A
        MOV     A,R7
        ADDC    A,#0x0
        MOV     R1,A
        MOV     A,#-0x1
        ADD     A,R0
        MOV     DPL,A
        MOV     A,#-0x1
        ADDC    A,R1
        MOV     DPH,A
        POP     A
        CFI CFA_SP SP+0
        MOVX    @DPTR,A
//  459 
//  460 #ifdef SPI_MGR_DEFAULT_PORT
//  461       HalUARTWrite ( SPI_MGR_DEFAULT_PORT, msg_ptr, len );
        ; Setup parameters for call to function HalUARTWrite
        MOV     R4,?V0 + 2
        MOV     R5,#0x0
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        MOV     R1,#0x0
        LCALL   ??HalUARTWrite?relay
        SJMP    ??MT_ProcessCommand_5
//  462 #endif
//  463       break;
//  464 
//  465 #if !defined ( NONWK )
//  466     case MT_SYS_APP_RSP_MSG:
//  467       len = SPI_0DATA_MSG_LEN + msg_ptr[DATALEN_FIELD];
//  468       MTProcessAppRspMsg( msg_ptr, len );
??MT_ProcessCommand_4:
        ; Setup parameters for call to function MTProcessAppRspMsg
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        ADD     A,#0x5
        MOV     R1,A
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        LCALL   ??MTProcessAppRspMsg?relay
//  469       break;
//  470 #endif  // NONWK
//  471 #endif  // ZTOOL
//  472 
//  473     default:
//  474       break;
//  475   }
//  476 
//  477   if ( deallocate )
//  478   {
//  479     osal_msg_deallocate( (uint8 *)msg );
??MT_ProcessCommand_5:
        ; Setup parameters for call to function osal_msg_deallocate
        MOV     R2,?V0 + 0
        MOV     R3,?V0 + 1
        LCALL   ??osal_msg_deallocate?relay
//  480   }
//  481 }
        LJMP    ??Subroutine25_1 & 0xFFFF
        CFI EndBlock cfiBlock11
//  482 
//  483 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  484 /*********************************************************************
//  485  * @fn      MT_ProcessDebugMsg
//  486  *
//  487  * @brief
//  488  *
//  489  *   Build and send a debug message.
//  490  *
//  491  * @param   byte *data - pointer to the data portion of the debug message
//  492  *
//  493  * @return  void
//  494  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  495 void MT_ProcessDebugMsg( mtDebugMsg_t *msg )
MT_ProcessDebugMsg:
        CFI Block cfiBlock12 Using cfiCommon0
        CFI Function MT_ProcessDebugMsg
//  496 {
        FUNCALL MT_ProcessDebugMsg, osal_msg_allocate
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 25, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 25, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessDebugMsg, MT_BuildSPIMsg
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 27, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 27, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessDebugMsg, HalUARTWrite
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 25, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 25, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessDebugMsg, osal_msg_deallocate
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 25, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 25, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xe
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 14)
        ; Saved register size: 14
        ; Auto size: 11
        MOV     A,#-0xb
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 25)
        MOV     A,R2
        MOV     R6,A
        MOV     A,R3
        MOV     R7,A
//  497   byte *msg_ptr;
//  498   byte dataLen;
//  499   uint8 buf[11];
//  500   uint8 *pBuf;
//  501 
//  502   // Calculate the data length based
//  503   dataLen = 5 + (msg->numParams * sizeof ( uint16 ));
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        INC     DPTR
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        CLR     C
        RLC     A
        ADD     A,#0x5
        MOV     ?V0 + 0,A
//  504 
//  505   // Get a message buffer to build the debug message
//  506   msg_ptr = osal_msg_allocate( (byte)(SPI_0DATA_MSG_LEN + dataLen + 1) );
        ; Setup parameters for call to function osal_msg_allocate
        MOV     A,#0x6
        LCALL   ?Subroutine14 & 0xFFFF
//  507   if ( msg_ptr )
??CrossCallReturnLabel_88:
        JNZ     ??MT_ProcessDebugMsg_0
        MOV     A,R3
??MT_ProcessDebugMsg_0:
        JNZ     $+5
        LJMP    ??MT_ProcessDebugMsg_1 & 0xFFFF
//  508   {
//  509     // Build the message
//  510     pBuf = buf;
//  511     *pBuf++ = msg->compID;
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ?Subroutine4 & 0xFFFF
//  512     *pBuf++ = msg->severity;
??CrossCallReturnLabel_10:
        MOVX    A,@DPTR
        PUSH    A
        CFI CFA_SP SP+-1
        MOV     A,#0x1
        LCALL   ?XSTACK_DISP0_8
        POP     A
        CFI CFA_SP SP+0
        MOVX    @DPTR,A
//  513     *pBuf++ = msg->numParams;
        MOV     A,R6
        ADD     A,#0x4
        MOV     R0,A
        MOV     A,R7
        ADDC    A,#0x0
        MOV     R1,A
        MOV     A,R0
        MOV     R2,A
        MOV     A,R1
        MOV     R3,A
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        PUSH    A
        CFI CFA_SP SP+-1
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        POP     A
        CFI CFA_SP SP+0
        MOVX    @DPTR,A
        MOV     A,#0x3
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,DPL
        MOV     R1,DPH
//  514 
//  515     if ( msg->numParams >= 1 )
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        JZ      ??MT_ProcessDebugMsg_2
//  516     {
//  517       *pBuf++ = HI_UINT16( msg->param1 );
        MOV     A,R6
        ADD     A,#0x5
        MOV     R0,A
        MOV     A,R7
        ADDC    A,#0x0
        MOV     R1,A
        MOV     DPL,R0
        MOV     DPH,R1
        INC     DPTR
        MOVX    A,@DPTR
        PUSH    A
        CFI CFA_SP SP+-1
        MOV     A,#0x3
        LCALL   ?XSTACK_DISP0_8
        POP     A
        CFI CFA_SP SP+0
        MOVX    @DPTR,A
//  518       *pBuf++ = LO_UINT16( msg->param1 );
        MOV     DPL,R0
        MOV     DPH,R1
        MOVX    A,@DPTR
        PUSH    A
        CFI CFA_SP SP+-1
        MOV     A,#0x4
        LCALL   ?XSTACK_DISP0_8
        POP     A
        CFI CFA_SP SP+0
        MOVX    @DPTR,A
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,DPL
        MOV     R1,DPH
//  519     }
//  520 
//  521     if ( msg->numParams >= 2 )
??MT_ProcessDebugMsg_2:
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        INC     DPTR
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        CLR     C
        SUBB    A,#0x2
        JC      ??CrossCallReturnLabel_6
//  522     {
//  523       *pBuf++ = HI_UINT16( msg->param2 );
        MOV     A,R6
        ADD     A,#0x7
        INC     R2
        INC     R2
        INC     R2
        LCALL   ?Subroutine1 & 0xFFFF
//  524       *pBuf++ = LO_UINT16( msg->param2 );
//  525     }
//  526 
//  527     if ( msg->numParams == 3 )
??CrossCallReturnLabel_6:
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        INC     DPTR
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        XRL     A,#0x3
        JNZ     ??CrossCallReturnLabel_7
//  528     {
//  529       *pBuf++ = HI_UINT16( msg->param3 );
        MOV     A,R6
        ADD     A,#0x9
        MOV     R2,A
        LCALL   ?Subroutine1 & 0xFFFF
//  530       *pBuf++ = LO_UINT16( msg->param3 );
//  531     }
//  532 
//  533     *pBuf++ = HI_UINT16( msg->timestamp );
??CrossCallReturnLabel_7:
        MOV     A,R6
        ADD     A,#0xb
        MOV     R2,A
        LCALL   ?Subroutine22 & 0xFFFF
??CrossCallReturnLabel_69:
        LCALL   ?Subroutine11 & 0xFFFF
??CrossCallReturnLabel_36:
        INC     DPTR
        MOV     R0,DPL
        MOV     R1,DPH
//  534     *pBuf++ = LO_UINT16( msg->timestamp );
        MOV     DPL,R2
        MOV     DPH,R3
        LCALL   ?Subroutine11 & 0xFFFF
//  535 
//  536 #ifdef SPI_MGR_DEFAULT_PORT
//  537     MT_BuildSPIMsg( SPI_CMD_DEBUG_MSG, &msg_ptr[1], dataLen, buf );
??CrossCallReturnLabel_37:
        MOV     DPL,?V0 + 2
        MOV     DPH,?V0 + 3
        INC     DPTR
        MOV     R6,DPL
        MOV     R7,DPH
        ; Setup parameters for call to function MT_BuildSPIMsg
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOV     ?V0 + 4,DPL
        MOV     ?V0 + 5,DPH
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 27)
        MOV     R1,?V0 + 0
        MOV     A,R6
        MOV     R4,A
        MOV     A,R7
        MOV     R5,A
        MOV     R2,#0x3
        MOV     R3,#0x40
        LCALL   ?Subroutine16 & 0xFFFF
??CrossCallReturnLabel_50:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 25)
//  538     HalUARTWrite ( SPI_MGR_DEFAULT_PORT, &msg_ptr[1], SPI_0DATA_MSG_LEN + dataLen );
        ; Setup parameters for call to function HalUARTWrite
        MOV     A,#0x5
        ADD     A,?V0 + 0
        MOV     R4,A
        CLR     A
        ADDC    A,#0x0
        MOV     R5,A
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        MOV     R1,#0x0
        LCALL   ??HalUARTWrite?relay
//  539 #endif
//  540     osal_msg_deallocate( msg_ptr );
        ; Setup parameters for call to function osal_msg_deallocate
        MOV     R2,?V0 + 2
        MOV     R3,?V0 + 3
        LCALL   ??osal_msg_deallocate?relay
//  541   }
//  542 }
??MT_ProcessDebugMsg_1:
        MOV     A,#0xb
        SJMP    ??Subroutine25_0
        CFI EndBlock cfiBlock12

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine25:
        CFI Block cfiBlock13 Using cfiCommon0
        CFI NoFunction
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 15)
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        MOV     A,#0x1
??Subroutine25_0:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 14)
??Subroutine25_1:
        MOV     R7,#0x6
        LJMP    ?BANKED_LEAVE_XDATA
        CFI EndBlock cfiBlock13

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine14:
        CFI Block cfiCond14 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_87
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        CFI Block cfiCond15 Using cfiCommon0
        CFI (cfiCond15) NoFunction
        CFI (cfiCond15) Conditional ??CrossCallReturnLabel_88
        CFI (cfiCond15) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond15) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond15) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond15) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond15) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond15) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond15) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond15) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond15) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond15) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond15) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond15) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond15) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond15) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond15) CFA_SP SP+0
        CFI (cfiCond15) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiPicker16 Using cfiCommon1
        CFI (cfiPicker16) NoFunction
        CFI (cfiPicker16) Picker
        ADD     A,?V0 + 0
        MOV     R2,A
        MOV     R3,#0x0
        LCALL   ??osal_msg_allocate?relay
        CFI EndBlock cfiCond14
        CFI EndBlock cfiCond15
        CFI EndBlock cfiPicker16
        REQUIRE ?Subroutine28
        ; // Fall through to label ?Subroutine28

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine28:
        CFI Block cfiCond17 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_87
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        CFI Block cfiCond18 Using cfiCommon0
        CFI (cfiCond18) NoFunction
        CFI (cfiCond18) Conditional ??CrossCallReturnLabel_88
        CFI (cfiCond18) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond18) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond18) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond18) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond18) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond18) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond18) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond18) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond18) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond18) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond18) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond18) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond18) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond18) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond18) CFA_SP SP+0
        CFI (cfiCond18) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond19 Using cfiCommon0
        CFI (cfiCond19) NoFunction
        CFI (cfiCond19) Conditional ??CrossCallReturnLabel_85
        CFI (cfiCond19) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond19) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond19) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond19) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond19) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond19) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond19) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond19) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond19) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond19) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond19) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond19) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond19) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond19) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond19) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond19) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond19) CFA_SP SP+0
        CFI (cfiCond19) CFA_XSP16 add(XSP16, 22)
        CFI Block cfiCond20 Using cfiCommon0
        CFI (cfiCond20) NoFunction
        CFI (cfiCond20) Conditional ??CrossCallReturnLabel_86
        CFI (cfiCond20) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond20) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond20) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond20) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond20) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond20) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond20) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond20) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond20) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond20) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond20) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond20) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond20) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond20) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond20) CFA_SP SP+0
        CFI (cfiCond20) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiPicker21 Using cfiCommon1
        CFI (cfiPicker21) NoFunction
        CFI (cfiPicker21) Picker
        MOV     ?V0 + 2,R2
        MOV     ?V0 + 3,R3
        MOV     A,R2
        RET
        CFI EndBlock cfiCond17
        CFI EndBlock cfiCond18
        CFI EndBlock cfiCond19
        CFI EndBlock cfiCond20
        CFI EndBlock cfiPicker21

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine1:
        CFI Block cfiCond22 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_6
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond23 Using cfiCommon0
        CFI (cfiCond23) NoFunction
        CFI (cfiCond23) Conditional ??CrossCallReturnLabel_7
        CFI (cfiCond23) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond23) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond23) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond23) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond23) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond23) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond23) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond23) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond23) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond23) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond23) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond23) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond23) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond23) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond23) CFA_SP SP+0
        CFI (cfiCond23) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiPicker24 Using cfiCommon1
        CFI (cfiPicker24) NoFunction
        CFI (cfiPicker24) Picker
        LCALL   ?Subroutine22 & 0xFFFF
??CrossCallReturnLabel_70:
        LCALL   ?Subroutine21 & 0xFFFF
??CrossCallReturnLabel_66:
        INC     DPTR
        MOV     R0,DPL
        MOV     R1,DPH
        MOV     DPL,R2
        MOV     DPH,R3
        LCALL   ?Subroutine21 & 0xFFFF
??CrossCallReturnLabel_67:
        INC     DPTR
        INC     R0
        MOV     R1,DPH
        RET
        CFI EndBlock cfiCond22
        CFI EndBlock cfiCond23
        CFI EndBlock cfiPicker24

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine22:
        CFI Block cfiCond25 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_69
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond26 Using cfiCommon0
        CFI (cfiCond26) NoFunction
        CFI (cfiCond26) Conditional ??CrossCallReturnLabel_70, ??CrossCallReturnLabel_6
        CFI (cfiCond26) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond26) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond26) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond26) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond26) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond26) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond26) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond26) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond26) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond26) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond26) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond26) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond26) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond26) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond26) CFA_SP SP+0
        CFI (cfiCond26) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond27 Using cfiCommon0
        CFI (cfiCond27) NoFunction
        CFI (cfiCond27) Conditional ??CrossCallReturnLabel_70, ??CrossCallReturnLabel_7
        CFI (cfiCond27) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond27) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond27) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond27) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond27) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond27) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond27) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond27) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond27) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond27) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond27) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond27) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond27) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond27) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond27) CFA_SP SP+0
        CFI (cfiCond27) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiPicker28 Using cfiCommon1
        CFI (cfiPicker28) NoFunction
        CFI (cfiPicker28) Picker
        MOV     A,R7
        ADDC    A,#0x0
        MOV     R3,A
        MOV     DPL,R2
        MOV     DPH,R3
        INC     DPTR
        RET
        CFI EndBlock cfiCond25
        CFI EndBlock cfiCond26
        CFI EndBlock cfiCond27
        CFI EndBlock cfiPicker28
//  543 #endif // ZTOOL
//  544 
//  545 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  546 /*********************************************************************
//  547  * @fn      MT_ProcessDebugStr
//  548  *
//  549  * @brief
//  550  *
//  551  *   Build and send a debug string.
//  552  *
//  553  * @param   byte *dstr - pointer to the data portion of the debug message
//  554  *
//  555  * @return  void
//  556  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  557 void MT_ProcessDebugStr( mtDebugStr_t *dstr )
MT_ProcessDebugStr:
        CFI Block cfiBlock29 Using cfiCommon0
        CFI Function MT_ProcessDebugStr
//  558 {
        FUNCALL MT_ProcessDebugStr, osal_mem_alloc
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 12, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 12, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessDebugStr, MT_BuildSPIMsg
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessDebugStr, HalUARTWrite
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 12, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 12, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessDebugStr, osal_mem_free
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 12, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 12, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xc
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 12)
        ; Saved register size: 12
        ; Auto size: 0
        MOV     ?V0 + 0,R2
        MOV     ?V0 + 1,R3
//  559   byte *msg_ptr;
//  560 
//  561   // Get a message buffer to build the debug message
//  562   msg_ptr = osal_mem_alloc( (byte)(SPI_0DATA_MSG_LEN + dstr->sln) );
        ; Setup parameters for call to function osal_mem_alloc
        MOV     DPL,R2
        MOV     DPH,R3
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        ADD     A,#0x5
        LCALL   ?Subroutine15 & 0xFFFF
//  563   if ( msg_ptr )
??CrossCallReturnLabel_47:
        JNZ     ??MT_ProcessDebugStr_0
        MOV     A,R7
??MT_ProcessDebugStr_0:
        JZ      ??CrossCallReturnLabel_46
//  564   {
//  565 #ifdef SPI_MGR_DEFAULT_PORT
//  566     MT_BuildSPIMsg( SPI_RESPONSE_BIT | SPI_SYS_STRING_MSG, msg_ptr, dstr->sln, dstr->pString );
        MOV     A,?V0 + 0
        ADD     A,#0x2
        MOV     ?V0 + 2,A
        MOV     A,?V0 + 1
        ADDC    A,#0x0
        MOV     ?V0 + 3,A
        ; Setup parameters for call to function MT_BuildSPIMsg
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        INC     DPTR
        INC     DPTR
        INC     DPTR
        LCALL   ?PUSH_XSTACK8_X_TWO
        CFI CFA_XSP16 add(XSP16, 14)
        MOV     DPL,?V0 + 2
        MOV     DPH,?V0 + 3
        MOVX    A,@DPTR
        MOV     R1,A
        MOV     A,R6
        MOV     R4,A
        MOV     A,R7
        MOV     R5,A
        MOV     R2,#0x15
        MOV     R3,#0x10
        LCALL   ?Subroutine16 & 0xFFFF
??CrossCallReturnLabel_51:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 12)
//  567     HalUARTWrite ( SPI_MGR_DEFAULT_PORT, msg_ptr, SPI_0DATA_MSG_LEN + dstr->sln );
        ; Setup parameters for call to function HalUARTWrite
        MOV     DPL,?V0 + 2
        MOV     DPH,?V0 + 3
        MOVX    A,@DPTR
        MOV     R0,A
        MOV     A,#0x5
        ADD     A,R0
        MOV     R4,A
        CLR     A
        ADDC    A,#0x0
        MOV     R5,A
        LCALL   ??Subroutine13_0 & 0xFFFF
        CFI EndBlock cfiBlock29
//  568 #endif
//  569     osal_mem_free( msg_ptr );
//  570   }
//  571 }
??CrossCallReturnLabel_46:
        REQUIRE ?Subroutine29
        ; // Fall through to label ?Subroutine29

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine29:
        CFI Block cfiBlock30 Using cfiCommon0
        CFI NoFunction
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 12)
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        MOV     R7,#0x4
        LJMP    ?BANKED_LEAVE_XDATA
        CFI EndBlock cfiBlock30

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine16:
        CFI Block cfiCond31 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_49
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 18)
        CFI Block cfiCond32 Using cfiCommon0
        CFI (cfiCond32) NoFunction
        CFI (cfiCond32) Conditional ??CrossCallReturnLabel_50
        CFI (cfiCond32) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond32) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond32) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond32) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond32) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond32) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond32) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond32) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond32) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond32) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond32) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond32) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond32) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond32) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond32) CFA_SP SP+0
        CFI (cfiCond32) CFA_XSP16 add(XSP16, 27)
        CFI Block cfiCond33 Using cfiCommon0
        CFI (cfiCond33) NoFunction
        CFI (cfiCond33) Conditional ??CrossCallReturnLabel_51
        CFI (cfiCond33) R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond33) VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond33) V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond33) V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond33) V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond33) V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond33) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond33) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond33) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond33) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond33) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond33) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond33) CFA_SP SP+0
        CFI (cfiCond33) CFA_XSP16 add(XSP16, 14)
        CFI Block cfiCond34 Using cfiCommon0
        CFI (cfiCond34) NoFunction
        CFI (cfiCond34) Conditional ??CrossCallReturnLabel_52
        CFI (cfiCond34) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond34) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond34) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond34) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond34) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond34) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond34) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond34) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond34) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond34) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond34) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond34) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond34) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond34) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond34) CFA_SP SP+0
        CFI (cfiCond34) CFA_XSP16 add(XSP16, 17)
        CFI Block cfiPicker35 Using cfiCommon1
        CFI (cfiPicker35) NoFunction
        CFI (cfiPicker35) Picker
        LCALL   ??MT_BuildSPIMsg?relay
        MOV     A,#0x2
        RET
        CFI EndBlock cfiCond31
        CFI EndBlock cfiCond32
        CFI EndBlock cfiCond33
        CFI EndBlock cfiCond34
        CFI EndBlock cfiPicker35
//  572 #endif // ZTOOL
//  573 
//  574 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  575 /*********************************************************************
//  576  * @fn      MT_ProcessSetNV
//  577  *
//  578  * @brief
//  579  *
//  580  *   The Set NV serial message.
//  581  *
//  582  * @param   byte *msg - pointer to the data
//  583  *
//  584  * @return  ZSuccess if successful
//  585  *
//  586  * @MT SPI_CMD_SYS_SET_NV
//  587  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  588 byte MT_ProcessSetNV( byte *pData )
MT_ProcessSetNV:
        CFI Block cfiBlock36 Using cfiCommon0
        CFI Function MT_ProcessSetNV
//  589 {
        FUNCALL MT_ProcessSetNV, osal_nv_item_len
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 12, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 12, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSetNV, osal_nv_write
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 14, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 14, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xa
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 10)
        ; Saved register size: 10
        ; Auto size: 0
//  590   uint16  attrib;
//  591   uint16  attlen;
//  592 
//  593   attrib = (uint16) *pData;
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        MOV     R6,A
//  594   pData += 2;   // skip additional byte containing len field
//  595   attlen = osal_nv_item_len( attrib );
//  596 
//  597   return osal_nv_write( attrib, 0, attlen, pData );
        ; Setup parameters for call to function osal_nv_write
        MOV     A,R2
        ADD     A,#0x2
        MOV     ?V0 + 0,A
        MOV     A,R3
        ADDC    A,#0x0
        MOV     ?V0 + 1,A
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 12)
        ; Setup parameters for call to function osal_nv_item_len
        MOV     A,R6
        MOV     R2,A
        LCALL   ?Subroutine12 & 0xFFFF
??CrossCallReturnLabel_39:
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 14)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     A,R6
        MOV     R2,A
        MOV     R3,#0x0
        LCALL   ??osal_nv_write?relay
        MOV     A,#0x4
        SJMP    ??Subroutine24_0
        CFI EndBlock cfiBlock36
//  598 }

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine24:
        CFI Block cfiBlock37 Using cfiCommon0
        CFI NoFunction
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 13)
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        LCALL   ?Subroutine2 & 0xFFFF
??CrossCallReturnLabel_71:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 11)
        MOV     A,#0x1
??Subroutine24_0:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 10)
??Subroutine24_1:
        MOV     R7,#0x2
        LJMP    ?BANKED_LEAVE_XDATA
        CFI EndBlock cfiBlock37
//  599 #endif
//  600 
//  601 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  602 /*********************************************************************
//  603  * @fn      MT_ProcessGetNV
//  604  *
//  605  * @brief
//  606  *
//  607  *   The Get NV serial message.
//  608  *
//  609  * @param   byte *msg - pointer to the data
//  610  *
//  611  * @return  void
//  612  *
//  613  * @MT SPI_CMD_SYS_GET_NV
//  614  *
//  615  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  616 void MT_ProcessGetNV( byte *pData )
MT_ProcessGetNV:
        CFI Block cfiBlock38 Using cfiCommon0
        CFI Function MT_ProcessGetNV
//  617 {
        FUNCALL MT_ProcessGetNV, osal_nv_item_len
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNV, osal_mem_alloc
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNV, osal_memset
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNV, osal_nv_read
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 20, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 20, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNV, MT_BuildAndSendZToolResponse
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 18, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 18, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNV, osal_mem_free
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 16, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 16, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0x10
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        ; Saved register size: 16
        ; Auto size: 0
//  618   uint16  attrib;
//  619   uint16 attlen;
//  620   uint16 buflen;
//  621   uint8 *buf;
//  622 
//  623   attrib = (uint16)*pData;
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        MOV     ?V0 + 0,A
//  624   attlen = osal_nv_item_len( attrib );
        ; Setup parameters for call to function osal_nv_item_len
        MOV     R2,A
        MOV     R3,#0x0
        LCALL   ??osal_nv_item_len?relay
        MOV     ?V0 + 2,R2
        MOV     ?V0 + 3,R3
//  625 
//  626   buflen = attlen + 3;
        MOV     A,#0x3
        ADD     A,?V0 + 2
        MOV     R6,A
        CLR     A
        ADDC    A,?V0 + 3
        MOV     R7,A
//  627   buf = osal_mem_alloc( buflen );
        ; Setup parameters for call to function osal_mem_alloc
        INC     R2
        INC     R2
        INC     R2
        MOV     R3,A
        LCALL   ??osal_mem_alloc?relay
        MOV     ?V0 + 6,R2
        MOV     ?V0 + 7,R3
//  628   if ( buf != NULL )
        MOV     A,R2
        JNZ     ??MT_ProcessGetNV_0
        MOV     A,R3
??MT_ProcessGetNV_0:
        JZ      ??MT_ProcessGetNV_1
//  629   {
//  630     osal_memset( buf, 0, buflen );
        ; Setup parameters for call to function osal_memset
        MOV     A,R6
        MOV     R4,A
        MOV     A,R7
        MOV     R5,A
        MOV     R1,#0x0
        LCALL   ??osal_memset?relay
//  631 
//  632     buf[0] = osal_nv_read( attrib, 0, attlen, &buf[3] );
        ; Setup parameters for call to function osal_nv_read
        MOV     A,?V0 + 6
        ADD     A,#0x3
        MOV     ?V0 + 4,A
        MOV     A,?V0 + 7
        ADDC    A,#0x0
        MOV     ?V0 + 5,A
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 18)
        MOV     R0,#?V0 + 2
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 20)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,?V0 + 0
        LCALL   ??Subroutine18_0 & 0xFFFF
??CrossCallReturnLabel_55:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 16)
        MOV     A,R1
        MOV     DPL,?V0 + 6
        MOV     DPH,?V0 + 7
        MOVX    @DPTR,A
//  633     buf[1] = (uint8)attrib;
        INC     DPTR
        MOV     A,?V0 + 0
        MOVX    @DPTR,A
//  634     buf[2] = attlen;
        MOV     DPL,?V0 + 6
        MOV     DPH,?V0 + 7
        INC     DPTR
        INC     DPTR
        MOV     A,?V0 + 2
        MOVX    @DPTR,A
//  635 
//  636     MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + buflen),
//  637                                   (SPI_RESPONSE_BIT | SPI_CMD_SYS_GET_NV),
//  638                                   buflen, buf );
        ; Setup parameters for call to function MT_BuildAndSendZToolResponse
        MOV     R0,#?V0 + 6
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 18)
        MOV     A,R6
        MOV     R4,A
        MOV     R2,#0x13
        MOV     R3,#0x10
        ADD     A,#0x5
        MOV     R1,A
        LCALL   ??Subroutine2_0 & 0xFFFF
??CrossCallReturnLabel_72:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 16)
//  639     osal_mem_free( buf );
        ; Setup parameters for call to function osal_mem_free
        MOV     R2,?V0 + 6
        MOV     R3,?V0 + 7
        LCALL   ??osal_mem_free?relay
//  640   }
//  641 }
??MT_ProcessGetNV_1:
        LJMP    ??Subroutine26_0 & 0xFFFF
        CFI EndBlock cfiBlock38
//  642 #endif
//  643 
//  644 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  645 #if !defined ( NONWK )
//  646 /***************************************************************************************************
//  647  * @fn      MT_ProcessGetNvInfo
//  648  *
//  649  * @brief
//  650  *
//  651  *   The Get NV Info serial message.
//  652  *
//  653  * @param   byte *msg - pointer to the data
//  654  *
//  655  * @return  void
//  656  *
//  657  * @MT SPI_CMD_SYS_GET_NV_INFO
//  658  *
//  659  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  660 void MT_ProcessGetNvInfo( void )
MT_ProcessGetNvInfo:
        CFI Block cfiBlock39 Using cfiCommon0
        CFI Function MT_ProcessGetNvInfo
//  661 {
        FUNCALL MT_ProcessGetNvInfo, osal_mem_alloc
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 22, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 22, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, osal_memset
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 22, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 22, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, osal_nv_read
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 26, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 26, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, MT_ReverseBytes
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 22, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 22, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, osal_nv_read
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 26, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 26, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, osal_nv_read
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 26, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 26, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, osal_nv_read
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 26, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 26, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, osal_nv_read
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 26, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 26, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, MT_BuildAndSendZToolResponse
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 24, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 24, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetNvInfo, osal_mem_free
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 22, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 22, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0x10
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        ; Saved register size: 16
        ; Auto size: 6
        MOV     A,#-0x6
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 22)
//  662   uint8 len;
//  663   uint8 stat;
//  664   uint8 *buf;
//  665   uint8 *pBuf;
//  666   uint16 tmp16;
//  667   uint32 tmp32;
//  668 
//  669   // Get required length of buffer
//  670   // Status + ExtAddr + ChanList + PanID  + SecLevel + PreCfgKey
//  671   len = 1 + Z_EXTADDR_LEN + 4 + 2 + 1 + SEC_KEY_LEN;
//  672 
//  673   buf = osal_mem_alloc( len );
        ; Setup parameters for call to function osal_mem_alloc
        MOV     R2,#0x20
        LCALL   ?Subroutine17 & 0xFFFF
//  674   if ( buf )
??CrossCallReturnLabel_85:
        JNZ     ??MT_ProcessGetNvInfo_0
        MOV     A,R3
??MT_ProcessGetNvInfo_0:
        JNZ     $+5
        LJMP    ??MT_ProcessGetNvInfo_1 & 0xFFFF
//  675   {
//  676     // Assume NV not available
//  677     osal_memset( buf, 0xFF, len );
        ; Setup parameters for call to function osal_memset
        MOV     R4,#0x20
        MOV     R5,#0x0
        MOV     R1,#-0x1
        LCALL   ??osal_memset?relay
//  678 
//  679     // Skip over status
//  680     pBuf = buf + 1;
        MOV     DPL,?V0 + 2
        MOV     DPH,?V0 + 3
        INC     DPTR
        MOV     ?V0 + 0,DPL
        MOV     ?V0 + 1,DPH
//  681 
//  682     // Start with 64-bit extended address
//  683     stat = osal_nv_read( ZCD_NV_EXTADDR, 0, Z_EXTADDR_LEN, pBuf );
        ; Setup parameters for call to function osal_nv_read
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 24)
        MOV     ?V0 + 4,#0x8
        MOV     ?V0 + 5,#0x0
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 26)
        LCALL   ?Subroutine18 & 0xFFFF
??CrossCallReturnLabel_53:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 22)
        MOV     A,R1
        MOV     R6,A
//  684     if ( stat ) stat = 0x01;
        JZ      ??MT_ProcessGetNvInfo_2
        MOV     R6,#0x1
//  685     MT_ReverseBytes( pBuf, Z_EXTADDR_LEN );
??MT_ProcessGetNvInfo_2:
        ; Setup parameters for call to function MT_ReverseBytes
        LCALL   ?Subroutine19 & 0xFFFF
//  686     pBuf += Z_EXTADDR_LEN;
//  687 
//  688     // Scan channel list (bit mask)
//  689     if (  osal_nv_read( ZCD_NV_CHANLIST, 0, sizeof( tmp32 ), &tmp32 ) )
??CrossCallReturnLabel_60:
        ; Setup parameters for call to function osal_nv_read
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     ?V0 + 4,DPL
        MOV     ?V0 + 5,DPH
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 24)
        MOV     ?V0 + 4,#0x4
        MOV     ?V0 + 5,#0x0
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 26)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#-0x7c
        LCALL   ??Subroutine18_0 & 0xFFFF
??CrossCallReturnLabel_56:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 22)
        MOV     A,R1
        JZ      ??MT_ProcessGetNvInfo_3
//  690       stat |= 0x02;
        MOV     A,R6
        SETB    0xE0 /* A   */.1
        MOV     R6,A
        SJMP    ??MT_ProcessGetNvInfo_4
//  691     else
//  692     {
//  693       pBuf[0] = BREAK_UINT32( tmp32, 3 );
??MT_ProcessGetNvInfo_3:
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 4
        LCALL   ?L_MOV_X
        MOV     A,#0x18
        MOV     R0,#?V0 + 4
        LCALL   ?UL_SHR
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        MOV     A,?V0 + 4
        MOVX    @DPTR,A
//  694       pBuf[1] = BREAK_UINT32( tmp32, 2 );
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 4
        LCALL   ?L_MOV_X
        MOV     A,#0x10
        MOV     R0,#?V0 + 4
        LCALL   ?UL_SHR
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        INC     DPTR
        MOV     A,?V0 + 4
        MOVX    @DPTR,A
//  695       pBuf[2] = BREAK_UINT32( tmp32, 1 );
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 4
        LCALL   ?L_MOV_X
        MOV     A,?V0 + 5
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        INC     DPTR
        INC     DPTR
        MOVX    @DPTR,A
//  696       pBuf[3] = BREAK_UINT32( tmp32, 0 );
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 4
        LCALL   ?L_MOV_X
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        INC     DPTR
        INC     DPTR
        INC     DPTR
        MOV     A,?V0 + 4
        MOVX    @DPTR,A
//  697     }
//  698     pBuf += sizeof( tmp32 );
??MT_ProcessGetNvInfo_4:
        MOV     A,?V0 + 0
        ADD     A,#0x4
        MOV     ?V0 + 0,A
        MOV     A,?V0 + 1
        ADDC    A,#0x0
        MOV     ?V0 + 1,A
//  699 
//  700     // ZigBee PanID
//  701     if ( osal_nv_read( ZCD_NV_PANID, 0, sizeof( tmp16 ), &tmp16 ) )
        ; Setup parameters for call to function osal_nv_read
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOV     ?V0 + 4,DPL
        MOV     ?V0 + 5,DPH
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 24)
        MOV     ?V0 + 4,#0x2
        MOV     ?V0 + 5,#0x0
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 26)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#-0x7d
        LCALL   ??Subroutine18_0 & 0xFFFF
??CrossCallReturnLabel_57:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 22)
        MOV     A,R1
        JZ      ??MT_ProcessGetNvInfo_5
//  702       stat |= 0x04;
        MOV     A,R6
        SETB    0xE0 /* A   */.2
        MOV     R6,A
        SJMP    ??MT_ProcessGetNvInfo_6
//  703     else
//  704     {
//  705       pBuf[0] = HI_UINT16( tmp16 );
??MT_ProcessGetNvInfo_5:
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        INC     DPTR
        MOVX    A,@DPTR
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        LCALL   ?Subroutine5 & 0xFFFF
//  706       pBuf[1] = LO_UINT16( tmp16 );
??CrossCallReturnLabel_12:
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        INC     DPTR
        MOVX    @DPTR,A
//  707     }
//  708     pBuf += sizeof( tmp16 );
//  709 
//  710     // Security level
//  711     if ( osal_nv_read( ZCD_NV_SECURITY_LEVEL, 0, sizeof( uint8 ), pBuf++ ) )
??MT_ProcessGetNvInfo_6:
        MOV     A,?V0 + 0
        ADD     A,#0x2
        MOV     ?V0 + 4,A
        MOV     A,?V0 + 1
        ADDC    A,#0x0
        MOV     ?V0 + 5,A
        MOV     DPL,?V0 + 4
        MOV     DPH,A
        INC     DPTR
        MOV     ?V0 + 0,DPL
        MOV     ?V0 + 1,DPH
        ; Setup parameters for call to function osal_nv_read
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 24)
        MOV     ?V0 + 4,#0x1
        MOV     ?V0 + 5,#0x0
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 26)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#0x61
        LCALL   ??Subroutine18_0 & 0xFFFF
??CrossCallReturnLabel_58:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 22)
        MOV     A,R1
        JZ      ??MT_ProcessGetNvInfo_7
//  712       stat |= 0x08;
        MOV     A,R6
        SETB    0xE0 /* A   */.3
        MOV     R6,A
//  713 
//  714     // Pre-configured security key
//  715     if ( osal_nv_read( ZCD_NV_PRECFGKEY, 0, SEC_KEY_LEN, pBuf ) )
??MT_ProcessGetNvInfo_7:
        ; Setup parameters for call to function osal_nv_read
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 24)
        MOV     ?V0 + 0,#0x10
        MOV     ?V0 + 1,#0x0
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 26)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#0x62
        LCALL   ??Subroutine18_0 & 0xFFFF
??CrossCallReturnLabel_59:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 22)
        MOV     A,R1
        JZ      ??MT_ProcessGetNvInfo_8
//  716       stat |= 0x10;
        MOV     A,R6
        SETB    0xE0 /* A   */.4
        MOV     R6,A
//  717 
//  718     // Status bit mask - bit=1 indicates failure
//  719     *buf = stat;
??MT_ProcessGetNvInfo_8:
        MOV     A,R6
        MOV     DPL,?V0 + 2
        MOV     DPH,?V0 + 3
        MOVX    @DPTR,A
//  720 
//  721     MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + len),
//  722                                   (SPI_RESPONSE_BIT | SPI_CMD_SYS_GET_NV_INFO),
//  723                                   len, buf );
        ; Setup parameters for call to function MT_BuildAndSendZToolResponse
        MOV     R0,#?V0 + 2
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 24)
        MOV     R4,#0x20
        MOV     R2,#0x1f
        MOV     R3,#0x10
        MOV     R1,#0x25
        LCALL   ??Subroutine2_0 & 0xFFFF
??CrossCallReturnLabel_73:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 22)
//  724 
//  725     osal_mem_free( buf );
        ; Setup parameters for call to function osal_mem_free
        MOV     R2,?V0 + 2
        MOV     R3,?V0 + 3
        LCALL   ??osal_mem_free?relay
//  726   }
//  727 }
??MT_ProcessGetNvInfo_1:
        MOV     A,#0x6
        LJMP    ?Subroutine26 & 0xFFFF
        CFI EndBlock cfiBlock39

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine18:
        CFI Block cfiCond40 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_53
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 26)
        CFI Block cfiCond41 Using cfiCommon0
        CFI (cfiCond41) NoFunction
        CFI (cfiCond41) Conditional ??CrossCallReturnLabel_54
        CFI (cfiCond41) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond41) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond41) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond41) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond41) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond41) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond41) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond41) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond41) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond41) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond41) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond41) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond41) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond41) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond41) CFA_SP SP+0
        CFI (cfiCond41) CFA_XSP16 add(XSP16, 19)
        CFI Block cfiPicker42 Using cfiCommon1
        CFI (cfiPicker42) NoFunction
        CFI (cfiPicker42) Picker
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#0x1
        CFI Block cfiCond43 Using cfiCommon0
        CFI (cfiCond43) NoFunction
        CFI (cfiCond43) Conditional ??CrossCallReturnLabel_55
        CFI (cfiCond43) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond43) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond43) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond43) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond43) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond43) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond43) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond43) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond43) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond43) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond43) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond43) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond43) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond43) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond43) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond43) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond43) CFA_SP SP+0
        CFI (cfiCond43) CFA_XSP16 add(XSP16, 20)
        CFI Block cfiCond44 Using cfiCommon0
        CFI (cfiCond44) NoFunction
        CFI (cfiCond44) Conditional ??CrossCallReturnLabel_56
        CFI (cfiCond44) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond44) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond44) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond44) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond44) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond44) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond44) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond44) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond44) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond44) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond44) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond44) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond44) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond44) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond44) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond44) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond44) CFA_SP SP+0
        CFI (cfiCond44) CFA_XSP16 add(XSP16, 26)
        CFI Block cfiCond45 Using cfiCommon0
        CFI (cfiCond45) NoFunction
        CFI (cfiCond45) Conditional ??CrossCallReturnLabel_57
        CFI (cfiCond45) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond45) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond45) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond45) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond45) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond45) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond45) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond45) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond45) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond45) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond45) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond45) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond45) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond45) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond45) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond45) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond45) CFA_SP SP+0
        CFI (cfiCond45) CFA_XSP16 add(XSP16, 26)
        CFI Block cfiCond46 Using cfiCommon0
        CFI (cfiCond46) NoFunction
        CFI (cfiCond46) Conditional ??CrossCallReturnLabel_58
        CFI (cfiCond46) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond46) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond46) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond46) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond46) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond46) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond46) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond46) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond46) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond46) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond46) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond46) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond46) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond46) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond46) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond46) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond46) CFA_SP SP+0
        CFI (cfiCond46) CFA_XSP16 add(XSP16, 26)
        CFI Block cfiCond47 Using cfiCommon0
        CFI (cfiCond47) NoFunction
        CFI (cfiCond47) Conditional ??CrossCallReturnLabel_59
        CFI (cfiCond47) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond47) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond47) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond47) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond47) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond47) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond47) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond47) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond47) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond47) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond47) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond47) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond47) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond47) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond47) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond47) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond47) CFA_SP SP+0
        CFI (cfiCond47) CFA_XSP16 add(XSP16, 26)
??Subroutine18_0:
        MOV     R3,#0x0
        LCALL   ??osal_nv_read?relay
        MOV     A,#0x4
        RET
        CFI EndBlock cfiCond40
        CFI EndBlock cfiCond41
        CFI EndBlock cfiPicker42
        CFI EndBlock cfiCond43
        CFI EndBlock cfiCond44
        CFI EndBlock cfiCond45
        CFI EndBlock cfiCond46
        CFI EndBlock cfiCond47
//  728 #endif  // NONWK
//  729 #endif  // ZTOOL
//  730 
//  731 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  732 #define DEVICE_INFO_RESPONSE_LEN 46
//  733 #define TYPE_COORDINATOR         1
//  734 #define TYPE_ROUTER              2
//  735 #define TYPE_ENDDEVICE           4
//  736 /***************************************************************************************************
//  737  * @fn      MT_ProcessGetDeviceInfo
//  738  *
//  739  * @brief
//  740  *
//  741  *   The Get Device Info serial message.
//  742  *
//  743  * @param   byte *msg - pointer to the data
//  744  *
//  745  * @return  void
//  746  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  747 void MT_ProcessGetDeviceInfo( void )
MT_ProcessGetDeviceInfo:
        CFI Block cfiBlock48 Using cfiCommon0
        CFI Function MT_ProcessGetDeviceInfo
//  748 {
        FUNCALL MT_ProcessGetDeviceInfo, osal_mem_alloc
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, osal_nv_read
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 19, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 19, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, MT_ReverseBytes
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, NLME_GetShortAddr
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, AssocMakeList
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, osal_memset
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, osal_mem_free
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, MT_BuildAndSendZToolResponse
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 17, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 17, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessGetDeviceInfo, osal_mem_free
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xe
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 14)
        ; Saved register size: 14
        ; Auto size: 1
        MOV     A,#-0x1
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 15)
//  749   byte *buf;
//  750   byte *pBuf;
//  751   uint8 deviceType = 0;
//  752   uint16 shortAddr;
//  753   uint16 *assocList;
//  754   byte assocCnt;
//  755   uint16 *puint16;
//  756   byte x;
//  757 
//  758   buf = osal_mem_alloc( DEVICE_INFO_RESPONSE_LEN );
        ; Setup parameters for call to function osal_mem_alloc
        MOV     R2,#0x2e
        LCALL   ?Subroutine17 & 0xFFFF
//  759   if ( buf )
??CrossCallReturnLabel_86:
        JNZ     ??MT_ProcessGetDeviceInfo_0
        MOV     A,R3
??MT_ProcessGetDeviceInfo_0:
        JNZ     $+5
        LJMP    ??MT_ProcessGetDeviceInfo_1 & 0xFFFF
//  760   {
//  761     pBuf = buf;
//  762 
//  763     *pBuf++ = ZSUCCESS;
        CLR     A
        MOV     DPL,R2
        MOV     DPH,R3
        LCALL   ??Subroutine0_0 & 0xFFFF
//  764 
//  765     osal_nv_read( ZCD_NV_EXTADDR, 0, Z_EXTADDR_LEN, pBuf );
??CrossCallReturnLabel_0:
        ; Setup parameters for call to function osal_nv_read
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 17)
        MOV     ?V0 + 4,#0x8
        MOV     ?V0 + 5,#0x0
        MOV     R0,#?V0 + 4
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 19)
        LCALL   ?Subroutine18 & 0xFFFF
??CrossCallReturnLabel_54:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 15)
//  766     // Outgoing extended address needs to be reversed
//  767     MT_ReverseBytes( pBuf, Z_EXTADDR_LEN );
        ; Setup parameters for call to function MT_ReverseBytes
        LCALL   ?Subroutine19 & 0xFFFF
//  768     pBuf += Z_EXTADDR_LEN;
//  769 
//  770 #if !defined( NONWK )
//  771     shortAddr = NLME_GetShortAddr();
??CrossCallReturnLabel_61:
        ; Setup parameters for call to function NLME_GetShortAddr
        LCALL   ??NLME_GetShortAddr?relay
//  772 #else
//  773     shortAddr = 0;
//  774 #endif
//  775 
//  776     *pBuf++ = HI_UINT16( shortAddr );
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        MOV     A,R3
        MOVX    @DPTR,A
        INC     DPTR
//  777     *pBuf++ = LO_UINT16( shortAddr );
        MOV     A,R2
        MOVX    @DPTR,A
        INC     DPTR
//  778 
//  779     // Return device type
//  780 #if !defined( NONWK )
//  781 #if defined (ZDO_COORDINATOR)
//  782     deviceType |= (uint8) TYPE_COORDINATOR;
//  783   #if defined (SOFT_START)
//  784     deviceType |= (uint8) TYPE_ROUTER;
//  785   #endif
//  786 #endif
//  787 #if defined (RTR_NWK) && !defined (ZDO_COORDINATOR)
//  788     deviceType |= (uint8) TYPE_ROUTER;
//  789 #elif !defined (RTR_NWK)
//  790     deviceType |= (uint8) TYPE_ENDDEVICE;
//  791 #endif
//  792 #endif
//  793     *pBuf++ = (byte) deviceType;
        MOV     A,#0x1
        LCALL   ??Subroutine0_0 & 0xFFFF
//  794 
//  795     //Return device state
//  796 #if !defined( NONWK )
//  797     *pBuf++ = (byte)devState;
??CrossCallReturnLabel_1:
        MOV     DPTR,#devState
        LCALL   ?Subroutine0 & 0xFFFF
//  798 #else
//  799     *pBuf++ = (byte)0;
//  800 #endif
//  801 
//  802 #if defined(RTR_NWK) && !defined( NONWK )
//  803     assocList = AssocMakeList( &assocCnt );
??CrossCallReturnLabel_2:
        ; Setup parameters for call to function AssocMakeList
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOV     R2,DPL
        MOV     R3,DPH
        LCALL   ??AssocMakeList?relay
        MOV     ?V0 + 4,R2
        MOV     ?V0 + 5,R3
        MOV     R6,?V0 + 4
        MOV     R7,?V0 + 5
//  804 #else
//  805     assocCnt = 0;
//  806     assocList = NULL;
//  807 #endif
//  808 
//  809     *pBuf++ = assocCnt;
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ?Subroutine0 & 0xFFFF
//  810 
//  811     // upto 16 devices
//  812     osal_memset( pBuf, 0, (16 * sizeof(uint16)) );
??CrossCallReturnLabel_3:
        ; Setup parameters for call to function osal_memset
        MOV     R4,#0x20
        MOV     R5,#0x0
        MOV     R1,#0x0
        MOV     R2,?V0 + 0
        MOV     R3,?V0 + 1
        LCALL   ??osal_memset?relay
//  813     puint16 = assocList;
        MOV     A,R6
        MOV     R0,A
        MOV     A,R7
        MOV     R1,A
//  814     for ( x = 0; x < assocCnt; x++ )
        MOV     R4,#0x0
        SJMP    ??MT_ProcessGetDeviceInfo_2
//  815     {
//  816       *pBuf++ = HI_UINT16( *puint16 );
??MT_ProcessGetDeviceInfo_3:
        MOV     DPL,R0
        MOV     DPH,R1
        INC     DPTR
        LCALL   ?Subroutine0 & 0xFFFF
//  817       *pBuf++ = LO_UINT16( *puint16 );
??CrossCallReturnLabel_4:
        MOV     DPL,R0
        MOV     DPH,R1
        LCALL   ?Subroutine0 & 0xFFFF
//  818       puint16++;
??CrossCallReturnLabel_5:
        MOV     A,R0
        ADD     A,#0x2
        INC     R0
        INC     R0
        MOV     A,R1
        ADDC    A,#0x0
        MOV     R1,A
//  819     }
        INC     R4
??MT_ProcessGetDeviceInfo_2:
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    A,@DPTR
        MOV     R2,A
        MOV     A,R4
        CLR     C
        SUBB    A,R2
        JC      ??MT_ProcessGetDeviceInfo_3
//  820 
//  821     if ( assocList )
        MOV     A,R6
        JNZ     ??MT_ProcessGetDeviceInfo_4
        MOV     A,R7
??MT_ProcessGetDeviceInfo_4:
        JZ      ??MT_ProcessGetDeviceInfo_5
//  822       osal_mem_free( assocList );
        ; Setup parameters for call to function osal_mem_free
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        LCALL   ??osal_mem_free?relay
//  823 
//  824     MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + DEVICE_INFO_RESPONSE_LEN),
//  825                                   (SPI_RESPONSE_BIT | SPI_CMD_SYS_GET_DEVICE_INFO),
//  826                                   DEVICE_INFO_RESPONSE_LEN, buf );
??MT_ProcessGetDeviceInfo_5:
        ; Setup parameters for call to function MT_BuildAndSendZToolResponse
        MOV     R0,#?V0 + 2
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 17)
        MOV     R4,#0x2e
        MOV     R2,#0x14
        MOV     R3,#0x10
        MOV     R1,#0x33
        LCALL   ??Subroutine2_0 & 0xFFFF
??CrossCallReturnLabel_74:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 15)
//  827 
//  828     osal_mem_free( buf );
        ; Setup parameters for call to function osal_mem_free
        MOV     R2,?V0 + 2
        MOV     R3,?V0 + 3
        LCALL   ??osal_mem_free?relay
//  829   }
//  830 }
??MT_ProcessGetDeviceInfo_1:
        LJMP    ?Subroutine25 & 0xFFFF
        CFI EndBlock cfiBlock48

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine19:
        CFI Block cfiCond49 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_60
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 22)
        CFI Block cfiCond50 Using cfiCommon0
        CFI (cfiCond50) NoFunction
        CFI (cfiCond50) Conditional ??CrossCallReturnLabel_61
        CFI (cfiCond50) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond50) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond50) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond50) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond50) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond50) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond50) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond50) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond50) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond50) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond50) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond50) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond50) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond50) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond50) CFA_SP SP+0
        CFI (cfiCond50) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiPicker51 Using cfiCommon1
        CFI (cfiPicker51) NoFunction
        CFI (cfiPicker51) Picker
        MOV     R1,#0x8
        MOV     R2,?V0 + 0
        MOV     R3,?V0 + 1
        LCALL   ??MT_ReverseBytes?relay
        MOV     A,?V0 + 0
        ADD     A,#0x8
        MOV     ?V0 + 0,A
        MOV     A,?V0 + 1
        ADDC    A,#0x0
        MOV     ?V0 + 1,A
        RET
        CFI EndBlock cfiCond49
        CFI EndBlock cfiCond50
        CFI EndBlock cfiPicker51

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine17:
        CFI Block cfiCond52 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_85
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 22)
        CFI Block cfiCond53 Using cfiCommon0
        CFI (cfiCond53) NoFunction
        CFI (cfiCond53) Conditional ??CrossCallReturnLabel_86
        CFI (cfiCond53) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond53) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond53) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond53) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond53) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond53) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond53) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond53) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond53) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond53) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond53) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond53) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond53) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond53) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond53) CFA_SP SP+0
        CFI (cfiCond53) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiPicker54 Using cfiCommon1
        CFI (cfiPicker54) NoFunction
        CFI (cfiPicker54) Picker
        MOV     R3,#0x0
        LCALL   ??osal_mem_alloc?relay
        LJMP    ?Subroutine28 & 0xFFFF
        CFI EndBlock cfiCond52
        CFI EndBlock cfiCond53
        CFI EndBlock cfiPicker54

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine0:
        CFI Block cfiCond55 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_2
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 15)
        CFI Block cfiCond56 Using cfiCommon0
        CFI (cfiCond56) NoFunction
        CFI (cfiCond56) Conditional ??CrossCallReturnLabel_3
        CFI (cfiCond56) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond56) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond56) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond56) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond56) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond56) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond56) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond56) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond56) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond56) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond56) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond56) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond56) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond56) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond56) CFA_SP SP+0
        CFI (cfiCond56) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiCond57 Using cfiCommon0
        CFI (cfiCond57) NoFunction
        CFI (cfiCond57) Conditional ??CrossCallReturnLabel_4
        CFI (cfiCond57) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond57) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond57) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond57) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond57) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond57) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond57) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond57) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond57) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond57) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond57) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond57) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond57) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond57) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond57) CFA_SP SP+0
        CFI (cfiCond57) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiCond58 Using cfiCommon0
        CFI (cfiCond58) NoFunction
        CFI (cfiCond58) Conditional ??CrossCallReturnLabel_5
        CFI (cfiCond58) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond58) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond58) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond58) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond58) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond58) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond58) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond58) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond58) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond58) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond58) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond58) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond58) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond58) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond58) CFA_SP SP+0
        CFI (cfiCond58) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiPicker59 Using cfiCommon1
        CFI (cfiPicker59) NoFunction
        CFI (cfiPicker59) Picker
        MOVX    A,@DPTR
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        CFI Block cfiCond60 Using cfiCommon0
        CFI (cfiCond60) NoFunction
        CFI (cfiCond60) Conditional ??CrossCallReturnLabel_0
        CFI (cfiCond60) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond60) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond60) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond60) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond60) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond60) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond60) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond60) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond60) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond60) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond60) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond60) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond60) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond60) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond60) CFA_SP SP+0
        CFI (cfiCond60) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiCond61 Using cfiCommon0
        CFI (cfiCond61) NoFunction
        CFI (cfiCond61) Conditional ??CrossCallReturnLabel_1
        CFI (cfiCond61) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond61) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond61) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond61) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond61) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond61) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond61) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond61) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond61) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond61) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond61) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond61) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond61) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond61) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond61) CFA_SP SP+0
        CFI (cfiCond61) CFA_XSP16 add(XSP16, 15)
??Subroutine0_0:
        MOVX    @DPTR,A
        INC     DPTR
        MOV     ?V0 + 0,DPL
        MOV     ?V0 + 1,DPH
        RET
        CFI EndBlock cfiCond55
        CFI EndBlock cfiCond56
        CFI EndBlock cfiCond57
        CFI EndBlock cfiCond58
        CFI EndBlock cfiPicker59
        CFI EndBlock cfiCond60
        CFI EndBlock cfiCond61
//  831 #endif
//  832 
//  833 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
//  834 /***************************************************************************************************
//  835  * @fn      MT_ProcessSerialCommand
//  836  *
//  837  * @brief
//  838  *
//  839  *   Process Serial Message.
//  840  *
//  841  * @param   byte *msg - pointer to event message
//  842  *
//  843  * @return  void
//  844  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
//  845 void MT_ProcessSerialCommand( byte *msg )
MT_ProcessSerialCommand:
        CFI Block cfiBlock62 Using cfiCommon0
        CFI Function MT_ProcessSerialCommand
//  846 {
        FUNCALL MT_ProcessSerialCommand, MT_RAMRead
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_RAMWrite
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_Reset
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, NLME_GetProtocolVersion
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_strlen
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_BuildAndSendZToolResponse
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 37, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 37, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_ReverseBytes
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, ZMacSetReq
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_write
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 39, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 39, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, ZMacGetReq
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_ReverseBytes
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_item_len
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 37, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 37, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_write
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 39, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 39, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_item_len
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 37, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 37, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_write
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 39, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 39, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_item_len
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 37, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 37, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_write
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 39, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 39, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_item_len
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 37, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 37, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_nv_write
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 39, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 39, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_ProcessGetNvInfo
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_ProcessGetDeviceInfo
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_ProcessSetNV
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MT_ProcessGetNV
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, osal_GetSystemClock
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, OnBoard_SendKeys
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MTProcessAppMsg
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_ProcessSerialCommand, MTProcessLedControl
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 35, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 35, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0x10
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        ; Saved register size: 16
        ; Auto size: 19
        MOV     A,#-0x13
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 35)
//  847   UINT16 cmd;
//  848   UINT16 callbackID;
//  849   byte len;
//  850   byte ret;
//  851   byte *pData;
//  852   uint16 tmp16;
//  853   uint32 tmp32;
//  854   byte extAddr[Z_EXTADDR_LEN];
//  855   byte *retValue;
//  856   byte x = 0;
        MOV     R1,#0x0
//  857 #if !defined ( NONWK )
//  858   uint16 attLen;
//  859 #endif // NONWK
//  860 
//  861   // dig out header info
//  862   cmd = BUILD_UINT16( msg[1], msg[0] );
        MOV     DPL,R2
        MOV     DPH,R3
        INC     DPTR
        MOVX    A,@DPTR
        MOV     R6,A
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        MOV     R7,A
//  863   save_cmd = cmd;
        MOV     DPTR,#save_cmd
        MOV     A,R6
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R7
        MOVX    @DPTR,A
//  864   len = msg[2];
//  865   pData = &msg[3];
        MOV     A,R2
        ADD     A,#0x3
        MOV     R4,A
        MOV     A,R3
        ADDC    A,#0x0
        MOV     R5,A
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOV     A,R4
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R5
        MOVX    @DPTR,A
//  866 
//  867     // Setup for return;
//  868     len = 0;
        MOV     R4,#0x0
//  869     retValue = &ret;
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     ?V0 + 0,DPL
        MOV     ?V0 + 1,DPH
        MOV     A,#0x3
        LCALL   ?XSTACK_DISP0_8
        MOV     A,?V0 + 0
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,?V0 + 1
        MOVX    @DPTR,A
//  870 
//  871     //Process the contents of the message
//  872     switch ( cmd )
        MOV     ?V0 + 0,R6
        MOV     ?V0 + 1,R7
        MOV     R0,#?V0 + 0
        LCALL   ?US_SWITCH_DENSE
`?<Jumptable for MT_ProcessSerialCommand>_0`:
        DATA
        DW        1
        DB        30
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_1
        DW        ??MT_ProcessSerialCommand_2
        DW        ??MT_ProcessSerialCommand_3
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_4
        DW        ??MT_ProcessSerialCommand_5
        DW        ??MT_ProcessSerialCommand_6
        DW        ??MT_ProcessSerialCommand_7
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_8
        DW        ??MT_ProcessSerialCommand_9
        DW        ??MT_ProcessSerialCommand_10
        DW        ??MT_ProcessSerialCommand_11
        DW        ??MT_ProcessSerialCommand_12
        DW        ??MT_ProcessSerialCommand_0
        DW        ??MT_ProcessSerialCommand_13
        DW        ??MT_ProcessSerialCommand_14
        DW        ??MT_ProcessSerialCommand_15
        DW        ??MT_ProcessSerialCommand_16
        DW        ??MT_ProcessSerialCommand_17
        DW        ??MT_ProcessSerialCommand_18
        DW        ??MT_ProcessSerialCommand_19
        DW        ??MT_ProcessSerialCommand_20
        DW        ??MT_ProcessSerialCommand_21
        DW        ??MT_ProcessSerialCommand_22
        CODE
//  873     {
//  874 #ifdef MACSIM
//  875       case SPI_CMD_ZIGNET_DATA:
//  876         MACSIM_TranslateMsg( pData, len );
//  877         break;
//  878 #endif
//  879 
//  880       case SPI_CMD_SYS_RAM_READ:
//  881         extAddr[0] = MT_RAMRead( (UINT16)BUILD_UINT16( pData[1], pData[0] ), &extAddr[1] );
??MT_ProcessSerialCommand_1:
        ; Setup parameters for call to function MT_RAMRead
        MOV     A,#0xc
        LCALL   ?XSTACK_DISP0_8
        MOV     R4,DPL
        MOV     R5,DPH
        LCALL   ?Subroutine6 & 0xFFFF
??CrossCallReturnLabel_79:
        MOV     R3,A
        LCALL   ??MT_RAMRead?relay
        MOV     A,#0xb
        LCALL   ?XSTACK_DISP0_8
        MOV     A,R1
        MOVX    @DPTR,A
//  882         len = MT_RAM_READ_RESP_LEN;
        MOV     R4,#0x2
//  883         retValue = extAddr;
??MT_ProcessSerialCommand_23:
        MOV     R0,DPL
        MOV     R1,DPH
        MOV     A,#0x3
        LCALL   ?XSTACK_DISP0_8
        MOV     A,R0
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R1
??MT_ProcessSerialCommand_24:
        MOVX    @DPTR,A
        LJMP    ??MT_ProcessSerialCommand_25 & 0xFFFF
//  884         break;
//  885 
//  886       case SPI_CMD_SYS_RAM_WRITE:
//  887         ret = MT_RAMWrite( (UINT16)BUILD_UINT16( pData[1], pData[0] ), pData[2] );
??MT_ProcessSerialCommand_2:
        ; Setup parameters for call to function MT_RAMWrite
        LCALL   ?Subroutine10 & 0xFFFF
??CrossCallReturnLabel_34:
        MOVX    A,@DPTR
        MOV     R1,A
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_14:
        MOV     R4,A
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ?Subroutine27 & 0xFFFF
??CrossCallReturnLabel_77:
        MOV     R3,A
        MOV     A,R4
        MOV     R2,A
        LCALL   ??MT_RAMWrite?relay
??MT_ProcessSerialCommand_26:
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     A,R1
        LJMP    ??MT_ProcessSerialCommand_27 & 0xFFFF
//  888         len = MT_RAM_WRITE_RESP_LEN;
//  889         break;
//  890 
//  891       case SPI_CMD_SYS_SET_DEBUG_THRESHOLD:
//  892         ret = MT_SetDebugThreshold( pData[0], pData[1] );
??MT_ProcessSerialCommand_3:
        LCALL   ?Subroutine9 & 0xFFFF
??CrossCallReturnLabel_81:
        MOV     R2,A
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_15:
        MOV     DPTR,#debugThreshold
        MOVX    @DPTR,A
        MOV     A,R2
        MOV     DPTR,#debugCompId
        MOVX    @DPTR,A
//  893         len = 1;
//  894         break;
//  895 
//  896       case SPI_CMD_TRACE_SUB:
//  897         break;
//  898 
//  899       case SPI_CMD_SYS_RESET:
//  900         MT_Reset( pData[0] );
//  901         break;
//  902 
//  903       case SPI_CMD_SYS_CALLBACK_SUB_CMD:
//  904         // a callback value of 0xFFFF turns on all available callbacks
//  905         callbackID = BUILD_UINT16( pData[1] , pData[0] );
//  906         if ( callbackID == 0xFFFF )
//  907         {
//  908           // What is the action
//  909           if ( pData[2] )
//  910           {
//  911             // Turn on
//  912 #if defined( MT_MAC_CB_FUNC )
//  913             _macCallbackSub = 0xFFFF;
//  914 #endif
//  915 #if defined( MT_NWK_CB_FUNC )
//  916             _nwkCallbackSub = 0xFFFF;
//  917 #endif
//  918 
//  919 #if defined( MT_ZDO_FUNC )
//  920             _zdoCallbackSub = 0xFFFFFFFF;
//  921 #endif
//  922 #if defined( MT_AF_CB_FUNC )
//  923             _afCallbackSub = 0xFFFF;
//  924 #endif
//  925 #if defined( MT_SAPI_CB_FUNC )
//  926             _sapiCallbackSub = 0xFFFF;
//  927 #endif
//  928           }
//  929           else
//  930           {
//  931             // Turn off
//  932 #if defined( MT_MAC_CB_FUNC )
//  933             _macCallbackSub = 0x0000;
//  934 #endif
//  935 #if defined( MT_NWK_CB_FUNC )
//  936             _nwkCallbackSub = 0x0000;
//  937 #endif
//  938 
//  939 #if defined( MT_ZDO_FUNC )
//  940             _zdoCallbackSub = 0x00000000;
//  941 #endif
//  942 #if defined( MT_AF_CB_FUNC )
//  943             _afCallbackSub = 0x0000;
//  944 #endif
//  945 #if defined( MT_SAPI_CB_FUNC )
//  946             _sapiCallbackSub = 0x0000;
//  947 #endif
//  948           }
//  949         }
//  950         else
//  951         {
//  952           //First check which layer callbacks are desired and then set the preference
//  953 
//  954 #if defined( MT_MAC_CB_FUNC )
//  955           //If it is a MAC callback, set the corresponding callback subscription bit
//  956           if (( callbackID & 0xFFF0 ) == SPI_MAC_CB_TYPE )
//  957           {
//  958             //Based on the action field, either enable or disable subscription
//  959             if ( pData[2] )
//  960               _macCallbackSub |=  ( 1 << ( pData[1] & 0x0F ) );
//  961             else
//  962               _macCallbackSub &= ~( 1 << ( pData[1] & 0x0F ) );
//  963           }
//  964 #endif
//  965 
//  966 #if defined( MT_NWK_CB_FUNC )
//  967           //If it is a NWK callback, set the corresponding callback subscription bit
//  968           if (( callbackID & 0xFFF0 ) == SPI_NWK_CB_TYPE )
//  969           {
//  970 
//  971             //Based on the action field, either enable or disable subscription
//  972             if ( pData[2] )
//  973               _nwkCallbackSub |=  ( 1 << ( pData[1] & 0x0F ) ) ;
//  974             else
//  975               _nwkCallbackSub &= ~( 1 << ( pData[1] & 0x0F ) );
//  976           }
//  977 #endif
//  978 
//  979 #if defined( MT_ZDO_FUNC )
//  980           //If it is a APS callback, set the corresponding callback subscription bit
//  981           if ( ((callbackID & 0xFFF0) == SPI_ZDO_CB_TYPE) ||
//  982                ((callbackID & 0xFFF0) == SPI_ZDO_CB2_TYPE) )
//  983           {
//  984             //Based on the action field, either enable or disable subscription
//  985             if ( pData[2] )
//  986               _zdoCallbackSub |=  ( 1L << ( pData[1] & 0x1F ) );
//  987             else
//  988               _zdoCallbackSub &= ~( 1L << ( pData[1] & 0x1F ) );
//  989           }
//  990 #endif
//  991 
//  992 #if defined( MT_AF_CB_FUNC )
//  993           // Set the corresponding callback subscription bit for an AF callback.
//  994           if (( callbackID & 0xFFF0 ) == SPI_AF_CB_TYPE )
//  995           {
//  996             // Based on the action field, either enable or disable subscription.
//  997             if ( pData[2] )
//  998               _afCallbackSub |=  ( 1 << ( pData[1] & 0x0F ) );
//  999             else
// 1000               _afCallbackSub &= ~( 1 << ( pData[1] & 0x0F ) );
// 1001           }
// 1002 #endif
// 1003 #if defined( MT_SAPI_CB_FUNC )
// 1004           // Set the corresponding callback subscription bit for an SAPI callback.
// 1005           if (( callbackID & 0xFFF0 ) == SPI_SAPI_CB_TYPE )
// 1006           {
// 1007             // Based on the action field, either enable or disable subscription.
// 1008             if ( pData[2] )
// 1009               _sapiCallbackSub |=  ( 1 << ( pData[1] & 0x0F ) );
// 1010             else
// 1011               _sapiCallbackSub &= ~( 1 << ( pData[1] & 0x0F ) );
// 1012           }
// 1013 #endif
// 1014         }
// 1015         len = 1;
// 1016         ret = ZSUCCESS;
// 1017         break;
// 1018 
// 1019       case SPI_CMD_SYS_PING:
// 1020         // Get a message buffer to build response message
// 1021         // The Ping response now has capabilities included
// 1022 
// 1023         // Build Capabilities
// 1024         tmp16 = MT_CAP_MAC | MT_CAP_NWK | MT_CAP_AF |
// 1025                 MT_CAP_ZDO | MT_CAP_USER_TEST | MT_CAP_SAPI_FUNC;
// 1026 
// 1027         // Convert to high byte first into temp buffer
// 1028         extAddr[0] = HI_UINT16( tmp16 );
// 1029         extAddr[1] = LO_UINT16( tmp16 );
// 1030         len = sizeof ( tmp16 );
// 1031         retValue = extAddr;
// 1032         break;
// 1033 
// 1034       case SPI_CMD_SYS_VERSION:
// 1035         {
// 1036 #if !defined ( NONWK )
// 1037           uint8 i = NLME_GetProtocolVersion() - 1;
// 1038 #else
// 1039           uint8 i = 1;   // just say '1.1' -- irrelevant if stack isn't there anyway
// 1040 #endif
// 1041 
// 1042           // Get a message buffer to build response message
// 1043           len      = (byte)(osal_strlen( (char *)MTVersionString[i] ));
// 1044           retValue = (byte *)MTVersionString[i];
// 1045         }
// 1046           break;
// 1047 
// 1048       case SPI_CMD_SYS_SET_EXTADDR:
// 1049         // Incoming extended address is reversed
// 1050         MT_ReverseBytes( pData, Z_EXTADDR_LEN );
// 1051 
// 1052         if ( ZMacSetReq( ZMacExtAddr, pData ) == ZMacSuccess )
// 1053           ret = osal_nv_write( ZCD_NV_EXTADDR, 0, Z_EXTADDR_LEN, pData );
// 1054         else
// 1055           ret = 1;
// 1056         len = 1;
// 1057         break;
// 1058 
// 1059       case SPI_CMD_SYS_GET_EXTADDR:
// 1060         ZMacGetReq( ZMacExtAddr, extAddr );
// 1061 
// 1062         // Outgoing extended address needs to be reversed
// 1063         MT_ReverseBytes( extAddr, Z_EXTADDR_LEN );
// 1064 
// 1065         len = Z_EXTADDR_LEN;
// 1066         retValue = extAddr;
// 1067         break;
// 1068 
// 1069 #if !defined ( NONWK )
// 1070       case SPI_CMD_SYS_SET_PANID:
// 1071         tmp16 = BUILD_UINT16( pData[1], pData[0] );
// 1072         attLen = osal_nv_item_len( ZCD_NV_PANID );
// 1073         ret = osal_nv_write( ZCD_NV_PANID, 0, attLen, &tmp16 );
// 1074         len = 1;
// 1075         break;
// 1076 
// 1077       case SPI_CMD_SYS_SET_CHANNELS:
// 1078         tmp32 = BUILD_UINT32( pData[3], pData[2], pData[1], pData[0] );
// 1079         attLen = osal_nv_item_len( ZCD_NV_CHANLIST );
// 1080         ret = osal_nv_write( ZCD_NV_CHANLIST, 0, attLen, &tmp32 );
// 1081         len = 1;
// 1082         break;
// 1083 
// 1084       case SPI_CMD_SYS_SET_SECLEVEL:
// 1085         attLen = osal_nv_item_len( ZCD_NV_SECURITY_LEVEL );
// 1086         ret = osal_nv_write( ZCD_NV_SECURITY_LEVEL, 0, attLen, pData );
// 1087         len = 1;
// 1088         break;
// 1089 
// 1090       case SPI_CMD_SYS_SET_PRECFGKEY:
// 1091         attLen = osal_nv_item_len( ZCD_NV_PRECFGKEY );
// 1092         ret = osal_nv_write( ZCD_NV_PRECFGKEY, 0, attLen, pData );
// 1093         len = 1;
// 1094         break;
// 1095 
// 1096       case SPI_CMD_SYS_GET_NV_INFO:
// 1097         MT_ProcessGetNvInfo();
// 1098         break;
// 1099 #endif // NONWK
// 1100 
// 1101       case SPI_CMD_SYS_GET_DEVICE_INFO:
// 1102         MT_ProcessGetDeviceInfo();
// 1103         break;
// 1104 
// 1105       case SPI_CMD_SYS_SET_NV:
// 1106         ret = MT_ProcessSetNV( pData );
// 1107         len = 1;
// 1108         break;
// 1109 
// 1110       case SPI_CMD_SYS_GET_NV:
// 1111         MT_ProcessGetNV( pData );
// 1112         break;
// 1113 
// 1114       case SPI_CMD_SYS_TIME_ALIVE:
// 1115         // Time since last reset (seconds)
// 1116         tmp32 = osal_GetSystemClock() / 1000;
// 1117         // Convert to high byte first into temp buffer
// 1118         extAddr[0] = BREAK_UINT32( tmp32, 3 );
// 1119         extAddr[1] = BREAK_UINT32( tmp32, 2 );
// 1120         extAddr[2] = BREAK_UINT32( tmp32, 1 );
// 1121         extAddr[3] = BREAK_UINT32( tmp32, 0 );
// 1122         len = sizeof ( tmp32 );
// 1123         retValue = extAddr;
// 1124         break;
// 1125 
// 1126       case SPI_CMD_SYS_KEY_EVENT:
// 1127         // Translate between SPI values to device values
// 1128         if ( pData[1] & 0x01 )
// 1129           x |= HAL_KEY_SW_1;
// 1130         if ( pData[1] & 0x02 )
// 1131           x |= HAL_KEY_SW_2;
// 1132         if ( pData[1] & 0x04 )
// 1133           x |= HAL_KEY_SW_3;
// 1134         if ( pData[1] & 0x08 )
// 1135           x |= HAL_KEY_SW_4;
// 1136 #if defined ( HAL_KEY_SW_5 )
// 1137         if ( pData[1] & 0x10 )
// 1138           x |= HAL_KEY_SW_5;
// 1139 #endif
// 1140 #if defined ( HAL_KEY_SW_6 )
// 1141         if ( pData[1] & 0x20 )
// 1142           x |= HAL_KEY_SW_6;
// 1143 #endif
// 1144 #if defined ( HAL_KEY_SW_7 )
// 1145         if ( pData[1] & 0x40 )
// 1146           x |= HAL_KEY_SW_7;
// 1147 #endif
// 1148 #if defined ( HAL_KEY_SW_8 )
// 1149         if ( pData[1] & 0x80 )
// 1150           x |= HAL_KEY_SW_8;
// 1151 #endif
// 1152         ret = OnBoard_SendKeys( x, pData[0]  );
// 1153         len = 1;
// 1154         break;
// 1155 
// 1156       case SPI_CMD_SYS_HEARTBEAT:
// 1157         ret = ZSUCCESS;
??MT_ProcessSerialCommand_14:
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        CLR     A
        LJMP    ??MT_ProcessSerialCommand_27 & 0xFFFF
??MT_ProcessSerialCommand_4:
        ; Setup parameters for call to function MT_Reset
        LCALL   ?Subroutine9 & 0xFFFF
??CrossCallReturnLabel_82:
        MOV     R1,A
        LCALL   ??MT_Reset?relay
        SJMP    ??MT_ProcessSerialCommand_28
??MT_ProcessSerialCommand_5:
        INC     R4
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        CLR     A
        SJMP    ??MT_ProcessSerialCommand_24
??MT_ProcessSerialCommand_6:
        MOV     A,#0x9
        LCALL   ?XSTACK_DISP0_8
        CLR     A
        MOVX    @DPTR,A
        INC     DPTR
        MOVX    @DPTR,A
        MOV     A,#0xb
        LCALL   ?XSTACK_DISP0_8
        CLR     A
        MOVX    @DPTR,A
        MOV     A,#0xc
        LCALL   ?XSTACK_DISP0_8
        CLR     A
        MOVX    @DPTR,A
        INC     R4
        INC     R4
??MT_ProcessSerialCommand_29:
        MOV     A,#0xb
        LCALL   ?XSTACK_DISP0_8
        SJMP    ??MT_ProcessSerialCommand_23
??MT_ProcessSerialCommand_7:
        ; Setup parameters for call to function NLME_GetProtocolVersion
        LCALL   ??NLME_GetProtocolVersion?relay
        MOV     A,R1
        DEC     A
        CLR     C
        RLC     A
        MOV     R0,A
        CLR     A
        RLC     A
        MOV     R1,A
        MOV     A,R0
        ADD     A,#(MTVersionString & 0xff)
        MOV     ?V0 + 0,A
        MOV     A,R1
        ADDC    A,#((MTVersionString >> 8) & 0xff)
        MOV     ?V0 + 1,A
        ; Setup parameters for call to function osal_strlen
        MOV     DPL,?V0 + 0
        MOV     DPH,A
        LCALL   ??Subroutine8_0 & 0xFFFF
??CrossCallReturnLabel_26:
        LCALL   ??osal_strlen?relay
        MOV     A,R2
        MOV     R4,A
        MOV     DPL,?V0 + 0
        MOV     DPH,?V0 + 1
        MOVX    A,@DPTR
        MOV     R0,A
        INC     DPTR
        MOVX    A,@DPTR
        MOV     R1,A
        MOV     A,#0x3
        LCALL   ?XSTACK_DISP0_8
        MOV     A,R0
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R1
        MOVX    @DPTR,A
// 1158         len = 1;
// 1159         break;
// 1160 
// 1161 #if !defined ( NONWK )
// 1162       case SPI_CMD_SYS_APP_MSG:
// 1163         ret = MTProcessAppMsg( pData, msg[2] );
// 1164         len = 0;
// 1165         break;
// 1166 #endif // NONWK
// 1167 
// 1168       case SPI_CMD_SYS_LED_CONTROL:
// 1169 #if (defined HAL_LED) && (HAL_LED == TRUE)
// 1170         ret = MTProcessLedControl( pData );
// 1171         len = 1;
// 1172 #endif
// 1173         break;
// 1174 
// 1175 #ifdef MT_MAC_FUNC
// 1176       case SPI_CMD_MAC_INIT:
// 1177       case SPI_CMD_MAC_ASSOCIATE_REQ:
// 1178       case SPI_CMD_MAC_ASSOCIATE_RSP:
// 1179       case SPI_CMD_MAC_DISASSOCIATE_REQ:
// 1180       case SPI_CMD_MAC_DATA_REQ:
// 1181       case SPI_CMD_MAC_GET_REQ:
// 1182       case SPI_CMD_MAC_SET_REQ:
// 1183       case SPI_CMD_MAC_START_REQ:
// 1184       case SPI_CMD_MAC_SCAN_REQ:
// 1185       case SPI_CMD_MAC_RESET_REQ:
// 1186       case SPI_CMD_MAC_GTS_REQ:
// 1187       case SPI_CMD_MAC_ORPHAN_RSP:
// 1188       case SPI_CMD_MAC_RX_ENABLE_REQ:
// 1189       case SPI_CMD_MAC_SYNC_REQ:
// 1190       case SPI_CMD_MAC_POLL_REQ:
// 1191       case SPI_CMD_MAC_PURGE_REQ:
// 1192         MT_MacCommandProcessing( cmd , len , pData );
// 1193         break;
// 1194 #endif
// 1195 
// 1196 #ifdef MT_NWK_FUNC
// 1197       case SPI_CMD_NWK_INIT:
// 1198       case SPI_CMD_NLDE_DATA_REQ:
// 1199       case SPI_CMD_NLME_INIT_COORD_REQ:
// 1200       case SPI_CMD_NLME_PERMIT_JOINING_REQ:
// 1201       case SPI_CMD_NLME_JOIN_REQ:
// 1202       case SPI_CMD_NLME_LEAVE_REQ:
// 1203       case SPI_CMD_NLME_RESET_REQ:
// 1204       case SPI_CMD_NLME_RX_STATE_REQ:
// 1205       case SPI_CMD_NLME_GET_REQ:
// 1206       case SPI_CMD_NLME_SET_REQ:
// 1207       case SPI_CMD_NLME_NWK_DISC_REQ:
// 1208       case SPI_CMD_NLME_ROUTE_DISC_REQ:
// 1209       case SPI_CMD_NLME_DIRECT_JOIN_REQ:
// 1210       case SPI_CMD_NLME_ORPHAN_JOIN_REQ:
// 1211       case SPI_CMD_NLME_START_ROUTER_REQ:
// 1212         MT_NwkCommandProcessing( cmd , len , pData );
// 1213         break;
// 1214 #endif
// 1215 
// 1216 #ifdef MT_ZDO_FUNC
// 1217       case SPI_CMD_ZDO_AUTO_ENDDEVICEBIND_REQ:
// 1218       case SPI_CMD_ZDO_AUTO_FIND_DESTINATION_REQ:
// 1219       case SPI_CMD_ZDO_NWK_ADDR_REQ:
// 1220       case SPI_CMD_ZDO_IEEE_ADDR_REQ:
// 1221       case SPI_CMD_ZDO_NODE_DESC_REQ:
// 1222       case SPI_CMD_ZDO_POWER_DESC_REQ:
// 1223       case SPI_CMD_ZDO_SIMPLE_DESC_REQ:
// 1224       case SPI_CMD_ZDO_ACTIVE_EPINT_REQ:
// 1225       case SPI_CMD_ZDO_MATCH_DESC_REQ:
// 1226       case SPI_CMD_ZDO_COMPLEX_DESC_REQ:
// 1227       case SPI_CMD_ZDO_USER_DESC_REQ:
// 1228       case SPI_CMD_ZDO_END_DEV_BIND_REQ:
// 1229       case SPI_CMD_ZDO_BIND_REQ:
// 1230       case SPI_CMD_ZDO_UNBIND_REQ:
// 1231       case SPI_CMD_ZDO_MGMT_NWKDISC_REQ:
// 1232       case SPI_CMD_ZDO_MGMT_LQI_REQ:
// 1233       case SPI_CMD_ZDO_MGMT_RTG_REQ:
// 1234       case SPI_CMD_ZDO_MGMT_BIND_REQ:
// 1235       case SPI_CMD_ZDO_MGMT_DIRECT_JOIN_REQ:
// 1236       case SPI_CMD_ZDO_USER_DESC_SET:
// 1237       case SPI_CMD_ZDO_END_DEV_ANNCE:
// 1238       case SPI_CMD_ZDO_MGMT_LEAVE_REQ:
// 1239       case SPI_CMD_ZDO_MGMT_PERMIT_JOIN_REQ:
// 1240       case SPI_CMD_ZDO_SERVERDISC_REQ:
// 1241       case SPI_CMD_ZDO_NETWORK_START_REQ:
// 1242         MT_ZdoCommandProcessing( cmd , len , pData );
// 1243         break;
// 1244 #endif
// 1245 
// 1246 #if defined ( MT_AF_FUNC )
// 1247       case SPI_CMD_AF_INIT:
// 1248       case SPI_CMD_AF_REGISTER:
// 1249       case SPI_CMD_AF_SENDMSG:
// 1250         MT_afCommandProcessing( cmd , len , pData );
// 1251         break;
// 1252 #endif
// 1253 
// 1254 #if defined ( MT_SAPI_FUNC )
// 1255       case SPI_CMD_SAPI_SYS_RESET:
// 1256       case SPI_CMD_SAPI_START_REQ:
// 1257       case SPI_CMD_SAPI_BIND_DEVICE:
// 1258       case SPI_CMD_SAPI_ALLOW_BIND:
// 1259       case SPI_CMD_SAPI_SEND_DATA:
// 1260       case SPI_CMD_SAPI_READ_CFG:
// 1261       case SPI_CMD_SAPI_WRITE_CFG:
// 1262       case SPI_CMD_SAPI_GET_DEV_INFO:
// 1263       case SPI_CMD_SAPI_FIND_DEV:
// 1264       case SPI_CMD_SAPI_PMT_JOIN:
// 1265         ret = MT_sapiCommandProcessing( cmd , len , pData );
// 1266         if ( ret == 0xff )
// 1267           len = 0;
// 1268         else
// 1269           len = 1;
// 1270         break;
// 1271 #endif
// 1272 
// 1273 #if defined ( MT_USER_TEST_FUNC )
// 1274       case SPI_CMD_USER_TEST:
// 1275         MT_ProcessAppUserCmd( pData );
// 1276         break;
// 1277 #endif
// 1278 
// 1279       default:
// 1280         break;
// 1281     }
// 1282 
// 1283     if ( len )
??MT_ProcessSerialCommand_0:
        MOV     A,R4
        JZ      ??MT_ProcessSerialCommand_28
// 1284     {
// 1285       MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + len),
// 1286                                     (SPI_RESPONSE_BIT | cmd),
// 1287                                     len, retValue );
??MT_ProcessSerialCommand_25:
        ; Setup parameters for call to function MT_BuildAndSendZToolResponse
        MOV     A,#0x3
        LCALL   ?XSTACK_DISP0_8
        LCALL   ?PUSH_XSTACK8_X_TWO
        CFI CFA_XSP16 add(XSP16, 37)
        MOV     A,R6
        MOV     R2,A
        MOV     A,#0x10
        ORL     A,R7
        MOV     R3,A
        MOV     A,#0x5
        ADD     A,R4
        MOV     R1,A
        LCALL   ??Subroutine2_0 & 0xFFFF
??CrossCallReturnLabel_75:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 35)
// 1288     }
// 1289   }
??MT_ProcessSerialCommand_28:
        MOV     A,#0x13
        LJMP    ?Subroutine26 & 0xFFFF
??MT_ProcessSerialCommand_8:
        ; Setup parameters for call to function MT_ReverseBytes
        MOV     R1,#0x8
        LCALL   ?Subroutine8 & 0xFFFF
??CrossCallReturnLabel_27:
        LCALL   ??MT_ReverseBytes?relay
        ; Setup parameters for call to function ZMacSetReq
        LCALL   ?Subroutine8 & 0xFFFF
??CrossCallReturnLabel_28:
        MOV     R1,#-0x1e
        LCALL   ZMacSetReq & 0xFFFF
        MOV     A,R1
        JNZ     ??MT_ProcessSerialCommand_30
        ; Setup parameters for call to function osal_nv_write
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ?PUSH_XSTACK8_X_TWO
        CFI CFA_XSP16 add(XSP16, 37)
        MOV     ?V0 + 0,#0x8
        MOV     ?V0 + 1,#0x0
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 39)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#0x1
??MT_ProcessSerialCommand_31:
        MOV     R3,#0x0
        LCALL   ??osal_nv_write?relay
        MOV     A,#0x4
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 35)
        LJMP    ??MT_ProcessSerialCommand_26 & 0xFFFF
??MT_ProcessSerialCommand_30:
        MOV     A,#0x2
        LCALL   ?XSTACK_DISP0_8
        MOV     A,#0x1
??MT_ProcessSerialCommand_27:
        MOVX    @DPTR,A
        MOV     R4,#0x1
        SJMP    ??MT_ProcessSerialCommand_25
??MT_ProcessSerialCommand_9:
        ; Setup parameters for call to function ZMacGetReq
        MOV     A,#0xb
        LCALL   ?XSTACK_DISP0_8
        MOV     R2,DPL
        MOV     R3,DPH
        MOV     R1,#-0x1e
        LCALL   ZMacGetReq & 0xFFFF
        ; Setup parameters for call to function MT_ReverseBytes
        MOV     R1,#0x8
        MOV     R2,DPL
        MOV     R3,DPH
        LCALL   ??MT_ReverseBytes?relay
        MOV     R4,#0x8
        LJMP    ??MT_ProcessSerialCommand_29 & 0xFFFF
??MT_ProcessSerialCommand_18:
        LCALL   ?Subroutine6 & 0xFFFF
??CrossCallReturnLabel_80:
        MOV     R1,A
        MOV     A,R2
        MOV     R0,A
        MOV     A,#0x9
        LCALL   ?XSTACK_DISP0_8
        MOV     A,R0
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R1
        MOVX    @DPTR,A
        ; Setup parameters for call to function osal_nv_write
        MOV     A,#0x9
        LCALL   ?XSTACK_DISP0_8
        MOV     ?V0 + 0,DPL
        MOV     ?V0 + 1,DPH
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 37)
        ; Setup parameters for call to function osal_nv_item_len
        MOV     R2,#-0x7d
        LCALL   ?Subroutine12 & 0xFFFF
??CrossCallReturnLabel_40:
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 39)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#-0x7d
        SJMP    ??MT_ProcessSerialCommand_31
        CFI CFA_XSP16 add(XSP16, 35)
??MT_ProcessSerialCommand_19:
        LCALL   ?Subroutine10 & 0xFFFF
??CrossCallReturnLabel_35:
        INC     DPTR
        MOVX    A,@DPTR
        MOV     ?V0 + 0,A
        MOV     ?V0 + 1,R1
        MOV     ?V0 + 2,R1
        MOV     ?V0 + 3,R1
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ??Subroutine20_0 & 0xFFFF
??CrossCallReturnLabel_62:
        INC     DPTR
        MOVX    A,@DPTR
        MOV     ?V0 + 4,A
        MOV     ?V0 + 5,R1
        MOV     ?V0 + 6,R1
        MOV     ?V0 + 7,R1
        MOV     A,#0x8
        MOV     R0,#?V0 + 4
        LCALL   ?L_SHL
        MOV     R0,#?V0 + 0
        MOV     R1,#?V0 + 4
        LCALL   ?L_ADD
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    A,@DPTR
        MOV     R0,A
        LCALL   ??Subroutine7_0 & 0xFFFF
??CrossCallReturnLabel_16:
        MOV     ?V0 + 4,A
        MOV     ?V0 + 5,R4
        MOV     A,#0x10
        MOV     R0,#?V0 + 4
        LCALL   ?L_SHL
        MOV     R0,#?V0 + 0
        MOV     R1,#?V0 + 4
        LCALL   ?L_ADD
        LCALL   ?Subroutine9 & 0xFFFF
??CrossCallReturnLabel_83:
        MOV     ?V0 + 4,A
        MOV     ?V0 + 6,R4
        MOV     A,#0x18
        MOV     R0,#?V0 + 4
        LCALL   ?L_SHL
        MOV     R0,#?V0 + 0
        MOV     R1,#?V0 + 4
        LCALL   ?L_ADD
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_TO_X
        ; Setup parameters for call to function osal_nv_write
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     ?V0 + 0,DPL
        MOV     ?V0 + 1,DPH
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 37)
        ; Setup parameters for call to function osal_nv_item_len
        MOV     R2,#-0x7c
        LCALL   ?Subroutine12 & 0xFFFF
??CrossCallReturnLabel_41:
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 39)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#-0x7c
??MT_ProcessSerialCommand_32:
        LJMP    ??MT_ProcessSerialCommand_31 & 0xFFFF
        CFI CFA_XSP16 add(XSP16, 35)
??MT_ProcessSerialCommand_20:
        ; Setup parameters for call to function osal_nv_write
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ?PUSH_XSTACK8_X_TWO
        CFI CFA_XSP16 add(XSP16, 37)
        ; Setup parameters for call to function osal_nv_item_len
        MOV     R2,#0x61
        LCALL   ?Subroutine12 & 0xFFFF
??CrossCallReturnLabel_42:
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 39)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#0x61
        LJMP    ??MT_ProcessSerialCommand_31 & 0xFFFF
        CFI CFA_XSP16 add(XSP16, 35)
??MT_ProcessSerialCommand_21:
        ; Setup parameters for call to function osal_nv_write
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ?PUSH_XSTACK8_X_TWO
        CFI CFA_XSP16 add(XSP16, 37)
        ; Setup parameters for call to function osal_nv_item_len
        MOV     R2,#0x62
        LCALL   ?Subroutine12 & 0xFFFF
??CrossCallReturnLabel_43:
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 39)
        MOV     R4,#0x0
        MOV     R5,#0x0
        MOV     R2,#0x62
        SJMP    ??MT_ProcessSerialCommand_32
        CFI CFA_XSP16 add(XSP16, 35)
??MT_ProcessSerialCommand_22:
        ; Setup parameters for call to function MT_ProcessGetNvInfo
        LCALL   ??MT_ProcessGetNvInfo?relay
        LJMP    ??MT_ProcessSerialCommand_28 & 0xFFFF
??MT_ProcessSerialCommand_12:
        ; Setup parameters for call to function MT_ProcessGetDeviceInfo
        LCALL   ??MT_ProcessGetDeviceInfo?relay
        LJMP    ??MT_ProcessSerialCommand_28 & 0xFFFF
??MT_ProcessSerialCommand_10:
        ; Setup parameters for call to function MT_ProcessSetNV
        LCALL   ?Subroutine8 & 0xFFFF
??CrossCallReturnLabel_29:
        LCALL   ??MT_ProcessSetNV?relay
        LJMP    ??MT_ProcessSerialCommand_26 & 0xFFFF
??MT_ProcessSerialCommand_11:
        ; Setup parameters for call to function MT_ProcessGetNV
        LCALL   ?Subroutine8 & 0xFFFF
??CrossCallReturnLabel_30:
        LCALL   ??MT_ProcessGetNV?relay
        LJMP    ??MT_ProcessSerialCommand_28 & 0xFFFF
??MT_ProcessSerialCommand_17:
        ; Setup parameters for call to function osal_GetSystemClock
        LCALL   ??osal_GetSystemClock?relay
        MOV     ?V0 + 4,R2
        MOV     ?V0 + 5,R3
        MOV     ?V0 + 6,R4
        MOV     ?V0 + 7,R5
        MOV     DPTR,#__Constant_3e8
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_X
        MOV     R0,#?V0 + 4
        MOV     R1,#?V0 + 0
        LCALL   ?UL_DIV_MOD
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 4
        LCALL   ?L_MOV_TO_X
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_X
        MOV     A,#0x18
        MOV     R0,#?V0 + 0
        LCALL   ?UL_SHR
        MOV     A,#0xb
        LCALL   ?XSTACK_DISP0_8
        MOV     A,?V0 + 0
        MOVX    @DPTR,A
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_X
        MOV     A,#0x10
        MOV     R0,#?V0 + 0
        LCALL   ?UL_SHR
        MOV     A,#0xc
        LCALL   ?XSTACK_DISP0_8
        MOV     A,?V0 + 0
        MOVX    @DPTR,A
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_X
        MOV     A,?V0 + 1
        MOV     ?V0 + 0,A
        MOV     A,#0xd
        LCALL   ?XSTACK_DISP0_8
        MOV     A,?V0 + 0
        MOVX    @DPTR,A
        MOV     A,#0x5
        LCALL   ?XSTACK_DISP0_8
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_X
        MOV     A,#0xe
        LCALL   ?XSTACK_DISP0_8
        MOV     A,?V0 + 0
        MOVX    @DPTR,A
        MOV     R4,#0x4
        LJMP    ??MT_ProcessSerialCommand_29 & 0xFFFF
??MT_ProcessSerialCommand_13:
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    A,@DPTR
        MOV     R0,A
        LCALL   ??Subroutine7_0 & 0xFFFF
??CrossCallReturnLabel_17:
        MOV     C,0xE0 /* A   */.0
        JNC     ??MT_ProcessSerialCommand_33
        INC     R1
??MT_ProcessSerialCommand_33:
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_18:
        MOV     C,0xE0 /* A   */.1
        JNC     ??MT_ProcessSerialCommand_34
        MOV     A,R1
        SETB    0xE0 /* A   */.1
        MOV     R1,A
??MT_ProcessSerialCommand_34:
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_19:
        MOV     C,0xE0 /* A   */.2
        JNC     ??MT_ProcessSerialCommand_35
        MOV     A,R1
        SETB    0xE0 /* A   */.4
        MOV     R1,A
??MT_ProcessSerialCommand_35:
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_20:
        MOV     C,0xE0 /* A   */.3
        JNC     ??MT_ProcessSerialCommand_36
        MOV     A,R1
        SETB    0xE0 /* A   */.3
        MOV     R1,A
??MT_ProcessSerialCommand_36:
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_21:
        MOV     C,0xE0 /* A   */.4
        JNC     ??MT_ProcessSerialCommand_37
        MOV     A,R1
        SETB    0xE0 /* A   */.2
        MOV     R1,A
??MT_ProcessSerialCommand_37:
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_22:
        MOV     C,0xE0 /* A   */.5
        JNC     ??MT_ProcessSerialCommand_38
        MOV     A,R1
        SETB    0xE0 /* A   */.5
        MOV     R1,A
??MT_ProcessSerialCommand_38:
        LCALL   ?Subroutine7 & 0xFFFF
??CrossCallReturnLabel_23:
        MOV     C,0xE0 /* A   */.6
        JNC     ??MT_ProcessSerialCommand_39
        MOV     A,R1
        SETB    0xE0 /* A   */.6
        MOV     R1,A
??MT_ProcessSerialCommand_39:
        ; Setup parameters for call to function OnBoard_SendKeys
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        LCALL   ?Subroutine27 & 0xFFFF
??CrossCallReturnLabel_78:
        MOV     R2,A
        LCALL   ??OnBoard_SendKeys?relay
        LJMP    ??MT_ProcessSerialCommand_26 & 0xFFFF
??MT_ProcessSerialCommand_15:
        ; Setup parameters for call to function MTProcessAppMsg
        MOV     DPL,R2
        MOV     DPH,R3
        INC     DPTR
        INC     DPTR
        MOVX    A,@DPTR
        MOV     R1,A
        LCALL   ?Subroutine8 & 0xFFFF
??CrossCallReturnLabel_31:
        LCALL   ??MTProcessAppMsg?relay
        LJMP    ??MT_ProcessSerialCommand_28 & 0xFFFF
??MT_ProcessSerialCommand_16:
        ; Setup parameters for call to function MTProcessLedControl
        LCALL   ?Subroutine8 & 0xFFFF
??CrossCallReturnLabel_32:
        LCALL   ??MTProcessLedControl?relay
        LJMP    ??MT_ProcessSerialCommand_26 & 0xFFFF
        CFI EndBlock cfiBlock62

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine12:
        CFI Block cfiCond63 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_39
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 12)
        CFI Block cfiCond64 Using cfiCommon0
        CFI (cfiCond64) NoFunction
        CFI (cfiCond64) Conditional ??CrossCallReturnLabel_40
        CFI (cfiCond64) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond64) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond64) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond64) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond64) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond64) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond64) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond64) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond64) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond64) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond64) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond64) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond64) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond64) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond64) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond64) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond64) CFA_SP SP+0
        CFI (cfiCond64) CFA_XSP16 add(XSP16, 37)
        CFI Block cfiCond65 Using cfiCommon0
        CFI (cfiCond65) NoFunction
        CFI (cfiCond65) Conditional ??CrossCallReturnLabel_41
        CFI (cfiCond65) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond65) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond65) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond65) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond65) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond65) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond65) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond65) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond65) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond65) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond65) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond65) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond65) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond65) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond65) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond65) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond65) CFA_SP SP+0
        CFI (cfiCond65) CFA_XSP16 add(XSP16, 37)
        CFI Block cfiCond66 Using cfiCommon0
        CFI (cfiCond66) NoFunction
        CFI (cfiCond66) Conditional ??CrossCallReturnLabel_42
        CFI (cfiCond66) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond66) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond66) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond66) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond66) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond66) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond66) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond66) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond66) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond66) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond66) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond66) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond66) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond66) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond66) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond66) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond66) CFA_SP SP+0
        CFI (cfiCond66) CFA_XSP16 add(XSP16, 37)
        CFI Block cfiCond67 Using cfiCommon0
        CFI (cfiCond67) NoFunction
        CFI (cfiCond67) Conditional ??CrossCallReturnLabel_43
        CFI (cfiCond67) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond67) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond67) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond67) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond67) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond67) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond67) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond67) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond67) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond67) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond67) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond67) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond67) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond67) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond67) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond67) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond67) CFA_SP SP+0
        CFI (cfiCond67) CFA_XSP16 add(XSP16, 37)
        CFI Block cfiPicker68 Using cfiCommon1
        CFI (cfiPicker68) NoFunction
        CFI (cfiPicker68) Picker
        MOV     R3,#0x0
        LCALL   ??osal_nv_item_len?relay
        MOV     ?V0 + 0,R2
        MOV     ?V0 + 1,R3
        MOV     R0,#?V0 + 0
        RET
        CFI EndBlock cfiCond63
        CFI EndBlock cfiCond64
        CFI EndBlock cfiCond65
        CFI EndBlock cfiCond66
        CFI EndBlock cfiCond67
        CFI EndBlock cfiPicker68

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine10:
        CFI Block cfiCond69 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_34
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond70 Using cfiCommon0
        CFI (cfiCond70) NoFunction
        CFI (cfiCond70) Conditional ??CrossCallReturnLabel_35
        CFI (cfiCond70) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond70) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond70) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond70) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond70) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond70) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond70) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond70) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond70) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond70) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond70) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond70) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond70) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond70) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond70) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond70) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond70) CFA_SP SP+0
        CFI (cfiCond70) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiPicker71 Using cfiCommon1
        CFI (cfiPicker71) NoFunction
        CFI (cfiPicker71) Picker
        LCALL   ?Subroutine20 & 0xFFFF
??CrossCallReturnLabel_65:
        INC     DPTR
        RET
        CFI EndBlock cfiCond69
        CFI EndBlock cfiCond70
        CFI EndBlock cfiPicker71

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine20:
        CFI Block cfiCond72 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_65, ??CrossCallReturnLabel_34
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond73 Using cfiCommon0
        CFI (cfiCond73) NoFunction
        CFI (cfiCond73) Conditional ??CrossCallReturnLabel_65, ??CrossCallReturnLabel_35
        CFI (cfiCond73) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond73) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond73) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond73) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond73) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond73) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond73) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond73) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond73) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond73) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond73) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond73) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond73) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond73) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond73) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond73) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond73) CFA_SP SP+0
        CFI (cfiCond73) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond74 Using cfiCommon0
        CFI (cfiCond74) NoFunction
        CFI (cfiCond74) Conditional ??CrossCallReturnLabel_63, ??CrossCallReturnLabel_79
        CFI (cfiCond74) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond74) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond74) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond74) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond74) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond74) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond74) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond74) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond74) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond74) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond74) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond74) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond74) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond74) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond74) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond74) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond74) CFA_SP SP+0
        CFI (cfiCond74) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond75 Using cfiCommon0
        CFI (cfiCond75) NoFunction
        CFI (cfiCond75) Conditional ??CrossCallReturnLabel_63, ??CrossCallReturnLabel_80
        CFI (cfiCond75) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond75) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond75) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond75) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond75) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond75) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond75) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond75) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond75) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond75) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond75) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond75) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond75) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond75) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond75) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond75) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond75) CFA_SP SP+0
        CFI (cfiCond75) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiPicker76 Using cfiCommon1
        CFI (cfiPicker76) NoFunction
        CFI (cfiPicker76) Picker
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    A,@DPTR
        MOV     R0,A
        CFI Block cfiCond77 Using cfiCommon0
        CFI (cfiCond77) NoFunction
        CFI (cfiCond77) Conditional ??CrossCallReturnLabel_62
        CFI (cfiCond77) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond77) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond77) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond77) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond77) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond77) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond77) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond77) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond77) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond77) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond77) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond77) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond77) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond77) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond77) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond77) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond77) CFA_SP SP+0
        CFI (cfiCond77) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond78 Using cfiCommon0
        CFI (cfiCond78) NoFunction
        CFI (cfiCond78) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_14
        CFI (cfiCond78) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond78) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond78) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond78) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond78) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond78) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond78) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond78) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond78) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond78) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond78) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond78) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond78) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond78) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond78) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond78) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond78) CFA_SP SP+0
        CFI (cfiCond78) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond79 Using cfiCommon0
        CFI (cfiCond79) NoFunction
        CFI (cfiCond79) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_15
        CFI (cfiCond79) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond79) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond79) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond79) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond79) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond79) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond79) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond79) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond79) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond79) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond79) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond79) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond79) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond79) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond79) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond79) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond79) CFA_SP SP+0
        CFI (cfiCond79) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond80 Using cfiCommon0
        CFI (cfiCond80) NoFunction
        CFI (cfiCond80) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_18
        CFI (cfiCond80) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond80) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond80) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond80) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond80) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond80) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond80) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond80) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond80) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond80) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond80) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond80) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond80) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond80) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond80) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond80) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond80) CFA_SP SP+0
        CFI (cfiCond80) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond81 Using cfiCommon0
        CFI (cfiCond81) NoFunction
        CFI (cfiCond81) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_19
        CFI (cfiCond81) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond81) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond81) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond81) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond81) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond81) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond81) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond81) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond81) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond81) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond81) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond81) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond81) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond81) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond81) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond81) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond81) CFA_SP SP+0
        CFI (cfiCond81) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond82 Using cfiCommon0
        CFI (cfiCond82) NoFunction
        CFI (cfiCond82) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_20
        CFI (cfiCond82) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond82) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond82) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond82) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond82) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond82) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond82) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond82) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond82) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond82) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond82) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond82) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond82) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond82) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond82) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond82) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond82) CFA_SP SP+0
        CFI (cfiCond82) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond83 Using cfiCommon0
        CFI (cfiCond83) NoFunction
        CFI (cfiCond83) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_21
        CFI (cfiCond83) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond83) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond83) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond83) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond83) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond83) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond83) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond83) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond83) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond83) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond83) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond83) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond83) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond83) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond83) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond83) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond83) CFA_SP SP+0
        CFI (cfiCond83) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond84 Using cfiCommon0
        CFI (cfiCond84) NoFunction
        CFI (cfiCond84) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_22
        CFI (cfiCond84) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond84) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond84) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond84) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond84) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond84) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond84) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond84) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond84) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond84) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond84) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond84) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond84) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond84) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond84) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond84) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond84) CFA_SP SP+0
        CFI (cfiCond84) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond85 Using cfiCommon0
        CFI (cfiCond85) NoFunction
        CFI (cfiCond85) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_23
        CFI (cfiCond85) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond85) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond85) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond85) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond85) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond85) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond85) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond85) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond85) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond85) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond85) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond85) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond85) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond85) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond85) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond85) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond85) CFA_SP SP+0
        CFI (cfiCond85) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond86 Using cfiCommon0
        CFI (cfiCond86) NoFunction
        CFI (cfiCond86) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_16
        CFI (cfiCond86) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond86) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond86) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond86) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond86) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond86) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond86) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond86) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond86) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond86) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond86) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond86) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond86) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond86) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond86) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond86) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond86) CFA_SP SP+0
        CFI (cfiCond86) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond87 Using cfiCommon0
        CFI (cfiCond87) NoFunction
        CFI (cfiCond87) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_17
        CFI (cfiCond87) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond87) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond87) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond87) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond87) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond87) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond87) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond87) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond87) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond87) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond87) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond87) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond87) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond87) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond87) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond87) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond87) CFA_SP SP+0
        CFI (cfiCond87) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond88 Using cfiCommon0
        CFI (cfiCond88) NoFunction
        CFI (cfiCond88) Conditional ??CrossCallReturnLabel_64, ??CrossCallReturnLabel_24
        CFI (cfiCond88) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond88) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond88) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond88) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond88) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond88) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond88) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond88) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond88) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond88) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond88) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond88) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond88) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond88) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond88) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond88) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond88) CFA_SP SP+0
        CFI (cfiCond88) CFA_XSP16 add(XSP16, 18)
??Subroutine20_0:
        INC     DPTR
        MOVX    A,@DPTR
        MOV     DPH,A
        MOV     DPL,R0
        INC     DPTR
        RET
        CFI EndBlock cfiCond72
        CFI EndBlock cfiCond73
        CFI EndBlock cfiCond74
        CFI EndBlock cfiCond75
        CFI EndBlock cfiPicker76
        CFI EndBlock cfiCond77
        CFI EndBlock cfiCond78
        CFI EndBlock cfiCond79
        CFI EndBlock cfiCond80
        CFI EndBlock cfiCond81
        CFI EndBlock cfiCond82
        CFI EndBlock cfiCond83
        CFI EndBlock cfiCond84
        CFI EndBlock cfiCond85
        CFI EndBlock cfiCond86
        CFI EndBlock cfiCond87
        CFI EndBlock cfiCond88

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine8:
        CFI Block cfiCond89 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_27
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond90 Using cfiCommon0
        CFI (cfiCond90) NoFunction
        CFI (cfiCond90) Conditional ??CrossCallReturnLabel_28
        CFI (cfiCond90) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond90) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond90) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond90) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond90) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond90) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond90) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond90) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond90) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond90) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond90) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond90) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond90) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond90) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond90) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond90) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond90) CFA_SP SP+0
        CFI (cfiCond90) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond91 Using cfiCommon0
        CFI (cfiCond91) NoFunction
        CFI (cfiCond91) Conditional ??CrossCallReturnLabel_29
        CFI (cfiCond91) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond91) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond91) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond91) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond91) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond91) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond91) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond91) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond91) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond91) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond91) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond91) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond91) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond91) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond91) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond91) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond91) CFA_SP SP+0
        CFI (cfiCond91) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond92 Using cfiCommon0
        CFI (cfiCond92) NoFunction
        CFI (cfiCond92) Conditional ??CrossCallReturnLabel_30
        CFI (cfiCond92) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond92) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond92) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond92) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond92) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond92) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond92) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond92) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond92) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond92) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond92) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond92) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond92) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond92) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond92) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond92) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond92) CFA_SP SP+0
        CFI (cfiCond92) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond93 Using cfiCommon0
        CFI (cfiCond93) NoFunction
        CFI (cfiCond93) Conditional ??CrossCallReturnLabel_31
        CFI (cfiCond93) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond93) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond93) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond93) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond93) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond93) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond93) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond93) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond93) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond93) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond93) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond93) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond93) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond93) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond93) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond93) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond93) CFA_SP SP+0
        CFI (cfiCond93) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond94 Using cfiCommon0
        CFI (cfiCond94) NoFunction
        CFI (cfiCond94) Conditional ??CrossCallReturnLabel_32
        CFI (cfiCond94) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond94) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond94) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond94) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond94) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond94) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond94) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond94) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond94) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond94) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond94) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond94) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond94) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond94) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond94) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond94) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond94) CFA_SP SP+0
        CFI (cfiCond94) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiPicker95 Using cfiCommon1
        CFI (cfiPicker95) NoFunction
        CFI (cfiPicker95) Picker
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        CFI Block cfiCond96 Using cfiCommon0
        CFI (cfiCond96) NoFunction
        CFI (cfiCond96) Conditional ??CrossCallReturnLabel_25
        CFI (cfiCond96) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond96) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond96) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond96) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond96) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond96) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond96) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond96) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond96) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond96) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond96) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond96) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond96) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond96) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond96) CFA_SP SP+0
        CFI (cfiCond96) CFA_XSP16 add(XSP16, 14)
        CFI Block cfiCond97 Using cfiCommon0
        CFI (cfiCond97) NoFunction
        CFI (cfiCond97) Conditional ??CrossCallReturnLabel_26
        CFI (cfiCond97) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond97) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond97) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond97) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond97) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond97) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond97) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond97) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond97) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond97) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond97) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond97) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond97) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond97) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond97) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond97) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond97) CFA_SP SP+0
        CFI (cfiCond97) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond98 Using cfiCommon0
        CFI (cfiCond98) NoFunction
        CFI (cfiCond98) Conditional ??CrossCallReturnLabel_33
        CFI (cfiCond98) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond98) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond98) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond98) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond98) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond98) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond98) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond98) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond98) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond98) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond98) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond98) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond98) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond98) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond98) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond98) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond98) CFA_SP SP+0
        CFI (cfiCond98) CFA_XSP16 add(XSP16, 21)
??Subroutine8_0:
        MOVX    A,@DPTR
        MOV     R2,A
        INC     DPTR
        MOVX    A,@DPTR
        MOV     R3,A
        RET
        CFI EndBlock cfiCond89
        CFI EndBlock cfiCond90
        CFI EndBlock cfiCond91
        CFI EndBlock cfiCond92
        CFI EndBlock cfiCond93
        CFI EndBlock cfiCond94
        CFI EndBlock cfiPicker95
        CFI EndBlock cfiCond96
        CFI EndBlock cfiCond97
        CFI EndBlock cfiCond98

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine6:
        CFI Block cfiCond99 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_79
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond100 Using cfiCommon0
        CFI (cfiCond100) NoFunction
        CFI (cfiCond100) Conditional ??CrossCallReturnLabel_80
        CFI (cfiCond100) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond100) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond100) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond100) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond100) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond100) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond100) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond100) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond100) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond100) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond100) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond100) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond100) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond100) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond100) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond100) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond100) CFA_SP SP+0
        CFI (cfiCond100) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiPicker101 Using cfiCommon1
        CFI (cfiPicker101) NoFunction
        CFI (cfiPicker101) Picker
        LCALL   ?Subroutine20 & 0xFFFF
??CrossCallReturnLabel_63:
        MOVX    A,@DPTR
        MOV     R2,A
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        CFI EndBlock cfiCond99
        CFI EndBlock cfiCond100
        CFI EndBlock cfiPicker101
        REQUIRE ?Subroutine27
        ; // Fall through to label ?Subroutine27

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine27:
        CFI Block cfiCond102 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_79
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond103 Using cfiCommon0
        CFI (cfiCond103) NoFunction
        CFI (cfiCond103) Conditional ??CrossCallReturnLabel_80
        CFI (cfiCond103) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond103) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond103) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond103) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond103) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond103) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond103) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond103) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond103) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond103) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond103) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond103) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond103) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond103) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond103) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond103) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond103) CFA_SP SP+0
        CFI (cfiCond103) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond104 Using cfiCommon0
        CFI (cfiCond104) NoFunction
        CFI (cfiCond104) Conditional ??CrossCallReturnLabel_81
        CFI (cfiCond104) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond104) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond104) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond104) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond104) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond104) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond104) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond104) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond104) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond104) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond104) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond104) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond104) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond104) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond104) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond104) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond104) CFA_SP SP+0
        CFI (cfiCond104) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond105 Using cfiCommon0
        CFI (cfiCond105) NoFunction
        CFI (cfiCond105) Conditional ??CrossCallReturnLabel_82
        CFI (cfiCond105) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond105) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond105) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond105) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond105) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond105) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond105) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond105) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond105) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond105) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond105) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond105) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond105) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond105) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond105) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond105) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond105) CFA_SP SP+0
        CFI (cfiCond105) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond106 Using cfiCommon0
        CFI (cfiCond106) NoFunction
        CFI (cfiCond106) Conditional ??CrossCallReturnLabel_83
        CFI (cfiCond106) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond106) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond106) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond106) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond106) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond106) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond106) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond106) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond106) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond106) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond106) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond106) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond106) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond106) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond106) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond106) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond106) CFA_SP SP+0
        CFI (cfiCond106) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond107 Using cfiCommon0
        CFI (cfiCond107) NoFunction
        CFI (cfiCond107) Conditional ??CrossCallReturnLabel_84
        CFI (cfiCond107) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond107) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond107) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond107) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond107) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond107) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond107) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond107) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond107) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond107) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond107) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond107) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond107) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond107) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond107) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond107) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond107) CFA_SP SP+0
        CFI (cfiCond107) CFA_XSP16 add(XSP16, 18)
        CFI Block cfiCond108 Using cfiCommon0
        CFI (cfiCond108) NoFunction
        CFI (cfiCond108) Conditional ??CrossCallReturnLabel_77
        CFI (cfiCond108) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond108) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond108) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond108) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond108) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond108) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond108) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond108) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond108) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond108) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond108) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond108) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond108) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond108) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond108) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond108) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond108) CFA_SP SP+0
        CFI (cfiCond108) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond109 Using cfiCommon0
        CFI (cfiCond109) NoFunction
        CFI (cfiCond109) Conditional ??CrossCallReturnLabel_78
        CFI (cfiCond109) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond109) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond109) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond109) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond109) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond109) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond109) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond109) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond109) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond109) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond109) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond109) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond109) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond109) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond109) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond109) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond109) CFA_SP SP+0
        CFI (cfiCond109) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiPicker110 Using cfiCommon1
        CFI (cfiPicker110) NoFunction
        CFI (cfiPicker110) Picker
        INC     DPTR
        MOVX    A,@DPTR
        MOV     DPH,A
        MOV     DPL,R0
        MOVX    A,@DPTR
        RET
        CFI EndBlock cfiCond102
        CFI EndBlock cfiCond103
        CFI EndBlock cfiCond104
        CFI EndBlock cfiCond105
        CFI EndBlock cfiCond106
        CFI EndBlock cfiCond107
        CFI EndBlock cfiCond108
        CFI EndBlock cfiCond109
        CFI EndBlock cfiPicker110

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine2:
        CFI Block cfiCond111 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_71
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 13)
        CFI Block cfiCond112 Using cfiCommon0
        CFI (cfiCond112) NoFunction
        CFI (cfiCond112) Conditional ??CrossCallReturnLabel_71
        CFI (cfiCond112) R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond112) VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond112) V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond112) V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond112) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond112) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond112) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond112) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond112) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond112) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond112) CFA_SP SP+0
        CFI (cfiCond112) CFA_XSP16 add(XSP16, 13)
        CFI Block cfiPicker113 Using cfiCommon1
        CFI (cfiPicker113) NoFunction
        CFI (cfiPicker113) Picker
        MOV     R3,#0x10
        MOV     R1,#0x6
        CFI Block cfiCond114 Using cfiCommon0
        CFI (cfiCond114) NoFunction
        CFI (cfiCond114) Conditional ??CrossCallReturnLabel_72
        CFI (cfiCond114) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond114) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond114) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond114) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond114) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond114) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond114) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond114) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond114) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond114) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond114) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond114) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond114) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond114) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond114) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond114) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond114) CFA_SP SP+0
        CFI (cfiCond114) CFA_XSP16 add(XSP16, 18)
        CFI Block cfiCond115 Using cfiCommon0
        CFI (cfiCond115) NoFunction
        CFI (cfiCond115) Conditional ??CrossCallReturnLabel_73
        CFI (cfiCond115) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond115) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond115) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond115) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond115) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond115) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond115) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond115) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond115) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond115) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond115) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond115) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond115) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond115) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond115) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond115) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond115) CFA_SP SP+0
        CFI (cfiCond115) CFA_XSP16 add(XSP16, 24)
        CFI Block cfiCond116 Using cfiCommon0
        CFI (cfiCond116) NoFunction
        CFI (cfiCond116) Conditional ??CrossCallReturnLabel_74
        CFI (cfiCond116) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond116) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond116) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond116) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond116) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond116) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond116) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond116) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond116) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond116) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond116) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond116) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond116) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond116) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond116) CFA_SP SP+0
        CFI (cfiCond116) CFA_XSP16 add(XSP16, 17)
        CFI Block cfiCond117 Using cfiCommon0
        CFI (cfiCond117) NoFunction
        CFI (cfiCond117) Conditional ??CrossCallReturnLabel_75
        CFI (cfiCond117) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond117) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond117) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond117) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond117) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond117) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond117) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond117) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond117) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond117) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond117) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond117) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond117) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond117) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond117) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond117) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond117) CFA_SP SP+0
        CFI (cfiCond117) CFA_XSP16 add(XSP16, 37)
        CFI Block cfiCond118 Using cfiCommon0
        CFI (cfiCond118) NoFunction
        CFI (cfiCond118) Conditional ??CrossCallReturnLabel_76
        CFI (cfiCond118) R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond118) VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond118) V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond118) V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond118) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond118) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond118) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond118) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond118) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond118) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond118) CFA_SP SP+0
        CFI (cfiCond118) CFA_XSP16 add(XSP16, 12)
??Subroutine2_0:
        LCALL   ??MT_BuildAndSendZToolResponse?relay
        MOV     A,#0x2
        RET
        CFI EndBlock cfiCond111
        CFI EndBlock cfiCond112
        CFI EndBlock cfiPicker113
        CFI EndBlock cfiCond114
        CFI EndBlock cfiCond115
        CFI EndBlock cfiCond116
        CFI EndBlock cfiCond117
        CFI EndBlock cfiCond118
// 1290 #endif // ZTOOL
// 1291 
// 1292 #if (defined HAL_LED) && (HAL_LED == TRUE)
// 1293 /***************************************************************************************************
// 1294  * @fn      MTProcessLedControl
// 1295  *
// 1296  * @brief
// 1297  *
// 1298  *   Process the LED Control Message
// 1299  *
// 1300  * @param   data - input serial buffer
// 1301  *
// 1302  * @return  status
// 1303  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1304 byte MTProcessLedControl( byte *pData )
MTProcessLedControl:
        CFI Block cfiBlock119 Using cfiCommon0
        CFI Function MTProcessLedControl
// 1305 {
        FUNCALL MTProcessLedControl, HalLedSet
        LOCFRAME ISTACK, 2, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 0, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 2, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 0, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        PUSH    DPL
        CFI DPL0 Frame(CFA_SP, 4)
        CFI CFA_SP SP+-4
        PUSH    DPH
        CFI DPH0 Frame(CFA_SP, 5)
        CFI CFA_SP SP+-5
        ; Saved register size: 2
        ; Auto size: 0
// 1306   byte iLed;
// 1307   byte Led;
// 1308   byte iMode;
// 1309   byte Mode;
// 1310 
// 1311   iLed = *pData++;
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        MOV     R4,A
        INC     DPTR
// 1312   iMode = *pData;
        MOVX    A,@DPTR
        MOV     R2,A
// 1313 
// 1314   if ( iLed == 1 )
        MOV     A,#0x1
        XRL     A,R4
        JNZ     ??MTProcessLedControl_0
// 1315     Led = HAL_LED_1;
        MOV     R1,#0x1
        SJMP    ??MTProcessLedControl_1
// 1316   else if ( iLed == 2 )
??MTProcessLedControl_0:
        MOV     A,#0x2
        XRL     A,R4
        JNZ     ??MTProcessLedControl_2
// 1317     Led = HAL_LED_2;
        MOV     R1,#0x2
        SJMP    ??MTProcessLedControl_1
// 1318   else if ( iLed == 3 )
??MTProcessLedControl_2:
        MOV     A,#0x3
        XRL     A,R4
        JNZ     ??MTProcessLedControl_3
// 1319     Led = HAL_LED_3;
        MOV     R1,#0x4
        SJMP    ??MTProcessLedControl_1
// 1320   else if ( iLed == 4 )
??MTProcessLedControl_3:
        MOV     A,#0x4
        XRL     A,R4
        JNZ     ??MTProcessLedControl_4
// 1321     Led = HAL_LED_4;
        MOV     R1,#0x8
        SJMP    ??MTProcessLedControl_1
// 1322   else if ( iLed == 0xFF )
??MTProcessLedControl_4:
        MOV     A,#-0x1
        XRL     A,R4
        JNZ     ??MTProcessLedControl_5
// 1323     Led = HAL_LED_ALL;
        MOV     R1,#0xf
        SJMP    ??MTProcessLedControl_1
// 1324   else
// 1325     Led = 0;
??MTProcessLedControl_5:
        MOV     R1,#0x0
// 1326 
// 1327   if ( iMode == 0 )
??MTProcessLedControl_1:
        MOV     A,R2
        JNZ     ??MTProcessLedControl_6
// 1328     Mode = HAL_LED_MODE_OFF;
        MOV     R2,#0x0
        SJMP    ??MTProcessLedControl_7
// 1329   else if ( iMode == 1 )
??MTProcessLedControl_6:
        MOV     A,#0x1
        XRL     A,R2
        JNZ     ??MTProcessLedControl_8
// 1330     Mode = HAL_LED_MODE_ON;
        MOV     R2,#0x1
        SJMP    ??MTProcessLedControl_7
// 1331   else if ( iMode == 2 )
??MTProcessLedControl_8:
        MOV     A,#0x2
        XRL     A,R2
        JNZ     ??MTProcessLedControl_9
// 1332     Mode = HAL_LED_MODE_BLINK;
        MOV     R2,#0x2
        SJMP    ??MTProcessLedControl_7
// 1333   else if ( iMode == 3 )
??MTProcessLedControl_9:
        MOV     A,#0x3
        XRL     A,R2
        JNZ     ??MTProcessLedControl_10
// 1334     Mode = HAL_LED_MODE_FLASH;
        MOV     R2,#0x4
        SJMP    ??MTProcessLedControl_7
// 1335   else if ( iMode == 4 )
??MTProcessLedControl_10:
        MOV     A,#0x4
        XRL     A,R2
        JNZ     ??MTProcessLedControl_11
// 1336     Mode = HAL_LED_MODE_TOGGLE;
        MOV     R2,#0x8
// 1337   else
// 1338     Led = 0;
// 1339 
// 1340   if ( Led != 0 )
??MTProcessLedControl_7:
        MOV     A,R1
        JZ      ??MTProcessLedControl_11
// 1341   {
// 1342     HalLedSet (Led, Mode );
        ; Setup parameters for call to function HalLedSet
        LCALL   ??HalLedSet?relay
// 1343     return ( ZSuccess );
        MOV     R1,#0x0
        SJMP    ??MTProcessLedControl_12
// 1344   }
// 1345   else
// 1346     return ( ZFailure );
??MTProcessLedControl_11:
        MOV     R1,#0x1
??MTProcessLedControl_12:
        LJMP    ?Subroutine23 & 0xFFFF
        CFI EndBlock cfiBlock119
// 1347 }
// 1348 #endif // HAL_LED
// 1349 
// 1350 #if !defined ( NONWK )
// 1351 /*********************************************************************
// 1352  * @fn      MTProcessAppMsg
// 1353  *
// 1354  * @brief
// 1355  *
// 1356  *   Process the User App Message
// 1357  *
// 1358  * @param   data - input serial buffer
// 1359  * @param   len - data length
// 1360  *
// 1361  * @return  status
// 1362  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1363 byte MTProcessAppMsg( byte *pData, byte len )
MTProcessAppMsg:
        CFI Block cfiBlock120 Using cfiCommon0
        CFI Function MTProcessAppMsg
// 1364 {
        FUNCALL MTProcessAppMsg, afFindEndPointDesc
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 18, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 18, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MTProcessAppMsg, osal_msg_allocate
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 18, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 18, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MTProcessAppMsg, osal_memcpy
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 21, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 21, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MTProcessAppMsg, osal_msg_send
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 18, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 18, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0x10
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 16)
        ; Saved register size: 16
        ; Auto size: 2
        MOV     A,#-0x2
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 18)
        MOV     ?V0 + 3,R1
// 1365   byte ret = ZFailure;
        MOV     ?V0 + 2,#0x1
// 1366   byte endpoint;
// 1367   endPointDesc_t *epDesc;
// 1368   mtSysAppMsg_t *msg;
// 1369 
// 1370   // Get the endpoint and skip past it.
// 1371   endpoint = *pData++;
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        MOV     ?V0 + 4,A
        INC     DPTR
        MOV     ?V0 + 6,DPL
        MOV     ?V0 + 7,DPH
// 1372   len--;
        DEC     ?V0 + 3
// 1373 
// 1374   // Look up the endpoint
// 1375   epDesc = afFindEndPointDesc( endpoint );
        ; Setup parameters for call to function afFindEndPointDesc
        MOV     R1,A
        LCALL   ??afFindEndPointDesc?relay
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOV     A,R2
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R3
        LCALL   ?Subroutine5 & 0xFFFF
// 1376 
// 1377   if ( epDesc )
??CrossCallReturnLabel_13:
        JNZ     ??MTProcessAppMsg_0
        INC     DPTR
        MOVX    A,@DPTR
??MTProcessAppMsg_0:
        JZ      ??MTProcessAppMsg_1
// 1378   {
// 1379     // Build and send the message to the APP
// 1380     msg = (mtSysAppMsg_t *)osal_msg_allocate( sizeof( mtSysAppMsg_t ) + len );
        ; Setup parameters for call to function osal_msg_allocate
        MOV     ?V0 + 0,?V0 + 3
        MOV     A,#0x6
        ADD     A,?V0 + 0
        MOV     R2,A
        CLR     A
        ADDC    A,#0x0
        MOV     R3,A
        LCALL   ??osal_msg_allocate?relay
        MOV     ?V0 + 0,R2
        MOV     ?V0 + 1,R3
        MOV     R6,?V0 + 0
        MOV     R7,?V0 + 1
// 1381     if ( msg )
        MOV     A,R6
        JNZ     ??MTProcessAppMsg_2
        MOV     A,R7
??MTProcessAppMsg_2:
        JZ      ??MTProcessAppMsg_1
// 1382     {
// 1383       msg->hdr.event = MT_SYS_APP_MSG;
        MOV     A,#0x23
        MOV     DPL,R6
        MOV     DPH,R7
        MOVX    @DPTR,A
// 1384       msg->endpoint = endpoint;
        INC     DPTR
        INC     DPTR
        MOV     A,?V0 + 4
        LCALL   ?Subroutine4 & 0xFFFF
// 1385       msg->appDataLen = len;
??CrossCallReturnLabel_11:
        MOV     A,?V0 + 3
        MOVX    @DPTR,A
// 1386       msg->appData = (uint8*)(msg+1);
        MOV     A,R6
        ADD     A,#0x4
        MOV     R2,A
        MOV     A,R7
        ADDC    A,#0x0
        MOV     R3,A
        MOV     A,R6
        ADD     A,#0x6
        MOV     R0,A
        MOV     A,R7
        ADDC    A,#0x0
        MOV     R1,A
        MOV     DPL,R2
        MOV     DPH,R3
        MOV     A,R0
        MOVX    @DPTR,A
        INC     DPTR
        MOV     A,R1
        MOVX    @DPTR,A
// 1387 
// 1388       osal_memcpy( msg->appData, pData, len );
        ; Setup parameters for call to function osal_memcpy
        MOV     ?V0 + 0,?V0 + 6
        MOV     ?V0 + 1,?V0 + 7
        MOV     ?V0 + 2,#0x0
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_THREE
        CFI CFA_XSP16 add(XSP16, 21)
        MOV     R4,?V0 + 3
        MOV     R5,#0x0
        MOV     DPL,R2
        MOV     DPH,R3
        LCALL   ??Subroutine8_0 & 0xFFFF
??CrossCallReturnLabel_33:
        LCALL   ??osal_memcpy?relay
        MOV     A,#0x3
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 18)
// 1389 
// 1390       osal_msg_send( *(epDesc->task_id), (uint8 *)msg );
        ; Setup parameters for call to function osal_msg_send
        MOV     A,R6
        MOV     R2,A
        MOV     A,R7
        MOV     R3,A
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    A,@DPTR
        MOV     R0,A
        LCALL   ??Subroutine7_0 & 0xFFFF
??CrossCallReturnLabel_24:
        LCALL   ??Subroutine9_0 & 0xFFFF
??CrossCallReturnLabel_84:
        MOV     R1,A
        LCALL   ??osal_msg_send?relay
// 1391 
// 1392       ret = ZSuccess;
// 1393     }
// 1394   }
// 1395 
// 1396   return ret;
??MTProcessAppMsg_1:
        MOV     R1,?V0 + 2
        MOV     A,#0x2
        LJMP    ?Subroutine26 & 0xFFFF
        CFI EndBlock cfiBlock120
// 1397 }

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine9:
        CFI Block cfiCond121 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_81
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond122 Using cfiCommon0
        CFI (cfiCond122) NoFunction
        CFI (cfiCond122) Conditional ??CrossCallReturnLabel_82
        CFI (cfiCond122) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond122) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond122) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond122) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond122) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond122) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond122) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond122) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond122) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond122) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond122) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond122) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond122) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond122) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond122) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond122) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond122) CFA_SP SP+0
        CFI (cfiCond122) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond123 Using cfiCommon0
        CFI (cfiCond123) NoFunction
        CFI (cfiCond123) Conditional ??CrossCallReturnLabel_83
        CFI (cfiCond123) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond123) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond123) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond123) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond123) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond123) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond123) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond123) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond123) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond123) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond123) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond123) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond123) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond123) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond123) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond123) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond123) CFA_SP SP+0
        CFI (cfiCond123) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiPicker124 Using cfiCommon1
        CFI (cfiPicker124) NoFunction
        CFI (cfiPicker124) Picker
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    A,@DPTR
        CFI Block cfiCond125 Using cfiCommon0
        CFI (cfiCond125) NoFunction
        CFI (cfiCond125) Conditional ??CrossCallReturnLabel_84
        CFI (cfiCond125) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond125) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond125) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond125) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond125) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond125) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond125) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond125) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond125) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond125) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond125) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond125) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond125) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond125) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond125) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond125) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond125) CFA_SP SP+0
        CFI (cfiCond125) CFA_XSP16 add(XSP16, 18)
??Subroutine9_0:
        MOV     R0,A
        LJMP    ?Subroutine27 & 0xFFFF
        CFI EndBlock cfiCond121
        CFI EndBlock cfiCond122
        CFI EndBlock cfiCond123
        CFI EndBlock cfiPicker124
        CFI EndBlock cfiCond125

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine7:
        CFI Block cfiCond126 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_14
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond127 Using cfiCommon0
        CFI (cfiCond127) NoFunction
        CFI (cfiCond127) Conditional ??CrossCallReturnLabel_15
        CFI (cfiCond127) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond127) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond127) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond127) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond127) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond127) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond127) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond127) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond127) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond127) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond127) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond127) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond127) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond127) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond127) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond127) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond127) CFA_SP SP+0
        CFI (cfiCond127) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond128 Using cfiCommon0
        CFI (cfiCond128) NoFunction
        CFI (cfiCond128) Conditional ??CrossCallReturnLabel_18
        CFI (cfiCond128) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond128) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond128) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond128) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond128) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond128) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond128) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond128) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond128) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond128) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond128) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond128) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond128) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond128) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond128) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond128) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond128) CFA_SP SP+0
        CFI (cfiCond128) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond129 Using cfiCommon0
        CFI (cfiCond129) NoFunction
        CFI (cfiCond129) Conditional ??CrossCallReturnLabel_19
        CFI (cfiCond129) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond129) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond129) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond129) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond129) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond129) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond129) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond129) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond129) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond129) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond129) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond129) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond129) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond129) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond129) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond129) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond129) CFA_SP SP+0
        CFI (cfiCond129) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond130 Using cfiCommon0
        CFI (cfiCond130) NoFunction
        CFI (cfiCond130) Conditional ??CrossCallReturnLabel_20
        CFI (cfiCond130) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond130) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond130) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond130) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond130) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond130) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond130) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond130) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond130) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond130) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond130) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond130) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond130) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond130) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond130) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond130) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond130) CFA_SP SP+0
        CFI (cfiCond130) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond131 Using cfiCommon0
        CFI (cfiCond131) NoFunction
        CFI (cfiCond131) Conditional ??CrossCallReturnLabel_21
        CFI (cfiCond131) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond131) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond131) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond131) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond131) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond131) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond131) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond131) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond131) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond131) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond131) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond131) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond131) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond131) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond131) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond131) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond131) CFA_SP SP+0
        CFI (cfiCond131) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond132 Using cfiCommon0
        CFI (cfiCond132) NoFunction
        CFI (cfiCond132) Conditional ??CrossCallReturnLabel_22
        CFI (cfiCond132) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond132) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond132) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond132) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond132) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond132) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond132) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond132) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond132) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond132) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond132) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond132) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond132) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond132) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond132) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond132) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond132) CFA_SP SP+0
        CFI (cfiCond132) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond133 Using cfiCommon0
        CFI (cfiCond133) NoFunction
        CFI (cfiCond133) Conditional ??CrossCallReturnLabel_23
        CFI (cfiCond133) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond133) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond133) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond133) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond133) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond133) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond133) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond133) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond133) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond133) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond133) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond133) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond133) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond133) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond133) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond133) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond133) CFA_SP SP+0
        CFI (cfiCond133) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiPicker134 Using cfiCommon1
        CFI (cfiPicker134) NoFunction
        CFI (cfiPicker134) Picker
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        CFI Block cfiCond135 Using cfiCommon0
        CFI (cfiCond135) NoFunction
        CFI (cfiCond135) Conditional ??CrossCallReturnLabel_16
        CFI (cfiCond135) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond135) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond135) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond135) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond135) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond135) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond135) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond135) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond135) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond135) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond135) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond135) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond135) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond135) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond135) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond135) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond135) CFA_SP SP+0
        CFI (cfiCond135) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond136 Using cfiCommon0
        CFI (cfiCond136) NoFunction
        CFI (cfiCond136) Conditional ??CrossCallReturnLabel_17
        CFI (cfiCond136) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond136) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond136) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond136) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond136) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond136) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond136) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond136) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond136) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond136) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond136) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond136) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond136) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond136) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond136) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond136) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond136) CFA_SP SP+0
        CFI (cfiCond136) CFA_XSP16 add(XSP16, 35)
        CFI Block cfiCond137 Using cfiCommon0
        CFI (cfiCond137) NoFunction
        CFI (cfiCond137) Conditional ??CrossCallReturnLabel_24
        CFI (cfiCond137) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond137) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond137) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond137) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond137) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond137) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond137) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond137) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond137) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond137) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond137) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond137) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond137) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond137) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond137) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond137) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond137) CFA_SP SP+0
        CFI (cfiCond137) CFA_XSP16 add(XSP16, 18)
??Subroutine7_0:
        LCALL   ??Subroutine20_0 & 0xFFFF
??CrossCallReturnLabel_64:
        MOVX    A,@DPTR
        RET
        CFI EndBlock cfiCond126
        CFI EndBlock cfiCond127
        CFI EndBlock cfiCond128
        CFI EndBlock cfiCond129
        CFI EndBlock cfiCond130
        CFI EndBlock cfiCond131
        CFI EndBlock cfiCond132
        CFI EndBlock cfiCond133
        CFI EndBlock cfiPicker134
        CFI EndBlock cfiCond135
        CFI EndBlock cfiCond136
        CFI EndBlock cfiCond137

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine5:
        CFI Block cfiCond138 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_12
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 22)
        CFI Block cfiCond139 Using cfiCommon0
        CFI (cfiCond139) NoFunction
        CFI (cfiCond139) Conditional ??CrossCallReturnLabel_13
        CFI (cfiCond139) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond139) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond139) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond139) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond139) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond139) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond139) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond139) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond139) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond139) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond139) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond139) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond139) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond139) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond139) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond139) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond139) CFA_SP SP+0
        CFI (cfiCond139) CFA_XSP16 add(XSP16, 18)
        CFI Block cfiPicker140 Using cfiCommon1
        CFI (cfiPicker140) NoFunction
        CFI (cfiPicker140) Picker
        MOVX    @DPTR,A
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    A,@DPTR
        RET
        CFI EndBlock cfiCond138
        CFI EndBlock cfiCond139
        CFI EndBlock cfiPicker140

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine4:
        CFI Block cfiCond141 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_10
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond142 Using cfiCommon0
        CFI (cfiCond142) NoFunction
        CFI (cfiCond142) Conditional ??CrossCallReturnLabel_11
        CFI (cfiCond142) R6 load(1, XDATA, add(CFA_XSP16, literal(-16)))
        CFI (cfiCond142) VB load(1, XDATA, add(CFA_XSP16, literal(-15)))
        CFI (cfiCond142) V0 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond142) V1 load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond142) V2 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond142) V3 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond142) V4 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond142) V5 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond142) V6 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond142) V7 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond142) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond142) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond142) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond142) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond142) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond142) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond142) CFA_SP SP+0
        CFI (cfiCond142) CFA_XSP16 add(XSP16, 18)
        CFI Block cfiPicker143 Using cfiCommon1
        CFI (cfiPicker143) NoFunction
        CFI (cfiPicker143) Picker
        MOVX    @DPTR,A
        MOV     DPL,R6
        MOV     DPH,R7
        INC     DPTR
        INC     DPTR
        INC     DPTR
        RET
        CFI EndBlock cfiCond141
        CFI EndBlock cfiCond142
        CFI EndBlock cfiPicker143
// 1398 #endif // NONWK
// 1399 
// 1400 #if defined ( ZTOOL_PORT )
// 1401 /*********************************************************************
// 1402  * @fn      MTProcessAppRspMsg
// 1403  *
// 1404  * @brief
// 1405  *
// 1406  *   Process the User App Response Message
// 1407  *
// 1408  * @param   data - output serial buffer.  The first byte must be the
// 1409  *          endpoint that send this message.
// 1410  * @param   len - data length
// 1411  *
// 1412  * @return  none
// 1413  */

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1414 void MTProcessAppRspMsg( byte *pData, byte len )
MTProcessAppRspMsg:
        CFI Block cfiBlock144 Using cfiCommon0
        CFI Function MTProcessAppRspMsg
// 1415 {
        FUNCALL MTProcessAppRspMsg, MT_BuildAndSendZToolResponse
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 12, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 12, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xa
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 10)
        ; Saved register size: 10
        ; Auto size: 0
// 1416   // Send out Reset Response message
// 1417   MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + len),
// 1418                                 (SPI_RESPONSE_BIT | SPI_CMD_SYS_APP_MSG),
// 1419                                 len, pData );
        ; Setup parameters for call to function MT_BuildAndSendZToolResponse
        MOV     ?V0 + 0,R2
        MOV     ?V0 + 1,R3
        MOV     R0,#?V0 + 0
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 12)
        MOV     A,R1
        MOV     R4,A
        MOV     R2,#0x18
        MOV     R3,#0x10
        MOV     A,#0x5
        ADD     A,R1
        MOV     R1,A
        LCALL   ??Subroutine2_0 & 0xFFFF
??CrossCallReturnLabel_76:
        LJMP    ??Subroutine24_0 & 0xFFFF
        CFI EndBlock cfiBlock144
// 1420 }
// 1421 #endif // ZTOOL_PORT
// 1422 
// 1423 
// 1424 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
// 1425 #if defined ( MT_USER_TEST_FUNC )
// 1426 /*********************************************************************
// 1427  * @fn      MT_ProcessAppUserCmd
// 1428  *
// 1429  * @brief
// 1430  *
// 1431  *   Temp function for testing
// 1432  *
// 1433  * @param   data - received message
// 1434  *
// 1435  * @return  void
// 1436  */
// 1437 void MT_ProcessAppUserCmd( byte *pData) 						
// 1438 {
// 1439   uint16 app_cmd;
// 1440   byte srcEp;
// 1441   uint16 param1;
// 1442   uint16 param2;
// 1443   byte len;
// 1444   uint16 ret;
// 1445 
// 1446   ret = INVALID_TASK;     //should be changed later
// 1447 
// 1448   srcEp = *pData++;
// 1449 
// 1450   app_cmd = BUILD_UINT16( pData[1] , pData[0] );
// 1451   pData = pData + sizeof( uint16 );
// 1452 
// 1453   param1 = BUILD_UINT16( pData[1] , pData[0] );
// 1454   pData = pData + sizeof( uint16 );
// 1455 
// 1456   param2 = BUILD_UINT16( pData[1] , pData[0] );
// 1457 
// 1458   len = SPI_RESP_MSG_LEN_DEFAULT;
// 1459 
// 1460 
// 1461   switch ( app_cmd )
// 1462   {
// 1463 
// 1464 #if defined (APP_TGEN)
// 1465     case TGEN_START:
// 1466       TrafficGenApp_SendCmdMSG( param1, param2, TRAFFICGENAPP_CMD_START );
// 1467       ret = ZSUCCESS;
// 1468       break;
// 1469 
// 1470     case TGEN_STOP:
// 1471       TrafficGenApp_SendCmdMSG( param1, param2, TRAFFICGENAPP_CMD_STOP );
// 1472       ret = ZSUCCESS;
// 1473       break;
// 1474 
// 1475     case TGEN_COUNT:
// 1476       ret = TrafficGenApp_CountPkt( param1, param2 );
// 1477       return;		// so that spi_resp is not sent...
// 1478       //ret = ZSUCCESS;
// 1479       break;				
// 1480 #endif
// 1481 
// 1482 #if defined (NWK_TEST)
// 1483     case HW_TEST:
// 1484       HwApp_Start( HI_UINT16(param1), LO_UINT16(param1), HI_UINT16(param2),
// 1485                     1000, LO_UINT16(param2), 3, 0 );
// 1486       break;
// 1487 
// 1488     case HW_DISPLAY_RESULT:
// 1489       HwApp_TestInfo();
// 1490       break;
// 1491 
// 1492     case HW_SEND_STATUS:
// 1493       HwApp_SendStats();
// 1494       break;
// 1495 #endif
// 1496 
// 1497 #if defined( APP_TP ) || defined ( APP_TP2 )
// 1498   #if defined( APP_TP )
// 1499     case TP_SEND_NODATA:
// 1500       ret = TestProfileApp_SendNoData( srcEp, (byte)param1 );
// 1501       break;
// 1502   #endif // APP_TP
// 1503 			
// 1504     case TP_SEND_BUFFERTEST:
// 1505       ret = TestProfileApp_SendBufferReq( srcEp, (byte)param1 );
// 1506       break;
// 1507 			
// 1508   #if defined( APP_TP )
// 1509     case TP_SEND_UINT8:
// 1510       ret = TestProfileApp_SendUint8( srcEp, (byte)param1 );
// 1511       break;
// 1512 
// 1513     case TP_SEND_INT8:
// 1514       ret = TestProfileApp_SendInt8( srcEp, (byte)param1 );
// 1515       break;
// 1516 
// 1517     case TP_SEND_UINT16:
// 1518       ret = TestProfileApp_SendUint16( srcEp, (byte)param1 );
// 1519       break;
// 1520 
// 1521     case TP_SEND_INT16:
// 1522       ret = TestProfileApp_SendInt16( srcEp, (byte)param1 );
// 1523       break;
// 1524 
// 1525     case TP_SEND_SEMIPREC:
// 1526       ret = TestProfileApp_SendSemiPrec( srcEp, (byte)param1 );
// 1527       break;
// 1528 
// 1529     case TP_SEND_FREEFORM:
// 1530       ret = TestProfileApp_SendFreeFormReq( srcEp, (byte)param1 );
// 1531       break;
// 1532 			
// 1533   #else // APP_TP
// 1534     case TP_SEND_FREEFORM:
// 1535       ret = TestProfileApp_SendFreeFormReq(srcEp, (byte)param1, (byte)param2);
// 1536       break;
// 1537   #endif
// 1538 			
// 1539   #if defined( APP_TP )
// 1540     case TP_SEND_ABS_TIME:
// 1541       ret = TestProfileApp_SendAbsTime( srcEp, (byte)param1 );
// 1542       break;
// 1543 
// 1544     case TP_SEND_REL_TIME:
// 1545       ret = TestProfileApp_SendRelativeTime( srcEp, (byte)param1 );
// 1546       break;
// 1547 
// 1548     case TP_SEND_CHAR_STRING:
// 1549       ret = TestProfileApp_SendCharString( srcEp, (byte)param1 );
// 1550       break;
// 1551 
// 1552     case TP_SEND_OCTET_STRING:
// 1553       ret = TestProfileApp_SendOctetString( srcEp, (byte)param1 );
// 1554       break;		
// 1555   #endif // APP_TP
// 1556 				
// 1557     case TP_SET_DSTADDRESS:			
// 1558       ret = TestProfileApp_SetDestAddress(HI_UINT16(param1), LO_UINT16(param1), param2);
// 1559       break;	
// 1560 
// 1561   #if defined( APP_TP2 )
// 1562     case TP_SEND_BUFFER_GROUP:
// 1563       ret = TestProfileApp_SendBufferGroup( srcEp, (byte)param1 );
// 1564       break;
// 1565   #endif // APP_TP
// 1566 
// 1567     case TP_SEND_BUFFER:
// 1568       ret = TestProfileApp_SendBuffer( srcEp, (byte)param1 );
// 1569       break;
// 1570 				
// 1571   #if defined( APP_TP )
// 1572     case TP_SEND_MULT_KVP_8BIT:
// 1573       TestProfileApp_SendMultiKVP_8bit( srcEp, (byte)param1 );
// 1574       ret = ZSuccess;
// 1575       break;
// 1576 
// 1577     case TP_SEND_MULT_KVP_16BIT:
// 1578       TestProfileApp_SendMultiKVP_16bit( srcEp, (byte)param1 );
// 1579       ret = ZSuccess;
// 1580       break;
// 1581 
// 1582     case TP_SEND_MULT_KVP_TIME:
// 1583       TestProfileApp_SendMultiKVP_Time( srcEp, (byte)param1 );
// 1584       ret = ZSuccess;
// 1585       break;
// 1586 
// 1587     case TP_SEND_MULT_KVP_STRING:
// 1588       TestProfileApp_SendMultiKVP_String( srcEp, (byte)param1 );
// 1589       ret = ZSuccess;
// 1590       break;
// 1591 
// 1592     case TP_SEND_MULTI_KVP_STR_TIME:
// 1593       ret = ZSuccess;
// 1594       TestProfileApp_SendMultiKVP_String_Time( srcEp, (byte)param1 );
// 1595       break;
// 1596   #endif // APP_TP
// 1597 				
// 1598     case TP_SEND_COUNTED_PKTS:
// 1599       TestProfileApp_SendCountedPktsReq(HI_UINT16(param1), LO_UINT16(param1), param2);
// 1600       ret = ZSuccess;
// 1601       break;
// 1602 
// 1603     case TP_SEND_RESET_COUNTER:
// 1604       TestProfileApp_CountedPakts_ResetCounterReq( (byte)param1 );
// 1605       ret = ZSuccess;
// 1606       break;
// 1607 
// 1608     case TP_SEND_GET_COUNTER:
// 1609       TestProfileApp_CountedPakts_GetCounterReq( srcEp, (byte)param1 );
// 1610       ret = ZSuccess;
// 1611       break;
// 1612 				
// 1613     case TP_SET_PERMIT_JOIN:
// 1614   #if defined ( RTR_NWK )
// 1615       NLME_PermitJoiningRequest( (byte)param1 );
// 1616       ret = ZSuccess;
// 1617   #else
// 1618       ret = ZFailure;
// 1619   #endif
// 1620       break;
// 1621 
// 1622   #if defined ( APP_TP2 )
// 1623     case TP_ADD_GROUP:
// 1624       ret = TestProfileApp_SetGroup( srcEp, param1 );
// 1625       break;
// 1626 
// 1627     case TP_REMOVE_GROUP:
// 1628       ret = TestProfileApp_RemoveGroup( srcEp, param1 );
// 1629       break;
// 1630 
// 1631     case TP_SEND_UPDATE_KEY:
// 1632       ret = TestProfileApp_UpdateKey( srcEp, (uint8)param1, param2 );
// 1633       break;
// 1634 
// 1635     case TP_SEND_SWITCH_KEY:
// 1636       ret = TestProfileApp_SwitchKey(  srcEp, (uint8)param1, param2 );
// 1637       break;
// 1638 			
// 1639     case TP_SEND_BUFFERTEST_GROUP:
// 1640       ret = TestProfileApp_SendBufferGroupReq( srcEp, (byte)param1 );
// 1641       break;
// 1642 
// 1643     case TP_SEND_ROUTE_DISC_REQ:
// 1644       ret = TestProfileApp_SendRouteDiscReq( srcEp, param1,
// 1645                                   HI_UINT16( param2 ), LO_UINT16( param2 ) );
// 1646       break;
// 1647 
// 1648     case TP_SEND_ROUTE_DISCOVERY:
// 1649 #if defined ( RTR_NWK )
// 1650       ret = TestProfileApp_SendRouteDiscovery( param1,
// 1651                                   HI_UINT16( param2 ), LO_UINT16( param2 ) );
// 1652 #endif
// 1653       break;
// 1654 
// 1655   #endif // APP_TP2
// 1656 
// 1657 #endif  // APP_TP || APP_TP2
// 1658 
// 1659 #if defined ( OSAL_TOTAL_MEM )
// 1660     case OSAL_MEM_STACK_HIGH_WATER:
// 1661     case OSAL_MEM_HEAP_HIGH_WATER:
// 1662       if ( app_cmd == OSAL_MEM_STACK_HIGH_WATER)
// 1663         param1 = osal_stack_used();
// 1664       else
// 1665         param1 = osal_heap_high_water();
// 1666       pData[0] = HI_UINT16( param1 );
// 1667       pData[1] = LO_UINT16( param1 );
// 1668 
// 1669       // The pData for this response will only send one byte,
// 1670       // so we are going to call it twice.
// 1671       //        MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + sizeof( uint16 )),
// 1672       //                                    (SPI_CMD_USER_TEST | SPI_RESPONSE_BIT),
// 1673       //                                    sizeof( uint16 ), pData );
// 1674       MT_SendSPIRespMsg( pData[0], SPI_CMD_USER_TEST, SPI_RESP_MSG_LEN_DEFAULT, 1);
// 1675       MT_SendSPIRespMsg( pData[1], SPI_CMD_USER_TEST, SPI_RESP_MSG_LEN_DEFAULT, 1);
// 1676       return;
// 1677 #endif
// 1678 
// 1679 #if defined ( APP_DEBUG )
// 1680     case DEBUG_GET:
// 1681       DebugApp_SendQuery( param1 );
// 1682       ret = ZSUCCESS;
// 1683       break;
// 1684 #endif
// 1685 
// 1686 #if defined ( APP_TP2 )
// 1687     case TP_SEND_BCAST_RSP:
// 1688       ret = TestProfileApp_SendBcastRsp( srcEp, (byte)param1 );
// 1689       break;
// 1690 #endif
// 1691 			
// 1692     default:
// 1693       break;
// 1694   }
// 1695 
// 1696   MT_SendSPIRespMsg( ( byte )ret, SPI_CMD_USER_TEST, len, 1);
// 1697 
// 1698 }
// 1699 #endif // MT_USER_TEST_FUNC
// 1700 #endif // ZTOOL
// 1701 
// 1702 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
// 1703 /***************************************************************************************************
// 1704  * @fn      MT_RAMRead
// 1705  *
// 1706  * @brief
// 1707  *
// 1708  *   Process Serial Message.
// 1709  *
// 1710  * @param   UINT16 addr - address to read from
// 1711  * @param   pData - pointer to buffer to put read data
// 1712  *
// 1713  * @return  ZSuccess or ZFailure
// 1714  *
// 1715  * @MT SPI_CMD_SYS_RAM_READ
// 1716  *
// 1717  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1718 byte MT_RAMRead( UINT16 addr, byte *pData  )
MT_RAMRead:
        CFI Block cfiBlock145 Using cfiCommon0
        CFI Function MT_RAMRead
// 1719 {
        PUSH    DPL
        CFI DPL0 Frame(CFA_SP, 4)
        CFI CFA_SP SP+-4
        PUSH    DPH
        CFI DPH0 Frame(CFA_SP, 5)
        CFI CFA_SP SP+-5
        ; Saved register size: 2
        ; Auto size: 0
// 1720   byte *pAddr;
// 1721 
// 1722   if ( IS_MEM_VALID( addr ) )
        CLR     C
        MOV     A,R3
        SUBB    A,#-0x20
        JC      ??MT_RAMRead_0
// 1723   {
// 1724     pAddr = (byte *)addr;
// 1725     *pData = *pAddr;
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    A,@DPTR
        MOV     DPL,R4
        MOV     DPH,R5
        MOVX    @DPTR,A
// 1726     return ( (byte)ZSuccess );
        MOV     R1,#0x0
        SJMP    ??MT_RAMRead_1
// 1727   }
// 1728   else
// 1729   {
// 1730     *pData = 0;
??MT_RAMRead_0:
        CLR     A
        MOV     DPL,R4
        MOV     DPH,R5
        MOVX    @DPTR,A
// 1731     return ( (byte)ZFailure );
        MOV     R1,#0x1
        CFI EndBlock cfiBlock145
??MT_RAMRead_1:
        REQUIRE ?Subroutine23
        ; // Fall through to label ?Subroutine23
// 1732   }
// 1733 }

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine23:
        CFI Block cfiBlock146 Using cfiCommon0
        CFI NoFunction
        CFI CFA_SP SP+-5
        CFI DPL0 Frame(CFA_SP, 4)
        CFI DPH0 Frame(CFA_SP, 5)
        POP     DPH
        CFI CFA_SP SP+-4
        CFI DPH0 SameValue
        POP     DPL
        CFI CFA_SP SP+-3
        CFI DPL0 SameValue
        LJMP    ?BRET
        CFI EndBlock cfiBlock146
// 1734 #endif
// 1735 
// 1736 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
// 1737 /***************************************************************************************************
// 1738  * @fn      MT_RAMWrite
// 1739  *
// 1740  * @brief
// 1741  *
// 1742  *   Process Serial Message.
// 1743  *
// 1744  * @param   UINT16 addr - address to write at
// 1745  * @param   byte val  - values to fill in the above address and the next
// 1746  *
// 1747  * @return  ZSuccess or ZFailure
// 1748  *
// 1749  * @MT SPI_CMD_SYS_RAM_WRITE
// 1750  *
// 1751  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1752 byte MT_RAMWrite( UINT16 addr, byte val )
MT_RAMWrite:
        CFI Block cfiBlock147 Using cfiCommon0
        CFI Function MT_RAMWrite
// 1753 {
        PUSH    DPL
        CFI DPL0 Frame(CFA_SP, 4)
        CFI CFA_SP SP+-4
        PUSH    DPH
        CFI DPH0 Frame(CFA_SP, 5)
        CFI CFA_SP SP+-5
        ; Saved register size: 2
        ; Auto size: 0
// 1754   if ( IS_MEM_VALID( addr ) )
        CLR     C
        MOV     A,R3
        SUBB    A,#-0x20
        JC      ??MT_RAMWrite_0
// 1755   {
// 1756     *((byte*)(addr)) = val;
        MOV     A,R1
        MOV     DPL,R2
        MOV     DPH,R3
        MOVX    @DPTR,A
// 1757     return ( (byte)ZSuccess );
        MOV     R1,#0x0
        SJMP    ??MT_RAMWrite_1
// 1758   }
// 1759   else
// 1760     return ( (byte)ZFailure );
??MT_RAMWrite_0:
        MOV     R1,#0x1
??MT_RAMWrite_1:
        SJMP    ?Subroutine23
        CFI EndBlock cfiBlock147
// 1761 }
// 1762 #endif
// 1763 
// 1764 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
// 1765 /***************************************************************************************************
// 1766  * @fn      MT_SetDebugThreshold
// 1767  *
// 1768  * @brief
// 1769  *
// 1770  *   Set Debug Threshold for software components.
// 1771  *
// 1772  * @param   comp_id   - software component ID.
// 1773  * @param   threshold - threshold value for reporting debug messages.
// 1774  *
// 1775  * @return  ZSuccess
// 1776  *
// 1777  * @MT SPI_CMD_SYS_SET_DEBUG_THRESHOLD
// 1778  *
// 1779  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1780 byte MT_SetDebugThreshold( byte compID, byte threshold )
MT_SetDebugThreshold:
        CFI Block cfiBlock148 Using cfiCommon0
        CFI Function MT_SetDebugThreshold
// 1781 {
        PUSH    DPL
        CFI DPL0 Frame(CFA_SP, 4)
        CFI CFA_SP SP+-4
        PUSH    DPH
        CFI DPH0 Frame(CFA_SP, 5)
        CFI CFA_SP SP+-5
        ; Saved register size: 2
        ; Auto size: 0
// 1782   // *** RKJ - for now if we get any threshold message, set it on
// 1783   debugThreshold = threshold;
        MOV     A,R2
        MOV     DPTR,#debugThreshold
        MOVX    @DPTR,A
// 1784   debugCompId = compID;
        MOV     A,R1
        MOV     DPTR,#debugCompId
        MOVX    @DPTR,A
// 1785 
// 1786   return ( (byte)ZSuccess );
        MOV     R1,#0x0
        SJMP    ?Subroutine23
        CFI EndBlock cfiBlock148
// 1787 }
// 1788 #endif
// 1789 
// 1790 /***************************************************************************************************
// 1791  * @fn      MT_Reset
// 1792  *
// 1793  * @brief
// 1794  *
// 1795  *   Reset/reprogram the device.
// 1796  *
// 1797  * @param   typID: 0=reset, 1=serial bootloader
// 1798  *
// 1799  * @return  void
// 1800  *
// 1801  * @MT SPI_CMD_SYS_RESET
// 1802  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1803 void MT_Reset( byte typID )
MT_Reset:
        CFI Block cfiBlock149 Using cfiCommon0
        CFI Function MT_Reset
// 1804 {
        MOV     A,#-0xc
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 12)
        ; Saved register size: 12
        ; Auto size: 0
// 1805   if ( typID )
        MOV     A,R1
        CLR     0xa8.7
        JZ      ??MT_Reset_0
// 1806   {
// 1807     // Jump to bootloader
// 1808     BootLoader();
        MOV     DPTR,#__Constant_53544159
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_X
        MOV     DPTR,#-0x2000
        MOV     R0,#?V0 + 0
        LCALL   ?L_MOV_TO_X
        MOV     0xc9,#-0x55
        MOV     0xc9,#0x5b
??MT_Reset_1:
        NOP
        SJMP    ??MT_Reset_1
// 1809   }
// 1810   else
// 1811   {
// 1812     // Restart this program
// 1813     SystemReset();
??MT_Reset_0:
        MOV     0xc9,#-0x55
        MOV     0xc9,#0x5b
??MT_Reset_2:
        NOP
        SJMP    ??MT_Reset_2
        CFI EndBlock cfiBlock149
        REQUIRE mboxMsg
        REQUIRE _A_IEN0
        REQUIRE WDCTL
// 1814   }
// 1815 }
// 1816 
// 1817 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
// 1818 /***************************************************************************************************
// 1819  * @fn      MT_SendErrorNotification
// 1820  *
// 1821  * @brief
// 1822  *
// 1823  *   Send Error Notofication Message to Test Tool.
// 1824  *
// 1825  * @param   byte err
// 1826  *
// 1827  * @return  void
// 1828  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1829 void MT_SendErrorNotification( byte err )
MT_SendErrorNotification:
        CFI Block cfiBlock150 Using cfiCommon0
        CFI Function MT_SendErrorNotification
// 1830 {
        FUNCALL MT_SendErrorNotification, MT_BuildAndSendZToolResponse
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 13, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 13, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xa
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 10)
        ; Saved register size: 10
        ; Auto size: 1
        MOV     A,#-0x1
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 11)
        MOV     A,R1
        LCALL   ?Subroutine3 & 0xFFFF
// 1831   MT_BuildAndSendZToolResponse( (SPI_0DATA_MSG_LEN + 1),
// 1832                               (SPI_RESPONSE_BIT | SPI_CMD_SYS_RAM_WRITE),
// 1833                               1, &err );
??CrossCallReturnLabel_9:
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 13)
        MOV     R4,#0x1
        MOV     R2,#0x2
        LJMP    ?Subroutine24 & 0xFFFF
        CFI EndBlock cfiBlock150
// 1834 }

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine3:
        CFI Block cfiCond151 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_8
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 11)
        CFI Block cfiCond152 Using cfiCommon0
        CFI (cfiCond152) NoFunction
        CFI (cfiCond152) Conditional ??CrossCallReturnLabel_9
        CFI (cfiCond152) R6 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond152) VB load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond152) V0 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond152) V1 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond152) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond152) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond152) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond152) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond152) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond152) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond152) CFA_SP SP+0
        CFI (cfiCond152) CFA_XSP16 add(XSP16, 11)
        CFI Block cfiPicker153 Using cfiCommon1
        CFI (cfiPicker153) NoFunction
        CFI (cfiPicker153) Picker
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    @DPTR,A
        ; Setup parameters for call to function MT_BuildAndSendZToolResponse
        ; Setup parameters for call to function MT_BuildAndSendZToolResponse
        MOV     ?V0 + 0,DPL
        MOV     ?V0 + 1,DPH
        MOV     R0,#?V0 + 0
        RET
        CFI EndBlock cfiCond151
        CFI EndBlock cfiCond152
        CFI EndBlock cfiPicker153
// 1835 #endif
// 1836 
// 1837 /***************************************************************************************************
// 1838  * @fn      MT_ReverseBytes
// 1839  *
// 1840  * @brief
// 1841  *
// 1842  *   Reverses bytes within an array
// 1843  *
// 1844  * @param   data - ptr to data buffer to reverse
// 1845  * @param    len - number of bytes in buffer
// 1846  *
// 1847  * @return  void
// 1848  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1849 void MT_ReverseBytes( byte *pData, byte len )
MT_ReverseBytes:
        CFI Block cfiBlock154 Using cfiCommon0
        CFI Function MT_ReverseBytes
// 1850 {
        MOV     A,#-0xc
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 12)
        ; Saved register size: 12
        ; Auto size: 0
        MOV     A,R1
        MOV     R4,A
// 1851   byte i,j;
// 1852   byte temp;
// 1853 
// 1854   for ( i = 0, j = len-1; len > 1; len-=2 ) {
        MOV     R5,#0x0
        MOV     A,#-0x1
        ADD     A,R4
        MOV     ?V0 + 2,A
        SJMP    ??MT_ReverseBytes_0
// 1855     temp = pData[i];
??MT_ReverseBytes_1:
        MOV     ?V0 + 0,R5
        MOV     A,R2
        ADD     A,?V0 + 0
        MOV     R0,A
        MOV     A,R3
        ADDC    A,#0x0
        MOV     R1,A
        MOV     DPL,R0
        MOV     DPH,R1
        MOVX    A,@DPTR
        MOV     ?V0 + 3,A
// 1856     pData[i++] = pData[j];
        MOV     ?V0 + 0,?V0 + 2
        MOV     A,R2
        ADD     A,?V0 + 0
        MOV     R6,A
        MOV     A,R3
        ADDC    A,#0x0
        MOV     R7,A
        MOV     DPL,R6
        MOV     DPH,R7
        LCALL   ?Subroutine11 & 0xFFFF
??CrossCallReturnLabel_38:
        INC     R5
// 1857     pData[j--] = temp;
        MOV     DPL,R6
        MOV     DPH,R7
        MOV     A,?V0 + 3
        MOVX    @DPTR,A
        DEC     ?V0 + 2
// 1858   }
        DEC     R4
        DEC     R4
??MT_ReverseBytes_0:
        MOV     A,R4
        CLR     C
        SUBB    A,#0x2
        JNC     ??MT_ReverseBytes_1
// 1859 }
        LJMP    ?Subroutine29 & 0xFFFF
        CFI EndBlock cfiBlock154

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine11:
        CFI Block cfiCond155 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_36
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond156 Using cfiCommon0
        CFI (cfiCond156) NoFunction
        CFI (cfiCond156) Conditional ??CrossCallReturnLabel_37
        CFI (cfiCond156) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond156) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond156) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond156) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond156) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond156) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond156) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond156) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond156) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond156) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond156) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond156) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond156) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond156) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond156) CFA_SP SP+0
        CFI (cfiCond156) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond157 Using cfiCommon0
        CFI (cfiCond157) NoFunction
        CFI (cfiCond157) Conditional ??CrossCallReturnLabel_38
        CFI (cfiCond157) R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond157) VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond157) V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond157) V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond157) V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond157) V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond157) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond157) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond157) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond157) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond157) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond157) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond157) CFA_SP SP+0
        CFI (cfiCond157) CFA_XSP16 add(XSP16, 12)
        CFI Block cfiPicker158 Using cfiCommon1
        CFI (cfiPicker158) NoFunction
        CFI (cfiPicker158) Picker
        LCALL   ?Subroutine21 & 0xFFFF
??CrossCallReturnLabel_68:
        RET
        CFI EndBlock cfiCond155
        CFI EndBlock cfiCond156
        CFI EndBlock cfiCond157
        CFI EndBlock cfiPicker158

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine21:
        CFI Block cfiCond159 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_66, ??CrossCallReturnLabel_6
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond160 Using cfiCommon0
        CFI (cfiCond160) NoFunction
        CFI (cfiCond160) Conditional ??CrossCallReturnLabel_66, ??CrossCallReturnLabel_7
        CFI (cfiCond160) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond160) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond160) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond160) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond160) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond160) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond160) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond160) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond160) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond160) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond160) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond160) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond160) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond160) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond160) CFA_SP SP+0
        CFI (cfiCond160) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond161 Using cfiCommon0
        CFI (cfiCond161) NoFunction
        CFI (cfiCond161) Conditional ??CrossCallReturnLabel_67, ??CrossCallReturnLabel_6
        CFI (cfiCond161) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond161) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond161) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond161) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond161) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond161) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond161) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond161) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond161) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond161) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond161) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond161) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond161) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond161) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond161) CFA_SP SP+0
        CFI (cfiCond161) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond162 Using cfiCommon0
        CFI (cfiCond162) NoFunction
        CFI (cfiCond162) Conditional ??CrossCallReturnLabel_67, ??CrossCallReturnLabel_7
        CFI (cfiCond162) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond162) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond162) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond162) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond162) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond162) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond162) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond162) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond162) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond162) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond162) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond162) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond162) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond162) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond162) CFA_SP SP+0
        CFI (cfiCond162) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond163 Using cfiCommon0
        CFI (cfiCond163) NoFunction
        CFI (cfiCond163) Conditional ??CrossCallReturnLabel_68, ??CrossCallReturnLabel_36
        CFI (cfiCond163) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond163) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond163) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond163) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond163) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond163) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond163) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond163) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond163) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond163) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond163) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond163) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond163) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond163) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond163) CFA_SP SP+0
        CFI (cfiCond163) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond164 Using cfiCommon0
        CFI (cfiCond164) NoFunction
        CFI (cfiCond164) Conditional ??CrossCallReturnLabel_68, ??CrossCallReturnLabel_37
        CFI (cfiCond164) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond164) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond164) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond164) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond164) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond164) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond164) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond164) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond164) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond164) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond164) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond164) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond164) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond164) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond164) CFA_SP SP+0
        CFI (cfiCond164) CFA_XSP16 add(XSP16, 25)
        CFI Block cfiCond165 Using cfiCommon0
        CFI (cfiCond165) NoFunction
        CFI (cfiCond165) Conditional ??CrossCallReturnLabel_68, ??CrossCallReturnLabel_38
        CFI (cfiCond165) R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond165) VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond165) V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond165) V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond165) V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond165) V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond165) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond165) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond165) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond165) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond165) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond165) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond165) CFA_SP SP+0
        CFI (cfiCond165) CFA_XSP16 add(XSP16, 12)
        CFI Block cfiPicker166 Using cfiCommon1
        CFI (cfiPicker166) NoFunction
        CFI (cfiPicker166) Picker
        MOVX    A,@DPTR
        MOV     DPL,R0
        MOV     DPH,R1
        MOVX    @DPTR,A
        RET
        CFI EndBlock cfiCond159
        CFI EndBlock cfiCond160
        CFI EndBlock cfiCond161
        CFI EndBlock cfiCond162
        CFI EndBlock cfiCond163
        CFI EndBlock cfiCond164
        CFI EndBlock cfiCond165
        CFI EndBlock cfiPicker166
// 1860 
// 1861 /***************************************************************************************************
// 1862  * @fn      MT_SendSPIRespMsg
// 1863  *
// 1864  * @brief
// 1865  *
// 1866  *   This function is used to process messages in the queue
// 1867  *
// 1868  * @param   none
// 1869  *
// 1870  * @return  void
// 1871  ***************************************************************************************************/

        RSEG BANKED_CODE:CODE:NOROOT(0)
// 1872 void MT_SendSPIRespMsg( byte ret, uint16 cmd_id, byte msgLen, byte respLen)
MT_SendSPIRespMsg:
        CFI Block cfiBlock167 Using cfiCommon0
        CFI Function MT_SendSPIRespMsg
// 1873 {
        FUNCALL MT_SendSPIRespMsg, osal_mem_alloc
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_SendSPIRespMsg, MT_BuildSPIMsg
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 17, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 17, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_SendSPIRespMsg, HalUARTWrite
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        FUNCALL MT_SendSPIRespMsg, osal_mem_free
        LOCFRAME ISTACK, 0, STACK
        LOCFRAME PSTACK, 0, STACK
        LOCFRAME XSTACK, 15, STACK
        LOCFRAME IOVERLAY, 0, STATIC
        LOCFRAME DOVERLAY, 0, STATIC
        ARGFRAME ISTACK, 0, STACK
        ARGFRAME PSTACK, 0, STACK
        ARGFRAME XSTACK, 15, STACK
        ARGFRAME IOVERLAY, 0, STATIC
        ARGFRAME DOVERLAY, 0, STATIC
        MOV     A,#-0xe
        LCALL   ?BANKED_ENTER_XDATA
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 14)
        ; Saved register size: 14
        ; Auto size: 1
        MOV     A,#-0x1
        LCALL   ?ALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 15)
        MOV     A,R1
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOVX    @DPTR,A
        MOV     ?V0 + 4,R2
        MOV     ?V0 + 5,R3
        MOV     ?V0 + 0,R4
        MOV     ?V0 + 1,R5
// 1874   byte *msgPtr;
// 1875 
// 1876   msgPtr = osal_mem_alloc( msgLen );
        ; Setup parameters for call to function osal_mem_alloc
        MOV     A,R4
        LCALL   ?Subroutine15 & 0xFFFF
// 1877   if ( msgPtr )
??CrossCallReturnLabel_48:
        JNZ     ??MT_SendSPIRespMsg_0
        MOV     A,R7
??MT_SendSPIRespMsg_0:
        JZ      ??CrossCallReturnLabel_45
// 1878   {
// 1879 #if defined (ZTOOL_P1) || defined (ZTOOL_P2)
// 1880     MT_BuildSPIMsg( (SPI_RESPONSE_BIT | cmd_id), msgPtr, respLen, &ret );
        ; Setup parameters for call to function MT_BuildSPIMsg
        MOV     DPL,?XSP + 0
        MOV     DPH,?XSP + 1
        MOV     ?V0 + 2,DPL
        MOV     ?V0 + 3,DPH
        MOV     R0,#?V0 + 2
        LCALL   ?PUSH_XSTACK_I_TWO
        CFI CFA_XSP16 add(XSP16, 17)
        MOV     R1,?V0 + 1
        MOV     A,R6
        MOV     R4,A
        MOV     A,R7
        MOV     R5,A
        MOV     R2,?V0 + 4
        MOV     A,#0x10
        ORL     A,?V0 + 5
        MOV     R3,A
        LCALL   ?Subroutine16 & 0xFFFF
??CrossCallReturnLabel_52:
        LCALL   ?DEALLOC_XSTACK8
        CFI CFA_XSP16 add(XSP16, 15)
// 1881     HalUARTWrite ( SPI_MGR_DEFAULT_PORT, msgPtr, msgLen );
        ; Setup parameters for call to function HalUARTWrite
        MOV     R4,?V0 + 0
        LCALL   ?Subroutine13 & 0xFFFF
// 1882 #endif
// 1883 
// 1884     osal_mem_free( msgPtr );
// 1885   }
// 1886 }
??CrossCallReturnLabel_45:
        LJMP    ?Subroutine25 & 0xFFFF
        CFI EndBlock cfiBlock167

        RSEG BANKED_CODE:CODE:NOROOT(0)
?Subroutine15:
        CFI Block cfiCond168 Using cfiCommon0
        CFI NoFunction
        CFI Conditional ??CrossCallReturnLabel_47
        CFI R6 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI VB load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI V0 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI V1 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI V2 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI V3 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI CFA_SP SP+0
        CFI CFA_XSP16 add(XSP16, 12)
        CFI Block cfiCond169 Using cfiCommon0
        CFI (cfiCond169) NoFunction
        CFI (cfiCond169) Conditional ??CrossCallReturnLabel_48
        CFI (cfiCond169) R6 load(1, XDATA, add(CFA_XSP16, literal(-14)))
        CFI (cfiCond169) VB load(1, XDATA, add(CFA_XSP16, literal(-13)))
        CFI (cfiCond169) V0 load(1, XDATA, add(CFA_XSP16, literal(-12)))
        CFI (cfiCond169) V1 load(1, XDATA, add(CFA_XSP16, literal(-11)))
        CFI (cfiCond169) V2 load(1, XDATA, add(CFA_XSP16, literal(-10)))
        CFI (cfiCond169) V3 load(1, XDATA, add(CFA_XSP16, literal(-9)))
        CFI (cfiCond169) V4 load(1, XDATA, add(CFA_XSP16, literal(-8)))
        CFI (cfiCond169) V5 load(1, XDATA, add(CFA_XSP16, literal(-7)))
        CFI (cfiCond169) R7 load(1, XDATA, add(CFA_XSP16, literal(-6)))
        CFI (cfiCond169) ?RET_LOW load(1, XDATA, add(CFA_XSP16, literal(-5)))
        CFI (cfiCond169) ?RET_HIGH load(1, XDATA, add(CFA_XSP16, literal(-4)))
        CFI (cfiCond169) ?BRET_EXT load(1, XDATA, add(CFA_XSP16, literal(-3)))
        CFI (cfiCond169) DPL0 load(1, XDATA, add(CFA_XSP16, literal(-2)))
        CFI (cfiCond169) DPH0 load(1, XDATA, add(CFA_XSP16, literal(-1)))
        CFI (cfiCond169) CFA_SP SP+0
        CFI (cfiCond169) CFA_XSP16 add(XSP16, 15)
        CFI Block cfiPicker170 Using cfiCommon1
        CFI (cfiPicker170) NoFunction
        CFI (cfiPicker170) Picker
        MOV     R2,A
        MOV     R3,#0x0
        LCALL   ??osal_mem_alloc?relay
        MOV     ?V0 + 2,R2
        MOV     ?V0 + 3,R3
        MOV     R6,?V0 + 2
        MOV     R7,?V0 + 3
        MOV     A,R6
        RET
        CFI EndBlock cfiCond168
        CFI EndBlock cfiCond169
        CFI EndBlock cfiPicker170

        RSEG XDATA_ID:CODE:NOROOT(0)
        DATA
`?<Initializer for <Constant "1.00 (F8W1.4.3)">`:
        DB "1.00 (F8W1.4.3)"

        RSEG XDATA_ID:CODE:NOROOT(0)
        DATA
`?<Initializer for <Constant "1.10 (F8W1.4.3)">`:
        DB "1.10 (F8W1.4.3)"

        RSEG XDATA_ID:CODE:NOROOT(0)
        DATA
`?<Initializer for MTVersionString>`:
        DW `?<Constant "1.00 (F8W1.4.3)">`, `?<Constant "1.10 (F8W1.4.3)">`

        RSEG XDATA_ID:CODE:NOROOT(0)
        DATA
`?<Initializer for __Constant_3e8>`:
        DD 1000

        RSEG XDATA_ID:CODE:NOROOT(0)
        DATA
`?<Initializer for __Constant_53544159>`:
        DD 1398030681

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_TaskInit?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_TaskInit

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_IndReset?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_IndReset

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessEvent?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessEvent

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_BuildSPIMsg?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_BuildSPIMsg

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_BuildAndSendZToolResponse?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_BuildAndSendZToolResponse

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_BuildAndSendZToolCB?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_BuildAndSendZToolCB

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessCommand?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessCommand

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessDebugMsg?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessDebugMsg

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessDebugStr?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessDebugStr

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessSetNV?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessSetNV

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessGetNV?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessGetNV

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessGetNvInfo?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessGetNvInfo

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessGetDeviceInfo?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessGetDeviceInfo

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ProcessSerialCommand?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ProcessSerialCommand

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MTProcessLedControl?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MTProcessLedControl

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MTProcessAppMsg?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MTProcessAppMsg

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MTProcessAppRspMsg?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MTProcessAppRspMsg

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_RAMRead?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_RAMRead

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_RAMWrite?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_RAMWrite

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_SetDebugThreshold?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_SetDebugThreshold

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_Reset?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_Reset

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_SendErrorNotification?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_SendErrorNotification

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_ReverseBytes?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_ReverseBytes

        RSEG BANK_RELAYS:CODE:REORDER:NOROOT(0)
??MT_SendSPIRespMsg?relay:
        LCALL   ?BDISPATCH
        DATA
        DC24    MT_SendSPIRespMsg

        END
// 1887 
// 1888 #endif  // MT_TASK
// 1889 
// 1890 /***************************************************************************************************
// 1891 ***************************************************************************************************/
// 
// 3 816 bytes in segment BANKED_CODE
//   144 bytes in segment BANK_RELAYS
//     2 bytes in segment SFR_AN
//     8 bytes in segment XDATA_AN
//    44 bytes in segment XDATA_I
//    44 bytes in segment XDATA_ID
//    13 bytes in segment XDATA_Z
// 
// 3 996 bytes of CODE  memory (+  8 bytes shared)
//     0 bytes of DATA  memory (+  2 bytes shared)
//    49 bytes of XDATA memory (+ 16 bytes shared)
//
//Errors: none
//Warnings: none
