Source Code

005048,000001: # Copyright 2004 Ronald S. Burkey <info@sandroid.org> 005049,000002: # 005050,000003: # This file is part of yaAGC. 005051,000004: 005052,000005: # yaAGC is free software; you can redistribute it and/or modify 005053,000006: # it under the terms of the GNU General Public License as published by 005054,000007: # the Free Software Foundation; either version 2 of the License, or 005055,000008: # (at your option) any later version. 005056,000009: 005057,000010: # yaAGC is distributed in the hope that it will be useful, 005058,000011: # but WITHOUT ANY WARRANTY; without even the implied warranty of 005059,000012: # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 005060,000013: # GNU General Public License for more details. 005061,000014: 005062,000015: # You should have received a copy of the GNU General Public License 005063,000016: # along with yaAGC; if not, write to the Free Software 005064,000017: # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 005065,000018: 005066,000019: # Filename: SmallyDVCHECK.agc 005067,000020: # Purpose: This is code written from the flowchart on p. 62-64 of 005068,000021: # E-2065, which is a document titled "Block II AGC 005069,000022: # Self-Check and Show-Banksum", by Edwin D. Smally. 005070,000023: # Mod history: 07/07/04 RSB. Began. 005071,000024: 005072,000025: # Similar code was apparently originally in Luminary and/or Colossus, 005073,000026: # but much of it was removed over the course of time to make more room. 005074,000027: # I don't know what the original code was like, but the flowcharts still 005075,000028: # exist, so I've rewritten the code from the flowcharts. 005076,000029: 005077,000030: # P. 62 of Smally. 005078,000031: 10,2003 37415 CA O-3777 005079,000032: 10,2004 54071 TS SKEEP4 005080,000033: 10,2005 24071 INCR SKEEP4 005081,000034: 10,2006 37405 CA O20000 005082,000035: 10,2007 54066 TS SKEEP1 005083,000036: 10,2010 37420 CA O-20000 005084,000037: 10,2011 54067 TS SKEEP2 005085,000038: 10,2012 37447 CA MAXN # -37777 005086,000039: 10,2013 54001 TS L 005087,000040: 10,2014 37404 CA O17777 005088,000041: 005089,000042: 10,2015 24062 INCR ERRSUB 005090,000043: 10,2016 37405 CA O20000 005091,000044: 10,2017 54063 TS TEMPI 005092,000045: 10,2020 37447 CA MAXN # -37777 005093,000046: 10,2021 54001 TS L 005094,000047: 10,2022 37404 CA O17777 005095,000048: 10,2023 00006 EXTEND 005096,000049: 10,2024 10063 DV TEMPI 005097,000050: 10,2025 54074 TS SKEEP7 005098,000051: 10,2026 30001 CA L 005099,000052: 10,2027 67424 AD NEGONE 005100,000053: 10,2030 00006 EXTEND 005101,000054: 10,2031 12033 BZF +2 005102,000055: 10,2032 12270 TCF DVERROR 005103,000056: 005104,000057: 10,2033 24062 INCR ERRSUB 005105,000058: 10,2034 37420 CA O-20000 005106,000059: 10,2035 54063 TS TEMPI 005107,000060: 10,2036 37447 CA MAXN 005108,000061: 10,2037 54001 TS L 005109,000062: 10,2040 37404 CA O17777 005110,000063: 10,2041 00006 EXTEND 005111,000064: 10,2042 10063 DV TEMPI 005112,000065: 10,2043 60074 AD SKEEP7 005113,000066: 10,2044 10000 CCS A 005114,000067: 10,2045 12046 NOOP 005115,000068: 10,2046 12047 NOOP 005116,000069: 10,2047 12270 TCF DVERROR 005117,000070: 10,2050 30001 CA L 005118,000071: 10,2051 67424 AD NEGONE 005119,000072: 10,2052 00006 EXTEND 005120,000073: 10,2053 12055 BZF +2 005121,000074: 10,2054 12270 TCF DVERROR 005122,000075: 005123,000076: 10,2055 24062 INCR ERRSUB 005124,000077: 10,2056 37405 CA O20000 005125,000078: 10,2057 54063 TS TEMPI 005126,000079: 10,2060 37443 CA MAXP 005127,000080: 10,2061 54001 TS L 005128,000081: 10,2062 37417 CA O-17777 005129,000082: 10,2063 00006 EXTEND 005130,000083: 10,2064 10063 DV TEMPI 005131,000084: 10,2065 54073 TS SKEEP6 005132,000085: 10,2066 60074 AD SKEEP7 005133,000086: 10,2067 10000 CCS A 005134,000087: 10,2070 12071 NOOP 005135,000088: 10,2071 12072 NOOP 005136,000089: 10,2072 12270 TCF DVERROR 005137,000090: 10,2073 30001 CA L 005138,000091: 10,2074 67430 AD ONE 005139,000092: 10,2075 00006 EXTEND 005140,000093: 10,2076 12100 BZF +2 005141,000094: 10,2077 12270 TCF DVERROR 005142,000095: 005143,000096: 10,2100 24062 INCR ERRSUB 005144,000097: 10,2101 37420 CA O-20000 005145,000098: 10,2102 54063 TS TEMPI 005146,000099: 10,2103 37443 CA MAXP 005147,000100: 10,2104 54001 TS L 005148,000101: 10,2105 37417 CA O-17777 005149,000102: 10,2106 00006 EXTEND 005150,000103: 10,2107 10063 DV TEMPI 005151,000104: 10,2110 60073 AD SKEEP6 005152,000105: 10,2111 10000 CCS A 005153,000106: 10,2112 12113 NOOP 005154,000107: 10,2113 12114 NOOP 005155,000108: 10,2114 12270 TCF DVERROR 005156,000109: 10,2115 30001 CA L 005157,000110: 10,2116 67430 AD ONE 005158,000111: 10,2117 00006 EXTEND 005159,000112: 10,2120 12122 BZF +2 005160,000113: 10,2121 12270 TCF DVERROR 005161,000114: 10,2122 37406 CA O37774 005162,000115: 10,2123 60073 AD SKEEP6 005163,000116: 10,2124 00006 EXTEND 005164,000117: 10,2125 12127 BZF +2 005165,000118: 10,2126 12270 TCF DVERROR 005166,000119: 005167,000120: 10,2127 24062 INCR ERRSUB 005168,000121: # P. 63 of Smally. 005169,000122: 10,2130 37405 CA O20000 005170,000123: 10,2131 54063 TS TEMPI 005171,000124: 10,2132 37443 CA MAXP # 37777 005172,000125: 10,2133 54001 TS L 005173,000126: 10,2134 37404 CA O17777 005174,000127: 10,2135 00006 EXTEND 005175,000128: 10,2136 10063 DV TEMPI 005176,000129: 10,2137 67447 AD MAXN # -37777 005177,000130: 10,2140 00006 EXTEND 005178,000131: 10,2141 12143 BZF +2 005179,000132: 10,2142 12270 TCF DVERROR 005180,000133: 005181,000134: 10,2143 24062 INCR ERRSUB 005182,000135: 10,2144 37407 CA O37776 005183,000136: 10,2145 54063 TS TEMPI 005184,000137: 10,2146 22007 ZL 005185,000138: 10,2147 37407 CA O37776 005186,000139: 10,2150 00006 EXTEND 005187,000140: 10,2151 10063 DV TEMPI 005188,000141: 10,2152 67447 AD MAXN # -37777 005189,000142: 10,2153 00006 EXTEND 005190,000143: 10,2154 12156 BZF +2 005191,000144: 10,2155 12270 TCF DVERROR 005192,000145: 10,2156 30001 CA L 005193,000146: 10,2157 67422 AD O-37776 005194,000147: 10,2160 00006 EXTEND 005195,000148: 10,2161 12163 BZF +2 005196,000149: 10,2162 12270 TCF DVERROR 005197,000150: 005198,000151: # P. 64 of Smally 005199,000152: 10,2163 30007 CA ZEROES 005200,000153: 10,2164 54066 TS SKEEP1 005201,000154: 10,2165 37423 CA NEGZERO 005202,000155: 10,2166 54067 TS SKEEP2 005203,000156: 005204,000157: 10,2167 24062 INCR ERRSUB 005205,000158: 10,2170 30007 CA ZEROES 005206,000159: 10,2171 54063 TS TEMPI 005207,000160: 10,2172 54001 TS L 005208,000161: 10,2173 00006 EXTEND 005209,000162: 10,2174 10063 DV TEMPI 005210,000163: 10,2175 54074 TS SKEEP7 005211,000164: 10,2176 10001 CCS L 005212,000165: 10,2177 12270 TCF DVERROR 005213,000166: 10,2200 12203 TCF +3 005214,000167: 10,2201 12202 NOOP 005215,000168: 10,2202 12270 TCF DVERROR 005216,000169: 005217,000170: 10,2203 24062 INCR ERRSUB 005218,000171: 10,2204 37423 CA NEGZERO 005219,000172: 10,2205 54063 TS TEMPI 005220,000173: 10,2206 22007 ZL 005221,000174: 10,2207 00006 EXTEND 005222,000175: 10,2210 10063 DV TEMPI 005223,000176: 10,2211 54073 TS SKEEP6 005224,000177: 10,2212 60074 AD SKEEP7 005225,000178: 10,2213 10000 CCS A 005226,000179: 10,2214 12215 NOOP 005227,000180: 10,2215 12216 NOOP 005228,000181: 10,2216 12270 TCF DVERROR 005229,000182: 10,2217 30001 CA L 005230,000183: 005231,000184: 10,2220 24062 INCR ERRSUB 005232,000185: 10,2221 30007 CA ZEROES 005233,000186: 10,2222 54063 TS TEMPI 005234,000187: 10,2223 37423 CA NEGZERO 005235,000188: 10,2224 54001 TS L 005236,000189: 10,2225 30007 CA ZEROES 005237,000190: 10,2226 00006 EXTEND 005238,000191: 10,2227 10063 DV TEMPI 005239,000192: 10,2230 60074 AD SKEEP7 005240,000193: 10,2231 10000 CCS A 005241,000194: 10,2232 12233 NOOP 005242,000195: 10,2233 12234 NOOP 005243,000196: 10,2234 12270 TCF DVERROR 005244,000197: 10,2235 10001 CCS L # Smally says -0, but I think +0. 005245,000198: 10,2236 12270 TCF DVERROR 005246,000199: 10,2237 12242 TCF +3 005247,000200: 10,2240 12270 TCF DVERROR 005248,000201: 10,2241 12270 TCF DVERROR 005249,000202: 005250,000203: 10,2242 24062 INCR ERRSUB 005251,000204: 10,2243 37423 CA NEGZERO 005252,000205: 10,2244 54063 TS TEMPI 005253,000206: 10,2245 54001 TS L 005254,000207: 10,2246 30007 CA ZEROES 005255,000208: 10,2247 00006 EXTEND 005256,000209: 10,2250 10063 DV TEMPI 005257,000210: 10,2251 60073 AD SKEEP6 005258,000211: 10,2252 10000 CCS A 005259,000212: 10,2253 12254 NOOP 005260,000213: 10,2254 12255 NOOP 005261,000214: 10,2255 12270 TCF DVERROR 005262,000215: 10,2256 10001 CCS L 005263,000216: 10,2257 12260 NOOP 005264,000217: 10,2260 12261 NOOP 005265,000218: 10,2261 12270 TCF DVERROR 005266,000219: 10,2262 37443 CA MAXP # 37777 005267,000220: 10,2263 60073 AD SKEEP6 005268,000221: 10,2264 00006 EXTEND 005269,000222: 10,2265 12267 BZF +2 005270,000223: 10,2266 12270 TCF DVERROR 005271,000224: 005272,000225: # All done. 005273,000226: 10,2267 12271 TCF DVDONE 005274,000227: 10,2270 07240 DVERROR TC ERRORDSP 005275,000228: 10,2271 DVDONE 005276,000229: End of include-file SmallyDVCHECK.agc. Parent file is ValidateSmally.agc