###############################################################################
#                                                                             #
# IAR 8051 C/C++ Compiler V7.30B/W32                    19/May/2010  09:38:58 #
# 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\Components #
#                          \stack\nwk\nwk_globals.c                           #
#    Command line       =  -f "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projec #
#                          ts\zstack\Samples\Location\CC2430DB\..\..\..\Tools #
#                          \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\Samples\Location\CC2430DB\..\..\..\Tools\CC #
#                          2430DB\f8wConfig.cfg" (-DSECURE=1                  #
#                          -DDEFAULT_CHANLIST=0x04000000                      #
#                          -DZDAPP_CONFIG_PAN_ID=0x00FF                       #
#                          -DNWK_START_DELAY=100 -DEXTENDED_JOINING_RANDOM_MA #
#                          SK=0x007F -DBEACON_REQUEST_DELAY=100               #
#                          -DBEACON_REQ_DELAY_MASK=0x00FF                     #
#                          -DROUTE_EXPIRY_TIME=30 -DAPSC_ACK_WAIT_DURATION_PO #
#                          LLED=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\Components\stack\nw #
#                          k\nwk_globals.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\Sam #
#                          ples\Location\CC2430DB\LocDongle\List\" -lA        #
#                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects\ #
#                          zstack\Samples\Location\CC2430DB\LocDongle\List\"  #
#                          --diag_suppress Pe001,Pa010 --diag_remark pe550    #
#                          -o "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projec #
#                          ts\zstack\Samples\Location\CC2430DB\LocDongle\Obj\ #
#                          " -e --require_prototypes -z9 --no_code_motion     #
#                          --debug --core=plain --dptr=16,1                   #
#                          --data_model=large --code_model=banked             #
#                          --calling_convention=xdata_reentrant               #
#                          --place_constants=data --nr_virtual_regs 8 -I      #
#                          "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects\ #
#                          zstack\Samples\Location\CC2430DB\" -I "C:\Texas    #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\SOURCE\" -I "C:\Texas    #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\ZMAIN\TI2430DB\"   #
#                          -I "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projec #
#                          ts\zstack\Samples\Location\CC2430DB\..\..\..\..\WX #
#                          L\INCLUDE\" -I "C:\Texas                           #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\M #
#                          T\" -I "C:\Texas Instruments\ZStack-1.4.3-1.2.1\Pr #
#                          ojects\zstack\Samples\Location\CC2430DB\..\..\..\. #
#                          .\..\COMPONENTS\HAL\INCLUDE\" -I "C:\Texas         #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\H #
#                          AL\TARGET\CC2430EB\" -I "C:\Texas                  #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\O #
#                          SAL\MCU\CCSOC\" -I "C:\Texas                       #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\O #
#                          SAL\INCLUDE\" -I "C:\Texas                         #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\S #
#                          TACK\AF\" -I "C:\Texas Instruments\ZStack-1.4.3-1. #
#                          2.1\Projects\zstack\Samples\Location\CC2430DB\..\. #
#                          .\..\..\..\COMPONENTS\STACK\NWK\" -I "C:\Texas     #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\S #
#                          TACK\SEC\" -I "C:\Texas Instruments\ZStack-1.4.3-1 #
#                          .2.1\Projects\zstack\Samples\Location\CC2430DB\..\ #
#                          ..\..\..\..\COMPONENTS\STACK\SYS\" -I "C:\Texas    #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\S #
#                          TACK\ZDO\" -I "C:\Texas Instruments\ZStack-1.4.3-1 #
#                          .2.1\Projects\zstack\Samples\Location\CC2430DB\..\ #
#                          ..\..\..\..\COMPONENTS\ZMAC\F8W\" -I "C:\Texas     #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\Z #
#                          MAC\" -I "C:\Texas Instruments\ZStack-1.4.3-1.2.1\ #
#                          Projects\zstack\Samples\Location\CC2430DB\..\..\.. #
#                          \..\..\COMPONENTS\SERVICES\SADDR\" -I "C:\Texas    #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\S #
#                          ERVICES\SDATA\" -I "C:\Texas                       #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\M #
#                          AC\INCLUDE\" -I "C:\Texas                          #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\M #
#                          AC\HIGH_LEVEL\" -I "C:\Texas                       #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\M #
#                          AC\LOW_LEVEL\SRF03\" -I "C:\Texas                  #
#                          Instruments\ZStack-1.4.3-1.2.1\Projects\zstack\Sam #
#                          ples\Location\CC2430DB\..\..\..\..\..\COMPONENTS\M #
#                          AC\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\z #
#                          stack\Samples\Location\CC2430DB\LocDongle\List\nwk #
#                          _globals.lst                                       #
#    Object file        =  C:\Texas Instruments\ZStack-1.4.3-1.2.1\Projects\z #
#                          stack\Samples\Location\CC2430DB\LocDongle\Obj\nwk_ #
#                          globals.r51                                        #
#                                                                             #
#                                                                             #
###############################################################################

