lib_str.txt 104 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176
; generated by Component: ARM Compiler 5.06 update 6 (build 750) Tool: ArmCC [4d3637]
; commandline ArmCC [--c99 --list --split_sections --debug -c --asm --interleave -o.\flash\obj\lib_str.o --asm_dir=.\Flash\List\ --list_dir=.\Flash\List\ --depend=.\flash\obj\lib_str.d --cpu=Cortex-M4.fp --apcs=interwork -O1 --diag_suppress=9931,870 -I..\..\Libraries\CMSIS\Include -I..\..\Libraries\CMSIS\Device\ST\STM32F4xx\Include -I..\..\Libraries\STM32F4xx_StdPeriph_Driver\inc -I..\..\uCOS-III\uC-CPU -I..\..\uCOS-III\uC-LIB -I..\..\uCOS-III\uCOS-III\Ports -I..\..\uCOS-III\uCOS-III\Source -I..\..\uCOS-III\uC-CPU\ARM-Cortex-M4\RealView -I..\..\uCOS-III\uC-LIB\Ports\ARM-Cortex-M4\RealView -I..\..\uCOS-III\uCOS-III\Ports\ARM-Cortex-M4\Generic\RealView -I..\..\User -I..\..\User\bsp -I..\..\User\bsp\inc -I..\..\User\libapp -I..\..\RL-ARM\Config -I..\..\RL-ARM\Driver -I..\..\RL-ARM\RL-RTX\inc -I..\..\User\bsp\BSP -I..\..\RL-ARM\RL-CAN -I..\..\Libraries\DSP_LIB\Include -I..\..\MODBUS\modbus\rtu -I..\..\MODBUS\BARE\port -I..\..\MODBUS\modbus\include -I..\..\User\bsp\BSP -I..\..\PLC -I..\..\Avoid -I..\..\User\parameter -I..\..\User\LaserMotionCtr -I..\..\User\W5100S -I..\..\User\bsp -I..\..\User\CHASSIS -I..\..\User\CONTROLFUNCTION -I..\..\User\DATAUPDATE -I..\..\User\HARAWARE -I..\..\User\MOTORDRIVER -I..\..\User\NAVAGATION -I..\..\User\PLATFORM -I..\..\User\SENSOR -I.\RTE\_Flash -IC:\Users\YDJ\AppData\Local\Arm\Packs\ARM\CMSIS\5.5.1\CMSIS\Core\Include -IC:\Users\YDJ\AppData\Local\Arm\Packs\Keil\STM32F4xx_DFP\2.13.0\Drivers\CMSIS\Device\ST\STM32F4xx\Include -D__UVISION_VERSION=527 -D_RTE_ -DSTM32F407xx -DUSE_STDPERIPH_DRIVER -DSTM32F40_41xxx -D__RTX -D__FPU_USED=1 --omf_browse=.\flash\obj\lib_str.crf ..\..\uCOS-III\uC-LIB\lib_str.c]
                          THUMB

                          AREA ||i.Str_Cat||, CODE, READONLY, ALIGN=1

                  Str_Cat PROC
;;;544    
;;;545    CPU_CHAR  *Str_Cat (       CPU_CHAR  *pstr_dest,
000000  f04f32ff          MOV      r2,#0xffffffff
;;;546                        const  CPU_CHAR  *pstr_cat)
;;;547    {
;;;548        CPU_CHAR  *pstr_rtn;
;;;549    
;;;550    
;;;551        pstr_rtn = Str_Cat_N(pstr_dest,
000004  f7ffbffe          B.W      Str_Cat_N
;;;552                             pstr_cat,
;;;553                             DEF_INT_CPU_U_MAX_VAL);
;;;554    
;;;555        return (pstr_rtn);
;;;556    }
;;;557    
                          ENDP


                          AREA ||i.Str_Cat_N||, CODE, READONLY, ALIGN=1

                  Str_Cat_N PROC
;;;627    /*$PAGE*/
;;;628    CPU_CHAR  *Str_Cat_N (       CPU_CHAR    *pstr_dest,
000000  b530              PUSH     {r4,r5,lr}
;;;629                          const  CPU_CHAR    *pstr_cat,
;;;630                                 CPU_SIZE_T   len_max)
;;;631    {
;;;632               CPU_CHAR    *pstr_cat_dest;
;;;633        const  CPU_CHAR    *pstr_cat_src;
;;;634               CPU_SIZE_T   len_cat;
;;;635    
;;;636                                                                    /* Rtn NULL if str ptr(s) NULL (see Note #3a1).         */
;;;637        if (pstr_dest == (CPU_CHAR *)0) {
000002  2800              CMP      r0,#0
000004  d004              BEQ      |L2.16|
;;;638            return ((CPU_CHAR *)0);
;;;639        }
;;;640        if (pstr_cat  == (const CPU_CHAR *)0) {
000006  b129              CBZ      r1,|L2.20|
;;;641            return ((CPU_CHAR *)0);
;;;642        }
;;;643    
;;;644        if (len_max < 1) {                                          /* Rtn dest str if cat len = 0 (see Note #3d2A).        */
000008  2a00              CMP      r2,#0
00000a  d002              BEQ      |L2.18|
;;;645            return ((CPU_CHAR *)pstr_dest);
;;;646        }
;;;647    
;;;648    
;;;649        pstr_cat_dest = pstr_dest;
00000c  4603              MOV      r3,r0
;;;650        while (( pstr_cat_dest != (CPU_CHAR *)  0 ) &&              /* Adv to end of cur dest str until NULL ptr ...        */
00000e  e004              B        |L2.26|
                  |L2.16|
000010  2000              MOVS     r0,#0                 ;638
                  |L2.18|
;;;651               (*pstr_cat_dest != (CPU_CHAR  )'\0')) {              /* ... or NULL char found..                             */
;;;652            pstr_cat_dest++;
;;;653        }
;;;654        if (pstr_cat_dest == (CPU_CHAR *)0) {                       /* Rtn NULL if NULL ptr found (see Note #3b1).          */
;;;655            return ((CPU_CHAR *)0);
;;;656        }
;;;657    
;;;658        pstr_cat_src = pstr_cat;
;;;659        len_cat      = 0u;
;;;660    
;;;661        while (( pstr_cat_dest != (      CPU_CHAR *)  0 ) &&        /* Cat str until NULL ptr(s)  [see Note #3b]  ...       */
;;;662               ( pstr_cat_src  != (const CPU_CHAR *)  0 ) &&
;;;663               (*pstr_cat_src  != (      CPU_CHAR  )'\0') &&        /* ... or NULL char found     (see Note #3c); ...       */
;;;664               ( len_cat       <  (      CPU_SIZE_T)len_max)) {     /* ... or max nbr chars cat'd (see Note #3d).           */
;;;665           *pstr_cat_dest = *pstr_cat_src;
;;;666            pstr_cat_dest++;
;;;667            pstr_cat_src++;
;;;668            len_cat++;
;;;669        }
;;;670                                                                    /* Rtn NULL if NULL ptr(s) found (see Note #3b1).       */
;;;671        if ((pstr_cat_dest == (      CPU_CHAR *)0) ||
;;;672            (pstr_cat_src  == (const CPU_CHAR *)0)) {
;;;673             return ((CPU_CHAR *)0);
;;;674        }
;;;675    
;;;676       *pstr_cat_dest = (CPU_CHAR)'\0';                             /* Append NULL char    (see Note #2a2C).                */
;;;677    
;;;678    
;;;679        return (pstr_dest);                                         /* Rtn ptr to dest str (see Note #2b1).                 */
;;;680    }
000012  bd30              POP      {r4,r5,pc}
                  |L2.20|
000014  2000              MOVS     r0,#0                 ;641
000016  bd30              POP      {r4,r5,pc}
                  |L2.24|
000018  1c5b              ADDS     r3,r3,#1              ;652
                  |L2.26|
