1 // In order to focus on the leverage Spec and BinAxis indexing provide, 2 // otherwise required STIL code is omitted. 3 4 Include "UserDefLib.stil"; 5 6 Spec ACSpeed { 7 Category cat500MHz { ... } // Index 0 8 Category cat250MHz { ... } // Index 1 9 Category cat166MHz { ... } // Index 2 10 } 11 Include "Selector.stil" // Theoretically contains definition for SelSpeedTyp 12 Include "DCLevels.stil" // Theoretically contains definition for DcNom 13 Include "Timing.stil" // Theoretically contains definition for AcLoose 14 Include "Burst.stil" // Theoretically contains definitions for Burst[1-5] 15 SoftBinDefs softbindefs { 16 Pass { 17 BinAxis Speed { 18 Bin "500MHz"; // Index 0 19 Bin "250MHz"; // Index 1 20 Bin "166MHz"; // Index 2 21 // To disable "166MHz" for all tests of type SpeedCatBased, substitute the 22 // code line below for the code line above 23 // Bin "166MHz" { Enable False; } 24 } 25 } 26 Fail { 27 Bin Funct; 28 } 29 } 30 BinMap binmap { 31 SoftBins softbindefs; 32 } 33 // ============================================================================= 34 // To add, e.g. 100MHz binning, for all tests of type SpeedCatBased, append 35 // cat100MHz to Spec ACSpeed and Bin "100MHz" to softbindefs, pass axis Speed. 36 TestProgram pgm { 37 BinMap binmap; 38 Flow StdFlow mainflow { 39 TestExec SpeedCatBased { passBin = Pass.Speed; failBin = Funct; patburst = Burst1; acspec = ACSpeed; acsel = SelSpeedTyp; tim = AcLoose; dclev = DcNom; } 40 TestExec SpeedCatBased { passBin = Pass.Speed; failBin = Funct; patburst = Burst2; acspec = ACSpeed; acsel = SelSpeedTyp; tim = AcLoose; dclev = DcNom; } 41 TestExec SpeedCatBased { passBin = Pass.Speed; failBin = Funct; patburst = Burst3; acspec = ACSpeed; acsel = SelSpeedTyp; tim = AcLoose; dclev = DcNom; } 42 TestExec SpeedCatBased { passBin = Pass.Speed; failBin = Funct; patburst = Burst4; acspec = ACSpeed; acsel = SelSpeedTyp; tim = AcLoose; dclev = DcNom; } 43 TestExec SpeedCatBased { passBin = Pass.Speed; failBin = Funct; patburst = Burst5; acspec = ACSpeed; acsel = SelSpeedTyp; tim = AcLoose; dclev = DcNom; } 44 } 45 EntryPoints { 46 On Start mainflow; 47 } 48 } 49 // ============================================================================= 50 // This section is Ric's MAINFLOW example with the speed test replicated 5 51 // times, a corollary to the above mainflow. As an exercise you may perform the 52 // edits required to add or subtract device classifications. Compare to edits on 53 // above code and reach your own conclusions about which is easier to 54 // comprehend, maintain and which is less error prone: 55 56 // Flow MAINFLOW { 57 // FlowNode test500MHz { 58 // TestNumber 10; 59 // Category cat500MHz; 60 // Selector selACSpeed; 61 // TestExec testFunc; 62 // ExitPorts { 63 // Port PASS CurrentExec.ExecResult==Pass { 64 // SetBin pass500MHz; 65 // Return; 66 // } 67 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 68 // } 69 // } 70 // FlowNode test250MHz { 71 // TestNumber 11; 72 // Category cat250MHz; 73 // Selector selACSpeed; 74 // TestExec testFunc; 75 // ExitPorts { 76 // Port PASS CurrentExec.ExecResult==Pass { 77 // SetBin pass250MHz; 78 // Return; 79 // } 80 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 81 // } 82 // } 83 // FlowNode test166MHz { 84 // TestNumber 12; 85 // Category cat166MHz; 86 // Selector selACSpeed; 87 // TestExec testFunc; 88 // ExitPorts { 89 // Port PASS CurrentExec.ExecResult==Pass { 90 // SetBin pass166MHz; 91 // Return; 92 // } 93 // Port FAIL CurrentExec.ExecResult==Fail { SetBinStop failFunc; } 94 // } 95 // } 96 // FlowNode test500MHz { 97 // TestNumber 10; 98 // Category cat500MHz; 99 // Selector selACSpeed; 100 // TestExec testFunc; 101 // ExitPorts { 102 // Port PASS CurrentExec.ExecResult==Pass { 103 // SetBin pass500MHz; 104 // Return; 105 // } 106 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 107 // } 108 // } 109 // FlowNode test250MHz { 110 // TestNumber 11; 111 // Category cat250MHz; 112 // Selector selACSpeed; 113 // TestExec testFunc; 114 // ExitPorts { 115 // Port PASS CurrentExec.ExecResult==Pass { 116 // SetBin pass250MHz; 117 // Return; 118 // } 119 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 120 // } 121 // } 122 // FlowNode test166MHz { 123 // TestNumber 12; 124 // Category cat166MHz; 125 // Selector selACSpeed; 126 // TestExec testFunc; 127 // ExitPorts { 128 // Port PASS CurrentExec.ExecResult==Pass { 129 // SetBin pass166MHz; 130 // Return; 131 // } 132 // Port FAIL CurrentExec.ExecResult==Fail { SetBinStop failFunc; } 133 // } 134 // } 135 // FlowNode test500MHz { 136 // TestNumber 10; 137 // Category cat500MHz; 138 // Selector selACSpeed; 139 // TestExec testFunc; 140 // ExitPorts { 141 // Port PASS CurrentExec.ExecResult==Pass { 142 // SetBin pass500MHz; 143 // Return; 144 // } 145 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 146 // } 147 // } 148 // FlowNode test250MHz { 149 // TestNumber 11; 150 // Category cat250MHz; 151 // Selector selACSpeed; 152 // TestExec testFunc; 153 // ExitPorts { 154 // Port PASS CurrentExec.ExecResult==Pass { 155 // SetBin pass250MHz; 156 // Return; 157 // } 158 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 159 // } 160 // } 161 // FlowNode test166MHz { 162 // TestNumber 12; 163 // Category cat166MHz; 164 // Selector selACSpeed; 165 // TestExec testFunc; 166 // ExitPorts { 167 // Port PASS CurrentExec.ExecResult==Pass { 168 // SetBin pass166MHz; 169 // Return; 170 // } 171 // Port FAIL CurrentExec.ExecResult==Fail { SetBinStop failFunc; } 172 // } 173 // } 174 // FlowNode test500MHz { 175 // TestNumber 10; 176 // Category cat500MHz; 177 // Selector selACSpeed; 178 // TestExec testFunc; 179 // ExitPorts { 180 // Port PASS CurrentExec.ExecResult==Pass { 181 // SetBin pass500MHz; 182 // Return; 183 // } 184 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 185 // } 186 // } 187 // FlowNode test250MHz { 188 // TestNumber 11; 189 // Category cat250MHz; 190 // Selector selACSpeed; 191 // TestExec testFunc; 192 // ExitPorts { 193 // Port PASS CurrentExec.ExecResult==Pass { 194 // SetBin pass250MHz; 195 // Return; 196 // } 197 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 198 // } 199 // } 200 // FlowNode test166MHz { 201 // TestNumber 12; 202 // Category cat166MHz; 203 // Selector selACSpeed; 204 // TestExec testFunc; 205 // ExitPorts { 206 // Port PASS CurrentExec.ExecResult==Pass { 207 // SetBin pass166MHz; 208 // Return; 209 // } 210 // Port FAIL CurrentExec.ExecResult==Fail { SetBinStop failFunc; } 211 // } 212 // } 213 // FlowNode test500MHz { 214 // TestNumber 10; 215 // Category cat500MHz; 216 // Selector selACSpeed; 217 // TestExec testFunc; 218 // ExitPorts { 219 // Port PASS CurrentExec.ExecResult==Pass { 220 // SetBin pass500MHz; 221 // Return; 222 // } 223 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 224 // } 225 // } 226 // FlowNode test250MHz { 227 // TestNumber 11; 228 // Category cat250MHz; 229 // Selector selACSpeed; 230 // TestExec testFunc; 231 // ExitPorts { 232 // Port PASS CurrentExec.ExecResult==Pass { 233 // SetBin pass250MHz; 234 // Return; 235 // } 236 // Port FAIL CurrentExec.ExecResult==Fail { Next; } 237 // } 238 // } 239 // FlowNode test166MHz { 240 // TestNumber 12; 241 // Category cat166MHz; 242 // Selector selACSpeed; 243 // TestExec testFunc; 244 // ExitPorts { 245 // Port PASS CurrentExec.ExecResult==Pass { 246 // SetBin pass166MHz; 247 // Return; 248 // } 249 // Port FAIL CurrentExec.ExecResult==Fail { SetBinStop failFunc; } 250 // } 251 // } 252 // }