### Atalanta dynamic library

This library contains classes which are used to generate test patterns or simulate them. There is one class needed and used as programing interface among library and applications. Name of the class is Atalanta. There is another class used to setup algorithms used at Atalanta. Name of this class is Params. Decription of these classed following.

### Class Atalanta

External application can use just 3 methods. The first method is int run(int argc, char **argv). This method give possibility to Atalanta run similar like console application. It is expectening parameters like in command line version of this application. The second method is void setParams(Params *p). This method using class Params to setup parameters of algorithms of Atalanta. The third method is int run(). This method run Atalanta with already set of parameters.

### Class Params

This class contain parameters to configure algorithms of Atalanta. Following table contains short description of methods used to setup these parameters. These methods set the same parameters you can set from command line.

Method | Description
--- | ---
char getCctMode(void) | Get mode of input file format.
void setCctMode(char p_cctMode) | Set mode of input file format.
int getRandomLimit (void) | Get limit of Random Pattern Testing.
void setRandomLimit(char p_randomLimit) | Set Random Pattern Testing (RPT). This session is included before deterministic test pattern generation session. The RPT session stops if any p_randomLimit consecutive packets of 32 random patterns do not detect any new fault. If p_randomLimit=0, the RPT session is not included. (default: p_randomLimit=16)
unsigned int getIseed(void) | Get initial seed for the random number generator.
void setIseed(unsigned int p_iseed) | Set initial seed for the random number generator (random()). If p_iseed=0, the initial seed is the current time. (default: p_iseed=0)
int getMaxCompact(void) | Set compacting of test patterns.
void setMaxCompact(int p_maxCompact) | Set compacting of test patterns. Atalanta compacts test patterns using two different methods: reverse order compaction and shuffling compaction. First, test patterns are applied in the reverse order and fault simulated (reverse order compaction). Second, test patterns are shuffled randomly and fault simulated (shuffling compaction). During the fault simulations, all the test patterns which do not detect a new fault are eliminated. p_maxCompact specifies the limit of shuffling compaction. If p_maxCompact>0, shuffling compaction is terminated if p_maxCompact consecutive shuffles do not drop a test pattern. If p_maxCompact=0, shuffling compaction is not included and compaction is done only by the reverse order fault simulation. (default: p_maxCompact=2)
char getCompact(void) | Get information if the compaction of test patterns will be performed.
void setCompact(char p_compact) | Set of test patterns compaction. If p_compact='y', compaction will be performed. If p_compact='n', compaction will not be performed.
int getMaxBackTrack(void) | Get number of maximum backtracks for the FAN algorithm phase 1.
void setMaxBackTrack(int p_maxBackTrack) | Set number of maximum backtracks for the FAN algorithm phase 1. (default: p_maxBackTrack=10)
int getMaxBackTrack1(void) |
void setMaxBackTrack1(int p_maxBackTrack1) | Set p_maxBackTrack1. If p_maxBackTrack1 > 0 option is specified, atalanta generates test patterns in two phases. In phase 1, static unique path sensitization is employed. If the test generation for a target fault is aborted in phase 1, the test generation is tried in phase 2. In phase 2, dynamic unique path sensitization is employed. If p_maxBackTrack1=0, phase 2 is not performed. If p_maxBackTrack1 > 0, phase 2 test generation is performed with the backtrack limit of p_maxBackTrack1. (default: p_maxBackTrack1=0, i.e., phase 2 is not performed.)
string getSPatternFile(void) |
void setSPatternFile(string p_sPatternFile) | Test patterns are are written or read from the file fn (written in TPG mode, read in simulation mode).
streambuf *getSPatternStream(void) |
void setSPatternStream(streambuf *p_sPatternStream) | Test patterns are are written or read from the file fn (written in TPG mode, read in simulation mode).
string getBenchFile(void) |
void setBenchFile(string p_benchFile) | Name of the .bench file. The -n statement is optional, the benchmark name can be specified without any prequisite parameter.
streambuf *getBenchStream(void) |
void setBenchStream(streambuf *p_benchStream) | Name of the .bench file. The -n statement is optional, the benchmark name can be specified without any prequisite parameter.
char getLearnMode(void) |
void setLearnMode(char p_learnMode) | Static learning is performed. (default: no learning)
char getFaultMode(void) |
void setFaultMode(char p_faultMode) |
string getFaultFile(void) |
void setFaultFile(string p_faultFile) | The fault file is read from fn. If not specified, all the s-a-faults are set as default.
streambuf *getFaultStream(void) |
void setfaultStream(streambuf *p_faultStream) | The fault file is read from fn. If not specified, all the s-a-faults are set as default.
string getWFaultFile(void) |
void setWFaultFile(string p_wFaultFile) | The processed fault list is written to a file fn.
streambuf *getWFaultFileStream(void) |
void setWFaultStream(streambuf *p_wFaultStream) | The processed fault list is written to a file fn.
char getSimMode(void) |
void setSimMode(char p_simMode) | HOPE is employed for fault simulation. In this option, three logic values (0, 1 and X), instead of two logic values (0 and 1), are employed. Due to the embedding of the unknown logic value and the parallel fault fault simulation algorithm, the test generation time is slower than the default mode.) (default: FSIM, which is a parallel pattern fault simulator, is employed, and two logic values are used.)
char getFillMode(void) |
void setFillMode(char p_fillMode) | During test generation, some inputs can be unspecified. Atalanta provides various options to set these unspecified inputs into a certain value. (default: -R)
char getGenAllPat(void) |
void setGenAllPat(char p_genAllPat) | Atalanta derives all test patterns for each fault. In this option, all unspecified inputs are left unknown, and fault simulation is not performed. HOPE fault simulator is employed. Note: it does not work properly. Not all existing test patterns are produced.
int getEachLimit(void) |
void setEachLimit(int p_eachLimit) | Atalanta derives n test patterns for each fault. In this option, all unspecified inputs are left unknown, and fault simulation is not performed. If both -A and -D option are specified, -D option is applied. HOPE fault simulator is employed. Note: it does not work properly. Not all existing test patterns are produced.
char getNoFaultSim(void) |
void setNoFaultSim(char p_noFaultSim) | Atalanta derives one test pattern for each fault. In this option, no fault simulation is performed during the entire test generation (including random pattern test generation session, deterministic test generation session and test compaction session). All unspecified inputs are left unknown.
int getUFaultMode(void) |
void setUFaultMode(int p_uFaultMode) | Atalanta prints out all identified redundant faults as well as aborted fauts in a file. The -U option has to be specified.
string getUdFaultsFile(void) |
void setUdFaultsFile(string p_udFaultsFile) | Atalanta writes the list of aborted (or undetected) faults to the given file name.
streambuf *getUdFaultsStream(void) |
void setudFaultsStream(streambuf *p_udFaultsStream) | Atalanta writes the list of aborted (or undetected) faults to the given file name.
int getSimulationMode(void) |
void setSimulationMode(int p_simulationMode) | Simulation mode is performed, instead of TPG. The pattern file has to be specified (-t option), if the -l option is not present.
string getMaskFile(void) |
void setMaskFile(string p_maskFile) | The fault mask is written to the file fn. The order of faults corresponds to the fault list.
streambuf *getMaskStream(void) |
void setMaskStream(streambuf *p_maskStream) | The fault mask is written to the file fn. The order of faults corresponds to the fault list.
string getReportFile(void) |
void setReportFile(string p_reportFile) | The ATPG/FS report is written to a file fn.
streambuf *getReportStream(void) |
void setReportStream(streambuf *p_reportStream) | The ATPG/FS report is written to a file fn.
int getWTestMode(void) |
void setWTestMode(int p_wTestMode) | The output test file format (for TPG only). n = 0 - no test pattern output (default). n = 1 - PAT file (test vectors only). Do not use together with -D n option, since all the test vectors are put together. n = 2 - input + output. Do not use together with -D n option, since all the test vectors are put together. n = 3 - more test vectors for each fault, output. n = 4 - more test vectors for each fault, output, with fault mask. HOPE simulator is employed.
int getLfsrSimMode(void) |
void setLfsrSimMode(int p_lfsrSimMode) | Simulates num LFSR patterns. The LFSR polynomial and seed are specified in octal form (poly, seed).
string getLfsrPoly(void) | Simulates num LFSR patterns. The LFSR polynomial and seed are specified in octal form (poly, seed).
string getLfsrSeed(void) | Simulates num LFSR patterns. The LFSR polynomial and seed are specified in octal form (poly, seed).
int getLfsrNum(void) | Simulates num LFSR patterns. The LFSR polynomial and seed are specified in octal form (poly, seed).
void setLfsrSimulation(string p_lfsrPoly, string p_lfsrSeed, int p_lfsrNum) |