C:\Texas Instruments\ZStack-1.4.3-1.2.1\Components\stack\nwk\nwk_globals.c
      1          /**************************************************************************************************
      2            Filename:       nwk_globals.c
      3            Revised:        $Date: 2008-03-03 17:57:18 -0800 (Mon, 03 Mar 2008) $
      4            Revision:       $Revision: 16530 $
      5          
      6            Description:    User definable Network Parameters.
      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          /*********************************************************************
     41           * INCLUDES
     42           */
     43          #include "ZComdef.h"
     44          #include "OSAL.h"
     45          #include "AddrMgr.h"
     46          #include "AssocList.h"
     47          #include "BindingTable.h"
     48          #include "nwk_globals.h"
     49          #include "ssp.h"
     50          #include "rtg.h"
     51          #include "ZDConfig.h"
     52          #include "ZGlobals.h"
     53          
     54          #if defined ( LCD_SUPPORTED )
     55            #include "OnBoard.h"
     56            #include "lcd128_64.h"
     57          #endif
     58          
     59          /* HAL */
     60          //#include "hal_lcd.h"
     61          
     62          
     63          
     64          /*********************************************************************
     65           * MACROS
     66           */
     67          
     68          /*********************************************************************
     69           * CONSTANTS
     70           */
     71          
     72          // Maximums for the data buffer queue
     73          #define NWK_MAX_DATABUFS_WAITING    8     // Waiting to be sent to MAC
     74          #define NWK_MAX_DATABUFS_SCHEDULED  5     // Timed messages to be sent
     75          #define NWK_MAX_DATABUFS_CONFIRMED  5     // Held after MAC confirms
     76          #define NWK_MAX_DATABUFS_TOTAL      12    // Total number of buffers
     77          
     78          // 1-255 (0 -> 256) X RTG_TIMER_INTERVAL
     79          // A known shortcoming is that when a message is enqueued as "hold" for a
     80          // sleeping device, the timer tick may have counted down to 1, so that msg
     81          // will not be held as long as expected. If NWK_INDIRECT_MSG_TIMEOUT is set to 1
     82          // the hold time will vary randomly from 0 - CNT_RTG_TIMER ticks.
     83          // So the hold time will vary within this interval:
     84          // { (NWK_INDIRECT_MSG_TIMEOUT-1)*CNT_RTG_TIMER,
     85          //                                    NWK_INDIRECT_MSG_TIMEOUT*CNT_RTG_TIMER }
     86          #define NWK_INDIRECT_CNT_RTG_TMR    1  //ggg - need hours or days?
     87          // To hold msg for sleeping end devices for 30 secs:
     88          // #define CNT_RTG_TIMER            1
     89          // #define NWK_INDIRECT_MSG_TIMEOUT 30
     90          // To hold msg for sleeping end devices for 30 mins:
     91          // #define CNT_RTG_TIMER            60
     92          // #define NWK_INDIRECT_MSG_TIMEOUT 30
     93          // To hold msg for sleeping end devices for 30 days:
     94          // #define CNT_RTG_TIMER            60
     95          // #define NWK_INDIRECT_MSG_TIMEOUT (30 * 24 * 60)
     96          // Maximum msgs to hold per associated device.
     97          #define NWK_INDIRECT_MSG_MAX_PER    3
     98          // Maximum total msgs to hold for all associated devices.
     99          #define NWK_INDIRECT_MSG_MAX_ALL    \
    100                                      (NWK_MAX_DATABUFS_TOTAL - NWK_INDIRECT_MSG_MAX_PER)
    101          
    102          
    103          /*********************************************************************
    104           * TYPEDEFS
    105           */
    106          
    107          /*********************************************************************
    108           * NWK GLOBAL VARIABLES
    109           */
    110          
    111          // Variables for MAX list size

   \                                 In  segment CODE_C, align 1
    112          CONST uint16 gNWK_MAX_DEVICE_LIST = NWK_MAX_DEVICES;
   \                     gNWK_MAX_DEVICE_LIST:
   \   000000   1500         DW 21
    113          
    114          // Variables for MAX data buffer levels

   \                                 In  segment CODE_C, align 1
    115          CONST byte gNWK_MAX_DATABUFS_WAITING = NWK_MAX_DATABUFS_WAITING;
   \                     gNWK_MAX_DATABUFS_WAITING:
   \   000000   08           DB 8

   \                                 In  segment CODE_C, align 1
    116          CONST byte gNWK_MAX_DATABUFS_SCHEDULED = NWK_MAX_DATABUFS_SCHEDULED;
   \                     gNWK_MAX_DATABUFS_SCHEDULED:
   \   000000   05           DB 5

   \                                 In  segment CODE_C, align 1
    117          CONST byte gNWK_MAX_DATABUFS_CONFIRMED = NWK_MAX_DATABUFS_CONFIRMED;
   \                     gNWK_MAX_DATABUFS_CONFIRMED:
   \   000000   05           DB 5

   \                                 In  segment CODE_C, align 1
    118          CONST byte gNWK_MAX_DATABUFS_TOTAL = NWK_MAX_DATABUFS_TOTAL;
   \                     gNWK_MAX_DATABUFS_TOTAL:
   \   000000   0C           DB 12
    119          

   \                                 In  segment CODE_C, align 1
    120          CONST byte gNWK_INDIRECT_CNT_RTG_TMR = NWK_INDIRECT_CNT_RTG_TMR;
   \                     gNWK_INDIRECT_CNT_RTG_TMR:
   \   000000   01           DB 1

   \                                 In  segment CODE_C, align 1
    121          CONST byte gNWK_INDIRECT_MSG_MAX_PER = NWK_INDIRECT_MSG_MAX_PER;
   \                     gNWK_INDIRECT_MSG_MAX_PER:
   \   000000   03           DB 3

   \                                 In  segment CODE_C, align 1
    122          CONST byte gNWK_INDIRECT_MSG_MAX_ALL = NWK_INDIRECT_MSG_MAX_ALL;
   \                     gNWK_INDIRECT_MSG_MAX_ALL:
   \   000000   09           DB 9
    123          
    124          #if defined ( RTR_NWK )
    125            // change this if using a different stack profile...
    126            // Cskip array

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    127            uint16 *Cskip;
   \                     Cskip:
   \   000000                DS 2
   \   000002                REQUIRE __INIT_XDATA_Z
    128          
    129            #if ( STACK_PROFILE_ID == HOME_CONTROLS )
    130              byte CskipRtrs[MAX_NODE_DEPTH+1] = {6,6,6,6,6,0};
    131              byte CskipChldrn[MAX_NODE_DEPTH+1] = {20,20,20,20,20,0};
    132            #elif ( STACK_PROFILE_ID == GENERIC_STAR )

   \                                 In  segment XDATA_I, align 1, keep-with-next
    133              byte CskipRtrs[MAX_NODE_DEPTH+1] = {5,5,5,5,5,0};
   \                     CskipRtrs:
   \   000000                DS 6
   \   000006                REQUIRE `?<Initializer for CskipRtrs>`
   \   000006                REQUIRE __INIT_XDATA_I

   \                                 In  segment XDATA_I, align 1, keep-with-next
    134              byte CskipChldrn[MAX_NODE_DEPTH+1] = {5,5,5,5,5,0};
   \                     CskipChldrn:
   \   000000                DS 6
   \   000006                REQUIRE `?<Initializer for CskipChldrn>`
   \   000006                REQUIRE __INIT_XDATA_I
    135            #elif ( STACK_PROFILE_ID == NETWORK_SPECIFIC )
    136              byte CskipRtrs[MAX_NODE_DEPTH+1] = {5,5,5,5,5,0};
    137              byte CskipChldrn[MAX_NODE_DEPTH+1] = {5,5,5,5,5,0};
    138            #endif // STACK_PROFILE_ID
    139          #endif  // RTR_NWK
    140          
    141          
    142          // Minimum lqi value that is required for association

   \                                 In  segment XDATA_I, align 1, keep-with-next
    143          byte gMIN_TREE_LINK_COST = MIN_LQI_COST_3;
   \                     gMIN_TREE_LINK_COST:
   \   000000                DS 1
   \   000001                REQUIRE `?<Initializer for gMIN_TREE_LINK_COST>`
   \   000001                REQUIRE __INIT_XDATA_I
    144          
    145          #if defined(RTR_NWK)
    146            // Statically defined Associated Device List

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    147            associated_devices_t AssociatedDevList[NWK_MAX_DEVICES];
   \                     AssociatedDevList:
   \   000000                DS 294
   \   000126                REQUIRE __INIT_XDATA_Z
    148          #endif
    149          

   \                                 In  segment CODE_C, align 1
    150          CONST byte gMAX_RTG_ENTRIES = MAX_RTG_ENTRIES;
   \                     gMAX_RTG_ENTRIES:
   \   000000   14           DB 20

   \                                 In  segment CODE_C, align 1
    151          CONST byte gMAX_UNRESERVED_RTG_ENTRIES = MAX_UNRESERVED_RTG_ENTRIES;
   \                     gMAX_UNRESERVED_RTG_ENTRIES:
   \   000000   10           DB 16

   \                                 In  segment CODE_C, align 1
    152          CONST byte gMAX_RREQ_ENTRIES = MAX_RREQ_ENTRIES;
   \                     gMAX_RREQ_ENTRIES:
   \   000000   0A           DB 10
    153          

   \                                 In  segment CODE_C, align 1
    154          CONST byte gMAX_NEIGHBOR_ENTRIES = MAX_NEIGHBOR_ENTRIES;
   \                     gMAX_NEIGHBOR_ENTRIES:
   \   000000   08           DB 8
    155          
    156           // Table of neighboring nodes (not including child nodes)

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    157          neighborEntry_t neighborTable[MAX_NEIGHBOR_ENTRIES];
   \                     neighborTable:
   \   000000                DS 88
   \   000058                REQUIRE __INIT_XDATA_Z
    158          
    159          #if defined ( RTR_NWK )
    160            // Routing table

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    161            rtgEntry_t rtgTable[MAX_RTG_ENTRIES];
   \                     rtgTable:
   \   000000                DS 120
   \   000078                REQUIRE __INIT_XDATA_Z
    162          
    163            // Table of current RREQ packets in the network

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    164            rtDiscEntry_t rtDiscTable[MAX_RREQ_ENTRIES];
   \                     rtDiscTable:
   \   000000                DS 80
   \   000050                REQUIRE __INIT_XDATA_Z
    165          
    166            // Table of data broadcast packets currently in circulation.

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    167            bcastEntry_t bcastTable[MAX_BCAST];
   \                     bcastTable:
   \   000000                DS 72
   \   000048                REQUIRE __INIT_XDATA_Z
    168          
    169            // These 2 arrays are to be used as an array of struct { uint8, uint32 }.

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    170            uint8 bcastHoldHandle[MAX_BCAST];
   \                     bcastHoldHandle:
   \   000000                DS 9
   \   000009                REQUIRE __INIT_XDATA_Z

   \                                 In  segment XDATA_Z, align 1, keep-with-next
    171            uint32 bcastHoldAckMask[MAX_BCAST];
   \                     bcastHoldAckMask:
   \   000000                DS 36
   \   000024                REQUIRE __INIT_XDATA_Z
    172          

   \                                 In  segment CODE_C, align 1
    173            CONST byte gMAX_BCAST = MAX_BCAST;
   \                     gMAX_BCAST:
   \   000000   09           DB 9
    174          #endif
    175          
    176          /*********************************************************************
    177           * APS GLOBAL VARIABLES
    178           */
    179          
    180          //#if defined ( REFLECTOR )
    181            // The Maximum number of binding records
    182            // This number is defined in BindingTable.h - change it there.

   \                                 In  segment CODE_C, align 1
    183            CONST uint16 gNWK_MAX_BINDING_ENTRIES = NWK_MAX_BINDING_ENTRIES;
   \                     gNWK_MAX_BINDING_ENTRIES:
   \   000000   0A00         DW 10
    184          #if defined ( REFLECTOR )
    185            // The Maximum number of cluster IDs in a binding record
    186            // This number is defined in BindingTable.h - change it there.
    187            CONST byte gMAX_BINDING_CLUSTER_IDS = MAX_BINDING_CLUSTER_IDS;
    188          
    189            CONST uint16 gBIND_REC_SIZE = sizeof( BindingEntry_t );
    190          
    191            // Binding Table
    192            BindingEntry_t BindingTable[NWK_MAX_BINDING_ENTRIES];
    193          #endif
    194          
    195          // Maximum number allowed in the groups table.

   \                                 In  segment CODE_C, align 1
    196          CONST uint8 gAPS_MAX_GROUPS = APS_MAX_GROUPS;
   \                     gAPS_MAX_GROUPS:
   \   000000   10           DB 16
    197          
    198          // The size of a tx window when using fragmentation

   \                                 In  segment CODE_C, align 1
    199          CONST uint8 apscMaxWindowSize = APS_DEFAULT_WINDOW_SIZE;
   \                     apscMaxWindowSize:
   \   000000   05           DB 5
    200          
    201          // The delay between tx packets when using fragmentaition

   \                                 In  segment CODE_C, align 1
    202          CONST uint16 gAPS_INTERFRAME_DELAY = APS_DEFAULT_INTERFRAME_DELAY;
   \                     gAPS_INTERFRAME_DELAY:
   \   000000   3200         DW 50
    203          
    204          
    205          /*********************************************************************
    206           * SECURITY GLOBAL VARIABLES
    207           */
    208          
    209          // This is the default pre-configured key,
    210          // change this to make a unique key
    211          // SEC_KEY_LEN is defined in ssp.h.

   \                                 In  segment CODE_C, align 1
    212          CONST byte defaultKey[SEC_KEY_LEN] =
   \                     defaultKey:
   \   000000   00010203     DB 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
   \            04050607
   \            08090A0B
   \            0C0D0E0F
    213          {
    214          #if defined ( APP_TP ) || defined ( APP_TP2 )
    215            // Key for ZigBee Conformance Testing
    216            0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    217            0x89, 0x67, 0x45, 0x23, 0x01, 0xEF, 0xCD, 0xAB
    218          #else
    219            // Key for In-House Testing
    220            0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
    221            0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F
    222          #endif
    223          };
    224          
    225          
    226          /*********************************************************************
    227           * STATUS STRINGS
    228           */
    229          #if defined ( LCD_SUPPORTED )
    230            const char PingStr[]         = "Ping Rcvd from";
    231            const char AssocCnfStr[]     = "Assoc Cnf";
    232            const char SuccessStr[]      = "Success";
    233            const char EndDeviceStr[]    = "EndDevice:";
    234            const char ParentStr[]       = "Parent:";
    235            const char ZigbeeCoordStr[]  = "ZigBee Coord";
    236            const char NetworkIDStr[]    = "Network ID:";
    237            const char RouterStr[]       = "Router:";
    238            const char OrphanRspStr[]    = "Orphan Response";
    239            const char SentStr[]         = "Sent";
    240            const char FailedStr[]       = "Failed";
    241            const char AssocRspFailStr[] = "Assoc Rsp fail";
    242            const char AssocIndStr[]     = "Assoc Ind";
    243            const char AssocCnfFailStr[] = "Assoc Cnf fail";
    244            const char EnergyLevelStr[]  = "Energy Level";
    245            const char ScanFailedStr[]   = "Scan Failed";
    246          #endif
    247          
    248          /*********************************************************************
    249           * @fn       nwk_globals_init()
    250           *
    251           * @brief
    252           *
    253           *   Initialize nwk layer globals.  These are the system defaults and
    254           *   should be changed by the user here.  The default definitions are
    255           *   defined in nwk.h or NLMEDE.h.
    256           *
    257           * @param   none
    258           *
    259           * @return  none
    260           */

   \                                 In  segment BANKED_CODE, align 1, keep-with-next
    261          void nwk_globals_init( void )
   \                     nwk_globals_init:
    262          {
   \   000000   C082         PUSH    DPL
   \   000002   C083         PUSH    DPH
   \   000004                ; Saved register size: 2
   \   000004                ; Auto size: 0
    263            AddrMgrInit( NWK_MAX_ADDRESSES );
   \   000004                ; Setup parameters for call to function AddrMgrInit
   \   000004   7A16         MOV     R2,#0x16
   \   000006   7B00         MOV     R3,#0x0
   \   000008   12....       LCALL   ??AddrMgrInit?relay
    264          
    265          #if defined ( RTR_NWK )
    266            // Initialize the Cskip Table
    267            Cskip = osal_mem_alloc(sizeof(uint16) *(MAX_NODE_DEPTH+1));
   \   00000B                ; Setup parameters for call to function osal_mem_alloc
   \   00000B   7A0C         MOV     R2,#0xc
   \   00000D   7B00         MOV     R3,#0x0
   \   00000F   12....       LCALL   ??osal_mem_alloc?relay
   \   000012   90....       MOV     DPTR,#Cskip
   \   000015   EA           MOV     A,R2
   \   000016   F0           MOVX    @DPTR,A
   \   000017   A3           INC     DPTR
   \   000018   EB           MOV     A,R3
   \   000019   F0           MOVX    @DPTR,A
    268            RTG_FillCSkipTable(CskipChldrn, CskipRtrs, MAX_NODE_DEPTH, Cskip);
   \   00001A                ; Setup parameters for call to function RTG_FillCSkipTable
   \   00001A   90....       MOV     DPTR,#Cskip
   \   00001D   12....       LCALL   ?PUSH_XSTACK8_X_TWO
   \   000020   7905         MOV     R1,#0x5
   \   000022   7C..         MOV     R4,#(CskipRtrs & 0xff)
   \   000024   7D..         MOV     R5,#((CskipRtrs >> 8) & 0xff)
   \   000026   7A..         MOV     R2,#(CskipChldrn & 0xff)
   \   000028   7B..         MOV     R3,#((CskipChldrn >> 8) & 0xff)
   \   00002A   12....       LCALL   ??RTG_FillCSkipTable?relay
   \   00002D   7402         MOV     A,#0x2
   \   00002F   12....       LCALL   ?DEALLOC_XSTACK8
    269          #endif
    270          }
   \   000032                REQUIRE ?Subroutine0
   \   000032                ; // Fall through to label ?Subroutine0

   \                                 In  segment BANKED_CODE, align 1, keep-with-next
   \                     ?Subroutine0:
   \   000000   D083         POP     DPH
   \   000002   D082         POP     DPL
   \   000004   02....       LJMP    ?BRET
    271          
    272          /*********************************************************************
    273           * @fn       NIB_init()
    274           *
    275           * @brief
    276           *
    277           *   Initialize attribute values in NIB
    278           *
    279           * @param   none
    280           *
    281           * @return  none
    282           */

   \                                 In  segment BANKED_CODE, align 1, keep-with-next
    283          void NIB_init()
   \                     NIB_init:
    284          {
   \   000000   C082         PUSH    DPL
   \   000002   C083         PUSH    DPH
   \   000004                ; Saved register size: 2
   \   000004                ; Auto size: 0
    285          #if defined ( AUTO_SOFT_START )
    286            byte extAddr[Z_EXTADDR_LEN];
    287            ZMacGetReq( ZMacExtAddr, extAddr );
    288            _NIB.SequenceNum = extAddr[0];
    289          #else
    290            _NIB.SequenceNum = 1;
   \   000004   7401         MOV     A,#0x1
   \   000006   90....       MOV     DPTR,#_NIB
   \   000009   F0           MOVX    @DPTR,A
    291          #endif
    292          
    293            _NIB.nwkProtocolVersion = ZB_PROT_VERS;
   \   00000A   7402         MOV     A,#0x2
   \   00000C   90....       MOV     DPTR,#(_NIB + 17)
   \   00000F   F0           MOVX    @DPTR,A
    294            _NIB.MaxDepth = MAX_NODE_DEPTH;
   \   000010   7405         MOV     A,#0x5
   \   000012   90....       MOV     DPTR,#(_NIB + 4)
   \   000015   F0           MOVX    @DPTR,A
    295          
    296          #if ( NWK_MODE == NWK_MODE_MESH )
    297            _NIB.beaconOrder = BEACON_ORDER_NO_BEACONS;
    298            _NIB.superFrameOrder = BEACON_ORDER_NO_BEACONS;
    299          #endif
    300          
    301             // BROADCAST SETTINGS:
    302             // *******************
    303             //   Broadcast Delivery Time
    304             //     - set to multiples of 100ms
    305             //     - should be 500ms more than the retry time
    306             //       -  "retry time" = PassiveAckTimeout * (MaxBroadcastRetries + 1)
    307             //   Passive Ack Timeout
    308             //     - set to multiples of 100ms
    309             _NIB.BroadcastDeliveryTime = zgBcastDeliveryTime;
   \   000016   90....       MOV     DPTR,#zgBcastDeliveryTime
   \   000019   E0           MOVX    A,@DPTR
   \   00001A   90....       MOV     DPTR,#(_NIB + 7)
   \   00001D   F0           MOVX    @DPTR,A
    310             _NIB.PassiveAckTimeout     = zgPassiveAckTimeout;
   \   00001E   90....       MOV     DPTR,#zgPassiveAckTimeout
   \   000021   E0           MOVX    A,@DPTR
   \   000022   90....       MOV     DPTR,#(_NIB + 1)
   \   000025   F0           MOVX    @DPTR,A
    311             _NIB.MaxBroadcastRetries   = zgMaxBcastRetires;
   \   000026   90....       MOV     DPTR,#zgMaxBcastRetires
   \   000029   E0           MOVX    A,@DPTR
   \   00002A   90....       MOV     DPTR,#(_NIB + 2)
   \   00002D   F0           MOVX    @DPTR,A
    312          
    313             _NIB.ReportConstantCost = 0;
   \   00002E   E4           CLR     A
   \   00002F   90....       MOV     DPTR,#(_NIB + 8)
   \   000032   F0           MOVX    @DPTR,A
    314             _NIB.RouteDiscRetries = 0;
   \   000033   90....       MOV     DPTR,#(_NIB + 9)
   \   000036   F0           MOVX    @DPTR,A
    315             _NIB.SecureAllFrames = USE_NWK_SECURITY;
   \   000037   7401         MOV     A,#0x1
   \   000039   90....       MOV     DPTR,#(_NIB + 11)
   \   00003C   F0           MOVX    @DPTR,A
    316             _NIB.SecurityLevel = zgSecurityLevel;
   \   00003D   90....       MOV     DPTR,#zgSecurityLevel
   \   000040   E0           MOVX    A,@DPTR
   \   000041   90....       MOV     DPTR,#(_NIB + 12)
   \   000044   F0           MOVX    @DPTR,A
    317             _NIB.SymLink = 0;
   \   000045   E4           CLR     A
   \   000046   90....       MOV     DPTR,#(_NIB + 13)
   \   000049   F0           MOVX    @DPTR,A
    318             _NIB.CapabilityInfo = ZDO_Config_Node_Descriptor.CapabilityFlags;
   \   00004A   90....       MOV     DPTR,#(ZDO_Config_Node_Descriptor + 2)
   \   00004D   E0           MOVX    A,@DPTR
   \   00004E   90....       MOV     DPTR,#(_NIB + 14)
   \   000051   F0           MOVX    @DPTR,A
    319          
    320             _NIB.TransactionPersistenceTime = zgIndirectMsgTimeout;
   \   000052   90....       MOV     DPTR,#zgIndirectMsgTimeout
   \   000055   E0           MOVX    A,@DPTR
   \   000056   90....       MOV     DPTR,#(_NIB + 15)
   \   000059   F0           MOVX    @DPTR,A
   \   00005A   A3           INC     DPTR
   \   00005B   E4           CLR     A
   \   00005C   F0           MOVX    @DPTR,A
    321          
    322             _NIB.RouteDiscoveryTime = 5;
   \   00005D   7405         MOV     A,#0x5
   \   00005F   90....       MOV     DPTR,#(_NIB + 18)
   \   000062   F0           MOVX    @DPTR,A
    323             _NIB.RouteExpiryTime = zgRouteExpiryTime;
   \   000063   90....       MOV     DPTR,#zgRouteExpiryTime
   \   000066   E0           MOVX    A,@DPTR
   \   000067   90....       MOV     DPTR,#(_NIB + 19)
   \   00006A   F0           MOVX    @DPTR,A
    324          
    325             _NIB.nwkDevAddress = INVALID_NODE_ADDR;
   \   00006B   90....       MOV     DPTR,#(_NIB + 20)
   \   00006E   74FE         MOV     A,#-0x2
   \   000070   F0           MOVX    @DPTR,A
   \   000071   A3           INC     DPTR
   \   000072   74FF         MOV     A,#-0x1
   \   000074   F0           MOVX    @DPTR,A
    326             _NIB.nwkLogicalChannel = 0;
   \   000075   E4           CLR     A
   \   000076   90....       MOV     DPTR,#(_NIB + 22)
   \   000079   F0           MOVX    @DPTR,A
    327             _NIB.nwkCoordAddress = INVALID_NODE_ADDR;
   \   00007A   90....       MOV     DPTR,#(_NIB + 23)
   \   00007D   74FE         MOV     A,#-0x2
   \   00007F   F0           MOVX    @DPTR,A
   \   000080   A3           INC     DPTR
   \   000081   74FF         MOV     A,#-0x1
   \   000083   F0           MOVX    @DPTR,A
    328             osal_memset( _NIB.nwkCoordExtAddress, 0, Z_EXTADDR_LEN );
   \   000084                ; Setup parameters for call to function osal_memset
   \   000084   7C08         MOV     R4,#0x8
   \   000086   7D00         MOV     R5,#0x0
   \   000088   7900         MOV     R1,#0x0
   \   00008A   7A..         MOV     R2,#((_NIB + 25) & 0xff)
   \   00008C   7B..         MOV     R3,#(((_NIB + 25) >> 8) & 0xff)
   \   00008E   12....       LCALL   ??osal_memset?relay
    329             _NIB.nwkPanId = INVALID_NODE_ADDR;
   \   000091   90....       MOV     DPTR,#(_NIB + 33)
   \   000094   74FE         MOV     A,#-0x2
   \   000096   F0           MOVX    @DPTR,A
   \   000097   A3           INC     DPTR
   \   000098   74FF         MOV     A,#-0x1
   \   00009A   F0           MOVX    @DPTR,A
    330          
    331             osal_cpyExtAddr( _NIB.extendedPANID, zgExtendedPANID );
   \   00009B                ; Setup parameters for call to function osal_cpyExtAddr
   \   00009B   7C..         MOV     R4,#(zgExtendedPANID & 0xff)
   \   00009D   7D..         MOV     R5,#((zgExtendedPANID >> 8) & 0xff)
   \   00009F   7A..         MOV     R2,#((_NIB + 53) & 0xff)
   \   0000A1   7B..         MOV     R3,#(((_NIB + 53) >> 8) & 0xff)
   \   0000A3   12....       LCALL   ??osal_cpyExtAddr?relay
    332          
    333             _NIB.nwkKeyLoaded = FALSE;
   \   0000A6   E4           CLR     A
   \   0000A7   90....       MOV     DPTR,#(_NIB + 61)
   \   0000AA   F0           MOVX    @DPTR,A
    334          }
   \   0000AB   02....       LJMP    ?Subroutine0 & 0xFFFF
    335          
    336          /*********************************************************************
    337           * @fn       nwk_Status()
    338           *
    339           * @brief
    340           *
    341           *   Status report.
    342           *
    343           * @param   statusCode
    344           * @param   statusValue
    345           *
    346           * @return  none
    347           */

   \                                 In  segment BANKED_CODE, align 1, keep-with-next
    348          void nwk_Status( uint16 statusCode, uint16 statusValue )
   \                     nwk_Status:
    349          {
   \   000000                ; Saved register size: 0
   \   000000                ; Auto size: 0
    350          #if defined ( LCD_SUPPORTED )
    351            switch ( statusCode )
    352            {
    353          
    354          #if defined( RTR_NWK )
    355              case NWK_STATUS_COORD_ADDR:
    356                //HalLcdWriteString( (char*)ZigbeeCoordStr, HAL_LCD_LINE_1 );
    357               // HalLcdWriteStringValue( (char*)NetworkIDStr, (uint32)statusValue, 16, HAL_LCD_LINE_2 );
    358                ClearScreen();
    359                Print8(HAL_LCD_LINE_1,10,(INT8U*)ZigbeeCoordStr,1);
    360                Print8(HAL_LCD_LINE_2,10,(INT8U*)NetworkIDStr,1);
    361                Printn8(HAL_LCD_LINE_3,10,statusValue,1,4);
    362                BuzzerControl( BUZZER_BLIP );
    363                break;
    364          
    365              case NWK_STATUS_ROUTER_ADDR:
    366                //HalLcdWriteStringValue( (char*)RouterStr, (uint32)statusValue, 16, HAL_LCD_LINE_1 );
    367                ClearScreen();
    368                Print8(HAL_LCD_LINE_1,10,(INT8U*)RouterStr,1);
    369                Printn8(HAL_LCD_LINE_1,40,statusValue,1,4);
    370                break;
    371          
    372              case NWK_STATUS_ORPHAN_RSP:
    373                if( statusValue == ZSuccess )
    374                {
    375                  //HalLcdWriteScreen( (char*)OrphanRspStr, (char*)SentStr );
    376                   ClearScreen();
    377                  Print8(HAL_LCD_LINE_1,10,(INT8U*)OrphanRspStr,1);
    378                  Print8(HAL_LCD_LINE_2,10,(INT8U*)SentStr,1);
    379                }
    380                else{
    381                //else
    382                  //HalLcdWriteScreen( (char*)OrphanRspStr, (char*)FailedStr );
    383                 ClearScreen();
    384                 Print8(HAL_LCD_LINE_1,10,(INT8U*)OrphanRspStr,1);
    385                 Print8(HAL_LCD_LINE_2,10,(INT8U*)FailedStr,1);
    386                }
    387                break;
    388          
    389              case NWK_ERROR_ASSOC_RSP:
    390                //HalLcdWriteString( (char*)AssocRspFailStr, HAL_LCD_LINE_1 );
    391               // HalLcdWriteValue( (uint32)(statusValue), 16, HAL_LCD_LINE_2 );
    392                 ClearScreen();
    393                 Print8(HAL_LCD_LINE_1,10,(INT8U*)AssocRspFailStr,1);
    394                 Printn8(HAL_LCD_LINE_2,10,statusValue,1,4);
    395          
    396                break;
    397          #else
    398              case NWK_STATUS_ED_ADDR:
    399                      //HalLcdWriteStringValue( (char*)EndDeviceStr, (uint32)statusValue, 16, HAL_LCD_LINE_1 );
    400                  //ClearScreen();
    401                  Print8(HAL_LCD_LINE_1,10,(INT8U*)EndDeviceStr,1);
    402                  Printn8(HAL_LCD_LINE_1,60,statusValue,1,4);
    403                break;
    404          #endif
    405          
    406              case NWK_STATUS_PARENT_ADDR:
    407                      //HalLcdWriteStringValue( (char*)ParentStr, (uint32)statusValue, 16, HAL_LCD_LINE_2 );
    408          
    409                      Print8(HAL_LCD_LINE_2,10,(INT8U*)ParentStr,1);
    410                      Printn8(HAL_LCD_LINE_3,10,statusValue,1,4);
    411                break;
    412          
    413              case NWK_STATUS_ASSOC_CNF:
    414               // HalLcdWriteScreen( (char*)AssocCnfStr, (char*)SuccessStr );
    415                 ClearScreen();
    416                Print8(HAL_LCD_LINE_1,10,(INT8U*)AssocCnfStr,1);
    417                Print8(HAL_LCD_LINE_2,10,(INT8U*)SuccessStr,1);
    418                break;
    419          
    420              case NWK_ERROR_ASSOC_CNF_DENIED:
    421                //HalLcdWriteString((char*)AssocCnfFailStr, HAL_LCD_LINE_1 );
    422                //HalLcdWriteValue( (uint32)(statusValue), 16, HAL_LCD_LINE_2 );
    423                 ClearScreen();
    424                Print8(HAL_LCD_LINE_1,10,(INT8U*)AssocCnfFailStr,1);
    425                Printn8(HAL_LCD_LINE_2,10,statusValue,1,4);
    426                break;
    427          
    428              case NWK_ERROR_ENERGY_SCAN_FAILED:
    429               // HalLcdWriteScreen( (char*)EnergyLevelStr, (char*)ScanFailedStr );
    430                 ClearScreen();
    431                 Print8(HAL_LCD_LINE_1,10,(INT8U*)EnergyLevelStr,1);
    432                 Print8(HAL_LCD_LINE_2,10,(INT8U*)ScanFailedStr ,1);
    433                break;
    434            }
    435          #endif
    436          }
   \   000000   02....       LJMP    ?BRET

   \                                 In  segment XDATA_ID, align 1, keep-with-next
   \                     `?<Initializer for CskipRtrs>`:
   \   000000   05050505     DB 5, 5, 5, 5, 5, 0
   \            0500    

   \                                 In  segment XDATA_ID, align 1, keep-with-next
   \                     `?<Initializer for CskipChldrn>`:
   \   000000   05050505     DB 5, 5, 5, 5, 5, 0
   \            0500    

   \                                 In  segment XDATA_ID, align 1, keep-with-next
   \                     `?<Initializer for gMIN_TREE_LINK_COST>`:
   \   000000   06           DB 6

   \                                 In  segment BANK_RELAYS, align 1
   \                     ??nwk_globals_init?relay:
   \   000000   12....       LCALL   ?BDISPATCH
   \   000003   ......       DC24    nwk_globals_init

   \                                 In  segment BANK_RELAYS, align 1
   \                     ??NIB_init?relay:
   \   000000   12....       LCALL   ?BDISPATCH
   \   000003   ......       DC24    NIB_init

   \                                 In  segment BANK_RELAYS, align 1
   \                     ??nwk_Status?relay:
   \   000000   12....       LCALL   ?BDISPATCH
   \   000003   ......       DC24    nwk_Status
    437          
    438          /*********************************************************************
    439          *********************************************************************/

   Maximum stack usage in bytes:

     Function                ISTACK PSTACK XSTACK
     --------                ------ ------ ------
     NIB_init                    2      0      0
       -> osal_memset            4      0      0
       -> osal_cpyExtAddr        4      0      0
     nwk_Status                  0      0      0
     nwk_globals_init            2      0      2
       -> AddrMgrInit            4      0      0
       -> osal_mem_alloc         4      0      0
       -> RTG_FillCSkipTable     4      0      4


   Segment part sizes:

     Function/Label                 Bytes
     --------------                 -----
     gNWK_MAX_DEVICE_LIST              2
     gNWK_MAX_DATABUFS_WAITING         1
     gNWK_MAX_DATABUFS_SCHEDULED       1
     gNWK_MAX_DATABUFS_CONFIRMED       1
     gNWK_MAX_DATABUFS_TOTAL           1
     gNWK_INDIRECT_CNT_RTG_TMR         1
     gNWK_INDIRECT_MSG_MAX_PER         1
     gNWK_INDIRECT_MSG_MAX_ALL         1
     Cskip                             2
     CskipRtrs                         6
     CskipChldrn                       6
     gMIN_TREE_LINK_COST               1
     AssociatedDevList               294
     gMAX_RTG_ENTRIES                  1
     gMAX_UNRESERVED_RTG_ENTRIES       1
     gMAX_RREQ_ENTRIES                 1
     gMAX_NEIGHBOR_ENTRIES             1
     neighborTable                    88
     rtgTable                        120
     rtDiscTable                      80
     bcastTable                       72
     bcastHoldHandle                   9
     bcastHoldAckMask                 36
     gMAX_BCAST                        1
     gNWK_MAX_BINDING_ENTRIES          2
     gAPS_MAX_GROUPS                   1
     apscMaxWindowSize                 1
     gAPS_INTERFRAME_DELAY             2
     defaultKey                       16
     nwk_globals_init                 50
     ?Subroutine0                      7
     NIB_init                        174
     nwk_Status                        3
     ?<Initializer for CskipRtrs>      6
     ?<Initializer for CskipChldrn>    6
     ?<Initializer for gMIN_TREE_LINK_COST>
                                       1
     ??nwk_globals_init?relay          6
     ??NIB_init?relay                  6
     ??nwk_Status?relay                6

 
 234 bytes in segment BANKED_CODE
  18 bytes in segment BANK_RELAYS
  36 bytes in segment CODE_C
  13 bytes in segment XDATA_I
  13 bytes in segment XDATA_ID
 701 bytes in segment XDATA_Z
 
 301 bytes of CODE  memory
 714 bytes of XDATA memory

Errors: none
Warnings: none