00001a  b113              CBZ      r3,|L2.34|
00001c  781c              LDRB     r4,[r3,#0]            ;651
00001e  2c00              CMP      r4,#0                 ;651
000020  d1fa              BNE      |L2.24|
                  |L2.34|
000022  b10b              CBZ      r3,|L2.40|
000024  2400              MOVS     r4,#0                 ;659
000026  e005              B        |L2.52|
                  |L2.40|
000028  2000              MOVS     r0,#0                 ;655
00002a  bd30              POP      {r4,r5,pc}
                  |L2.44|
00002c  f8035b01          STRB     r5,[r3],#1            ;665
000030  1c49              ADDS     r1,r1,#1              ;667
000032  1c64              ADDS     r4,r4,#1              ;668
                  |L2.52|
000034  b123              CBZ      r3,|L2.64|
000036  b119              CBZ      r1,|L2.64|
000038  780d              LDRB     r5,[r1,#0]            ;663
00003a  b10d              CBZ      r5,|L2.64|
00003c  4294              CMP      r4,r2                 ;664
00003e  d3f5              BCC      |L2.44|
                  |L2.64|
000040  b11b              CBZ      r3,|L2.74|
000042  b111              CBZ      r1,|L2.74|
000044  2100              MOVS     r1,#0                 ;676
000046  7019              STRB     r1,[r3,#0]            ;676
000048  bd30              POP      {r4,r5,pc}
                  |L2.74|
00004a  2000              MOVS     r0,#0                 ;673
00004c  bd30              POP      {r4,r5,pc}
;;;681    
                          ENDP


                          AREA ||i.Str_Char||, CODE, READONLY, ALIGN=1

                  Str_Char PROC
;;;1277   
;;;1278   CPU_CHAR  *Str_Char (const  CPU_CHAR  *pstr,
000000  460a              MOV      r2,r1
;;;1279                               CPU_CHAR   srch_char)
;;;1280   {
;;;1281       CPU_CHAR  *pstr_rtn;
;;;1282   
;;;1283   
;;;1284       pstr_rtn = Str_Char_N(pstr,
000002  f04f31ff          MOV      r1,#0xffffffff
000006  f7ffbffe          B.W      Str_Char_N
;;;1285                             DEF_INT_CPU_U_MAX_VAL,
;;;1286                             srch_char);
;;;1287   
;;;1288       return (pstr_rtn);
;;;1289   }
;;;1290   
                          ENDP


                          AREA ||i.Str_Char_Last||, CODE, READONLY, ALIGN=1

                  Str_Char_Last PROC
;;;1456   
;;;1457   CPU_CHAR  *Str_Char_Last (const  CPU_CHAR  *pstr,
000000  460a              MOV      r2,r1
;;;1458                                    CPU_CHAR   srch_char)
;;;1459   {
;;;1460       CPU_CHAR  *pstr_rtn;
;;;1461   
;;;1462   
;;;1463       pstr_rtn = Str_Char_Last_N(pstr,
000002  f04f31ff          MOV      r1,#0xffffffff
000006  f7ffbffe          B.W      Str_Char_Last_N
;;;1464                                  DEF_INT_CPU_U_MAX_VAL,
;;;1465                                  srch_char);
;;;1466   
;;;1467       return (pstr_rtn);
;;;1468   }
;;;1469   
                          ENDP


                          AREA ||i.Str_Char_Last_N||, CODE, READONLY, ALIGN=1

                  Str_Char_Last_N PROC
;;;1539   /*$PAGE*/
;;;1540   CPU_CHAR  *Str_Char_Last_N (const  CPU_CHAR    *pstr,
000000  b530              PUSH     {r4,r5,lr}
;;;1541                                      CPU_SIZE_T   len_max,
;;;1542                                      CPU_CHAR     srch_char)
;;;1543   {
000002  4604              MOV      r4,r0
000004  4615              MOV      r5,r2
;;;1544       const  CPU_CHAR    *pstr_char;
;;;1545              CPU_SIZE_T   str_len_max;
;;;1546              CPU_SIZE_T   str_len;
;;;1547   
;;;1548   
;;;1549       if (pstr == (const CPU_CHAR *)0) {                          /* Rtn NULL if srch str ptr NULL (see Note #3a1).       */
000006  2c00              CMP      r4,#0
000008  d007              BEQ      |L5.26|
;;;1550           return ((CPU_CHAR *)0);
;;;1551       }
;;;1552   
;;;1553       if (len_max < 1) {                                          /* Rtn NULL if srch len = 0      (see Note #3e1).       */
00000a  b141              CBZ      r1,|L5.30|
;;;1554           return ((CPU_CHAR *)0);
;;;1555       }
;;;1556   
;;;1557   
;;;1558       pstr_char    = pstr;
;;;1559        str_len_max = len_max - sizeof((CPU_CHAR)'\0');            /* Str len adj'd for NULL char len.                     */
00000c  1e49              SUBS     r1,r1,#1
;;;1560        str_len     = Str_Len_N(pstr_char, str_len_max);
00000e  4620              MOV      r0,r4
000010  f7fffffe          BL       Str_Len_N
;;;1561       pstr_char   += str_len;
000014  4420              ADD      r0,r0,r4
;;;1562   
;;;1563       if (pstr_char == (const CPU_CHAR *)0) {                     /* Rtn NULL if NULL ptr found        (see Note #3b1).   */
000016  b120              CBZ      r0,|L5.34|
000018  e006              B        |L5.40|
                  |L5.26|
00001a  2000              MOVS     r0,#0                 ;1550
;;;1564           return ((CPU_CHAR *)0);
;;;1565       }
;;;1566   
;;;1567       while (( pstr_char != pstr) &&                              /* Srch str from end until beginning (see Note #3c) ... */
;;;1568              (*pstr_char != srch_char)) {                         /* ... until srch char found         (see Note #3d).    */
;;;1569           pstr_char--;
;;;1570       }
;;;1571   
;;;1572   
;;;1573       if (*pstr_char != srch_char) {                              /* Rtn NULL if srch char NOT found   (see Note #3c1).   */
;;;1574            return ((CPU_CHAR *)0);
;;;1575       }
;;;1576   
;;;1577   
;;;1578       return ((CPU_CHAR *)pstr_char);                             /* Else rtn ptr to found srch char   (see Note #3d1).   */
;;;1579   }
00001c  bd30              POP      {r4,r5,pc}
                  |L5.30|
00001e  2000              MOVS     r0,#0                 ;1554
000020  bd30              POP      {r4,r5,pc}
                  |L5.34|
000022  2000              MOVS     r0,#0                 ;1564
                  |L5.36|
000024  bd30              POP      {r4,r5,pc}
                  |L5.38|
000026  1e40              SUBS     r0,r0,#1              ;1569
                  |L5.40|
000028  42a0              CMP      r0,r4                 ;1567
00002a  d002              BEQ      |L5.50|
00002c  7801              LDRB     r1,[r0,#0]            ;1568
00002e  42a9              CMP      r1,r5                 ;1568
000030  d1f9              BNE      |L5.38|
                  |L5.50|
000032  7801              LDRB     r1,[r0,#0]            ;1573
000034  42a9              CMP      r1,r5                 ;1573
000036  d0f5              BEQ      |L5.36|
000038  2000              MOVS     r0,#0                 ;1574
00003a  bd30              POP      {r4,r5,pc}
;;;1580   
                          ENDP


                          AREA ||i.Str_Char_N||, CODE, READONLY, ALIGN=1

                  Str_Char_N PROC
;;;1358   /*$PAGE*/
;;;1359   CPU_CHAR  *Str_Char_N (const  CPU_CHAR    *pstr,
000000  b510              PUSH     {r4,lr}
;;;1360                                 CPU_SIZE_T   len_max,
;;;1361                                 CPU_CHAR     srch_char)
;;;1362   {
;;;1363       const  CPU_CHAR    *pstr_char;
;;;1364              CPU_SIZE_T   len_srch;
;;;1365   
;;;1366   
;;;1367       if (pstr == (const CPU_CHAR *)0) {                          /* Rtn NULL if srch str ptr NULL (see Note #3a1).       */
000002  2800              CMP      r0,#0
000004  d002              BEQ      |L6.12|
;;;1368           return ((CPU_CHAR *)0);
;;;1369       }
;;;1370   
;;;1371       if (len_max < 1) {                                          /* Rtn NULL if srch len = 0      (see Note #3e1).       */
000006  b119              CBZ      r1,|L6.16|
;;;1372           return ((CPU_CHAR *)0);
;;;1373       }
;;;1374   
;;;1375   
;;;1376       pstr_char = pstr;
;;;1377       len_srch  = 0u;
000008  2300              MOVS     r3,#0
;;;1378   
;;;1379       while (( pstr_char != (const CPU_CHAR *)  0 )      &&       /* Srch str until NULL ptr     [see Note #3b]  ...      */
00000a  e005              B        |L6.24|
                  |L6.12|
00000c  2000              MOVS     r0,#0                 ;1368
;;;1380              (*pstr_char != (      CPU_CHAR  )'\0')      &&       /* ... or NULL char            (see Note #3c)  ...      */
;;;1381              (*pstr_char != (      CPU_CHAR  )srch_char) &&       /* ... or srch char found      (see Note #3d); ...      */
;;;1382              ( len_srch  <  (      CPU_SIZE_T)len_max)) {         /* ... or max nbr chars srch'd (see Note #3e).          */
;;;1383           pstr_char++;
;;;1384           len_srch++;
;;;1385       }
;;;1386   
;;;1387   
;;;1388       if (pstr_char == (const CPU_CHAR *)0) {                     /* Rtn NULL if NULL ptr found      (see Note #3b1).     */
;;;1389           return ((CPU_CHAR *)0);
;;;1390       }
;;;1391   
;;;1392       if (len_srch >= len_max) {                                  /* Rtn NULL if srch char NOT found ...                  */
;;;1393           return ((CPU_CHAR *)0);                                 /* ... within max nbr of chars     (see Note #3e1).     */
;;;1394       }
;;;1395   
;;;1396       if (*pstr_char != srch_char) {                              /* Rtn NULL if srch char NOT found (see Note #3c1).     */
;;;1397            return ((CPU_CHAR *)0);
;;;1398       }
;;;1399   
;;;1400   
;;;1401       return ((CPU_CHAR *)pstr_char);                             /* Else rtn ptr to found srch char (see Note #3d1).     */
;;;1402   }
00000e  bd10              POP      {r4,pc}
                  |L6.16|
000010  2000              MOVS     r0,#0                 ;1372
000012  bd10              POP      {r4,pc}
                  |L6.20|
000014  1c40              ADDS     r0,r0,#1              ;1383
000016  1c5b              ADDS     r3,r3,#1              ;1384
                  |L6.24|
000018  b128              CBZ      r0,|L6.38|
00001a  7804              LDRB     r4,[r0,#0]            ;1380
00001c  b11c              CBZ      r4,|L6.38|
00001e  4294              CMP      r4,r2                 ;1381
000020  d001              BEQ      |L6.38|
000022  428b              CMP      r3,r1                 ;1382
000024  d3f6              BCC      |L6.20|
                  |L6.38|
000026  b118              CBZ      r0,|L6.48|
000028  428b              CMP      r3,r1                 ;1392
00002a  d303              BCC      |L6.52|
00002c  2000              MOVS     r0,#0                 ;1393
00002e  bd10              POP      {r4,pc}
                  |L6.48|
000030  2000              MOVS     r0,#0                 ;1389
                  |L6.50|
000032  bd10              POP      {r4,pc}
                  |L6.52|
000034  7801              LDRB     r1,[r0,#0]            ;1396
000036  4291              CMP      r1,r2                 ;1396
000038  d0fb              BEQ      |L6.50|
00003a  2000              MOVS     r0,#0                 ;1397
00003c  bd10              POP      {r4,pc}
;;;1403   
                          ENDP


                          AREA ||i.Str_Char_Replace||, CODE, READONLY, ALIGN=1

                  Str_Char_Replace PROC
;;;1619   
;;;1620   CPU_CHAR  *Str_Char_Replace (CPU_CHAR  *pstr,
000000  f04f33ff          MOV      r3,#0xffffffff
;;;1621                                CPU_CHAR   char_srch,
;;;1622                                CPU_CHAR   char_replace)
;;;1623   {
;;;1624       CPU_CHAR  *pstr_rtn;
;;;1625   
;;;1626   
;;;1627       pstr_rtn = Str_Char_Replace_N(pstr,
000004  f7ffbffe          B.W      Str_Char_Replace_N
;;;1628                                     char_srch,
;;;1629                                     char_replace,
;;;1630                                     DEF_INT_CPU_U_MAX_VAL);
;;;1631   
;;;1632       return (pstr_rtn);
;;;1633   }
;;;1634   
                          ENDP


                          AREA ||i.Str_Char_Replace_N||, CODE, READONLY, ALIGN=1

                  Str_Char_Replace_N PROC
;;;1682   
;;;1683   CPU_CHAR  *Str_Char_Replace_N (CPU_CHAR    *pstr,
000000  b530              PUSH     {r4,r5,lr}
;;;1684                                  CPU_CHAR     char_srch,
;;;1685                                  CPU_CHAR     char_replace,
;;;1686                                  CPU_SIZE_T   len_max)
;;;1687   {
;;;1688       CPU_CHAR    *pstr_char;
;;;1689       CPU_SIZE_T   len;
;;;1690   
;;;1691   
;;;1692       if (pstr == (const CPU_CHAR *)0) {                          /* Rtn NULL if srch str ptr NULL (see Note #2a1).       */
000002  2800              CMP      r0,#0
000004  d002              BEQ      |L8.12|
;;;1693           return ((CPU_CHAR *)0);
;;;1694       }
;;;1695   
;;;1696       if (len_max < 1) {                                          /* Rtn NULL if srch len = 0      (see Note #2e1).       */
000006  b11b              CBZ      r3,|L8.16|
;;;1697           return ((CPU_CHAR *)0);
;;;1698       }
;;;1699   
;;;1700       pstr_char = pstr;
000008  4604              MOV      r4,r0
;;;1701       len       = len_max;
;;;1702   
;;;1703       while (( pstr_char != (const CPU_CHAR *)0) &&               /* Srch str until NULL ptr     [see Note #2b]  ...      */
00000a  e008              B        |L8.30|
                  |L8.12|
00000c  2000              MOVS     r0,#0                 ;1693
;;;1704              (*pstr_char !=  ASCII_CHAR_NULL   ) &&               /* ... or NULL char            (see Note #2c)  ...      */
;;;1705              ( len        >                   0)) {               /* ... or max nbr chars srch'd (see Note #2e).          */
;;;1706   
;;;1707           if (*pstr_char == char_srch) {
;;;1708               *pstr_char  = char_replace;                         /* Replace char if srch char is found.                  */
;;;1709           }
;;;1710   
;;;1711           pstr_char++;
;;;1712           len--;
;;;1713       }
;;;1714   
;;;1715       return (pstr);
;;;1716   }
00000e  bd30              POP      {r4,r5,pc}
                  |L8.16|
000010  2000              MOVS     r0,#0                 ;1697
                  |L8.18|
000012  bd30              POP      {r4,r5,pc}
                  |L8.20|
000014  428d              CMP      r5,r1                 ;1707
000016  d100              BNE      |L8.26|
000018  7022              STRB     r2,[r4,#0]            ;1708
                  |L8.26|
00001a  1c64              ADDS     r4,r4,#1              ;1711
00001c  1e5b              SUBS     r3,r3,#1              ;1712
                  |L8.30|
00001e  2c00              CMP      r4,#0                 ;1703
000020  d0f7              BEQ      |L8.18|
000022  7825              LDRB     r5,[r4,#0]            ;1704
000024  2d00              CMP      r5,#0                 ;1704
000026  d0f4              BEQ      |L8.18|
000028  2b00              CMP      r3,#0                 ;1705
00002a  d1f3              BNE      |L8.20|
00002c  bd30              POP      {r4,r5,pc}
;;;1717   
                          ENDP


                          AREA ||i.Str_Cmp||, CODE, READONLY, ALIGN=1

                  Str_Cmp PROC
;;;758    
;;;759    CPU_INT16S  Str_Cmp (const  CPU_CHAR  *p1_str,
000000  f04f32ff          MOV      r2,#0xffffffff
;;;760                         const  CPU_CHAR  *p2_str)
;;;761    {
;;;762        CPU_INT16S  cmp_val;
;;;763    
;;;764    
;;;765        cmp_val = Str_Cmp_N(p1_str,
000004  f7ffbffe          B.W      Str_Cmp_N
;;;766                            p2_str,
;;;767                            DEF_INT_CPU_U_MAX_VAL);
;;;768    
;;;769        return (cmp_val);
;;;770    }
;;;771    
                          ENDP


                          AREA ||i.Str_CmpIgnoreCase||, CODE, READONLY, ALIGN=1

                  Str_CmpIgnoreCase PROC
;;;1025   /*$PAGE*/
;;;1026   CPU_INT16S  Str_CmpIgnoreCase (const  CPU_CHAR  *p1_str,
000000  f04f32ff          MOV      r2,#0xffffffff
;;;1027                                  const  CPU_CHAR  *p2_str)
;;;1028   {
;;;1029       CPU_INT16S  cmp_val;
;;;1030   
;;;1031   
;;;1032       cmp_val = Str_CmpIgnoreCase_N(p1_str,
000004  f7ffbffe          B.W      Str_CmpIgnoreCase_N
;;;1033                                     p2_str,
;;;1034                                     DEF_INT_CPU_U_MAX_VAL);
;;;1035   
;;;1036       return (cmp_val);
;;;1037   }
;;;1038   
                          ENDP


                          AREA ||i.Str_CmpIgnoreCase_N||, CODE, READONLY, ALIGN=1

                  Str_CmpIgnoreCase_N PROC
;;;1137   
;;;1138   CPU_INT16S  Str_CmpIgnoreCase_N (const  CPU_CHAR    *p1_str,
000000  e92d47f0          PUSH     {r4-r10,lr}
;;;1139                                    const  CPU_CHAR    *p2_str,
;;;1140                                           CPU_SIZE_T   len_max)
;;;1141   {
000004  4692              MOV      r10,r2
;;;1142       const  CPU_CHAR    *p1_str_cmp;
;;;1143       const  CPU_CHAR    *p2_str_cmp;
;;;1144       const  CPU_CHAR    *p1_str_cmp_next;
;;;1145       const  CPU_CHAR    *p2_str_cmp_next;
;;;1146              CPU_CHAR     char_1;
;;;1147              CPU_CHAR     char_2;
;;;1148              CPU_INT16S   cmp_val;
;;;1149              CPU_SIZE_T   cmp_len;
;;;1150   
;;;1151   
;;;1152       if (len_max < 1) {                                          /* If cmp len = 0,        rtn 0       (see Note #3d1A). */
000006  f1ba0f00          CMP      r10,#0
00000a  d011              BEQ      |L11.48|
;;;1153           return (0);
;;;1154       }
;;;1155   
;;;1156       if (p1_str == (const CPU_CHAR *)0) {
00000c  b198              CBZ      r0,|L11.54|
;;;1157           if (p2_str == (const CPU_CHAR *)0) {
;;;1158               return (0);                                         /* If BOTH str ptrs NULL, rtn 0       (see Note #3a1A). */
;;;1159           }
;;;1160           char_2  =  ASCII_ToLower(*p2_str);
;;;1161           cmp_val = (CPU_INT16S)0 - (CPU_INT16S)char_2;
;;;1162           return (cmp_val);                                       /* If p1_str NULL, rtn neg p2_str val (see Note #3a1B1).*/
;;;1163       }
;;;1164       if (p2_str == (const CPU_CHAR *)0) {
00000e  b1d1              CBZ      r1,|L11.70|
;;;1165           char_1  =  ASCII_ToLower(*p1_str);
;;;1166           cmp_val = (CPU_INT16S)char_1;
;;;1167           return (cmp_val);                                       /* If p2_str NULL, rtn pos p1_str val (see Note #3a1B2).*/
;;;1168       }
;;;1169   
;;;1170   
;;;1171       p1_str_cmp      = p1_str;
000010  4604              MOV      r4,r0
;;;1172       p2_str_cmp      = p2_str;
000012  460f              MOV      r7,r1
;;;1173       p1_str_cmp_next = p1_str_cmp;
000014  4620              MOV      r0,r4
;;;1174       p2_str_cmp_next = p2_str_cmp;
000016  4639              MOV      r1,r7
;;;1175       p1_str_cmp_next++;
000018  1c46              ADDS     r6,r0,#1
;;;1176       p2_str_cmp_next++;
00001a  1c4d              ADDS     r5,r1,#1
;;;1177       char_1          = ASCII_ToLower(*p1_str_cmp);
00001c  7820              LDRB     r0,[r4,#0]
00001e  f7fffffe          BL       ASCII_ToLower
000022  4681              MOV      r9,r0
;;;1178       char_2          = ASCII_ToLower(*p2_str_cmp);
000024  7838              LDRB     r0,[r7,#0]
000026  f7fffffe          BL       ASCII_ToLower
;;;1179       cmp_len         = 0u;
00002a  f04f0800          MOV      r8,#0
;;;1180   
;;;1181       while (( char_1          ==  char_2)                &&      /* Cmp strs until non-matching chars (see Note #3c) ... */
00002e  e01c              B        |L11.106|
                  |L11.48|
000030  2000              MOVS     r0,#0                 ;1153
                  |L11.50|
;;;1182              (*p1_str_cmp      != (      CPU_CHAR  )'\0') &&      /* ... or NULL chars                 (see Note #3b) ... */
;;;1183              ( p1_str_cmp_next != (const CPU_CHAR *)  0 ) &&      /* ... or NULL ptr(s) found          (see Note #3a2).   */
;;;1184              ( p2_str_cmp_next != (const CPU_CHAR *)  0 ) &&
;;;1185              ( cmp_len         <  (      CPU_SIZE_T)len_max)) {   /* ... or max nbr chars cmp'd        (see Note #3d2).   */
;;;1186           p1_str_cmp++;
;;;1187           p2_str_cmp++;
;;;1188           p1_str_cmp_next++;
;;;1189           p2_str_cmp_next++;
;;;1190           cmp_len++;
;;;1191           char_1 = ASCII_ToLower(*p1_str_cmp);
;;;1192           char_2 = ASCII_ToLower(*p2_str_cmp);
;;;1193       }
;;;1194   
;;;1195   
;;;1196       if (cmp_len == len_max) {                                   /* If strs     identical for max len nbr of chars, ...  */
;;;1197           return (0);                                             /* ... rtn 0                 (see Note #3d2A).          */
;;;1198       }
;;;1199   
;;;1200       if (char_1 != char_2) {                                     /* If strs NOT identical, ...                           */
;;;1201            cmp_val = (CPU_INT16S)char_1 - (CPU_INT16S)char_2;     /* ... calc & rtn char diff  (see Note #3c1).           */
;;;1202   
;;;1203       } else if (char_1 == (CPU_CHAR)'\0') {                      /* If NULL char(s) found, ...                           */
;;;1204            cmp_val = (CPU_INT16S)0;                               /* ... strs identical; rtn 0 (see Note #3b).            */
;;;1205   
;;;1206       } else {
;;;1207           if (p1_str_cmp_next == (const CPU_CHAR *)0) {
;;;1208               if (p2_str_cmp_next == (const CPU_CHAR *)0) {       /* If BOTH next str ptrs NULL, ...                      */
;;;1209                   cmp_val = (CPU_INT16S)0;                        /* ... rtn 0                       (see Note #3a2A).    */
;;;1210               } else {                                            /* If p1_str_cmp_next NULL, ...                         */
;;;1211                   char_2  =  ASCII_ToLower(*p2_str_cmp_next);
;;;1212                   cmp_val = (CPU_INT16S)0 - (CPU_INT16S)char_2;   /* ... rtn neg p2_str_cmp_next val (see Note #3a2B1).   */
;;;1213               }
;;;1214           } else {                                                /* If p2_str_cmp_next NULL, ...                         */
;;;1215               char_1  =  ASCII_ToLower(*p1_str_cmp_next);
;;;1216               cmp_val = (CPU_INT16S)char_1;                       /* ... rtn pos p1_str_cmp_next val (see Note #3a2B2).   */
;;;1217           }
;;;1218       }
;;;1219   
;;;1220   
;;;1221       return (cmp_val);
;;;1222   }
000032  e8bd87f0          POP      {r4-r10,pc}
                  |L11.54|
000036  b121              CBZ      r1,|L11.66|
000038  7808              LDRB     r0,[r1,#0]            ;1160
00003a  f7fffffe          BL       ASCII_ToLower
00003e  4240              RSBS     r0,r0,#0              ;1161
000040  e7f7              B        |L11.50|
                  |L11.66|
000042  2000              MOVS     r0,#0                 ;1158
000044  e7f5              B        |L11.50|
                  |L11.70|
000046  7800              LDRB     r0,[r0,#0]            ;1165
000048  e8bd47f0          POP      {r4-r10,lr}           ;1165
00004c  f7ffbffe          B.W      ASCII_ToLower
                  |L11.80|
000050  1c64              ADDS     r4,r4,#1              ;1186
000052  1c7f              ADDS     r7,r7,#1              ;1187
000054  1c76              ADDS     r6,r6,#1              ;1188
000056  1c6d              ADDS     r5,r5,#1              ;1189
000058  f1080801          ADD      r8,r8,#1              ;1190
00005c  7820              LDRB     r0,[r4,#0]            ;1191
00005e  f7fffffe          BL       ASCII_ToLower
000062  4681              MOV      r9,r0                 ;1191
000064  7838              LDRB     r0,[r7,#0]            ;1192
000066  f7fffffe          BL       ASCII_ToLower
                  |L11.106|
00006a  4581              CMP      r9,r0                 ;1181
00006c  d105              BNE      |L11.122|
00006e  7821              LDRB     r1,[r4,#0]            ;1182
000070  b119              CBZ      r1,|L11.122|
000072  b116              CBZ      r6,|L11.122|
000074  b10d              CBZ      r5,|L11.122|
000076  45d0              CMP      r8,r10                ;1185
000078  d3ea              BCC      |L11.80|
                  |L11.122|
00007a  45d0              CMP      r8,r10                ;1196
00007c  d101              BNE      |L11.130|
00007e  2000              MOVS     r0,#0                 ;1197
000080  e7d7              B        |L11.50|
                  |L11.130|
000082  4581              CMP      r9,r0                 ;1200
000084  d002              BEQ      |L11.140|
000086  eba90000          SUB      r0,r9,r0              ;1201
00008a  e7d2              B        |L11.50|
                  |L11.140|
00008c  f1b90f00          CMP      r9,#0                 ;1203
000090  d005              BEQ      |L11.158|
000092  b136              CBZ      r6,|L11.162|
000094  7830              LDRB     r0,[r6,#0]            ;1215
000096  e8bd47f0          POP      {r4-r10,lr}           ;1215
00009a  f7ffbffe          B.W      ASCII_ToLower
                  |L11.158|
00009e  2000              MOVS     r0,#0                 ;1204
0000a0  e7c7              B        |L11.50|
                  |L11.162|
0000a2  b125              CBZ      r5,|L11.174|
0000a4  7828              LDRB     r0,[r5,#0]            ;1211
0000a6  f7fffffe          BL       ASCII_ToLower
0000aa  4240              RSBS     r0,r0,#0              ;1212
0000ac  e7c1              B        |L11.50|
                  |L11.174|
0000ae  2000              MOVS     r0,#0                 ;1209
0000b0  e7bf              B        |L11.50|
;;;1223   
                          ENDP


                          AREA ||i.Str_Cmp_N||, CODE, READONLY, ALIGN=1

                  Str_Cmp_N PROC
;;;860    /*$PAGE*/
;;;861    CPU_INT16S  Str_Cmp_N (const  CPU_CHAR    *p1_str,
000000  b5f0              PUSH     {r4-r7,lr}
;;;862                           const  CPU_CHAR    *p2_str,
;;;863                                  CPU_SIZE_T   len_max)
;;;864    {
;;;865        const  CPU_CHAR    *p1_str_cmp;
;;;866        const  CPU_CHAR    *p2_str_cmp;
;;;867        const  CPU_CHAR    *p1_str_cmp_next;
;;;868        const  CPU_CHAR    *p2_str_cmp_next;
;;;869               CPU_INT16S   cmp_val;
;;;870               CPU_SIZE_T   cmp_len;
;;;871    
;;;872    
;;;873        if (len_max < 1) {                                          /* If cmp len = 0,        rtn 0       (see Note #3d1A). */
000002  2a00              CMP      r2,#0
000004  d009              BEQ      |L12.26|
;;;874            return (0);
;;;875        }
;;;876    
;;;877        if (p1_str == (const CPU_CHAR *)0) {
000006  b150              CBZ      r0,|L12.30|
;;;878            if (p2_str == (const CPU_CHAR *)0) {
;;;879                return (0);                                         /* If BOTH str ptrs NULL, rtn 0       (see Note #3a1A). */
;;;880            }
;;;881            cmp_val = (CPU_INT16S)0 - (CPU_INT16S)(*p2_str);
;;;882            return (cmp_val);                                       /* If p1_str NULL, rtn neg p2_str val (see Note #3a1B1).*/
;;;883        }
;;;884        if (p2_str == (const CPU_CHAR *)0) {
000008  b179              CBZ      r1,|L12.42|
;;;885            cmp_val = (CPU_INT16S)(*p1_str);
;;;886            return (cmp_val);                                       /* If p2_str NULL, rtn pos p1_str val (see Note #3a1B2).*/
;;;887        }
;;;888    
;;;889    
;;;890        p1_str_cmp      = p1_str;
00000a  4604              MOV      r4,r0
;;;891        p2_str_cmp      = p2_str;
00000c  460b              MOV      r3,r1
;;;892        p1_str_cmp_next = p1_str_cmp;
00000e  4620              MOV      r0,r4
;;;893        p2_str_cmp_next = p2_str_cmp;
000010  4619              MOV      r1,r3
;;;894        p1_str_cmp_next++;
000012  1c40              ADDS     r0,r0,#1
;;;895        p2_str_cmp_next++;
000014  1c49              ADDS     r1,r1,#1
;;;896        cmp_len         = 0u;
000016  2500              MOVS     r5,#0
;;;897    
;;;898        while ((*p1_str_cmp      == *p2_str_cmp)            &&      /* Cmp strs until non-matching chars (see Note #3c) ... */
000018  e00e              B        |L12.56|
                  |L12.26|
00001a  2000              MOVS     r0,#0                 ;874
;;;899               (*p1_str_cmp      != (      CPU_CHAR  )'\0') &&      /* ... or NULL chars                 (see Note #3b) ... */
;;;900               ( p1_str_cmp_next != (const CPU_CHAR *)  0 ) &&      /* ... or NULL ptr(s) found          (see Note #3a2).   */
;;;901               ( p2_str_cmp_next != (const CPU_CHAR *)  0 ) &&
;;;902               ( cmp_len         <  (      CPU_SIZE_T)len_max)) {   /* ... or max nbr chars cmp'd        (see Note #3d2).   */
;;;903            p1_str_cmp++;
;;;904            p2_str_cmp++;
;;;905            p1_str_cmp_next++;
;;;906            p2_str_cmp_next++;
;;;907            cmp_len++;
;;;908        }
;;;909    
;;;910    
;;;911        if (cmp_len == len_max) {                                   /* If strs     identical for max len nbr of chars, ...  */
;;;912            return (0);                                             /* ... rtn 0                 (see Note #3d2A).          */
;;;913        }
;;;914    
;;;915        if (*p1_str_cmp != *p2_str_cmp) {                           /* If strs NOT identical, ...                           */
;;;916                                                                    /* ... calc & rtn char diff  (see Note #3c1).           */
;;;917             cmp_val = (CPU_INT16S)(*p1_str_cmp) - (CPU_INT16S)(*p2_str_cmp);
;;;918    
;;;919        } else if (*p1_str_cmp  == (CPU_CHAR)'\0') {                /* If NULL char(s) found, ...                           */
;;;920             cmp_val = (CPU_INT16S)0;                               /* ... strs identical; rtn 0 (see Note #3b).            */
;;;921    
;;;922        } else {
;;;923            if (p1_str_cmp_next == (const CPU_CHAR *)0) {
;;;924                if (p2_str_cmp_next == (const CPU_CHAR *)0) {       /* If BOTH next str ptrs NULL, ...                      */
;;;925                    cmp_val = (CPU_INT16S)0;                        /* ... rtn 0                       (see Note #3a2A).    */
;;;926                } else {                                            /* If p1_str_cmp_next NULL, ...                         */
;;;927                                                                    /* ... rtn neg p2_str_cmp_next val (see Note #3a2B1).   */
;;;928                    cmp_val = (CPU_INT16S)0 - (CPU_INT16S)(*p2_str_cmp_next);
;;;929                }
;;;930            } else {                                                /* If p2_str_cmp_next NULL, ...                         */
;;;931                cmp_val = (CPU_INT16S)(*p1_str_cmp_next);           /* ... rtn pos p1_str_cmp_next val (see Note #3a2B2).   */
;;;932            }
;;;933        }
;;;934    
;;;935    
;;;936        return (cmp_val);
;;;937    }
00001c  bdf0              POP      {r4-r7,pc}
                  |L12.30|
00001e  b111              CBZ      r1,|L12.38|
000020  7808              LDRB     r0,[r1,#0]            ;881
000022  4240              RSBS     r0,r0,#0              ;881
000024  bdf0              POP      {r4-r7,pc}
                  |L12.38|
000026  2000              MOVS     r0,#0                 ;879
000028  bdf0              POP      {r4-r7,pc}
                  |L12.42|
00002a  7800              LDRB     r0,[r0,#0]            ;885
00002c  bdf0              POP      {r4-r7,pc}
                  |L12.46|
00002e  1c64              ADDS     r4,r4,#1              ;903
000030  1c5b              ADDS     r3,r3,#1              ;904
000032  1c40              ADDS     r0,r0,#1              ;905
000034  1c49              ADDS     r1,r1,#1              ;906
000036  1c6d              ADDS     r5,r5,#1              ;907
                  |L12.56|
000038  7826              LDRB     r6,[r4,#0]            ;898
00003a  781f              LDRB     r7,[r3,#0]            ;898
00003c  42be              CMP      r6,r7                 ;898
00003e  d104              BNE      |L12.74|
000040  b11e              CBZ      r6,|L12.74|
000042  b110              CBZ      r0,|L12.74|
000044  b109              CBZ      r1,|L12.74|
000046  4295              CMP      r5,r2                 ;902
000048  d3f1              BCC      |L12.46|
                  |L12.74|
00004a  4295              CMP      r5,r2                 ;911
00004c  d101              BNE      |L12.82|
00004e  2000              MOVS     r0,#0                 ;912
000050  bdf0              POP      {r4-r7,pc}
                  |L12.82|
000052  7824              LDRB     r4,[r4,#0]            ;915
000054  781a              LDRB     r2,[r3,#0]            ;915
000056  4294              CMP      r4,r2                 ;915
000058  d001              BEQ      |L12.94|
00005a  1ab0              SUBS     r0,r6,r2              ;917
00005c  bdf0              POP      {r4-r7,pc}
                  |L12.94|
00005e  b116              CBZ      r6,|L12.102|
000060  b118              CBZ      r0,|L12.106|
000062  7800              LDRB     r0,[r0,#0]            ;931
000064  bdf0              POP      {r4-r7,pc}
                  |L12.102|
000066  2000              MOVS     r0,#0                 ;920
000068  bdf0              POP      {r4-r7,pc}
                  |L12.106|
00006a  b111              CBZ      r1,|L12.114|
00006c  7808              LDRB     r0,[r1,#0]            ;928
00006e  4240              RSBS     r0,r0,#0              ;928
000070  bdf0              POP      {r4-r7,pc}
                  |L12.114|
000072  2000              MOVS     r0,#0                 ;925
000074  bdf0              POP      {r4-r7,pc}
;;;938    
                          ENDP


                          AREA ||i.Str_Copy||, CODE, READONLY, ALIGN=1

                  Str_Copy PROC
;;;351    
;;;352    CPU_CHAR  *Str_Copy (       CPU_CHAR  *pstr_dest,
000000  f04f32ff          MOV      r2,#0xffffffff
;;;353                         const  CPU_CHAR  *pstr_src)
;;;354    {
;;;355        CPU_CHAR  *pstr_rtn;
;;;356    
;;;357    
;;;358        pstr_rtn = Str_Copy_N(pstr_dest,
000004  f7ffbffe          B.W      Str_Copy_N
;;;359                              pstr_src,
;;;360                              DEF_INT_CPU_U_MAX_VAL);
;;;361    
;;;362        return (pstr_rtn);
;;;363    }
;;;364    
                          ENDP


                          AREA ||i.Str_Copy_N||, CODE, READONLY, ALIGN=1

                  Str_Copy_N PROC
;;;442    /*$PAGE*/
;;;443    CPU_CHAR  *Str_Copy_N (       CPU_CHAR    *pstr_dest,
000000  b530              PUSH     {r4,r5,lr}
;;;444                           const  CPU_CHAR    *pstr_src,
;;;445                                  CPU_SIZE_T   len_max)
;;;446    {
;;;447               CPU_CHAR    *pstr_copy_dest;
;;;448        const  CPU_CHAR    *pstr_copy_src;
;;;449               CPU_SIZE_T   len_copy;
;;;450    
;;;451                                                                    /* Rtn NULL if str ptr(s) NULL (see Note #3a1).         */
;;;452        if (pstr_dest == (CPU_CHAR *)0) {
000002  2800              CMP      r0,#0
000004  d003              BEQ      |L14.14|
;;;453            return ((CPU_CHAR *)0);
;;;454        }
;;;455        if (pstr_src  == (const CPU_CHAR *)0) {
000006  b121              CBZ      r1,|L14.18|
;;;456            return ((CPU_CHAR *)0);
;;;457        }
;;;458    
;;;459    
;;;460        pstr_copy_dest = pstr_dest;
000008  4603              MOV      r3,r0
;;;461        pstr_copy_src  = pstr_src;
;;;462        len_copy       = 0u;
00000a  2400              MOVS     r4,#0
;;;463    
;;;464        while (( pstr_copy_dest != (      CPU_CHAR *)  0 ) &&       /* Copy str until NULL ptr(s)  [see Note #3b]  ...      */
00000c  e007              B        |L14.30|
                  |L14.14|
00000e  2000              MOVS     r0,#0                 ;453
;;;465               ( pstr_copy_src  != (const CPU_CHAR *)  0 ) &&
;;;466               (*pstr_copy_src  != (      CPU_CHAR  )'\0') &&       /* ... or NULL char found      (see Note #3c); ...      */
;;;467               ( len_copy       <  (      CPU_SIZE_T)len_max)) {    /* ... or max nbr chars copied (see Note #3d).          */
;;;468           *pstr_copy_dest = *pstr_copy_src;
;;;469            pstr_copy_dest++;
;;;470            pstr_copy_src++;
;;;471            len_copy++;
;;;472        }
;;;473                                                                    /* Rtn NULL if NULL ptr(s) found  (see Note #3b1).      */
;;;474        if ((pstr_copy_dest == (      CPU_CHAR *)0) ||
;;;475            (pstr_copy_src  == (const CPU_CHAR *)0)) {
;;;476             return ((CPU_CHAR *)0);
;;;477        }
;;;478    
;;;479        if (len_copy < len_max) {                                   /* If  copy str len < max buf len (see Note #2a2A), ... */
;;;480           *pstr_copy_dest = (CPU_CHAR)'\0';                        /* ... copy NULL char  (see Note #3c1).                 */
;;;481        }
;;;482    
;;;483    
;;;484        return (pstr_dest);                                         /* Rtn ptr to dest str (see Note #2b1).                 */
;;;485    }
000010  bd30              POP      {r4,r5,pc}
                  |L14.18|
000012  2000              MOVS     r0,#0                 ;456
                  |L14.20|
000014  bd30              POP      {r4,r5,pc}
                  |L14.22|
000016  f8035b01          STRB     r5,[r3],#1            ;468
00001a  1c49              ADDS     r1,r1,#1              ;470
00001c  1c64              ADDS     r4,r4,#1              ;471
                  |L14.30|
00001e  b123              CBZ      r3,|L14.42|
000020  b119              CBZ      r1,|L14.42|
000022  780d              LDRB     r5,[r1,#0]            ;466
000024  b10d              CBZ      r5,|L14.42|
000026  4294              CMP      r4,r2                 ;467
000028  d3f5              BCC      |L14.22|
                  |L14.42|
00002a  b12b              CBZ      r3,|L14.56|
00002c  b121              CBZ      r1,|L14.56|
00002e  4294              CMP      r4,r2                 ;479
000030  d2f0              BCS      |L14.20|
000032  2100              MOVS     r1,#0                 ;480
000034  7019              STRB     r1,[r3,#0]            ;480
000036  bd30              POP      {r4,r5,pc}
                  |L14.56|
000038  2000              MOVS     r0,#0                 ;476
00003a  bd30              POP      {r4,r5,pc}
;;;486    
                          ENDP


                          AREA ||i.Str_FmtNbr_Int32||, CODE, READONLY, ALIGN=1

                  Str_FmtNbr_Int32 PROC
;;;3471   
;;;3472   static  CPU_CHAR  *Str_FmtNbr_Int32 (CPU_INT32U    nbr,
000000  e92d5fff          PUSH     {r0-r12,lr}
;;;3473                                        CPU_INT08U    nbr_dig,
;;;3474                                        CPU_INT08U    nbr_base,
;;;3475                                        CPU_BOOLEAN   nbr_neg,
;;;3476                                        CPU_CHAR      lead_char,
;;;3477                                        CPU_BOOLEAN   lower_case,
;;;3478                                        CPU_BOOLEAN   nul,
;;;3479                                        CPU_CHAR     *pstr)
;;;3480   {
000004  4607              MOV      r7,r0
000006  9d0e              LDR      r5,[sp,#0x38]
000008  4689              MOV      r9,r1
00000a  4614              MOV      r4,r2
;;;3481       CPU_CHAR     *pstr_fmt;
;;;3482       CPU_DATA      i;
;;;3483       CPU_INT32U    nbr_fmt;
;;;3484       CPU_INT32U    nbr_log;
;;;3485       CPU_INT08U    nbr_dig_max;
;;;3486       CPU_INT08U    nbr_dig_min;
;;;3487       CPU_INT08U    nbr_dig_fmtd;
;;;3488       CPU_INT08U    nbr_neg_sign;
;;;3489       CPU_INT08U    nbr_lead_char;
;;;3490       CPU_INT08U    dig_val;
;;;3491       CPU_INT08U    lead_char_delta_0;
;;;3492       CPU_INT08U    lead_char_delta_a;
;;;3493       CPU_BOOLEAN   lead_char_dig;
;;;3494       CPU_BOOLEAN   lead_char_0;
;;;3495       CPU_BOOLEAN   fmt_invalid;
;;;3496       CPU_BOOLEAN   print_char;
;;;3497       CPU_BOOLEAN   nbr_neg_fmtd;
;;;3498   
;;;3499   
;;;3500   /*$PAGE*/
;;;3501                                                                   /* ---------------- VALIDATE FMT ARGS ----------------- */
;;;3502       if (pstr == (CPU_CHAR *)0) {                                /* Rtn NULL if str ptr NULL (see Note #6a).             */
00000c  9811              LDR      r0,[sp,#0x44]
00000e  2800              CMP      r0,#0
000010  d004              BEQ      |L15.28|
;;;3503           return ((CPU_CHAR *)0);
;;;3504       }
;;;3505   
;;;3506       fmt_invalid = DEF_NO;
000012  2600              MOVS     r6,#0
;;;3507   
;;;3508       if (nbr_dig < 1) {                                          /* If nbr digs = 0, ...                                 */
000014  f1b90f00          CMP      r9,#0
000018  d004              BEQ      |L15.36|
00001a  e004              B        |L15.38|
                  |L15.28|
00001c  2000              MOVS     r0,#0                 ;3503
                  |L15.30|
;;;3509           fmt_invalid = DEF_YES;                                  /* ... fmt invalid str (see Note #6b).                  */
;;;3510       }
;;;3511                                                                   /* If invalid base, ...                                 */
;;;3512       if ((nbr_base <  2u) ||
;;;3513           (nbr_base > 36u)) {
;;;3514           fmt_invalid = DEF_YES;                                  /* ... fmt invalid str (see Note #6d).                  */
;;;3515       }
;;;3516   
;;;3517       if (lead_char != (CPU_CHAR)'\0') {
;;;3518           print_char =  ASCII_IsPrint(lead_char);
;;;3519           if (print_char != DEF_YES) {                            /* If lead char non-printable (see Note #3a1), ...      */
;;;3520               fmt_invalid = DEF_YES;                              /* ... fmt invalid str        (see Note #6e).           */
;;;3521   
;;;3522           } else if (lead_char != '0') {                          /* Chk lead char for non-0 nbr base dig.                */
;;;3523               lead_char_delta_0 = (CPU_INT08U)(lead_char - '0');
;;;3524               if (lower_case != DEF_YES) {
;;;3525                   lead_char_delta_a = (CPU_INT08U)(lead_char - 'A');
;;;3526               } else {
;;;3527                   lead_char_delta_a = (CPU_INT08U)(lead_char - 'a');
;;;3528               }
;;;3529   
;;;3530               lead_char_dig = (((nbr_base <= 10u) &&  (lead_char_delta_0 <  nbr_base))      ||
;;;3531                                ((nbr_base >  10u) && ((lead_char_delta_0 <             10u) ||
;;;3532                                                       (lead_char_delta_a < (nbr_base - 10u))))) ? DEF_YES : DEF_NO;
;;;3533   
;;;3534               if (lead_char_dig == DEF_YES) {                     /* If lead char non-0 nbr base dig (see Note #3a2A), ...*/
;;;3535                   fmt_invalid = DEF_YES;                          /* ... fmt invalid str             (see Note #6e).      */
;;;3536               }
;;;3537           }
;;;3538       }
;;;3539   
;;;3540   
;;;3541                                                                   /* ----------------- PREPARE NBR FMT ------------------ */
;;;3542       pstr_fmt = pstr;
;;;3543   
;;;3544       if (fmt_invalid == DEF_NO) {
;;;3545           nbr_fmt     = nbr;
;;;3546           nbr_log     = nbr;
;;;3547           nbr_dig_max = 1u;
;;;3548           while (nbr_log >= nbr_base) {                           /* While nbr base digs avail, ...                       */
;;;3549               nbr_dig_max++;                                      /* ... calc max nbr digs.                               */
;;;3550               nbr_log /= nbr_base;
;;;3551           }
;;;3552   
;;;3553           nbr_neg_sign = (nbr_neg == DEF_YES) ? 1u : 0u;
;;;3554           if (nbr_dig >= (nbr_dig_max + nbr_neg_sign)) {          /* If req'd nbr digs >= (max nbr digs + neg sign), ...  */
;;;3555               nbr_neg_fmtd = DEF_NO;
;;;3556               nbr_dig_min  = DEF_MIN(nbr_dig_max, nbr_dig);
;;;3557                                                                   /* ... calc nbr digs to fmt & nbr lead chars.           */
;;;3558               if (lead_char != (CPU_CHAR)'\0') {
;;;3559                   nbr_dig_fmtd  = nbr_dig;
;;;3560                   nbr_lead_char = nbr_dig     -
;;;3561                                   nbr_dig_min - nbr_neg_sign;
;;;3562               } else {
;;;3563                   nbr_dig_fmtd  = nbr_dig_min + nbr_neg_sign;
;;;3564                   nbr_lead_char = 0u;
;;;3565               }
;;;3566   
;;;3567               if (nbr_lead_char > 0) {                            /* If lead chars to fmt, ...                            */
;;;3568                   lead_char_0 = (lead_char == '0')                /* ... chk if lead char a '0' dig (see Note #3a2B).     */
;;;3569                               ?  DEF_YES : DEF_NO;
;;;3570               } else {
;;;3571                   lead_char_0 =  DEF_NO;
;;;3572               }
;;;3573   
;;;3574           } else {                                                /* Else if nbr trunc'd, ...                             */
;;;3575               fmt_invalid = DEF_YES;                              /* ... fmt invalid str (see Note #6c).                  */
;;;3576           }
;;;3577       }
;;;3578   
;;;3579       if (fmt_invalid != DEF_NO) {
;;;3580           nbr_dig_fmtd = nbr_dig;
;;;3581       }
;;;3582   
;;;3583   
;;;3584   /*$PAGE*/
;;;3585                                                                   /* ------------------- FMT NBR STR -------------------- */
;;;3586       pstr_fmt += nbr_dig_fmtd;                                   /* Start fmt @ least-sig dig.                           */
;;;3587   
;;;3588       if (nul != DEF_NO) {                                        /* If NOT DISABLED, append NULL char (see Note #4).     */
;;;3589          *pstr_fmt = (CPU_CHAR)'\0';
;;;3590       }
;;;3591       pstr_fmt--;
;;;3592   
;;;3593   
;;;3594       for (i = 0u; i < nbr_dig_fmtd; i++) {                       /* Fmt str for desired nbr digs :                       */
;;;3595           if (fmt_invalid == DEF_NO) {
;;;3596               if ((nbr_fmt > 0) ||                                /* If fmt nbr > 0                               ...     */
;;;3597                   (i == 0u)) {                                    /* ... OR on one's  dig to fmt (see Note #3c1), ...     */
;;;3598                                                                   /* ... calc & fmt dig val;                      ...     */
;;;3599                   dig_val = (CPU_INT08U)(nbr_fmt % nbr_base);
;;;3600                   if (dig_val < 10u) {
;;;3601                      *pstr_fmt-- = (CPU_CHAR)(dig_val + '0');
;;;3602                   } else {
;;;3603                       if (lower_case !=  DEF_YES) {
;;;3604                          *pstr_fmt--  = (CPU_CHAR)((dig_val - 10u) + 'A');
;;;3605                       } else {
;;;3606                          *pstr_fmt--  = (CPU_CHAR)((dig_val - 10u) + 'a');
;;;3607                       }
;;;3608                   }
;;;3609   
;;;3610                   nbr_fmt /= nbr_base;                            /* Shift to next more-sig dig.                          */
;;;3611   
;;;3612               } else if ((nbr_neg      == DEF_YES)  &&            /* ... else if nbr neg             AND          ...     */
;;;3613                        (((lead_char_0  == DEF_NO )  &&            /* ... lead char NOT a '0' dig                  ...     */
;;;3614                          (nbr_neg_fmtd == DEF_NO )) ||            /* ... but neg sign NOT yet fmt'd  OR           ...     */
;;;3615                         ((lead_char_0  != DEF_NO )  &&            /* ... lead char is  a '0' dig                  ...     */
;;;3616                          (i == (nbr_dig_fmtd - 1u))))) {          /* ... & on most-sig dig to fmt,                ...     */
;;;3617   
;;;3618                  *pstr_fmt--   = '-';                             /* ... prepend neg sign (see Note #3b);         ...     */
;;;3619                   nbr_neg_fmtd = DEF_YES;
;;;3620   
;;;3621               } else if (lead_char != (CPU_CHAR)'\0') {           /* ... else if avail,                           ...     */
;;;3622                  *pstr_fmt-- = lead_char;                         /* ... fmt lead char.                                   */
;;;3623               }
;;;3624   
;;;3625           } else {                                                /* Else fmt '?' for invalid str (see Note #7).          */
;;;3626              *pstr_fmt-- = '?';
;;;3627           }
;;;3628       }
;;;3629   
;;;3630   
;;;3631       if (fmt_invalid != DEF_NO) {                                /* Rtn NULL for invalid str fmt (see Notes #6a - #6e).  */
;;;3632           return ((CPU_CHAR *)0);
;;;3633       }
;;;3634   
;;;3635   
;;;3636       return (pstr);                                              /* Rtn ptr to fmt'd str (see Note #6f).                 */
;;;3637   }
00001e  b004              ADD      sp,sp,#0x10
000020  e8bd9ff0          POP      {r4-r12,pc}
                  |L15.36|
000024  2601              MOVS     r6,#1                 ;3509
                  |L15.38|
000026  1ea0              SUBS     r0,r4,#2              ;3512
000028  2823              CMP      r0,#0x23              ;3512
00002a  d300              BCC      |L15.46|
00002c  2601              MOVS     r6,#1                 ;3514
                  |L15.46|
00002e  b33d              CBZ      r5,|L15.128|
000030  4628              MOV      r0,r5                 ;3518
000032  f7fffffe          BL       ASCII_IsPrint
000036  2801              CMP      r0,#1                 ;3519
000038  d001              BEQ      |L15.62|
00003a  2601              MOVS     r6,#1                 ;3520
00003c  e020              B        |L15.128|
                  |L15.62|
00003e  2d30              CMP      r5,#0x30              ;3522
000040  d01e              BEQ      |L15.128|
000042  f1a50030          SUB      r0,r5,#0x30           ;3523
000046  b2c0              UXTB     r0,r0                 ;3523
000048  990f              LDR      r1,[sp,#0x3c]         ;3524
00004a  2901              CMP      r1,#1                 ;3524
00004c  d003              BEQ      |L15.86|
00004e  f1a50141          SUB      r1,r5,#0x41           ;3525
000052  b2c9              UXTB     r1,r1                 ;3525
000054  e002              B        |L15.92|
                  |L15.86|
000056  f1a50161          SUB      r1,r5,#0x61           ;3527
00005a  b2c9              UXTB     r1,r1                 ;3527
                  |L15.92|
00005c  2c0a              CMP      r4,#0xa               ;3530
00005e  d801              BHI      |L15.100|
000060  42a0              CMP      r0,r4                 ;3530
000062  d307              BCC      |L15.116|
                  |L15.100|
000064  2c0a              CMP      r4,#0xa               ;3531
000066  d907              BLS      |L15.120|
000068  280a              CMP      r0,#0xa               ;3531
00006a  d303              BCC      |L15.116|
00006c  f1a4000a          SUB      r0,r4,#0xa            ;3532
000070  4281              CMP      r1,r0                 ;3532
000072  d201              BCS      |L15.120|
                  |L15.116|
000074  2001              MOVS     r0,#1                 ;3532
000076  e000              B        |L15.122|
                  |L15.120|
000078  2000              MOVS     r0,#0                 ;3532
                  |L15.122|
00007a  2801              CMP      r0,#1                 ;3534
00007c  d100              BNE      |L15.128|
00007e  2601              MOVS     r6,#1                 ;3535
                  |L15.128|
000080  9a11              LDR      r2,[sp,#0x44]         ;3542
000082  bb36              CBNZ     r6,|L15.210|
000084  4638              MOV      r0,r7                 ;3546
000086  2101              MOVS     r1,#1                 ;3547
000088  e003              B        |L15.146|
                  |L15.138|
00008a  1c49              ADDS     r1,r1,#1              ;3549
00008c  b2c9              UXTB     r1,r1                 ;3549
00008e  fbb0f0f4          UDIV     r0,r0,r4              ;3550
                  |L15.146|
000092  42a0              CMP      r0,r4                 ;3548
000094  d2f9              BCS      |L15.138|
000096  9803              LDR      r0,[sp,#0xc]          ;3553
000098  2801              CMP      r0,#1                 ;3553
00009a  d00f              BEQ      |L15.188|
00009c  2000              MOVS     r0,#0                 ;3553
                  |L15.158|
00009e  180b              ADDS     r3,r1,r0              ;3554
0000a0  454b              CMP      r3,r9                 ;3554
0000a2  d81d              BHI      |L15.224|
0000a4  f04f0b00          MOV      r11,#0                ;3555
0000a8  4549              CMP      r1,r9                 ;3556
0000aa  d300              BCC      |L15.174|
0000ac  4649              MOV      r1,r9                 ;3556
                  |L15.174|
0000ae  b13d              CBZ      r5,|L15.192|
0000b0  eba90101          SUB      r1,r9,r1              ;3560
0000b4  1a08              SUBS     r0,r1,r0              ;3560
0000b6  46c8              MOV      r8,r9                 ;3560
0000b8  b2c0              UXTB     r0,r0                 ;3560
0000ba  e005              B        |L15.200|
                  |L15.188|
0000bc  2001              MOVS     r0,#1                 ;3553
0000be  e7ee              B        |L15.158|
                  |L15.192|
0000c0  4408              ADD      r0,r0,r1              ;3563
0000c2  f00008ff          AND      r8,r0,#0xff           ;3563
0000c6  2000              MOVS     r0,#0                 ;3564
                  |L15.200|
0000c8  b138              CBZ      r0,|L15.218|
0000ca  2d30              CMP      r5,#0x30              ;3568
0000cc  d002              BEQ      |L15.212|
0000ce  f04f0a00          MOV      r10,#0                ;3569
                  |L15.210|
0000d2  e006              B        |L15.226|
                  |L15.212|
0000d4  f04f0a01          MOV      r10,#1                ;3569
0000d8  e003              B        |L15.226|
                  |L15.218|
0000da  f04f0a00          MOV      r10,#0                ;3571
0000de  e000              B        |L15.226|
                  |L15.224|
0000e0  2601              MOVS     r6,#1                 ;3575
                  |L15.226|
0000e2  b106              CBZ      r6,|L15.230|
0000e4  46c8              MOV      r8,r9                 ;3580
                  |L15.230|
0000e6  eb020008          ADD      r0,r2,r8              ;3586
0000ea  9910              LDR      r1,[sp,#0x40]         ;3588
0000ec  b109              CBZ      r1,|L15.242|
0000ee  2100              MOVS     r1,#0                 ;3589
0000f0  7001              STRB     r1,[r0,#0]            ;3589
                  |L15.242|
0000f2  1e40              SUBS     r0,r0,#1              ;3591
0000f4  2100              MOVS     r1,#0                 ;3594
0000f6  e004              B        |L15.258|
                  |L15.248|
0000f8  b146              CBZ      r6,|L15.268|
0000fa  223f              MOVS     r2,#0x3f              ;3626
0000fc  f8002901          STRB     r2,[r0],#-1           ;3626
                  |L15.256|
000100  1c49              ADDS     r1,r1,#1              ;3594
                  |L15.258|
000102  4541              CMP      r1,r8                 ;3594
000104  d3f8              BCC      |L15.248|
000106  b37e              CBZ      r6,|L15.360|
000108  2000              MOVS     r0,#0                 ;3632
00010a  e788              B        |L15.30|
                  |L15.268|
00010c  b927              CBNZ     r7,|L15.280|
00010e  b119              CBZ      r1,|L15.280|
000110  9a03              LDR      r2,[sp,#0xc]          ;3612
000112  2a01              CMP      r2,#1                 ;3612
000114  d018              BEQ      |L15.328|
000116  e028              B        |L15.362|
                  |L15.280|
000118  fbb7f2f4          UDIV     r2,r7,r4              ;3599
00011c  fb047212          MLS      r2,r4,r2,r7           ;3599
000120  b2d2              UXTB     r2,r2                 ;3599
000122  2a0a              CMP      r2,#0xa               ;3600
000124  d203              BCS      |L15.302|
000126  3230              ADDS     r2,r2,#0x30           ;3601
000128  f8002901          STRB     r2,[r0],#-1           ;3601
00012c  e009              B        |L15.322|
                  |L15.302|
00012e  9b0f              LDR      r3,[sp,#0x3c]         ;3603
000130  2b01              CMP      r3,#1                 ;3603
000132  d003              BEQ      |L15.316|
000134  3237              ADDS     r2,r2,#0x37           ;3604
000136  f8002901          STRB     r2,[r0],#-1           ;3604
00013a  e002              B        |L15.322|
                  |L15.316|
00013c  3257              ADDS     r2,r2,#0x57           ;3606
00013e  f8002901          STRB     r2,[r0],#-1           ;3606
                  |L15.322|
000142  fbb7f7f4          UDIV     r7,r7,r4              ;3610
000146  e7db              B        |L15.256|
                  |L15.328|
000148  ea5a020b          ORRS     r2,r10,r11            ;3613
00014c  d006              BEQ      |L15.348|
00014e  f1ba0f00          CMP      r10,#0                ;3615
000152  d00a              BEQ      |L15.362|
000154  f1a80201          SUB      r2,r8,#1              ;3616
000158  4291              CMP      r1,r2                 ;3616
00015a  d106              BNE      |L15.362|
                  |L15.348|
00015c  222d              MOVS     r2,#0x2d              ;3618
00015e  f8002901          STRB     r2,[r0],#-1           ;3618
000162  f04f0b01          MOV      r11,#1                ;3619
000166  e7cb              B        |L15.256|
                  |L15.360|
000168  e004              B        |L15.372|
                  |L15.362|
00016a  2d00              CMP      r5,#0                 ;3621
00016c  d0c8              BEQ      |L15.256|
00016e  f8005901          STRB     r5,[r0],#-1           ;3622
000172  e7c5              B        |L15.256|
                  |L15.372|
000174  9811              LDR      r0,[sp,#0x44]         ;3636
000176  e752              B        |L15.30|
;;;3638   
                          ENDP


                          AREA ||i.Str_FmtNbr_Int32S||, CODE, READONLY, ALIGN=1

                  Str_FmtNbr_Int32S PROC
;;;2275   
;;;2276   CPU_CHAR  *Str_FmtNbr_Int32S (CPU_INT32S    nbr,
000000  e92d41ff          PUSH     {r0-r8,lr}
;;;2277                                 CPU_INT08U    nbr_dig,
;;;2278                                 CPU_INT08U    nbr_base,
;;;2279                                 CPU_CHAR      lead_char,
;;;2280                                 CPU_BOOLEAN   lower_case,
;;;2281                                 CPU_BOOLEAN   nul,
;;;2282                                 CPU_CHAR     *pstr)
;;;2283   {
000004  461c              MOV      r4,r3
000006  e9dd760a          LDRD     r7,r6,[sp,#0x28]
00000a  9d0c              LDR      r5,[sp,#0x30]
;;;2284       CPU_CHAR     *pstr_fmt;
;;;2285       CPU_INT32S    nbr_fmt;
;;;2286       CPU_BOOLEAN   nbr_neg;
;;;2287   
;;;2288   
;;;2289       if (nbr < 0) {                                              /* If nbr neg, ...                                      */
00000c  2800              CMP      r0,#0
00000e  da02              BGE      |L16.22|
;;;2290           nbr_fmt = -nbr;                                         /* ... negate nbr.                                      */
000010  4240              RSBS     r0,r0,#0
;;;2291           nbr_neg =  DEF_YES;
000012  2301              MOVS     r3,#1
000014  e000              B        |L16.24|
                  |L16.22|
;;;2292       } else {
;;;2293           nbr_fmt =  nbr;
;;;2294           nbr_neg =  DEF_NO;
000016  2300              MOVS     r3,#0
                  |L16.24|
;;;2295       }
;;;2296   
;;;2297       pstr_fmt = Str_FmtNbr_Int32((CPU_INT32U)nbr_fmt,            /* Fmt signed int into str.                             */
000018  e9cd7601          STRD     r7,r6,[sp,#4]
00001c  9503              STR      r5,[sp,#0xc]
00001e  9400              STR      r4,[sp,#0]
000020  f7fffffe          BL       Str_FmtNbr_Int32
;;;2298                                               nbr_dig,
;;;2299                                               nbr_base,
;;;2300                                               nbr_neg,
;;;2301                                               lead_char,
;;;2302                                               lower_case,
;;;2303                                               nul,
;;;2304                                               pstr);
;;;2305   
;;;2306       return (pstr_fmt);
;;;2307   }
000024  b004              ADD      sp,sp,#0x10
000026  e8bd81f0          POP      {r4-r8,pc}
;;;2308   
                          ENDP


                          AREA ||i.Str_FmtNbr_Int32U||, CODE, READONLY, ALIGN=1

                  Str_FmtNbr_Int32U PROC
;;;2058   
;;;2059   CPU_CHAR  *Str_FmtNbr_Int32U (CPU_INT32U    nbr,
000000  b57f              PUSH     {r0-r6,lr}
;;;2060                                 CPU_INT08U    nbr_dig,
;;;2061                                 CPU_INT08U    nbr_base,
;;;2062                                 CPU_CHAR      lead_char,
;;;2063                                 CPU_BOOLEAN   lower_case,
;;;2064                                 CPU_BOOLEAN   nul,
;;;2065                                 CPU_CHAR     *pstr)
;;;2066   {
000002  e9dd6508          LDRD     r6,r5,[sp,#0x20]
000006  9c0a              LDR      r4,[sp,#0x28]
;;;2067       CPU_CHAR  *pstr_fmt;
;;;2068   
;;;2069   
;;;2070       pstr_fmt = Str_FmtNbr_Int32(nbr,                            /* Fmt unsigned int into str.                           */
000008  e9cd6501          STRD     r6,r5,[sp,#4]
00000c  9300              STR      r3,[sp,#0]
00000e  9403              STR      r4,[sp,#0xc]
000010  2300              MOVS     r3,#0
000012  f7fffffe          BL       Str_FmtNbr_Int32
;;;2071                                   nbr_dig,
;;;2072                                   nbr_base,
;;;2073                                   DEF_NO,
;;;2074                                   lead_char,
;;;2075                                   lower_case,
;;;2076                                   nul,
;;;2077                                   pstr);
;;;2078   
;;;2079       return (pstr_fmt);
;;;2080   }
000016  b004              ADD      sp,sp,#0x10
000018  bd70              POP      {r4-r6,pc}
;;;2081   
                          ENDP


                          AREA ||i.Str_Len||, CODE, READONLY, ALIGN=1

                  Str_Len PROC
;;;218    
;;;219    CPU_SIZE_T  Str_Len (const  CPU_CHAR  *pstr)
000000  f04f31ff          MOV      r1,#0xffffffff
;;;220    {
;;;221        CPU_SIZE_T  len;
;;;222    
;;;223    
;;;224        len = Str_Len_N(pstr,
000004  f7ffbffe          B.W      Str_Len_N
;;;225                        DEF_INT_CPU_U_MAX_VAL);
;;;226    
;;;227        return (len);
;;;228    }
;;;229    
                          ENDP


                          AREA ||i.Str_Len_N||, CODE, READONLY, ALIGN=1

                  Str_Len_N PROC
;;;278    
;;;279    CPU_SIZE_T  Str_Len_N (const  CPU_CHAR    *pstr,
000000  2200              MOVS     r2,#0
;;;280                                  CPU_SIZE_T   len_max)
;;;281    {
000002  e001              B        |L19.8|
                  |L19.4|
;;;282        const  CPU_CHAR    *pstr_len;
;;;283               CPU_SIZE_T   len;
;;;284    
;;;285    
;;;286        pstr_len = pstr;
;;;287        len      = 0u;
;;;288        while (( pstr_len != (const CPU_CHAR *)  0 ) &&             /* Calc str len until NULL ptr (see Note #3a) ...       */
;;;289               (*pstr_len != (      CPU_CHAR  )'\0') &&             /* ... or NULL char found      (see Note #3b) ...       */
;;;290               ( len      <  (      CPU_SIZE_T)len_max)) {          /* ... or max nbr chars srch'd (see Note #3c).          */
;;;291            pstr_len++;
000004  1c40              ADDS     r0,r0,#1
;;;292            len++;
000006  1c52              ADDS     r2,r2,#1
                  |L19.8|
000008  b118              CBZ      r0,|L19.18|
00000a  7803              LDRB     r3,[r0,#0]            ;289
00000c  b10b              CBZ      r3,|L19.18|
00000e  428a              CMP      r2,r1                 ;290
000010  d3f8              BCC      |L19.4|
                  |L19.18|
;;;293        }
;;;294    
;;;295        return (len);                                               /* Rtn str len (see Note #3b1).                         */
000012  4610              MOV      r0,r2
;;;296    }
000014  4770              BX       lr
;;;297    
                          ENDP


                          AREA ||i.Str_ParseNbr_Int32||, CODE, READONLY, ALIGN=2

                  Str_ParseNbr_Int32 PROC
;;;3866   /*$PAGE*/
;;;3867   static  CPU_INT32U  Str_ParseNbr_Int32 (const  CPU_CHAR      *pstr,
000000  e92d5fff          PUSH     {r0-r12,lr}
;;;3868                                                  CPU_CHAR     **pstr_next,
;;;3869                                                  CPU_INT08U     nbr_base,
;;;3870                                                  CPU_BOOLEAN    nbr_signed,
;;;3871                                                  CPU_BOOLEAN   *pnbr_neg)
;;;3872   {
000004  4682              MOV      r10,r0
000006  4689              MOV      r9,r1
000008  4615              MOV      r5,r2
00000a  461e              MOV      r6,r3
;;;3873       const  CPU_CHAR     *pstr_parse;
;;;3874       const  CPU_CHAR     *pstr_parse_nbr;
;;;3875              CPU_CHAR     *pstr_parse_unused;
;;;3876              CPU_CHAR      parse_char;
;;;3877              CPU_INT08U    parse_dig;
;;;3878              CPU_INT32U    nbr;
;;;3879              CPU_BOOLEAN   nbr_neg_unused;
;;;3880              CPU_BOOLEAN   nbr_dig;
;;;3881              CPU_BOOLEAN   nbr_alpha;
;;;3882              CPU_BOOLEAN   nbr_hex;
;;;3883              CPU_BOOLEAN   nbr_hex_lower;
;;;3884              CPU_BOOLEAN   whitespace;
;;;3885              CPU_BOOLEAN   neg;
;;;3886              CPU_BOOLEAN   ovf;
;;;3887              CPU_BOOLEAN   done;
;;;3888   
;;;3889                                                                   /* --------------- VALIDATE PARSE ARGS ---------------- */
;;;3890       if (pstr_next == (CPU_CHAR **) 0) {                         /* If NOT avail, ...                                    */
00000c  f1b90f00          CMP      r9,#0
000010  d101              BNE      |L20.22|
;;;3891           pstr_next  = (CPU_CHAR **)&pstr_parse_unused;           /* ... re-cfg NULL rtn ptr to unused local var.         */
000012  f10d0908          ADD      r9,sp,#8
                  |L20.22|
;;;3892          (void)&pstr_parse_unused;                                /* Prevent possible 'variable unused' warning.          */
;;;3893       }
;;;3894      *pstr_next = (CPU_CHAR *)pstr;                               /* Init rtn str for err (see Note #5).                  */
000016  f8c9a000          STR      r10,[r9,#0]
;;;3895   
;;;3896       if (pnbr_neg == (CPU_BOOLEAN *) 0) {                        /* If NOT avail, ...                                    */
00001a  980e              LDR      r0,[sp,#0x38]
00001c  b908              CBNZ     r0,|L20.34|
;;;3897           pnbr_neg  = (CPU_BOOLEAN *)&nbr_neg_unused;             /* ... re-cfg NULL rtn ptr to unused local var.         */
00001e  a801              ADD      r0,sp,#4
000020  900e              STR      r0,[sp,#0x38]
                  |L20.34|
;;;3898          (void)&nbr_neg_unused;                                   /* Prevent possible 'variable unused' warning.          */
;;;3899       }
;;;3900      *pnbr_neg = DEF_NO;                                          /* Init nbr neg for err (see Note #5).                  */
000022  980e              LDR      r0,[sp,#0x38]
000024  2100              MOVS     r1,#0
000026  7001              STRB     r1,[r0,#0]
;;;3901   
;;;3902   
;;;3903       if (pstr == (CPU_CHAR *)0) {                                /* Rtn zero if str ptr NULL (see Note #4b1).            */
000028  f1ba0f00          CMP      r10,#0
00002c  d007              BEQ      |L20.62|
;;;3904           return (0u);
;;;3905       }
;;;3906                                                                   /* Rtn zero if invalid base (see Note #4a).             */
;;;3907       if ((nbr_base == 1u) ||
00002e  2d01              CMP      r5,#1
000030  d001              BEQ      |L20.54|
;;;3908           (nbr_base > 36u)) {
000032  2d24              CMP      r5,#0x24
000034  d905              BLS      |L20.66|
                  |L20.54|
;;;3909           return (0u);
000036  2000              MOVS     r0,#0
                  |L20.56|
;;;3910       }
;;;3911   
;;;3912   
;;;3913                                                                   /* ------------- IGNORE PRECEDING CHAR(S) ------------- */
;;;3914       pstr_parse = pstr;                                          /* Save ptr to init'l str for err (see Note #2a2A2).    */
;;;3915   
;;;3916       whitespace = ASCII_IsSpace(*pstr_parse);
;;;3917       while (whitespace == DEF_YES) {                             /* Ignore initial white-space char(s) [see Note #2a1A]. */
;;;3918           pstr_parse++;
;;;3919           whitespace = ASCII_IsSpace(*pstr_parse);
;;;3920       }
;;;3921   
;;;3922       switch (*pstr_parse) {
;;;3923           case '+':                                               /* Ignore   pos sign (see Note #2a1B2).                 */
;;;3924                pstr_parse++;
;;;3925                neg = DEF_NO;
;;;3926                break;
;;;3927   
;;;3928   
;;;3929           case '-':                                               /* Validate neg sign (see Note #2a1B2a).                */
;;;3930                if (nbr_signed == DEF_YES) {
;;;3931                    pstr_parse++;
;;;3932                }
;;;3933                neg = DEF_YES;
;;;3934                break;
;;;3935   
;;;3936   
;;;3937           default:
;;;3938                neg = DEF_NO;
;;;3939                break;
;;;3940       }
;;;3941   
;;;3942   
;;;3943   /*$PAGE*/
;;;3944                                                                   /* --------- IGNORE NBR BASE PRECEDING CHAR(S) -------- */
;;;3945       pstr_parse_nbr = pstr_parse;                                /* Save ptr to str's nbr (see Note #2a1A1).             */
;;;3946   
;;;3947       switch (nbr_base) {
;;;3948           case  0u:                                               /* Determine unspecified nbr base (see Notes #2a1B1a).  */
;;;3949                if (*pstr_parse == '0') {                          /* If avail, ...                                        */
;;;3950                     pstr_parse++;                                 /* ... adv past '0'  prefix (see Note #2a1B1b2).        */
;;;3951                     switch (*pstr_parse) {
;;;3952                         case 'x':                                 /* For '0x' prefix, ...                                 */
;;;3953                         case 'X':
;;;3954                              nbr_base   = 16u;                    /* ... set nbr base = 16    (see Note #2a1B1a3).        */
;;;3955                              parse_char = (CPU_CHAR)(*(pstr_parse + 1));
;;;3956                              nbr_hex    =  ASCII_IsDigHex(parse_char);
;;;3957                              if (nbr_hex == DEF_YES) {            /* If next char is valid hex dig, ...                   */
;;;3958                                  pstr_parse++;                    /* ... adv past '0x' prefix (see Note #2a1B1b2A).       */
;;;3959                              }
;;;3960                              break;
;;;3961   
;;;3962   
;;;3963                         default:                                  /* For '0'  prefix, ...                                 */
;;;3964                              nbr_base =  8u;                      /* ... set nbr base =  8    (see Note #2a1B1a2).        */
;;;3965                              break;
;;;3966                     }
;;;3967   
;;;3968                } else {                                           /* For non-'0' prefix, ...                              */
;;;3969                    nbr_base = 10u;                                /* ... set nbr base = 10    (see Note #2a1B1a1).        */
;;;3970                }
;;;3971                break;
;;;3972   
;;;3973   
;;;3974           case  8u:                                               /* See Note #2a1B1a2.                                   */
;;;3975                if (*pstr_parse == '0') {                          /* If avail, ...                                        */
;;;3976                     pstr_parse++;                                 /* ... adv past '0'  prefix (see Note #2a1B1b2B).       */
;;;3977                }
;;;3978                break;
;;;3979   
;;;3980   
;;;3981           case 16u:                                               /* See Note #2a1B1a3.                                   */
;;;3982                if (*pstr_parse == '0') {                          /* If avail, ...                                        */
;;;3983                     pstr_parse++;                                 /* ... adv past '0'  prefix (see Note #2a1B1b2).        */
;;;3984                     switch (*pstr_parse) {
;;;3985                         case 'x':
;;;3986                         case 'X':
;;;3987                              parse_char = (CPU_CHAR)(*(pstr_parse + 1));
;;;3988                              nbr_hex    =  ASCII_IsDigHex(parse_char);
;;;3989                              if (nbr_hex == DEF_YES) {            /* If next char is valid hex dig, ...                   */
;;;3990                                  pstr_parse++;                    /* ... adv past '0x' prefix (see Note #2a1B1b2A).       */
;;;3991                              }
;;;3992                              break;
;;;3993   
;;;3994   
;;;3995                         default:
;;;3996                              break;
;;;3997                     }
;;;3998                }
;;;3999                break;
;;;4000   
;;;4001   
;;;4002           default:                                                /* See Note #2a1B1b.                                    */
;;;4003                break;
;;;4004       }
;;;4005   
;;;4006   
;;;4007   /*$PAGE*/
;;;4008                                                                   /* ------------------ PARSE INT STR ------------------- */
;;;4009       nbr  = 0u;
;;;4010       ovf  = DEF_NO;
;;;4011       done = DEF_NO;
;;;4012   
;;;4013       while (done == DEF_NO) {                                    /* Parse str for desired nbr base digs (see Note #2a2). */
;;;4014           parse_char = (CPU_CHAR)*pstr_parse;
;;;4015           nbr_alpha  =  ASCII_IsAlphaNum(parse_char);
;;;4016           if (nbr_alpha == DEF_YES) {                             /* If valid alpha num nbr dig avail, ...                */
;;;4017                                                                   /* ... convert parse char into nbr dig.                 */
;;;4018               nbr_dig = ASCII_IsDig(parse_char);
;;;4019               if (nbr_dig == DEF_YES) {
;;;4020                   parse_dig = (CPU_INT08U)(parse_char - '0');
;;;4021               } else {
;;;4022                   nbr_hex_lower = ASCII_IsLower(parse_char);
;;;4023                   if (nbr_hex_lower == DEF_YES) {
;;;4024                       parse_dig = (CPU_INT08U)((parse_char - 'a') + 10u);
;;;4025                   } else {
;;;4026                       parse_dig = (CPU_INT08U)((parse_char - 'A') + 10u);
;;;4027                   }
;;;4028               }
;;;4029   
;;;4030               if (parse_dig < nbr_base) {                         /* If parse char valid for nbr base ...                 */
;;;4031                   if (ovf == DEF_NO) {                            /* ... & nbr NOT yet ovf'd,         ...                 */
;;;4032                       if (nbr <= Str_MultOvfThTbl_Int32U[nbr_base]) {
;;;4033                                                                   /* ... merge parse char dig into nbr.                   */
;;;4034                           nbr *= nbr_base;
;;;4035                           nbr += parse_dig;
;;;4036                           if (nbr < parse_dig) {
;;;4037                               ovf = DEF_YES;
;;;4038                           }
;;;4039                       } else {
;;;4040                           ovf = DEF_YES;
;;;4041                       }
;;;4042                   }
;;;4043                   pstr_parse++;
;;;4044   
;;;4045               } else {                                            /* Invalid         char parsed (see Note #2a1C1a).      */
;;;4046                   done = DEF_YES;
;;;4047               }
;;;4048   
;;;4049           } else {                                                /* Invalid OR NULL char parsed (see Note #2a1C1).       */
;;;4050               done = DEF_YES;
;;;4051           }
;;;4052       }
;;;4053   
;;;4054       if (ovf == DEF_YES) {                                       /* If nbr ovf'd, ...                                    */
;;;4055           nbr  = DEF_INT_32U_MAX_VAL;                             /* ... rtn max int val (see Note #2a3A1).               */
;;;4056       }
;;;4057   
;;;4058   
;;;4059       if (pstr_parse !=             pstr_parse_nbr) {             /* If final parse str != init'l parse nbr str,       .. */
;;;4060          *pstr_next   = (CPU_CHAR *)pstr_parse;                   /* .. rtn   parse str's next char (see Note #2a2B2); .. */
;;;4061       } else {
;;;4062          *pstr_next   = (CPU_CHAR *)pstr;                         /* .. else rtn initial parse str  (see Note #2a2A2).    */
;;;4063       }
;;;4064   
;;;4065      *pnbr_neg = neg;                                             /* Rtn neg nbr status.                                  */
;;;4066   
;;;4067   
;;;4068       return (nbr);
;;;4069   }
000038  b004              ADD      sp,sp,#0x10
00003a  e8bd9ff0          POP      {r4-r12,pc}
                  |L20.62|
00003e  2000              MOVS     r0,#0                 ;3904
000040  e7fa              B        |L20.56|
                  |L20.66|
000042  4654              MOV      r4,r10                ;3914
000044  7820              LDRB     r0,[r4,#0]            ;3916
000046  f7fffffe          BL       ASCII_IsSpace
00004a  e003              B        |L20.84|
                  |L20.76|
00004c  1c64              ADDS     r4,r4,#1              ;3918
00004e  7820              LDRB     r0,[r4,#0]            ;3919
000050  f7fffffe          BL       ASCII_IsSpace
                  |L20.84|
000054  2801              CMP      r0,#1                 ;3917
000056  d0f9              BEQ      |L20.76|
000058  7820              LDRB     r0,[r4,#0]            ;3922
00005a  282b              CMP      r0,#0x2b              ;3922
00005c  d00a              BEQ      |L20.116|
00005e  282d              CMP      r0,#0x2d              ;3922
000060  d00c              BEQ      |L20.124|
000062  2000              MOVS     r0,#0                 ;3938
000064  9000              STR      r0,[sp,#0]            ;3938
                  |L20.102|
000066  9403              STR      r4,[sp,#0xc]          ;3945
000068  b175              CBZ      r5,|L20.136|
00006a  2d08              CMP      r5,#8                 ;3947
00006c  d021              BEQ      |L20.178|
00006e  2d10              CMP      r5,#0x10              ;3947
000070  d133              BNE      |L20.218|
000072  e023              B        |L20.188|
                  |L20.116|
000074  1c64              ADDS     r4,r4,#1              ;3924
000076  2000              MOVS     r0,#0                 ;3925
000078  9000              STR      r0,[sp,#0]            ;3925
00007a  e7f4              B        |L20.102|
                  |L20.124|
00007c  2e01              CMP      r6,#1                 ;3930
00007e  d100              BNE      |L20.130|
000080  1c64              ADDS     r4,r4,#1              ;3931
                  |L20.130|
000082  2001              MOVS     r0,#1                 ;3933
000084  9000              STR      r0,[sp,#0]            ;3933
000086  e7ee              B        |L20.102|
                  |L20.136|
000088  7820              LDRB     r0,[r4,#0]            ;3949
00008a  2830              CMP      r0,#0x30              ;3949
00008c  d001              BEQ      |L20.146|
00008e  250a              MOVS     r5,#0xa               ;3969
000090  e023              B        |L20.218|
                  |L20.146|
000092  1c64              ADDS     r4,r4,#1              ;3950
000094  7820              LDRB     r0,[r4,#0]            ;3951
000096  2858              CMP      r0,#0x58              ;3951
000098  d003              BEQ      |L20.162|
00009a  2878              CMP      r0,#0x78              ;3951
00009c  d001              BEQ      |L20.162|
00009e  2508              MOVS     r5,#8                 ;3964
0000a0  e01b              B        |L20.218|
                  |L20.162|
0000a2  2510              MOVS     r5,#0x10              ;3954
0000a4  7860              LDRB     r0,[r4,#1]            ;3955
0000a6  f7fffffe          BL       ASCII_IsDigHex
0000aa  2801              CMP      r0,#1                 ;3957
0000ac  d115              BNE      |L20.218|
0000ae  1c64              ADDS     r4,r4,#1              ;3958
0000b0  e013              B        |L20.218|
                  |L20.178|
0000b2  7820              LDRB     r0,[r4,#0]            ;3975
0000b4  2830              CMP      r0,#0x30              ;3975
0000b6  d110              BNE      |L20.218|
0000b8  1c64              ADDS     r4,r4,#1              ;3976
0000ba  e00e              B        |L20.218|
                  |L20.188|
0000bc  7820              LDRB     r0,[r4,#0]            ;3982
0000be  2830              CMP      r0,#0x30              ;3982
0000c0  d10b              BNE      |L20.218|
0000c2  1c64              ADDS     r4,r4,#1              ;3983
0000c4  7820              LDRB     r0,[r4,#0]            ;3984
0000c6  2858              CMP      r0,#0x58              ;3984
0000c8  d001              BEQ      |L20.206|
0000ca  2878              CMP      r0,#0x78              ;3984
0000cc  d105              BNE      |L20.218|
                  |L20.206|
0000ce  7860              LDRB     r0,[r4,#1]            ;3987
0000d0  f7fffffe          BL       ASCII_IsDigHex
0000d4  2801              CMP      r0,#1                 ;3989
0000d6  d100              BNE      |L20.218|
0000d8  1c64              ADDS     r4,r4,#1              ;3990
                  |L20.218|
0000da  2600              MOVS     r6,#0                 ;4009
0000dc  2700              MOVS     r7,#0                 ;4010
0000de  46b0              MOV      r8,r6                 ;4011
                  |L20.224|
0000e0  f894b000          LDRB     r11,[r4,#0]           ;4014
0000e4  4658              MOV      r0,r11                ;4015
0000e6  f7fffffe          BL       ASCII_IsAlphaNum
0000ea  2801              CMP      r0,#1                 ;4016
0000ec  d007              BEQ      |L20.254|
0000ee  f04f0801          MOV      r8,#1                 ;4050
                  |L20.242|
0000f2  f1b80f00          CMP      r8,#0                 ;4013
0000f6  d0f3              BEQ      |L20.224|
0000f8  2f01              CMP      r7,#1                 ;4054
0000fa  d02d              BEQ      |L20.344|
0000fc  e02e              B        |L20.348|
                  |L20.254|
0000fe  4658              MOV      r0,r11                ;4018
000100  f7fffffe          BL       ASCII_IsDig
000104  2801              CMP      r0,#1                 ;4019
000106  d00c              BEQ      |L20.290|
000108  4658              MOV      r0,r11                ;4022
00010a  f7fffffe          BL       ASCII_IsLower
00010e  2801              CMP      r0,#1                 ;4023
000110  d00c              BEQ      |L20.300|
000112  f1ab0b37          SUB      r11,r11,#0x37         ;4026
000116  f00b00ff          AND      r0,r11,#0xff          ;4026
                  |L20.282|
00011a  42a8              CMP      r0,r5                 ;4030
00011c  d219              BCS      |L20.338|
00011e  b157              CBZ      r7,|L20.310|
000120  e015              B        |L20.334|
                  |L20.290|
000122  f1ab0b30          SUB      r11,r11,#0x30         ;4020
000126  f00b00ff          AND      r0,r11,#0xff          ;4020
00012a  e7f6              B        |L20.282|
                  |L20.300|
00012c  f1ab0b57          SUB      r11,r11,#0x57         ;4024
000130  f00b00ff          AND      r0,r11,#0xff          ;4024
000134  e7f1              B        |L20.282|
                  |L20.310|
000136  4910              LDR      r1,|L20.376|
000138  f8511025          LDR      r1,[r1,r5,LSL #2]     ;4032
00013c  42b1              CMP      r1,r6                 ;4032
00013e  d305              BCC      |L20.332|
000140  436e              MULS     r6,r5,r6              ;4034
000142  4406              ADD      r6,r6,r0              ;4035
000144  4286              CMP      r6,r0                 ;4036
000146  d202              BCS      |L20.334|
000148  2701              MOVS     r7,#1                 ;4037
00014a  e000              B        |L20.334|
                  |L20.332|
00014c  2701              MOVS     r7,#1                 ;4040
                  |L20.334|
00014e  1c64              ADDS     r4,r4,#1              ;4043
000150  e7cf              B        |L20.242|
                  |L20.338|
000152  f04f0801          MOV      r8,#1                 ;4046
000156  e7cc              B        |L20.242|
                  |L20.344|
000158  f04f36ff          MOV      r6,#0xffffffff        ;4055
                  |L20.348|
00015c  9803              LDR      r0,[sp,#0xc]          ;4059
00015e  4284              CMP      r4,r0                 ;4059
000160  d002              BEQ      |L20.360|
000162  f8c94000          STR      r4,[r9,#0]            ;4060
000166  e001              B        |L20.364|
                  |L20.360|
000168  f8c9a000          STR      r10,[r9,#0]           ;4062
                  |L20.364|
00016c  990e              LDR      r1,[sp,#0x38]         ;4065
00016e  9800              LDR      r0,[sp,#0]            ;4065
000170  7008              STRB     r0,[r1,#0]            ;4065
000172  4630              MOV      r0,r6                 ;4068
000174  e760              B        |L20.56|
;;;4070   
                          ENDP

000176  0000              DCW      0x0000
                  |L20.376|
                          DCD      ||.constdata||

                          AREA ||i.Str_ParseNbr_Int32S||, CODE, READONLY, ALIGN=1

                  Str_ParseNbr_Int32S PROC
;;;3215   
;;;3216   CPU_INT32S  Str_ParseNbr_Int32S (const  CPU_CHAR     *pstr,
000000  b51c              PUSH     {r2-r4,lr}
;;;3217                                           CPU_CHAR    **pstr_next,
;;;3218                                           CPU_INT08U    nbr_base)
;;;3219   {
;;;3220       CPU_INT32S   nbr;
;;;3221       CPU_INT32U   nbr_abs;
;;;3222       CPU_BOOLEAN  nbr_neg;
;;;3223   
;;;3224   
;;;3225       nbr_abs = Str_ParseNbr_Int32(pstr,                          /* Parse/convert str ...                                */
000002  ab01              ADD      r3,sp,#4
000004  9300              STR      r3,[sp,#0]
000006  2301              MOVS     r3,#1
000008  f7fffffe          BL       Str_ParseNbr_Int32
;;;3226                                    pstr_next,
;;;3227                                    nbr_base,
;;;3228                                    DEF_YES,                       /* ... as signed int (see Note #2a2).                   */
;;;3229                                   &nbr_neg);
;;;3230   
;;;3231       if (nbr_neg == DEF_NO) {                                    /* Chk for neg nbr & ovf/undf (see Note #2a3A1).        */
00000c  f89d2004          LDRB     r2,[sp,#4]
;;;3232           nbr = (nbr_abs > (CPU_INT32U) DEF_INT_32S_MAX_VAL)          ?  (CPU_INT32S)DEF_INT_32S_MAX_VAL
000010  f04f4100          MOV      r1,#0x80000000
000014  b122              CBZ      r2,|L21.32|
;;;3233                                                                       :  (CPU_INT32S)nbr_abs;
;;;3234       } else {
;;;3235           nbr = (nbr_abs > (CPU_INT32U)-DEF_INT_32S_MIN_VAL_ONES_CPL) ?  (CPU_INT32S)DEF_INT_32S_MIN_VAL
000016  4288              CMP      r0,r1
000018  d200              BCS      |L21.28|
;;;3236                                                                       : -(CPU_INT32S)nbr_abs;
00001a  4241              RSBS     r1,r0,#0
                  |L21.28|
00001c  4608              MOV      r0,r1
                  |L21.30|
;;;3237       }
;;;3238   
;;;3239       return (nbr);
;;;3240   }
00001e  bd1c              POP      {r2-r4,pc}
                  |L21.32|
000020  4288              CMP      r0,r1                 ;3232
000022  d3fc              BCC      |L21.30|
000024  f06f4000          MVN      r0,#0x80000000        ;3232
000028  bd1c              POP      {r2-r4,pc}
;;;3241   
                          ENDP


                          AREA ||i.Str_ParseNbr_Int32U||, CODE, READONLY, ALIGN=1

                  Str_ParseNbr_Int32U PROC
;;;2998   
;;;2999   CPU_INT32U  Str_ParseNbr_Int32U (const  CPU_CHAR     *pstr,
000000  b508              PUSH     {r3,lr}
;;;3000                                           CPU_CHAR    **pstr_next,
;;;3001                                           CPU_INT08U    nbr_base)
;;;3002   {
;;;3003       CPU_INT32U  nbr;
;;;3004   
;;;3005   
;;;3006       nbr = Str_ParseNbr_Int32(               pstr,               /* Parse/convert str ...                                */
000002  2300              MOVS     r3,#0
000004  9300              STR      r3,[sp,#0]
000006  f7fffffe          BL       Str_ParseNbr_Int32
;;;3007                                               pstr_next,
;;;3008                                               nbr_base,
;;;3009                                               DEF_NO,             /* ... as unsigned int (see Note #2a2).                 */
;;;3010                                (CPU_BOOLEAN *)0);
;;;3011   
;;;3012       return (nbr);
;;;3013   }
00000a  bd08              POP      {r3,pc}
;;;3014   
                          ENDP


                          AREA ||i.Str_Str||, CODE, READONLY, ALIGN=1

                  Str_Str PROC
;;;1779   
;;;1780   CPU_CHAR  *Str_Str (const  CPU_CHAR  *pstr,
000000  f04f32ff          MOV      r2,#0xffffffff
;;;1781                       const  CPU_CHAR  *pstr_srch)
;;;1782   {
;;;1783       CPU_CHAR  *pstr_rtn;
;;;1784   
;;;1785   
;;;1786       pstr_rtn = Str_Str_N(pstr,
000004  f7ffbffe          B.W      Str_Str_N
;;;1787                            pstr_srch,
;;;1788                            DEF_INT_CPU_U_MAX_VAL);
;;;1789   
;;;1790       return (pstr_rtn);
;;;1791   }
;;;1792   
                          ENDP


                          AREA ||i.Str_Str_N||, CODE, READONLY, ALIGN=1

                  Str_Str_N PROC
;;;1864   /*$PAGE*/
;;;1865   CPU_CHAR  *Str_Str_N (const  CPU_CHAR    *pstr,
000000  e92d43f0          PUSH     {r4-r9,lr}
;;;1866                         const  CPU_CHAR    *pstr_srch,
;;;1867                                CPU_SIZE_T   len_max)
;;;1868   {
000004  4688              MOV      r8,r1
000006  4606              MOV      r6,r0
000008  4611              MOV      r1,r2
;;;1869              CPU_SIZE_T    str_len;
;;;1870              CPU_SIZE_T    str_len_srch;
;;;1871              CPU_SIZE_T    len_max_srch;
;;;1872              CPU_SIZE_T    srch_len;
;;;1873              CPU_SIZE_T    srch_ix;
;;;1874              CPU_BOOLEAN   srch_done;
;;;1875              CPU_INT16S    srch_cmp;
;;;1876       const  CPU_CHAR     *pstr_str;
;;;1877       const  CPU_CHAR     *pstr_srch_ix;
;;;1878   
;;;1879                                                                   /* Rtn NULL if str ptr(s) NULL (see Note #3a).          */
;;;1880       if (pstr == (const CPU_CHAR *)0) {
00000a  2e00              CMP      r6,#0
00000c  d006              BEQ      |L24.28|
;;;1881           return ((CPU_CHAR *)0);
;;;1882       }
;;;1883       if (pstr_srch == (const CPU_CHAR *)0) {
00000e  f1b80f00          CMP      r8,#0
000012  d006              BEQ      |L24.34|
;;;1884           return ((CPU_CHAR *)0);
;;;1885       }
;;;1886   
;;;1887       if (len_max < 1) {                                          /* Rtn NULL if srch len = 0    (see Note #3g).          */
000014  b139              CBZ      r1,|L24.38|
;;;1888           return ((CPU_CHAR *)0);
;;;1889       }
;;;1890   
;;;1891                                                                   /* Lim max srch str len (to chk > str len).             */
;;;1892       len_max_srch = (len_max <       DEF_INT_CPU_U_MAX_VAL)
000016  1c48              ADDS     r0,r1,#1
000018  d007              BEQ      |L24.42|
;;;1893                    ? (len_max + 1u) : DEF_INT_CPU_U_MAX_VAL;
00001a  e008              B        |L24.46|
                  |L24.28|
00001c  2000              MOVS     r0,#0                 ;1881
                  |L24.30|
;;;1894   
;;;1895       str_len      = Str_Len_N(pstr,      len_max);
;;;1896       str_len_srch = Str_Len_N(pstr_srch, len_max_srch);
;;;1897       if (str_len_srch < 1) {                                     /* Rtn ptr to str if srch str len = 0 (see Note #2b2).  */
;;;1898           return ((CPU_CHAR *)pstr);
;;;1899       }
;;;1900       if (str_len_srch > str_len) {                               /* Rtn NULL if srch str len > str len (see Note #3d).   */
;;;1901           return ((CPU_CHAR *)0);
;;;1902       }
;;;1903                                                                   /* Rtn NULL if NULL ptr found         (see Note #3b1).  */
;;;1904       pstr_str = pstr      + str_len;
;;;1905       if (pstr_str == (const CPU_CHAR *)0) {
;;;1906           return ((CPU_CHAR *)0);
;;;1907       }
;;;1908       pstr_str = pstr_srch + str_len_srch;
;;;1909       if (pstr_str == (const CPU_CHAR *)0) {
;;;1910           return ((CPU_CHAR *)0);
;;;1911       }
;;;1912   
;;;1913   
;;;1914       srch_len  = str_len - str_len_srch;                         /* Calc srch len (see Note #3e2).                       */
;;;1915       srch_ix   = 0u;
;;;1916       srch_done = DEF_NO;
;;;1917   
;;;1918       do {
;;;1919           pstr_srch_ix = (const CPU_CHAR *)(pstr + srch_ix);
;;;1920           srch_cmp     =  Str_Cmp_N(pstr_srch_ix, pstr_srch, str_len_srch);
;;;1921           srch_done    = (srch_cmp == 0) ? DEF_YES : DEF_NO;
;;;1922           srch_ix++;
;;;1923       } while ((srch_done == DEF_NO) && (srch_ix <= srch_len));
;;;1924   
;;;1925   
;;;1926       if (srch_cmp != 0) {                                        /* Rtn NULL if srch str NOT found (see Note #3e2).      */
;;;1927           return ((CPU_CHAR *)0);
;;;1928       }
;;;1929   
;;;1930       return ((CPU_CHAR *)pstr_srch_ix);                          /* Else rtn ptr to found srch str (see Note #3f1).      */
;;;1931   }
00001e  e8bd83f0          POP      {r4-r9,pc}
                  |L24.34|
000022  2000              MOVS     r0,#0                 ;1884
000024  e7fb              B        |L24.30|
                  |L24.38|
000026  2000              MOVS     r0,#0                 ;1888
000028  e7f9              B        |L24.30|
                  |L24.42|
00002a  f04f30ff          MOV      r0,#0xffffffff        ;1893
                  |L24.46|
00002e  4605              MOV      r5,r0                 ;1893
000030  4630              MOV      r0,r6                 ;1895
000032  f7fffffe          BL       Str_Len_N
000036  4604              MOV      r4,r0                 ;1895
000038  4629              MOV      r1,r5                 ;1896
00003a  4640              MOV      r0,r8                 ;1896
00003c  f7fffffe          BL       Str_Len_N
000040  4605              MOV      r5,r0                 ;1896
000042  0028              MOVS     r0,r5                 ;1897
000044  d003              BEQ      |L24.78|
000046  42a5              CMP      r5,r4                 ;1900
000048  d903              BLS      |L24.82|
00004a  2000              MOVS     r0,#0                 ;1901
00004c  e7e7              B        |L24.30|
                  |L24.78|
00004e  4630              MOV      r0,r6                 ;1898
000050  e7e5              B        |L24.30|
                  |L24.82|
000052  1930              ADDS     r0,r6,r4              ;1904
000054  b188              CBZ      r0,|L24.122|
000056  eb080005          ADD      r0,r8,r5              ;1908
00005a  b180              CBZ      r0,|L24.126|
00005c  1b67              SUBS     r7,r4,r5              ;1914
00005e  2400              MOVS     r4,#0                 ;1915
                  |L24.96|
000060  eb060904          ADD      r9,r6,r4              ;1919
000064  462a              MOV      r2,r5                 ;1920
000066  4641              MOV      r1,r8                 ;1920
000068  4648              MOV      r0,r9                 ;1920
00006a  f7fffffe          BL       Str_Cmp_N
00006e  4601              MOV      r1,r0                 ;1920
000070  b139              CBZ      r1,|L24.130|
000072  2000              MOVS     r0,#0                 ;1921
                  |L24.116|
000074  1c64              ADDS     r4,r4,#1              ;1922
000076  b130              CBZ      r0,|L24.134|
000078  e007              B        |L24.138|
                  |L24.122|
00007a  2000              MOVS     r0,#0                 ;1906
00007c  e7cf              B        |L24.30|
                  |L24.126|
00007e  2000              MOVS     r0,#0                 ;1910
000080  e7cd              B        |L24.30|
                  |L24.130|
000082  2001              MOVS     r0,#1                 ;1921
000084  e7f6              B        |L24.116|
                  |L24.134|
000086  42bc              CMP      r4,r7                 ;1923
000088  d9ea              BLS      |L24.96|
                  |L24.138|
00008a  b109              CBZ      r1,|L24.144|
00008c  2000              MOVS     r0,#0                 ;1927
00008e  e7c6              B        |L24.30|
                  |L24.144|
000090  4648              MOV      r0,r9                 ;1930
000092  e7c4              B        |L24.30|
;;;1932   
                          ENDP


                          AREA ||.constdata||, DATA, READONLY, ALIGN=2

                  Str_MultOvfThTbl_Int32U
                          DCD      0xffffffff
                          DCD      0xffffffff
                          DCD      0x7fffffff
                          DCD      0x55555555
                          DCD      0x3fffffff
                          DCD      0x33333333
                          DCD      0x2aaaaaaa
                          DCD      0x24924924
                          DCD      0x1fffffff
                          DCD      0x1c71c71c
                          DCD      0x19999999
                          DCD      0x1745d174
                          DCD      0x15555555
                          DCD      0x13b13b13
                          DCD      0x12492492
                          DCD      0x11111111
                          DCD      0x0fffffff
                          DCD      0x0f0f0f0f
                          DCD      0x0e38e38e
                          DCD      0x0d79435e
                          DCD      0x0ccccccc
                          DCD      0x0c30c30c
                          DCD      0x0ba2e8ba
                          DCD      0x0b21642c
                          DCD      0x0aaaaaaa
                          DCD      0x0a3d70a3
                          DCD      0x09d89d89
                          DCD      0x097b425e
                          DCD      0x09249249
                          DCD      0x08d3dcb0
                          DCD      0x08888888
                          DCD      0x08421084
                          DCD      0x07ffffff
                          DCD      0x07c1f07c
                          DCD      0x07878787
                          DCD      0x07507507
                          DCD      0x071c71c7