diff --git a/trick_test/requirements_docs/DTD/TopLevelReqs.dtd b/trick_test/requirements_docs/DTD/TopLevelReqs.dtd deleted file mode 100644 index f718936d..00000000 --- a/trick_test/requirements_docs/DTD/TopLevelReqs.dtd +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/trick_test/requirements_docs/Makefile b/trick_test/requirements_docs/Makefile deleted file mode 100644 index 22c3ba42..00000000 --- a/trick_test/requirements_docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -all: build_date - @ xsltproc XSLT/XMLstoXML.xsl src_xml/Test_List.xml > src_xml/AllTests.xml - @ $(MAKE) -C TagRequirements/ - @ ./TagRequirements/TagRequirements src_xml/TopLevelReqs.xml > src_xml/TopLevelReqs_tag.xml - @ xsltproc XSLT/REQtoREQNUM.xsl src_xml/TopLevelReqs_tag.xml > src_xml/intermediate.xml - @ xsltproc XSLT/XMLtoHTML.xsl src_xml/intermediate.xml > Requirements.html - @ rm -rf build_date.xml - @ rm -rf src_xml/intermediate.xml - @ rm -rf src_xml/TopLevelReqs_tag.xml - @ rm -rf src_xml/AllTests.xml - -build_date: - @ echo "" > build_date.xml - -clean: - @ rm -rf Requirements.html - @ $(MAKE) -C TagRequirements clean - -install: all - @ cp Requirements.html ${TRICK_HOME}/docs/. diff --git a/trick_test/requirements_docs/README b/trick_test/requirements_docs/README deleted file mode 100644 index 810d0384..00000000 --- a/trick_test/requirements_docs/README +++ /dev/null @@ -1,41 +0,0 @@ -####################################################################################### - README: TRICK 13 REQUIREMENTS DOCUMENT INSTRUCTIONS - --------------------------------------------------- -Author: Lindsay Landry -####################################################################################### - -To generate Requirements.html in this directory, type (in the current directory): - [usr]$ make -**Requirements document is also made after typing "make test" from the top level directory - Requirements.html will be put into the docs folder under trunk. - -To add new unit test xml files to documentation, add the file name to "Test_List.xml" - -To add requirements to the tree, make changes to "TopLevelReqs.xml" - -These requirements are organized in a hierarchical format (think of a tree), -with the topmost level requirements at the roots of this "tree" and the lower level -requirements making up the branches. Keep this format in mind when adding, deleting, -or making changes to requirements in the tree. - -Each requirement in TopLevelReqs.xml looks as follows: - - - -statement: - This is where the actual requirement verbage goes, verbatim, as you want it to appear - in the document. - -Each requirement in Requirements.html looks as follows: - - 3.2.3 Trick shall respond to executive commands sent via the input processor. [3822434711] - -[3822434711]: - This is the tag associated with the requirement statement. This number is used when - linking one or more unit test with this requirement. - -For instructions on how to link unit tests with requirements, go to - ${TRICK_HOME}/trick_source/trick_utils/reqs/ -and look at the README document. As an alternative, you can look at the Integrator unit -test code for examples. diff --git a/trick_test/requirements_docs/TagRequirements/Requirement.cpp b/trick_test/requirements_docs/TagRequirements/Requirement.cpp deleted file mode 100644 index 51ae7a22..00000000 --- a/trick_test/requirements_docs/TagRequirements/Requirement.cpp +++ /dev/null @@ -1,168 +0,0 @@ -#include "Requirement.hh" -#include -#include -#include - -int Requirement::Initialize(xmlNode *root_node) { - - int rc = 0; - if (strcmp((char*) root_node->name, "requirement") == 0) { - - /* Process children */ - xmlNode *current_node = root_node->children; - - while (current_node != NULL) { - - if (current_node->type == XML_ELEMENT_NODE) { - - if ( strcmp( (char *)current_node->name, "requirement") == 0) { - try { - - Requirement* requirement = new Requirement(current_node); - derivedRequirements.push_back(requirement); - - } catch (std::invalid_argument) { - std::cerr << "ERROR: specification." << std::endl; - } - } else { - std::cerr << "WARNING: unknown element \"<" << current_node->name << ">\". Skipping." << std::endl; - } - } - current_node = current_node->next; - } - } else { - std::cerr << "ERROR: Expected component but alas it wasn\'t found." << std::endl; - rc = -1; - } - return rc; -} - -// CONSTRUCTOR -Requirement::Requirement(xmlNode *Base_node) throw (std::invalid_argument) - : XMLComponent(Base_node) { - - if ( Initialize( Base_node) < 0) { - throw std::invalid_argument("Requirement is un-usable."); - } -} - - -// DESTRUCTOR -Requirement::~Requirement() { -} - -unsigned int Requirement::derivedRequirementsCount() { - return (unsigned int)derivedRequirements.size(); -} - -unsigned int hash( const char * s ) { - unsigned int h = 31; - while (*s) { - h = h * 101 + (unsigned int)*s; - s++; - } - return h; -} - - -// Strip all of the extraneous white space from a string. -std::string normalize( std::string& s) { - - int state = 0; - std::string result_s; - - for (std::string::iterator ii = s.begin() ; ii < s.end() ; ii++) { - - if (state == 0) { - if (!isspace(*ii)) { - result_s += *ii; - state = 1; - } - } else { - if (isspace(*ii)) { - result_s += ' '; - state = 0; - } else { - result_s += *ii; - } - } - } - return result_s; -} - -void Requirement::writeAttribute( std::string& v, const char* k) { - - std::string out_v; - std::cout << " " << k << " = \"" ; - for (std::string::iterator ii = v.begin() ; ii < v.end() ; ii++) { - if (*ii == '"' ) { - out_v += """; - } else if (*ii == '\'') { - out_v += "'"; - } else { - out_v += *ii; - } - } - std::cout << out_v << "\"" ; -} - -/* -void Requirement::writeStatement( std::string& s) { - - std::string out_s; - std::cout << " statement = \"" ; - for (std::string::iterator ii = s.begin() ; ii < s.end() ; ii++) { - if (*ii == '"' ) { - out_s += """; - } else if (*ii == '\'') { - out_s += "'"; - } else { - out_s += *ii; - } - } - std::cout << out_s << "\"" ; -} -*/ - -void Requirement::writeTagged(int indent) { - - for (int ii = 0; ii < indent; ii++) { std::cout << " "; } - - std::cout << "" << std::endl; - } else { - std::cout << ">" << std::endl; - for (unsigned int ii = 0; ii < numberOfDerivedRequirements; ii++) { - Requirement* dreq = derivedRequirements[ii]; - dreq->writeTagged(indent+3); - } - - for (int ii = 0; ii < indent; ii++) { std::cout << " "; } - std::cout << "" << std::endl; - } -} - diff --git a/trick_test/requirements_docs/TagRequirements/Requirement.hh b/trick_test/requirements_docs/TagRequirements/Requirement.hh deleted file mode 100644 index 3bea191e..00000000 --- a/trick_test/requirements_docs/TagRequirements/Requirement.hh +++ /dev/null @@ -1,30 +0,0 @@ -#ifndef REQUIREMENT_HH -#define REQUIREMENT_HH - -#include -#include -#include "XMLComponent.hh" - -class Requirement : public XMLComponent { - -public: - /** - * Constructor. - */ - Requirement(xmlNode * node) throw (std::invalid_argument); - - /** - * Destructor - */ - ~Requirement(); - - unsigned int derivedRequirementsCount(); - void writeTagged(int indent); - void writeAttribute( std::string& v, const char* k); - -private: - std::vector derivedRequirements; - - int Initialize(xmlNode *node); -}; -#endif diff --git a/trick_test/requirements_docs/TagRequirements/TagRequirements.cpp b/trick_test/requirements_docs/TagRequirements/TagRequirements.cpp deleted file mode 100644 index 574a1fae..00000000 --- a/trick_test/requirements_docs/TagRequirements/TagRequirements.cpp +++ /dev/null @@ -1,66 +0,0 @@ -#include -#include -#include -#include "Requirement.hh" - -const char*usage_info[] = { -"--------------------------------------------------", -"", -"", -"", -"--------------------------------------------------", -}; - -#define N_USAGE_LINES (sizeof(usage_info)/sizeof(usage_info[0])) -void print_usage(const char* info[], int nlines) { - int i; - for (i=0; ivalid == 0) { - std::cerr << "WARNING: XML file \"" << argv[1] << "\"" << " is not valid according to the dtd." << std::endl; - } - root_node = xmlDocGetRootElement(doc); - - Requirement* requirement = new Requirement( root_node); - std::cout << "" << std::endl; - std::cout << "" << std::endl; - std::cout << std::endl; - - requirement->writeTagged(0); - - xmlFreeDoc(doc); - } else { - std::cerr << "ERROR: Parse of XML file \"" << argv[1] << "\"" << " failed." << std::endl; - } - } -} - diff --git a/trick_test/requirements_docs/TagRequirements/XMLAttribute.cpp b/trick_test/requirements_docs/TagRequirements/XMLAttribute.cpp deleted file mode 100644 index be4c82af..00000000 --- a/trick_test/requirements_docs/TagRequirements/XMLAttribute.cpp +++ /dev/null @@ -1,20 +0,0 @@ -#include "XMLAttribute.hh" -#include -#include - -// COPY CONSTRUCTOR -XMLAttribute::XMLAttribute(const XMLAttribute *attr) { - key = attr->key; - value = attr->value; -} - -// MEMBER FUNCTION -int XMLAttribute::key_is (const char *name) { - return (strcmp(name, this->key.c_str()) == 0); -} - -// MEMBER FUNCTION -const std::string& XMLAttribute::value_of() { - return this->value; -} - diff --git a/trick_test/requirements_docs/TagRequirements/XMLAttribute.hh b/trick_test/requirements_docs/TagRequirements/XMLAttribute.hh deleted file mode 100644 index fe3c2ffa..00000000 --- a/trick_test/requirements_docs/TagRequirements/XMLAttribute.hh +++ /dev/null @@ -1,38 +0,0 @@ -#ifndef XMLATTRIBUTE_HH -#define XMLATTRIBUTE_HH - -#include -#include - -class XMLAttribute { - -public: - /** - * XMLAttribute constructor. - * @param Key the identifier for the attribute. - * @param Value the value of he attribute. - */ - XMLAttribute(const std::string& Key, const std::string& Value) - : key(Key), value(Value) {} - - /** - * Copy constructor. - */ - XMLAttribute(const XMLAttribute *attr); - - /** - * If name matches the key value of the attribute return 1, otherwise return 0.. - */ - int key_is(const char *name); - - /** - * Return a pointer to a copy of the attribute value. The caller shall - * be responsible for deleting the string that is returned. - */ - const std::string& value_of(); - -private: - std::string key; /**< The name of the attribute.*/ - std::string value; /**< The value of the attribute.*/ -}; -#endif diff --git a/trick_test/requirements_docs/TagRequirements/XMLComponent.cpp b/trick_test/requirements_docs/TagRequirements/XMLComponent.cpp deleted file mode 100644 index 66660953..00000000 --- a/trick_test/requirements_docs/TagRequirements/XMLComponent.cpp +++ /dev/null @@ -1,54 +0,0 @@ -#include "XMLComponent.hh" - -void XMLComponent::Initialize( xmlNode *Base_node) { - - if ( (Base_node == NULL) || - (Base_node->type != XML_ELEMENT_NODE )) { - std::cerr << "XMLComponent::Initialize: Bad parameters." << std::endl; - } else { - xmlAttr *current_attr = NULL; - - /* Get Attributes from the XML parse tree. */ - for (current_attr = Base_node->properties; current_attr ; current_attr = current_attr->next ) { - if (current_attr->type == XML_ATTRIBUTE_NODE ) { - // Add the attribute to the list. - std::string key( (const char *)current_attr->name); - std::string value( (const char *)current_attr->children->content); - attribute_list.push_back( new XMLAttribute(key, value) ); - } - } - } -} - -// XML CONSTRUCTOR -XMLComponent::XMLComponent(xmlNode *Base_node) { - - Initialize( Base_node); -} - -// DESTRUCTOR -XMLComponent::~XMLComponent() { - // destroy each of the attributes in the attribute list - unsigned int i; - std::vector::size_type attr_count = this->attribute_list.size(); - for (i = 0; iattribute_list[i]; - } -} - -// MEMBER FUNCTION -unsigned int XMLComponent::NumberOfAttributes() { - return (unsigned int)attribute_list.size(); -} - -// MEMBER FUNCTION -const char *XMLComponent::AttributeValue( const char *name ) { - unsigned int i; - std::vector::size_type attr_count = this->attribute_list.size(); - for (i=0 ; ikey_is(name) ) { - return ( attribute_list[i]->value_of().c_str()); - } - } - return ""; -} diff --git a/trick_test/requirements_docs/TagRequirements/XMLComponent.hh b/trick_test/requirements_docs/TagRequirements/XMLComponent.hh deleted file mode 100644 index 7372c51e..00000000 --- a/trick_test/requirements_docs/TagRequirements/XMLComponent.hh +++ /dev/null @@ -1,41 +0,0 @@ -#ifndef XMLCOMPONENT_HH -#define XMLCOMPONENT_HH - -#include -#include -#include "XMLAttribute.hh" - -class XMLComponent { - -public: - - XMLComponent() {} - /** - * XML constructor. - */ - XMLComponent(xmlNode *element_node); - - /** - * XMLComponent Destructor. - */ - ~XMLComponent(); - - /** - * Return the number of attributes contained within this XMLComponent. - */ - unsigned int NumberOfAttributes(); - - /** - * Return a pointer to a copy of the Attribute value by name. - * @param key this is the key to be matched. - */ - const char *AttributeValue(const char *key); - -protected: - std::vector attribute_list; /**< This is the list of attributes - associated with an XMLComponent. */ - -private: - void Initialize( xmlNode *base_node); -}; -#endif diff --git a/trick_test/requirements_docs/TagRequirements/makefile b/trick_test/requirements_docs/TagRequirements/makefile deleted file mode 100644 index b1c8af20..00000000 --- a/trick_test/requirements_docs/TagRequirements/makefile +++ /dev/null @@ -1,39 +0,0 @@ - -# $Id$ - -SHELL = /bin/sh -RM = rm -rf -CC = gcc -CPP = g++ - -INCDIRS = -I/usr/include/libxml2 - -CFLAGS = -g \ - -Wall \ - -Wshadow \ - -Wconversion \ - -Wextra \ - -Wno-unused-parameter \ - -Wno-missing-braces \ - -Wno-unused-variable - -OBJDIR = obj -OBJS = XMLAttribute.o \ - XMLComponent.o \ - Requirement.o \ - TagRequirements.o - -.cpp.o: - ${CPP} ${CFLAGS} ${INCDIRS} -c $< - -all: TagRequirements - -TagRequirements: ${OBJS} - ${CPP} ${CFLAGS} -o $@ ${OBJS} -lxml2 - -clean: - ${RM} *.o - ${RM} *~ - ${RM} TagRequirements - -spotless: clean diff --git a/trick_test/requirements_docs/XSLT/REQtoREQNUM.xsl b/trick_test/requirements_docs/XSLT/REQtoREQNUM.xsl deleted file mode 100644 index 624610f9..00000000 --- a/trick_test/requirements_docs/XSLT/REQtoREQNUM.xsl +++ /dev/null @@ -1,28 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/trick_test/requirements_docs/XSLT/XMLstoXML.xsl b/trick_test/requirements_docs/XSLT/XMLstoXML.xsl deleted file mode 100644 index 538c7342..00000000 --- a/trick_test/requirements_docs/XSLT/XMLstoXML.xsl +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/trick_test/requirements_docs/XSLT/XMLtoHTML.xsl b/trick_test/requirements_docs/XSLT/XMLtoHTML.xsl deleted file mode 100644 index 37ef0e2d..00000000 --- a/trick_test/requirements_docs/XSLT/XMLtoHTML.xsl +++ /dev/null @@ -1,183 +0,0 @@ - - - - - - - - - - - - - -

Trick Software Requirements Specification

-

Automation, Robotics and Simulation Division

-

Trick 13  

-

Last updated: -

-
-

Total Tests: - -         Failures: - -

-
- - -


- - - - -
- - - - - - -

- -      -

- -

-

-
- -

-

-
- - -
- - - - - - - - - - - - - - -

- - -      - -

- -

-

-
-
- - -

- - -        - - - -    [ - ]
- - NOTE:  - -

-
-
- - - -

- [VERIFIED] - -

-
- - - - - -

- - - - - -

-
-
-
-
-
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - [ FAILED ] - - - [ PASSED ] - - - - - - - -
diff --git a/trick_test/requirements_docs/src_xml/Test_List.xml b/trick_test/requirements_docs/src_xml/Test_List.xml deleted file mode 100644 index 9ce292e6..00000000 --- a/trick_test/requirements_docs/src_xml/Test_List.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/trick_test/requirements_docs/src_xml/TopLevelReqs.xml b/trick_test/requirements_docs/src_xml/TopLevelReqs.xml deleted file mode 100644 index ba5431e3..00000000 --- a/trick_test/requirements_docs/src_xml/TopLevelReqs.xml +++ /dev/null @@ -1,1186 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/trick_test/requirements_docs/src_xml/headerReqs.xml b/trick_test/requirements_docs/src_xml/headerReqs.xml deleted file mode 100644 index 3534e18e..00000000 --- a/trick_test/requirements_docs/src_xml/headerReqs.xml +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/trick_test/requirements_testing/models/helios/include/JD.h b/trick_test/requirements_testing/models/helios/include/JD.h deleted file mode 100644 index 60684075..00000000 --- a/trick_test/requirements_testing/models/helios/include/JD.h +++ /dev/null @@ -1,49 +0,0 @@ -#ifndef JD_H -#define JD_H -/** - @file JD.h - @brief the amalgomated, gonkulated JD.h file - - Here is a detailed description. Here is a detailed description. - Here is a detailed description. Here is a detailed description. - Here is a detailed description. Here is a detailed description. - Here is a detailed description. Here is a detailed description. - Here is a detailed description. - */ -#include -#include - -#ifdef __cplusplus -extern "C" { -#endif -/** - * Returns 1 if the specified date is a Gregorian date. - * @param Y (IN) Year - * @param M (IN) Month - * @param D (IN) Day - */ -int is_gregorian_date (int Y, int M, double D); -/** - * Returns 1 if the specified date is a Julian date. - * @param Y (IN) Year - * @param M (IN) Month - * @param D (IN) Day - */ -int is_julian_date (int Y, int M, double D); -/** - * Calculates the Julian date from the given calendar date. - * @param Y (IN) Year - * @param M (IN) Month - * @param D (IN) Day - * @param JD (OUT) Julian date - */ -int Calendar_Date_to_JD (int Y, int M, float D, double * JD); -void JD_to_Calendar_Date (double JD, int *year, int *month, float *day) ; -#ifdef __cplusplus -} -#endif - -#endif - - - diff --git a/trick_test/requirements_testing/models/helios/include/lh_coords.h b/trick_test/requirements_testing/models/helios/include/lh_coords.h deleted file mode 100644 index 9a3eb02b..00000000 --- a/trick_test/requirements_testing/models/helios/include/lh_coords.h +++ /dev/null @@ -1,22 +0,0 @@ -#ifndef LH_COORDS_H -#define LH_COORDS_H - -#ifdef __cplusplus -extern "C" { -#endif - -void equatorial_to_local_horiz(double lat, /* Observer's latitude IN */ - double HA, /* hour_angle IN */ - double ra, /* Right Ascension (degrees) IN */ - double decl, /* Declination (degrees) IN */ - double *az, /* Azimuth (degrees) OUT */ - double *el) ; /* Elevation (degrees) OUT */ - -#ifdef __cplusplus -} -#endif - -#endif - - - diff --git a/trick_test/requirements_testing/models/helios/include/sidereal.h b/trick_test/requirements_testing/models/helios/include/sidereal.h deleted file mode 100644 index 56572487..00000000 --- a/trick_test/requirements_testing/models/helios/include/sidereal.h +++ /dev/null @@ -1,16 +0,0 @@ -#ifndef SIDEREAL_H -#define SIDEREAL_H - -#ifdef __cplusplus -extern "C" { -#endif - -void GST_secs_time( double JD, double *GST ); -void LST_secs_time( double GST, double longitude, double *LST ); - -#ifdef __cplusplus -} -#endif - -#endif - diff --git a/trick_test/requirements_testing/models/helios/include/sun_pos.h b/trick_test/requirements_testing/models/helios/include/sun_pos.h deleted file mode 100644 index 3506eef4..00000000 --- a/trick_test/requirements_testing/models/helios/include/sun_pos.h +++ /dev/null @@ -1,20 +0,0 @@ -#ifndef SUN_POS_H -#define SUN_POS_H - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * Calculate the Sun's position at the given Julian day number. - * @param JD The Julian day number. - * @param sun_right_ascension. - * @param sun_declination. - */ -int sun_pos_at_JD (double JD, double *sun_right_ascension, double *sun_declination ); - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/trick_test/requirements_testing/models/helios/include/sun_pred.d b/trick_test/requirements_testing/models/helios/include/sun_pred.d deleted file mode 100644 index 0dda892d..00000000 --- a/trick_test/requirements_testing/models/helios/include/sun_pred.d +++ /dev/null @@ -1,15 +0,0 @@ -SUN_PRED.observer_latitude = 29.55298; -SUN_PRED.observer_longitude = 95.09379; -SUN_PRED.observer_offset_from_UTC = -6; - -SUN_PRED.local_time.year = 2006; -SUN_PRED.local_time.month = 8; -SUN_PRED.local_time.day = 8; -SUN_PRED.local_time.hour = 12; -SUN_PRED.local_time.min = 0; -SUN_PRED.local_time.sec = 0.0; - -SUN_PRED.label_UTC = "UTC"; -SUN_PRED.label_JD = "JD"; -SUN_PRED.label_Azimuth = "A"; -SUN_PRED.label_Elevation = "h"; diff --git a/trick_test/requirements_testing/models/helios/include/sun_pred.h b/trick_test/requirements_testing/models/helios/include/sun_pred.h deleted file mode 100644 index caa7827c..00000000 --- a/trick_test/requirements_testing/models/helios/include/sun_pred.h +++ /dev/null @@ -1,51 +0,0 @@ -/************************************************************************* -PURPOSE: (SUN sim) -**************************************************************************/ -#ifndef SUN_PRED_H -#define SUN_PRED_H -#include - -typedef struct { - int year; /* (-- ) Year (-4712 .. INT_MAX) */ - int month; /* (-- ) Month (Jan=1, ... Dec=12) */ - int day; /* (day) Day of the month (1..31) */ - int hour; /* (hr ) Hour of the day (0..23) */ - int min; /* (min) Minute of the hour (0..59) */ - double sec; /* (s ) Second of the minute (0..59) */ -} CALENDAR_DATE; - -typedef struct { - double observer_latitude; /* (d) */ - double observer_longitude; /* (d) */ - CALENDAR_DATE local_time; /* (--) */ - double local_sidereal_time; /* (s) */ - double sidereal_time_at_Greenwich; /* (s) */ - int observer_offset_from_UTC; /* (hr) */ - CALENDAR_DATE utc; /* (--) */ - double JD_start; /* (day) Julian date at the beginning of the sim run.*/ - double JD; /* (day) Current Julian date */ - double right_ascension; /* (d) */ - double declination; /* (d) */ - double hour_angle; /* (d) */ - double solar_azimuth; /* (d) */ - double solar_elevation; /* (d) */ - wchar_t* label_UTC; /* (--) wide character pointer */ - wchar_t* label_JD; /* (--) wide character pointer */ - wchar_t* label_Azimuth; /* (--) wide character pointer */ - wchar_t* label_Elevation; /* (--) wide character pointer */ -} SUN_PRED; - -#ifdef __cplusplus -extern "C" { -#endif -int sun_pred_cyclic( SUN_PRED* S, double current_sim_time ) ; -int sun_pred_init( SUN_PRED* S ) ; -int sun_pred_shutdown( void ) ; -int sun_pred_slow_display( SUN_PRED* S ) ; -int sun_pred_fast_display( SUN_PRED* S ) ; -#ifdef __cplusplus -} -#endif - - -#endif diff --git a/trick_test/requirements_testing/models/helios/src/JD.c b/trick_test/requirements_testing/models/helios/src/JD.c deleted file mode 100644 index 805ca0b7..00000000 --- a/trick_test/requirements_testing/models/helios/src/JD.c +++ /dev/null @@ -1,94 +0,0 @@ -/******************************************************************* - * @\file JD.c - * @\brief This is the JD.c file - * Reference(s): - * (1) Meeus,Jean."Astronomical Algorithms", - * 2nd Edition, Willmann-Bell, Inc. - * Chapter 7. - ******************************************************************* - */ - -#include -#include -#include "JD.h" - -int is_gregorian_date (int Y, int M, double D) { - return ((Y>1582)||((Y==1582)&&(M>10))||((Y==1582)&&(M==10)&&(D>=15.0))); -} - -int is_julian_date (int Y, int M, double D) { - return ((Y<1582)||((Y==1582)&&(M<10))||((Y==1582)&&(M==10)&&(D<5.0))); -} - -/* The algorithm for this function is described on page 60 of ref(1). */ -int Calendar_Date_to_JD (int Y, int M, float D, double * JD) { - - int A, B; - /* Is the day valid? */ - if ((D < 1.0) || (M >= 32.0)) return -1; - - /* Is the month valid? */ - if ((M < 1) || (M > 12)) return -1; - - /* Is the year valid? */ - if ((Y < -4712) || ((Y == -4712) && (D < 1.5))) return -1; - - if (M <= 2) { - Y = Y - 1; - M = M + 12; - } - - A = (int)(Y / 100.0); - - if (is_gregorian_date(Y,M,D)) { - B = 2 - A + (int)(A/4.0); - } else if (is_julian_date (Y,M,D)) { - B = 0; - } else { - return -1; - } - - *JD = (int)(365.25 * (Y + 4716)) + (int)(30.6001 * (M+1)) + D + B - 1524.5; - - return 0; -} - -/* The algorithm for this function is described on page 63 of ref(1). */ -void JD_to_Calendar_Date (double JD, int *Year, int *Month, float *Day) { - - int Z,A,B,C,D,E; - int alpha, year, month; - float day; - float F; - - Z = (int)(JD + 0.5); - F = (JD + 0.5) - Z; - if ( Z < 2299161 ) { - A = Z; - } else { - alpha = (int)( (Z - 1867216.25) / 36524.25 ); - A = Z + 1 + alpha - (int)(alpha/4); - } - B = A + 1524; - C = (int)((B-122.1)/365.25); - D = (int)(365.25 * C); - E = (int)((B-D)/30.6001); - - day = B - D - (int)(30.6001 * E) + F; - - if ( E < 14) { - month = E - 1; - } else { - month = E - 13; - } - - if ( month > 2 ) { - year = C -4716; - } else { - year = C -4715; - } - - *Day = day; - *Month = month; - *Year = year; -} diff --git a/trick_test/requirements_testing/models/helios/src/lh_coords.c b/trick_test/requirements_testing/models/helios/src/lh_coords.c deleted file mode 100644 index 3ece4d1c..00000000 --- a/trick_test/requirements_testing/models/helios/src/lh_coords.c +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************* - * Reference(s): - * (1) Meeus,Jean."Astronomical Algorithms", - * 2nd Edition, Willmann-Bell, Inc. - * Chapter 13. - ******************************************************************* - */ - -#include -#include "lh_coords.h" - -#ifndef PI -#define PI 3.14159264 -#endif -#define DEG_TO_RAD (PI/180.0) -#define RAD_TO_DEG (180.0/PI) - -void equatorial_to_local_horiz(double lat, /* Observer's latitude IN */ - double HA, /* hour_angle IN */ - double ra, /* Right Ascension (degrees) IN */ - double decl, /* Declination (degrees) IN */ - double *az, /* Azimuth (degrees) OUT */ - double *el) { /* Elevation (degrees) OUT */ - - double HA_r = HA * DEG_TO_RAD; - double lat_r = lat * DEG_TO_RAD; - double decl_r = decl * DEG_TO_RAD; - - /* Ref(1), (13.5) */ - *az = RAD_TO_DEG * atan2 ( sin(HA_r) , ( cos(HA_r) * sin(lat_r) - tan (decl_r) * cos(lat_r) ) ); - /* Ref(1), (13.6) */ - *el = RAD_TO_DEG * asin ( sin(lat_r) * sin(decl_r) + cos(lat_r)*cos(decl_r)*cos(HA_r) ); - -} - diff --git a/trick_test/requirements_testing/models/helios/src/sidereal.c b/trick_test/requirements_testing/models/helios/src/sidereal.c deleted file mode 100644 index 3cdbe4db..00000000 --- a/trick_test/requirements_testing/models/helios/src/sidereal.c +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************* - * Reference(s): - * (1) Meeus,Jean."Astronomical Algorithms", - * 2nd Edition, Willmann-Bell, Inc. - * Chapter 12. - ******************************************************************* - */ -#include -#include -#include "JD.h" -#include "sidereal.h" - -#define SECONDS_PER_DAY 86400 - -/* Calculate sidereal time at Greenwich. */ -void GST_secs_time( double JD, double *GST ) { - - double T; - double cap_theta_0; - double theta_0; - double JD_0; - double UT; - - /* In the calculation for mean sidereal time (below) - * T must correspond to 0h UT of the date. So, we - * calculate JD_0 that corresponds to 0h. - */ - if ( (JD-(int)JD) < 0.5) { - JD_0 = (int)JD - 0.5; - } else { - JD_0 = (int)JD + 0.5; - } - - UT = (JD - JD_0) * SECONDS_PER_DAY; - - /* Ref(1), equation (12.1). */ - /* Note that 2451545.0 is the J2000 epoch. */ - T = (JD_0 - 2451545.0) / 36525.0; - - /* Ref(1), equation (12.2) */ - /* Mean sidereal time (in seconds) at Greenwich at 0-h UT. */ - cap_theta_0 = 24110.54842 + - (8640184.812866 * T) + - (0.093104 * T * T) - - (0.0000062 * T * T * T); - - /* We want it in the range 0..86400. */ - /* Note that there are 84600 seconds in a day. */ - if (cap_theta_0 >= 0.0) { - cap_theta_0 = fmod(cap_theta_0, 86400.0); - } else { - cap_theta_0 = fmod(cap_theta_0, 86400.0) + 86400.0; - } - - /* Ref(1), page 87 */ - theta_0 = UT * 1.00273790935 + cap_theta_0; - - if (theta_0 >= 0.0) { - theta_0 = fmod(theta_0, 86400.0); - } else { - theta_0 = fmod(theta_0, 86400.0) + 86400.0; - } - - *GST = theta_0; - -} - -void LST_secs_time( double GST, double longitude, double *LST) { - - *LST = GST - (longitude * (3600.0/15.0)); -} - - - - - - - - - - - - diff --git a/trick_test/requirements_testing/models/helios/src/sun_pos.c b/trick_test/requirements_testing/models/helios/src/sun_pos.c deleted file mode 100644 index 982f608a..00000000 --- a/trick_test/requirements_testing/models/helios/src/sun_pos.c +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************* - * Reference(s): - * (1) Meeus,Jean."Astronomical Algorithms", - * 2nd Edition, Willmann-Bell, Inc. - * Chapter 25. - ******************************************************************* - */ -#include -#include "sun_pos.h" - -#ifndef PI -#define PI 3.14159264 -#endif -#define DEG_TO_RAD (PI/180.0) -#define RAD_TO_DEG (180.0/PI) - -static double norm_mod(double x, double y) { - if (x >= 0.0) { - x = fmod(x, y); - } else { - x = fmod(x, y) + y; - } - return x; -} - -/** - * Calculate the position of the Sun (right ascension and declination ) - * @param JD Julian Date - * @param sun_right_ascension Right ascension of the Sun - * @param sun_declination Declination of the Sun - */ -int sun_pos_at_JD (double JD, - double *sun_right_ascension, - double *sun_declination ) { - - /* We are ignoring nutation in this calculation. */ - - double T; - double L_0; - double M; - double M_rad; - double C; - double Suns_true_longitude; - double epsilon; - double tmp_d; - double right_ascension; - double declination; - - /* Ref(1), (25.1) */ - T = (JD - 2451545.0) / 36525.0; - - /* Geometric mean longitude of the Sun. Ref(1), (25.2) */ - L_0 = 280.46646 + T * (36000.76983 + T * 0.0003032 ) ; - L_0 = norm_mod(L_0, 360.0); - - /* Mean anomaly of the Sun. Ref(1), (25.3) */ - M = 357.52911 + T * (35999.05029 + T * 0.0001537 ) ; - M = norm_mod(M, 360.0); - - M_rad = M * DEG_TO_RAD; - - C = ( 1.914602 - T * ( 0.004817 - T * 0.000014 ) ) * sin( M_rad ) - + ( 0.019993 - T * 0.000101 ) * sin (2 * M_rad) - + 0.000289 * sin (3 * M_rad) ; - - Suns_true_longitude = L_0 + C; - - epsilon = 23.4392911; /* Ref(1), page 92 */ - - tmp_d = cos( epsilon * DEG_TO_RAD ) * sin(Suns_true_longitude * DEG_TO_RAD) ; - right_ascension = RAD_TO_DEG * atan2( tmp_d, cos(Suns_true_longitude * DEG_TO_RAD) ); - right_ascension = norm_mod(right_ascension, 360.0); - - tmp_d = sin( epsilon * DEG_TO_RAD ) * sin (Suns_true_longitude * DEG_TO_RAD); - declination = RAD_TO_DEG * asin (tmp_d); - - *sun_right_ascension = right_ascension; - *sun_declination = declination; - - return 0; -} diff --git a/trick_test/requirements_testing/models/helios/src/sun_pred_cyclic.c b/trick_test/requirements_testing/models/helios/src/sun_pred_cyclic.c deleted file mode 100644 index 681be614..00000000 --- a/trick_test/requirements_testing/models/helios/src/sun_pred_cyclic.c +++ /dev/null @@ -1,89 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Predict the path of the SUN across the sky.) -LIBRARY DEPENDENCY: - ((sun_pos.o)(lh_coords.o)(sidereal.o) -PROGRAMMERS: - (((John M. Penn) (L-3 Titan) (Oct 8, 2006) (Trick Demo) )) -*******************************************************************************/ -#include -#include -#include "JD.h" -#include "sun_pred.h" -#include "sun_pos.h" -#include "lh_coords.h" -#include "sidereal.h" - -#define HOURS_PER_DAY 24.0 -#define MINUTES_PER_DAY 1440.0 -#define SECONDS_PER_DAY 86400.0 - -int sun_pred_cyclic( - SUN_PRED* S, - double current_sim_time ) -{ - float dday; - double JDL; - double tsec; - - /* Update the Julian date by one second. */ - S->JD = S->JD_start + ( current_sim_time / SECONDS_PER_DAY ); - - - /* Convert the new JD to UTC Calendar date. */ - JD_to_Calendar_Date (S->JD, &S->utc.year, &S->utc.month, &dday ); - - S->utc.day = (int)dday; - tsec = (dday - S->utc.day ) * SECONDS_PER_DAY + 0.5; - S->utc.hour = (int)( tsec / 3600.0 ); tsec = tsec - ( S->utc.hour * 3600.0 ); - S->utc.min = (int)( tsec / 60.0 ); tsec = tsec - ( S->utc.min * 60.0 ); - S->utc.sec = (int)( tsec ); - - - /* Convert the new JD to Local Calendar date. */ - JDL = S->JD + ( S->observer_offset_from_UTC / HOURS_PER_DAY ) ; - - JD_to_Calendar_Date (JDL, &S->local_time.year, &S->local_time.month, &dday ); - - S->local_time.day = (int)dday; - tsec = (dday - S->local_time.day ) * SECONDS_PER_DAY + 0.5; - S->local_time.hour = (int)( tsec / 3600.0 ); tsec = tsec - ( S->local_time.hour * 3600.0 ); - S->local_time.min = (int)( tsec / 60.0 ); tsec = tsec - ( S->local_time.min * 60.0 ); - S->local_time.sec = (int)( tsec ); - - /* Calculate the sidereal time at Greenwich. */ - GST_secs_time( S->JD, &S->sidereal_time_at_Greenwich ); - - - /* Calculate the local sidereal time. */ - LST_secs_time( S->sidereal_time_at_Greenwich, - S->observer_longitude, &S->local_sidereal_time ); - - - /* Calculate the right_ascension and declination of the Sun. */ - if ( sun_pos_at_JD (S->JD, &S->right_ascension, &S->declination) < 0 ){ - return -1; - } - - /* Calculate the local hour angle of the Sun. */ - S->hour_angle = S->sidereal_time_at_Greenwich * ( 360.0 / 86400.0 ) - - S->observer_longitude - S->right_ascension; - - - /* Calculate the local azimuth and elevation of the Sun. */ - equatorial_to_local_horiz(S->observer_latitude, - S->hour_angle, - S->right_ascension, - S->declination, - &S->solar_azimuth, - &S->solar_elevation); - - - /* The previous function reckons azimuth from south. - * We want to reckon it from north. - */ - S->solar_azimuth += 180.0; - - return 0; -} - diff --git a/trick_test/requirements_testing/models/helios/src/sun_pred_fast_display.c b/trick_test/requirements_testing/models/helios/src/sun_pred_fast_display.c deleted file mode 100644 index 87ff6301..00000000 --- a/trick_test/requirements_testing/models/helios/src/sun_pred_fast_display.c +++ /dev/null @@ -1,74 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Predict the path of the SUN across the sky.) -LIBRARY DEPENDENCY: - ((JD.o)) -PROGRAMMERS: - (((John M. Penn) (L-3 Titan) (Oct 8, 2006) (Trick Demo) )) -*******************************************************************************/ -#include -#include -#include "sun_pred.h" - -#define HOURS_PER_DAY 24.0 -#define MINUTES_PER_DAY 1440.0 -#define SECONDS_PER_DAY 86400.0 - -#define DEGREE_SIGN 0x00B0 -#define SUN 0x2609 -#define CLOCK 0x231A - -#define GREEK_SMALL_LETTER_ALPHA 0x03B1 -#define GREEK_SMALL_LETTER_BETA 0x03B2 -#define GREEK_SMALL_LETTER_GAMMA 0x03B3 -#define GREEK_SMALL_LETTER_DELTA 0x03B4 -#define GREEK_SMALL_LETTER_EPSILON 0x03B5 -#define GREEK_SMALL_LETTER_ZETA 0x03B6 -#define GREEK_SMALL_LETTER_ETA 0x03B7 -#define GREEK_SMALL_LETTER_THETA 0x03B8 -#define GREEK_SMALL_LETTER_IOTA 0x03B9 -#define GREEK_SMALL_LETTER_KAPPA 0x03BA -#define GREEK_SMALL_LETTER_LAMBDA 0x03BB -#define GREEK_SMALL_LETTER_MU 0x03BC -#define GREEK_SMALL_LETTER_NU 0x03BD -#define GREEK_SMALL_LETTER_XI 0x03BE -#define GREEK_SMALL_LETTER_OMICRON 0x03BF -#define GREEK_SMALL_LETTER_PI 0x03C0 -#define GREEK_SMALL_LETTER_RHO 0x03C1 -#define GREEK_SMALL_LETTER_SIGMA 0x03C3 -#define GREEK_SMALL_LETTER_TAU 0x03C4 -#define GREEK_SMALL_LETTER_UPSILON 0x03C5 -#define GREEK_SMALL_LETTER_PHI 0x03C6 -#define GREEK_SMALL_LETTER_CHI 0x03C7 -#define GREEK_SMALL_LETTER_PSI 0x03C8 -#define GREEK_SMALL_LETTER_OMEGA 0x03C9 - - -/* Prototype */ -int send_hs(FILE * fp, char *format, ...); - -int sun_pred_fast_display( - SUN_PRED* S ) -{ - char tmp_s[20]; - char message[500]; - - message[0] = '\0'; - sprintf(tmp_s,"%ls %0d:%0d:%02.f",S->label_UTC, S->utc.hour , S->utc.min , S->utc.sec ); - strcat(message,tmp_s); - // sprintf(tmp_s," %ls %.6f",S->label_JD, S->JD); - // strcat(message,tmp_s); - if ( S->label_Azimuth != NULL ) { - sprintf(tmp_s," %ls %.3f%lc",S->label_Azimuth, S->solar_azimuth, DEGREE_SIGN); - } else { - sprintf(tmp_s," AZIMUTH %.3f%lc", S->solar_azimuth, DEGREE_SIGN); - } - strcat(message,tmp_s); - sprintf(tmp_s," %ls %.3f%lc",S->label_Elevation, S->solar_elevation, DEGREE_SIGN); - strcat(message,tmp_s); - - send_hs(stdout,"%s",message); - - return 0; -} - diff --git a/trick_test/requirements_testing/models/helios/src/sun_pred_init.c b/trick_test/requirements_testing/models/helios/src/sun_pred_init.c deleted file mode 100644 index 257cb1ef..00000000 --- a/trick_test/requirements_testing/models/helios/src/sun_pred_init.c +++ /dev/null @@ -1,46 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Predict the path of the SUN across the sky.) -LIBRARY DEPENDENCY: - ((JD.o)) -PROGRAMMERS: - (((John M. Penn) (L-3 Titan) (Oct 8, 2006) (Trick Demo) )) -*******************************************************************************/ -#include "sun_pred.h" -#include "JD.h" - -#define HOURS_PER_DAY 24.0 -#define MINUTES_PER_DAY 1440.0 -#define SECONDS_PER_DAY 86400.0 - -int sun_pred_init( - SUN_PRED* S ) -{ - float dday; - double JDL; - double tsec; - - /* Convert the local time to JD */ - dday = S->local_time.day + - ( S->local_time.hour / HOURS_PER_DAY ) + - ( S->local_time.min / MINUTES_PER_DAY ) + - ( S->local_time.sec / SECONDS_PER_DAY ) ; - - Calendar_Date_to_JD (S->local_time.year, S->local_time.month, dday, &JDL); - - /* Subtract the local offset from UTC from the JD. */ - S->JD_start = JDL - ( S->observer_offset_from_UTC / HOURS_PER_DAY ) ; - S->JD = S->JD_start; - - /* Convert the new JD back to UTC Calendar date */ - JD_to_Calendar_Date (S->JD, &S->utc.year, &S->utc.month, &dday ); - - S->utc.day = (int)dday; - tsec = (dday - S->utc.day ) * SECONDS_PER_DAY + 0.5; - S->utc.hour = (int)( tsec / 3600.0 ); tsec = tsec - ( S->utc.hour * 3600.0 ); - S->utc.min = (int)( tsec / 60.0 ); tsec = tsec - ( S->utc.min * 60.0 ); - S->utc.sec = (int)( tsec ); - - return 0 ; -} - diff --git a/trick_test/requirements_testing/models/helios/src/sun_pred_shutdown.c b/trick_test/requirements_testing/models/helios/src/sun_pred_shutdown.c deleted file mode 100644 index 01b47917..00000000 --- a/trick_test/requirements_testing/models/helios/src/sun_pred_shutdown.c +++ /dev/null @@ -1,13 +0,0 @@ -/***************************************************************************** -PURPOSE: (Shut the thingy down) -*****************************************************************************/ -#include -#include "sun_pred.h" - -int sun_pred_shutdown( - void ) -{ - printf("SIM Shutdown.\n"); - fflush(stdout); - return 0 ; -} diff --git a/trick_test/requirements_testing/models/helios/src/sun_pred_slow_display.c b/trick_test/requirements_testing/models/helios/src/sun_pred_slow_display.c deleted file mode 100644 index c43b8b6c..00000000 --- a/trick_test/requirements_testing/models/helios/src/sun_pred_slow_display.c +++ /dev/null @@ -1,72 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Predict the path of the SUN across the sky.) -LIBRARY DEPENDENCY: - ((JD.o)) -PROGRAMMERS: - (((John M. Penn) (L-3 Titan) (Oct 8, 2006) (Trick Demo) )) -*******************************************************************************/ -#include -#include -#include "sun_pred.h" - -#define HOURS_PER_DAY 24.0 -#define MINUTES_PER_DAY 1440.0 -#define SECONDS_PER_DAY 86400.0 - -#define DEGREE_SIGN 0x00B0 -#define SUN 0x2609 -#define POSITION_INDICATOR 0x2316 -#define CLOCK 0x231A - -#define GREEK_SMALL_LETTER_ALPHA 0x03B1 -#define GREEK_SMALL_LETTER_BETA 0x03B2 -#define GREEK_SMALL_LETTER_GAMMA 0x03B3 -#define GREEK_SMALL_LETTER_DELTA 0x03B4 -#define GREEK_SMALL_LETTER_EPSILON 0x03B5 -#define GREEK_SMALL_LETTER_ZETA 0x03B6 -#define GREEK_SMALL_LETTER_ETA 0x03B7 -#define GREEK_SMALL_LETTER_THETA 0x03B8 -#define GREEK_SMALL_LETTER_IOTA 0x03B9 -#define GREEK_SMALL_LETTER_KAPPA 0x03BA -#define GREEK_SMALL_LETTER_LAMBDA 0x03BB -#define GREEK_SMALL_LETTER_MU 0x03BC -#define GREEK_SMALL_LETTER_NU 0x03BD -#define GREEK_SMALL_LETTER_XI 0x03BE -#define GREEK_SMALL_LETTER_OMICRON 0x03BF -#define GREEK_SMALL_LETTER_PI 0x03C0 -#define GREEK_SMALL_LETTER_RHO 0x03C1 -#define GREEK_SMALL_LETTER_SIGMA 0x03C3 -#define GREEK_SMALL_LETTER_TAU 0x03C4 -#define GREEK_SMALL_LETTER_UPSILON 0x03C5 -#define GREEK_SMALL_LETTER_PHI 0x03C6 -#define GREEK_SMALL_LETTER_CHI 0x03C7 -#define GREEK_SMALL_LETTER_PSI 0x03C8 -#define GREEK_SMALL_LETTER_OMEGA 0x03C9 - - -/* Prototype */ -int send_hs(FILE * fp, char *format, ...); - -int sun_pred_slow_display( - SUN_PRED* S ) -{ - char tmp_s[20]; - char message[500]; - - message[0] = '\0'; - sprintf(tmp_s,"%lc",POSITION_INDICATOR); - strcat(message,tmp_s); - sprintf(tmp_s," %lc %5.2f%lc",GREEK_SMALL_LETTER_PHI, S->observer_latitude, DEGREE_SIGN); - strcat(message,tmp_s); - sprintf(tmp_s," L %5.2f%lc", S->observer_longitude, DEGREE_SIGN); - strcat(message,tmp_s); - sprintf(tmp_s," %lc %5.2f%lc",GREEK_SMALL_LETTER_ALPHA, S->right_ascension, DEGREE_SIGN); - strcat(message,tmp_s); - sprintf(tmp_s," %lc %5.2f%lc",GREEK_SMALL_LETTER_DELTA, S->declination, DEGREE_SIGN); - strcat(message,tmp_s); - send_hs(stdout,"%s",message); - - return 0 ; -} - diff --git a/trick_test/requirements_testing/models/test/dp/.checksums b/trick_test/requirements_testing/models/test/dp/.checksums deleted file mode 100644 index a86f27aa..00000000 --- a/trick_test/requirements_testing/models/test/dp/.checksums +++ /dev/null @@ -1,2 +0,0 @@ -53463 4 ./src/dp.c -9166 3 ./include/dp.h diff --git a/trick_test/requirements_testing/models/test/dp/include/dp.h b/trick_test/requirements_testing/models/test/dp/include/dp.h deleted file mode 100644 index fa00d16c..00000000 --- a/trick_test/requirements_testing/models/test/dp/include/dp.h +++ /dev/null @@ -1,63 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Data products test ) -REFERENCES: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: dp.h,v $ - * Revision 7.2 2007-01-08 13:55:09-06 dstrauss - * Bugs in parsing new units specs - * - * Revision 7.1 2006-06-22 14:14:18-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:52-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:23 lin - * Bump version number for 04 - * - * Revision 1.2 2002/10/07 15:16:22 lin - * Add rcs version info to all trick_models files - * - */ - -#ifndef _DATA_PRODUCTS_H_ -#define _DATA_PRODUCTS_H_ - -typedef struct { - - short si[3] ; /* ohm -- */ - int i[3] ; /* M -- */ - long l[3] ; /* amp -- */ - float f[3] ; /* M/s2 -- */ - double d[3] ; /* kg*M/s2 -- */ - unsigned short us[3] ; /* N -- */ - unsigned int ui[3] ; /* dB -- */ - unsigned long ul[3] ; /* v -- */ - long long ll[3] ; /* K -- */ - -} STRUCT_1 ; - -typedef struct { - - STRUCT_1 s1[2][3] ; /* -- */ - -} STRUCT_2 ; - -typedef struct { - - STRUCT_2 s2[3][2] ; /* -- */ - -} STRUCT_3 ; - -typedef struct { - - STRUCT_3 s3[2] ; /* -- */ - -} DP_TEST ; - - -#endif diff --git a/trick_test/requirements_testing/models/test/dp/src/dp.c b/trick_test/requirements_testing/models/test/dp/src/dp.c deleted file mode 100644 index 23b35419..00000000 --- a/trick_test/requirements_testing/models/test/dp/src/dp.c +++ /dev/null @@ -1,62 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test data products ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -LIBRARY DEPENDENCY: ( dp.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: dp.c,v $ - * Revision 7.1 2006-06-22 14:14:18-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:53-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:23 lin - * Bump version number for 04 - * - * Revision 1.2 2002/10/07 15:16:22 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/dp.h" - - -/* - * Loads 1,2,3 into the last dim on -all- vars in STRUCT_1 - */ -int dp( - /* RETURN: -- Always return zero */ - DP_TEST *DP ) /* INOUT: -- Schedule struct */ -{ - - -#define LOOP for ( i = 0 ; i < 3 ; i++ ) \ - for ( j = 0 ; j < 3 ; j++ ) \ - for ( k = 0 ; k < 2 ; k++ ) \ - for ( l = 0 ; l < 2 ; l++ ) \ - for ( m = 0 ; m < 3 ; m++ ) \ - for ( n = 0 ; n < 2 ; n++ ) - - int i,j,k,l,m,n ; - - LOOP DP->s3[n].s2[m][l].s1[k][j].si[i] = (short) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].i[i] = (int) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].l[i] = (long) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].f[i] = (float) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].d[i] = (double) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].us[i] = (unsigned short) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].ui[i] = (unsigned int) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].ul[i] = (unsigned long) (i+1) ; - LOOP DP->s3[n].s2[m][l].s1[k][j].ll[i] = (long long) (i+1) ; - - /* LOOP printf("\"dp.test.s3[%d].s2[%d][%d].s1[%d][%d].d[%d]\" ,\n", - n,m,l,k,j,i); */ - - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/impexp/.checksums b/trick_test/requirements_testing/models/test/impexp/.checksums deleted file mode 100644 index ba79f62e..00000000 --- a/trick_test/requirements_testing/models/test/impexp/.checksums +++ /dev/null @@ -1,5 +0,0 @@ -64414 2 ./src/export_master.c -64733 2 ./src/export_slave.c -63364 2 ./src/import_master.c -3730 3 ./src/import_slave.c -18794 3 ./include/test.h diff --git a/trick_test/requirements_testing/models/test/impexp/include/test.h b/trick_test/requirements_testing/models/test/impexp/include/test.h deleted file mode 100644 index 60017d3a..00000000 --- a/trick_test/requirements_testing/models/test/impexp/include/test.h +++ /dev/null @@ -1,56 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Trick test) -REFERENCES: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (Nov 2001))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: test.h,v $ - * Revision 7.1 2006-06-22 14:14:17-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:53-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:21 lin - * Bump version number for 04 - * - * Revision 3.3 2002/10/07 15:16:24 lin - * Add rcs version info to all trick_models files - * - */ - -#ifndef _TEST_H_ -#define _TEST_H_ - -typedef struct { /* A ------------------------------------------------*/ - - double d ; /* -- A double */ - int i ; /* -- An int */ - int j ; /* -- An int */ - -} A ; /*--------------------------------------------------------------*/ - -typedef struct { /* B ------------------------------------------------*/ - - double d ; /* -- A double */ - int i ; /* -- An int */ - int j ; /* -- An int */ - -} B ; /*--------------------------------------------------------------*/ - -typedef struct { /* TEST ---------------------------------------------*/ - - A a ; /* -- A */ - B b ; /* -- B */ - -} TEST ; /*------------------------------------------------------------*/ - -#endif diff --git a/trick_test/requirements_testing/models/test/impexp/src/export_master.c b/trick_test/requirements_testing/models/test/impexp/src/export_master.c deleted file mode 100644 index c2f04c7b..00000000 --- a/trick_test/requirements_testing/models/test/impexp/src/export_master.c +++ /dev/null @@ -1,48 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((export_master.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: export_master.c,v $ - * Revision 7.1 2006-06-22 14:14:15-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:53-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:20 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:25 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include "../include/test.h" - - /* ENTRY POINT */ -void export_master( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - - T->a.i++ ; - T->a.d += 0.1 ; - - T->b.i-- ; - T->b.d -= 0.1 ; -} diff --git a/trick_test/requirements_testing/models/test/impexp/src/export_slave.c b/trick_test/requirements_testing/models/test/impexp/src/export_slave.c deleted file mode 100644 index 05e5741e..00000000 --- a/trick_test/requirements_testing/models/test/impexp/src/export_slave.c +++ /dev/null @@ -1,47 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((export_slave.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: export_slave.c,v $ - * Revision 7.1 2006-06-22 14:14:16-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:54-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:20 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:25 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include -#include "../include/test.h" - - /* ENTRY POINT */ -void export_slave( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - - /* Do nothing */ - T->a.i = T->a.i ; - -} diff --git a/trick_test/requirements_testing/models/test/impexp/src/import_master.c b/trick_test/requirements_testing/models/test/impexp/src/import_master.c deleted file mode 100644 index bc78c7bb..00000000 --- a/trick_test/requirements_testing/models/test/impexp/src/import_master.c +++ /dev/null @@ -1,44 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((import_master.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: import_master.c,v $ - * Revision 7.1 2006-06-22 14:14:16-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:54-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:20 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:26 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include "../include/test.h" - - /* ENTRY POINT */ -void import_master( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - /* Do nothing */ - T->a.i = T->a.i ; -} diff --git a/trick_test/requirements_testing/models/test/impexp/src/import_slave.c b/trick_test/requirements_testing/models/test/impexp/src/import_slave.c deleted file mode 100644 index 79d1b05a..00000000 --- a/trick_test/requirements_testing/models/test/impexp/src/import_slave.c +++ /dev/null @@ -1,53 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((import_slave.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: import_slave.c,v $ - * Revision 7.1 2006-06-22 14:14:17-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:54-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:21 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:26 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include -#include "../include/test.h" - - /* ENTRY POINT */ -void import_slave( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - - /* Make a saw tooth */ - if ( T->a.i > 20 ) { - T->a.i = 0 ; - T->a.d = 0 ; - - T->b.i = 0 ; - T->b.d = 0 ; - } - -} diff --git a/trick_test/requirements_testing/models/test/ip/.checksums b/trick_test/requirements_testing/models/test/ip/.checksums deleted file mode 100644 index 5fbfabac..00000000 --- a/trick_test/requirements_testing/models/test/ip/.checksums +++ /dev/null @@ -1,4 +0,0 @@ -20793 12 ./src/ip_test.c -8488 10 ./include/ip_c_types.h -18178 28 ./include/ip_test.d -57882 9 ./include/ip_test.h diff --git a/trick_test/requirements_testing/models/test/ip/include/ip_c_types.h b/trick_test/requirements_testing/models/test/ip/include/ip_c_types.h deleted file mode 100644 index c1ea202c..00000000 --- a/trick_test/requirements_testing/models/test/ip/include/ip_c_types.h +++ /dev/null @@ -1,118 +0,0 @@ -/* TRICK HEADER -PURPOSE: - (Test all possible C data types recognized by the Interface Code - Generator and the executive input processor.) - -REFERENCE: - (((Bailey, Robert W.) - (User's Guide and Operational Procedures Volume ... - of the Trick Simulation Environment) (MDSS-HD TM-6.24.26-04) - (McDonnell Douglas Space Systems - Houston Division) (March 1993) (--))) - -ASSUMPTIONS AND LIMITATIONS: - ((Unlimited software array dimensions and sizing) - (Unlimited software dynamically allocated array dimensions and sizing) - (Excessively large structures may overrun hardware memory) - (ICG ignores all compilier directives except '#define') - (ICG ignores all typedef declarations other than 'typedef struct' - and 'typedef enum')) - -PROGRAMMERS: - (((Robert W. Bailey) (LinCom) (10/1/90) (Trick-CR-00000) (Initial Release))) -*/ - -/* - * $Log: ip_c_types.h,v $ - * Revision 7.1 2006-06-22 14:14:14-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:55-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:19 lin - * Bump version number for 04 - * - * Revision 1.3 2003/05/29 18:57:16 vetter - * Add Bitfield Test To IP Test - * - * Revision 1.2 2002/10/07 15:16:26 lin - * Add rcs version info to all trick_models files - * - */ - -#ifndef _IP_C_TYPES -#define _IP_C_TYPES - -#define TWO 2 /* THE Value 2 */ - -typedef struct { - unsigned int bits_a : 5 ; /* -- Test bits 5 */ - unsigned int : 2 ; /* -- Test bits 7 */ - unsigned int bits_b : 9 ; /* -- Test bits 16 */ - unsigned int bits_c : 16 ; /* -- Test bits 32 */ - double doub_x ; /* -- Miscellaneous double */ - unsigned int bits_d : 7 ; /* -- Test bits */ -} BITS ; - -typedef struct { /* FUNDAMENTAL 'C' DATA TYPES ----------------------------*/ - -char c ; /* -- Single character */ -unsigned char uc ; /* -- Single unsigned character */ -char * cp ; /* -- Single string */ -short s ; /* -- Single short integer */ -unsigned short us ; /* -- Single unsigned short integer */ -int i ; /* -- Integer */ -unsigned int ui ; /* -- Single unsigned integer */ -long l ; /* -- Single long integer */ -unsigned long ul ; /* -- Single unsigned long integer */ -float f ; /* -- Single precision floating point value*/ -double d ; /* -- Double precision floating point value */ - -} C_TYPES ; /*----------------------------------------------------------------*/ - -typedef struct { /* ARRAYS ------------------------------------------------*/ - -char ca[2][2][2] ; /* -- characters (strings) */ -unsigned char uca[2][2][2] ; /* -- unsigned character s*/ -short sa[2][2][2] ; /* -- short integers */ -unsigned short usa[2][2][2] ; /* -- unsigned short integers */ -int ia[2][2][2] ; /* -- integers */ -unsigned int uia[2][2][2] ; /* -- unsigned integers */ -long la[2][2][2] ; /* -- long integers */ -unsigned long ula[2][2][2] ; /* -- unsigned long integers */ -float fa[2][2][2] ; /* -- single precision floating point */ -double da[2][2][2] ; /* -- double precision floating point */ - -} C_ARR_TYPES ; /*------------------------------------------------------------*/ - -typedef struct { /* POINTERS -- UNCONSTRAINED ARRAYS ----------------------*/ - - char **** cpp ; /* -- strings */ - unsigned char *** ucpp ; /* -- unsigned characters */ - short *** spp ; /* -- short integers */ - unsigned short *** uspp ; /* -- unsigned short integers */ - int *** ipp ; /* -- integers */ - unsigned int *** uipp ; /* -- unsigned integers */ - long *** lpp ; /* -- long integers */ - unsigned long *** ulpp ; /* -- unsigned long integers */ - float *** fpp ; /* -- single precision floating point */ - double *** dpp ; /* -- double precision floating point */ - -} C_PTR_TYPES ; /*------------------------------------------------------------*/ - -typedef struct { /* MIXED POINTERS AND ARRAYS -----------------------------*/ - - char *** cpa[TWO] ; /* -- characters (strings) */ - unsigned char ** ucpa[TWO] ; /* -- unsigned characters */ - short ** spa[TWO] ; /* -- short integers */ - unsigned short ** uspa[TWO] ; /* -- unsigned short integers */ - int ** ipa[TWO] ; /* -- integers */ - unsigned int ** uipa[TWO] ; /* -- unsigned integers */ - long ** lpa[TWO] ; /* -- long integers */ - unsigned long ** ulpa[TWO] ; /* -- unsigned long integers */ - float ** fpa[TWO] ; /* -- single precision floating points */ - double ** dpa[TWO] ; /* -- double precision floating points */ - -} C_MIX_TYPES ; /*------------------------------------------------------------*/ - -#endif diff --git a/trick_test/requirements_testing/models/test/ip/include/ip_test.d b/trick_test/requirements_testing/models/test/ip/include/ip_test.d deleted file mode 100644 index 597cb262..00000000 --- a/trick_test/requirements_testing/models/test/ip/include/ip_test.d +++ /dev/null @@ -1,514 +0,0 @@ -/* -PURPOSE: - (Test Trick input processor memory allocation and input field syntax and - capabilities.) - -REFERENCE: - (((Bailey, R.W) - (User's Guide and Operational Procedures Volume ... - of the Trick Simulation Environment) (MDSS-HD TM-6.24.26-04) - (McDonnell Dougla Space Systems - Houston Division) (March 1993) ())) - -ASSUMPTIONS AND LIMITATIONS: - ((What you see is what you get.)) - -PROGRAMMERS: - (((Robert W. Bailey) (LinCom) (9/1/90 (Trick-CR-00000) (Initial Release))) -*/ - -/* - * $Log: ip_test.d,v $ - * Revision 7.3 2007-01-08 11:22:17-06 dstrauss - * Bugs in parsing new units specs - * - * Revision 7.2 2006-08-31 13:59:12-05 hchen - * SIM_test_ip error - convert the old style of allocation statements to the new style and update the file due to the variable units changed to units_test - * - * Revision 7.1 2006-06-22 14:14:14-05 lin - * Bump version number for 07 - * - * Revision 5.2 2004-09-07 11:48:42-05 lin - * New #define handling does not pass SIM_test_ip - * - * Revision 5.1 2004-08-05 13:06:55-05 lin - * Bump - * - * Revision 4.3 2004/02/18 21:54:41 lin - * remove "STRING" as the special case for "char *" - * - * Revision 4.2 2004/01/15 22:36:42 lin - * test sims do not work - * - * Revision 4.1 2003/10/21 21:49:19 lin - * Bump version number for 04 - * - * Revision 1.5 2003/06/09 21:03:13 vetter - * Forget Fortran For 4 - * - * Revision 1.4 2003/05/29 18:57:21 vetter - * Add Bitfield Test To IP Test - * - * Revision 1.3 2003/03/14 20:16:51 lin - * Try and rewrite ip_alloc scheme to remove extra 8 byte requirement - * - * Revision 1.2 2002/10/07 15:16:27 lin - * Add rcs version info to all trick_models files - * - */ - -#define TWO (2.00000000) -#define TWO2 ((4*2.0)-6.00000000) -#define THREE 3.00000000 -#define DTR 0.0174532925199432957 - -IP_TEST.strings_good = 1 ; - -IP_TEST.bits[0].bits_a = 1 ; -IP_TEST.bits[0].bits_b = 2 ; -IP_TEST.bits[0].bits_c = 3 ; -IP_TEST.bits[0].bits_d = 4 ; -IP_TEST.bits[0].doub_x = 777.0 ; - -IP_TEST.bits[1].bits_a = 5 ; -IP_TEST.bits[1].bits_b = 6 ; -IP_TEST.bits[1].bits_c = 7 ; -IP_TEST.bits[1].bits_d = 8 ; -IP_TEST.bits[1].doub_x = 999.0 ; - -/* The following are the old style of allocation statements. -IP_TEST.c_pointer_types.cpp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.ucpp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.spp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.uspp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.ipp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.uipp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.lpp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.ulpp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.fpp[ 2 ][ 2 ][ 2 ] ; -IP_TEST.c_pointer_types.dpp[ 2 ][ 2 ][ 2 ] ; - -IP_TEST.c_mixed_types.cpa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.cpa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.ucpa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.ucpa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.spa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.spa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.uspa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.uspa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.ipa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.ipa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.uipa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.uipa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.lpa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.lpa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.ulpa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.ulpa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.fpa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.fpa[ 1 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.dpa[ 0 ][ 2 ][ 2 ] ; -IP_TEST.c_mixed_types.dpa[ 1 ][ 2 ][ 2 ] ; - -IP_TEST.units_test[ 0 ][ 2 ][ 2 ] ; -IP_TEST.units_test[ 1 ][ 2 ][ 2 ] ;*/ - - /* NEW ALLOCATION STATEMENTS */ -int i,j; - -IP_TEST.c_pointer_types.cpp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.cpp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.cpp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.ucpp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.ucpp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.ucpp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.spp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.spp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.spp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.uspp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.uspp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.uspp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.ipp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.ipp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.ipp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.uipp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.uipp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.uipp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.lpp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.lpp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.lpp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.ulpp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.ulpp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.ulpp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.fpp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.fpp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.fpp[i][j] = alloc(2); - } -} - -IP_TEST.c_pointer_types.dpp = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_pointer_types.dpp[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_pointer_types.dpp[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.cpa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.cpa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.cpa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.ucpa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.ucpa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.ucpa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.spa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.spa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.spa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.uspa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.uspa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.uspa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.ipa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.ipa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.ipa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.uipa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.uipa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.uipa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.lpa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.lpa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.lpa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.ulpa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.ulpa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.ulpa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.fpa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.fpa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.fpa[i][j] = alloc(2); - } -} - -IP_TEST.c_mixed_types.dpa = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.c_mixed_types.dpa[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.c_mixed_types.dpa[i][j] = alloc(2); - } -} - - -IP_TEST.units_test = alloc(2); -for (i = 0; i < 2; i++) { - IP_TEST.units_test[i] = alloc(2); - for (j=0; j < 2; j++) { - IP_TEST.units_test[i][j] = alloc(2); - } -} - - - /* UNITS CONVERSION */ -IP_TEST.units_test[0][0][0].second[0] = 1.0 ; -IP_TEST.units_test[0][0][0].second[1] {s} = 1.0 ; -IP_TEST.units_test[0][0][0].second[2] {min} = 1.0 ; -IP_TEST.units_test[0][0][0].second[3] {hr} = 1.0 ; -IP_TEST.units_test[0][0][0].second[4] {day} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[0] = 1.0 ; -IP_TEST.units_test[0][0][0].meter[1] {mm} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[2] {cm} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[3] {M} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[4] {km} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[5] {in} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[6] {ft} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[7] {yd} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[8] {mi} = 1.0 ; -IP_TEST.units_test[0][0][0].meter[9] {n.m.} = 1.0 ; -IP_TEST.units_test[0][0][0].radian[0] = 1.0 ; -IP_TEST.units_test[0][0][0].radian[1] {r} = 1.0 ; -IP_TEST.units_test[0][0][0].radian[2] {as} = 1.0 ; -IP_TEST.units_test[0][0][0].radian[3] {am} = 1.0 ; -IP_TEST.units_test[0][0][0].radian[4] {d} = 1.0 ; -IP_TEST.units_test[0][0][0].kilogram[0] = 1.0 ; -IP_TEST.units_test[0][0][0].kilogram[1] {g} = 1.0 ; -IP_TEST.units_test[0][0][0].kilogram[2] {kg} = 1.0 ; -IP_TEST.units_test[0][0][0].kilogram[3] {mt} = 1.0 ; -IP_TEST.units_test[0][0][0].kilogram[4] {sl} = 1.0 ; -IP_TEST.units_test[0][0][0].kilogram[5] {lbm} = 1.0 ; -IP_TEST.units_test[0][0][0].newton[0] = 1.0 ; -IP_TEST.units_test[0][0][0].newton[1] {N} = 1.0 ; -IP_TEST.units_test[0][0][0].newton[2] {kN} = 1.0 ; -IP_TEST.units_test[0][0][0].newton[3] {oz} = 1.0 ; -IP_TEST.units_test[0][0][0].newton[4] {lbf} = 1.0 ; -IP_TEST.units_test[0][0][0].volt[0] = 1.0 ; -IP_TEST.units_test[0][0][0].volt[1] {v} = 1.0 ; -IP_TEST.units_test[0][0][0].volt[2] {kv} = 1.0 ; -IP_TEST.units_test[0][0][0].amp[0] = 1.0 ; -IP_TEST.units_test[0][0][0].amp[1] {amp} = 1.0 ; -IP_TEST.units_test[0][0][0].amp[2] {mamp} = 1.0 ; -IP_TEST.units_test[0][0][0].ohm[0] = 1.0 ; -IP_TEST.units_test[0][0][0].ohm[1] {ohm} = 1.0 ; -IP_TEST.units_test[0][0][0].celsius[0] = 1.0 ; -IP_TEST.units_test[0][0][0].celsius[1] {K} = 1.0 ; -IP_TEST.units_test[0][0][0].celsius[2] {R} = 1.0 ; -IP_TEST.units_test[0][0][0].celsius[3] {F} = 1.0 ; -IP_TEST.units_test[0][0][0].fahrenheit[0] = 1.0 ; -IP_TEST.units_test[0][0][0].fahrenheit[1] {C} = 1.0 ; -IP_TEST.units_test[0][0][0].fahrenheit[2] {K} = 1.0 ; -IP_TEST.units_test[0][0][0].fahrenheit[3] {R} = 1.0 ; -IP_TEST.units_test[0][0][0].temp_rate[0] = 1.0 ; -IP_TEST.units_test[0][0][0].temp_rate[1] {C/s} = 1.0 ; -IP_TEST.units_test[0][0][0].temp_rate[2] {R/min} = 1.0 ; -IP_TEST.units_test[0][0][0].temp_rate[3] {F/s} = 1.0 ; -IP_TEST.units_test[0][0][0].area[0] = 1.0 ; -IP_TEST.units_test[0][0][0].area[1] {ft2} = 1.0 ; -IP_TEST.units_test[0][0][0].area[2] {cm2} = 1.0 ; -IP_TEST.units_test[0][0][0].volume[0] = 1.0 ; -IP_TEST.units_test[0][0][0].volume[1] {cm3} = 1.0 ; -IP_TEST.units_test[0][0][0].volume[2] {ft3} = 1.0 ; -IP_TEST.units_test[0][0][0].velocity[0] = 1.0 ; -IP_TEST.units_test[0][0][0].velocity[1] {mi/hr} = 1.0 ; -IP_TEST.units_test[0][0][0].velocity[2] {yd/min} = 1.0 ; -IP_TEST.units_test[0][0][0].velocity_eng[0] {mi/hr} = 1.0 ; -IP_TEST.units_test[0][0][0].velocity_eng[1] {M/s} = 1.0 ; -IP_TEST.units_test[0][0][0].accel[0] = 1.0 ; -IP_TEST.units_test[0][0][0].accel[1] {ft/s2} = 1.0 ; -IP_TEST.units_test[0][0][0].accel[2] {n.m./day2} = 1.0 ; -IP_TEST.units_test[0][0][0].inertia[0] = 1.0 ; -IP_TEST.units_test[0][0][0].inertia[1] {lbm*ft2} = 1.0 ; -IP_TEST.units_test[0][0][0].inertia[2] {sl*in2} = 1.0 ; -IP_TEST.units_test[0][0][0].torque[0] = 1.0 ; -IP_TEST.units_test[0][0][0].torque[1] {lbf*ft} = 1.0 ; -IP_TEST.units_test[0][0][0].torque[2] {oz*in} = 1.0 ; -IP_TEST.units_test[0][0][0].pressure[0] = 1.0 ; -IP_TEST.units_test[0][0][0].pressure[1] {oz/in2} = 1.0 ; -IP_TEST.units_test[0][0][0].pressure[2] {lbf/ft2} = 1.0 ; -IP_TEST.units_test[0][0][0].density[0] = 1.0 ; -IP_TEST.units_test[0][0][0].density[1] {g/cm3} = 1.0 ; -IP_TEST.units_test[0][0][0].density[2] {sl/ft3} = 1.0 ; - - -IP_TEST.units_test[0][0][0].measure = meter ; -IP_TEST.units_test[0][0][1].measure = centimeter ; -IP_TEST.units_test[0][1][0].measure = millimeter ; -IP_TEST.units_test[0][1][1].measure = kilometer ; -IP_TEST.units_test[1][0][0].measure = inches ; -IP_TEST.units_test[1][0][1].measure = feet ; -IP_TEST.units_test[1][1][0].measure = yard ; -IP_TEST.units_test[1][1][1].measure = mile ; - -IP_TEST.c_types.c = 'c' ; -IP_TEST.c_types.uc = 'u' ; -IP_TEST.c_types.cp = "Testing Char Pointers." ; -IP_TEST.c_types.s = abs( -1 ) ; -IP_TEST.c_types.us = 2 % THREE ; -IP_TEST.c_types.i = -3 % TWO ; -IP_TEST.c_types.ui = pow ( 4 , TWO ) ; -IP_TEST.c_types.l = pow ( -5 , THREE ) ; -IP_TEST.c_types.ul = 6 * TWO2 ; -IP_TEST.c_types.f = THREE/7.7777777 ; -IP_TEST.c_types.d = 8.88888888888888888888888 + TWO ; - -IP_TEST.c_array_types.ca[0][0][0] = 'a' , 'b' ; -IP_TEST.c_array_types.ca[0][1][0] = 'c' , 'd' ; -IP_TEST.c_array_types.ca[1][0][0] = 'e' , 'f' ; -IP_TEST.c_array_types.ca[1][1][0] = 'g' , 'h' ; -IP_TEST.c_array_types.uca[0][0][0] = 'i' , 'j' ; -IP_TEST.c_array_types.uca[0][1][0] = 'k' , 'l' ; -IP_TEST.c_array_types.uca[1][0][0] = 'm' , 'n' ; -IP_TEST.c_array_types.uca[1][1][0] = 'o' , 'p' ; -IP_TEST.c_array_types.sa[0][0][0] = -1 - THREE , - THREE ; -IP_TEST.c_array_types.sa[0][1][0] = TWO2 * { -3 , -4 } ; -IP_TEST.c_array_types.sa[1][0][0] = { -5 , -6 } * ( 1.0 / TWO ) ; -IP_TEST.c_array_types.sa[1][1][0] = -7 , -8 ; -IP_TEST.c_array_types.usa[0][0][0] = 0x0009 , 0x000A ; -IP_TEST.c_array_types.usa[0][1][0] = 0x000b , 0x000C ; -IP_TEST.c_array_types.usa[1][0][0] = 0x000d , 14 ; -IP_TEST.c_array_types.usa[1][1][0] = 15 , 16 ; -IP_TEST.c_array_types.ia[0][0][0] = -20 , -21 ; -IP_TEST.c_array_types.ia[0][1][0] = -22 , -23 ; -IP_TEST.c_array_types.ia[1][0][0] = -24 , -25 ; -IP_TEST.c_array_types.ia[1][1][0] = -26 , -27 ; -IP_TEST.c_array_types.uia[0][0][0] = 28 , 29 ; -IP_TEST.c_array_types.uia[0][1][0] = 30 , 31 ; -IP_TEST.c_array_types.uia[1][0][0] = 32 , 33 ; -IP_TEST.c_array_types.uia[1][1][0] = 34 , 35 ; -IP_TEST.c_array_types.la[0][0][0] = -200001 ,-200002 ; -IP_TEST.c_array_types.la[0][1][0] = -200003 ,-200004 ; -IP_TEST.c_array_types.la[1][0][0] = -200005 ,-200006 ; -IP_TEST.c_array_types.la[1][1][0] = -200007 ,-200008 ; -IP_TEST.c_array_types.ula[0][0][0] = 200009 , 200010 ; -IP_TEST.c_array_types.ula[0][1][0] = 200011 , 200012 ; -IP_TEST.c_array_types.ula[1][0][0] = 200013 , 200014 ; -IP_TEST.c_array_types.ula[1][1][0] = 200015 , 200016 ; -IP_TEST.c_array_types.fa[0][0][0] = abs( cos( 30.0 * DTR ) ) ; -IP_TEST.c_array_types.fa[0][1][0] = pow( 3.33333333 , 4.44444444 ) ; -IP_TEST.c_array_types.fa[1][0][0] = exp( 5.55555555 ) ; -IP_TEST.c_array_types.fa[1][1][0] = log( 7.77777777 ) ; -IP_TEST.c_array_types.da[0][0][0] = cos( 30.0 * DTR ) ; -IP_TEST.c_array_types.da[0][1][0] = sin( 30.0 * DTR ) ; -IP_TEST.c_array_types.da[1][0][0] = tan( 30.0 * DTR ) ; -IP_TEST.c_array_types.da[1][1][0] = acos( 0.5 ) ; - -IP_TEST.c_pointer_types.cpp[0][0][0] = "I'd" , "rather" ; -IP_TEST.c_pointer_types.cpp[0][1][0] = "be" , "developing" ; -IP_TEST.c_pointer_types.cpp[1][0][0] = "than" , "testing" ; -IP_TEST.c_pointer_types.cpp[1][1][0] = "or" , "debugging." ; -IP_TEST.c_pointer_types.ucpp[0][0][0] = 'A' , 'B' ; -IP_TEST.c_pointer_types.ucpp[0][1][0] = 'C' , 'D' ; -IP_TEST.c_pointer_types.ucpp[1][0][0] = 'E' , 'F' ; -IP_TEST.c_pointer_types.ucpp[1][1][0] = 'G' , 'H' ; -IP_TEST.c_pointer_types.spp[0][0][0] = -1 , -2 ; -IP_TEST.c_pointer_types.spp[0][1][0] = -3 , -4 ; -IP_TEST.c_pointer_types.spp[1][0][0] = -5 , -6 ; -IP_TEST.c_pointer_types.spp[1][1][0] = -7 , -8 ; -IP_TEST.c_pointer_types.uspp[0][0][0] = 9 , 10 ; -IP_TEST.c_pointer_types.uspp[0][1][0] = 11 , 12 ; -IP_TEST.c_pointer_types.uspp[1][0][0] = 13 , 14 ; -IP_TEST.c_pointer_types.uspp[1][1][0] = 15 , 16 ; -IP_TEST.c_pointer_types.ipp[0][0][0] = -20 , -21 ; -IP_TEST.c_pointer_types.ipp[0][1][0] = -22 , -23 ; -IP_TEST.c_pointer_types.ipp[1][0][0] = -24 , -25 ; -IP_TEST.c_pointer_types.ipp[1][1][0] = -26 , -27 ; -IP_TEST.c_pointer_types.uipp[0][0][0] = 28 , 29 ; -IP_TEST.c_pointer_types.uipp[0][1][0] = 30 , 31 ; -IP_TEST.c_pointer_types.uipp[1][0][0] = 32 , 33 ; -IP_TEST.c_pointer_types.uipp[1][1][0] = 34 , 35 ; -IP_TEST.c_pointer_types.lpp[0][0][0] = -200001 ,-200002 ; -IP_TEST.c_pointer_types.lpp[0][1][0] = -200003 ,-200004 ; -IP_TEST.c_pointer_types.lpp[1][0][0] = -200005 ,-200006 ; -IP_TEST.c_pointer_types.lpp[1][1][0] = -200007 ,-200008 ; -IP_TEST.c_pointer_types.ulpp[0][0][0] = 200009 , 200010 ; -IP_TEST.c_pointer_types.ulpp[0][1][0] = 200011 , 200012 ; -IP_TEST.c_pointer_types.ulpp[1][0][0] = 200013 , 200014 ; -IP_TEST.c_pointer_types.ulpp[1][1][0] = 200015 , 200016 ; -IP_TEST.c_pointer_types.fpp[0][0][0] = asin( 0.5 ) ; -IP_TEST.c_pointer_types.fpp[0][1][0] = atan( 0.5 ) , atan2( -1.0 , 2.0 ) ; -IP_TEST.c_pointer_types.fpp[1][0][0] = sqrt( THREE ) ; -IP_TEST.c_pointer_types.fpp[1][1][0] = 7.77777777 , 8.88888888 ; -IP_TEST.c_pointer_types.dpp[0][0][0] = -1.1111111111111111, -2.2222222222222222; -IP_TEST.c_pointer_types.dpp[0][1][0] = -3.3333333333333333, -4.4444444444444444; -IP_TEST.c_pointer_types.dpp[1][0][0] = -5.5555555555555555, -6.6666666666666666; -IP_TEST.c_pointer_types.dpp[1][1][0] = -7.777E-03 , -8.888e+003 ; - -#define SURF surfing -#define COLOR blue -#define BEACH Wakiki - - -IP_TEST.c_mixed_types.cpa[0][0][0] = "I" , "would" ; -IP_TEST.c_mixed_types.cpa[0][1][0] = "rather" , "be" ; -IP_TEST.c_mixed_types.cpa[1][0][0] = "#(SURF)" , "today" ; -IP_TEST.c_mixed_types.cpa[1][1][0] = "in" , "the #{COLOR} oceans of #(BEACH)." ; -IP_TEST.c_mixed_types.ucpa[0][0][0] = 'A' , 'B' ; -IP_TEST.c_mixed_types.ucpa[0][1][0] = 'C' , 'D' ; -IP_TEST.c_mixed_types.ucpa[1][0][0] = 'E' , 'F' ; -IP_TEST.c_mixed_types.ucpa[1][1][0] = 'G' , 'H' ; -IP_TEST.c_mixed_types.spa[0][0][0] = -1 , -2 ; -IP_TEST.c_mixed_types.spa[0][1][0] = -3 , -4 ; -IP_TEST.c_mixed_types.spa[1][0][0] = -5 , -6 ; -IP_TEST.c_mixed_types.spa[1][1][0] = -7 , -8 ; -IP_TEST.c_mixed_types.uspa[0][0][0] = 9 , 10 ; -IP_TEST.c_mixed_types.uspa[0][1][0] = 11 , 12 ; -IP_TEST.c_mixed_types.uspa[1][0][0] = 13 , 14 ; -IP_TEST.c_mixed_types.uspa[1][1][0] = 15 , 16 ; -IP_TEST.c_mixed_types.ipa[0][0][0] = -20 , -21 ; -IP_TEST.c_mixed_types.ipa[0][1][0] = -22 , -23 ; -IP_TEST.c_mixed_types.ipa[1][0][0] = -24 , -25 ; -IP_TEST.c_mixed_types.ipa[1][1][0] = -26 , -27 ; -IP_TEST.c_mixed_types.uipa[0][0][0] = 28 , 29 ; -IP_TEST.c_mixed_types.uipa[0][1][0] = 30 , 31 ; -IP_TEST.c_mixed_types.uipa[1][0][0] = 32 , 33 ; -IP_TEST.c_mixed_types.uipa[1][1][0] = 34 , 35 ; -IP_TEST.c_mixed_types.lpa[0][0][0] = -200001 ,-200002 ; -IP_TEST.c_mixed_types.lpa[0][1][0] = -200003 ,-200004 ; -IP_TEST.c_mixed_types.lpa[1][0][0] = -200005 ,-200006 ; -IP_TEST.c_mixed_types.lpa[1][1][0] = -200007 ,-200008 ; -IP_TEST.c_mixed_types.ulpa[0][0][0] = 200009 , 200010 ; -IP_TEST.c_mixed_types.ulpa[0][1][0] = 200011 , 200012 ; -IP_TEST.c_mixed_types.ulpa[1][0][0] = 200013 , 200014 ; -IP_TEST.c_mixed_types.ulpa[1][1][0] = 200015 , 200016 ; -IP_TEST.c_mixed_types.fpa[0][0][0] = 1.11111111 , 2.22222222 ; -IP_TEST.c_mixed_types.fpa[0][1][0] = 3.33333333 , 4.44444444 ; -IP_TEST.c_mixed_types.fpa[1][0][0] = 5.55555555 , 6.66666666 ; -IP_TEST.c_mixed_types.fpa[1][1][0] = -7.777E-03 , -8.888e+03 ; -IP_TEST.c_mixed_types.dpa[0][0][0] = -1.1111111111111111 , -2.2222222222222222 ; -IP_TEST.c_mixed_types.dpa[0][1][0] = -3.3333333333333333 , -4.4444444444444444 ; -IP_TEST.c_mixed_types.dpa[1][0][0] = -5.5555555555555555 , -6.6666666666666666 ; -IP_TEST.c_mixed_types.dpa[1][1][0] = -7.7777777777777777 , -8.8888888888888888 ; diff --git a/trick_test/requirements_testing/models/test/ip/include/ip_test.h b/trick_test/requirements_testing/models/test/ip/include/ip_test.h deleted file mode 100644 index 2fcec561..00000000 --- a/trick_test/requirements_testing/models/test/ip/include/ip_test.h +++ /dev/null @@ -1,131 +0,0 @@ -/* TRICK HEADER -PURPOSE: - (Test all possible data types recognized by the Interface Code - Generator and the executive input processor.) - -REFERENCE: - (((Bailey, Robert W.) - (User's Guide and Operational Procedures Volume ... - of the Trick Simulation Environment) (MDSS-HD TM-6.24.26-04) - (McDonnell Douglas Space Systems - Houston Division) (March 1993) (--))) - -ASSUMPTIONS AND LIMITATIONS: - ((Unlimited software array dimensions and sizing) - (Unlimited software dynamically allocated array dimensions and sizing) - (Excessively large structures may overrun hardware memory) - (All parameter declarations MUST start in the first column)) - -PROGRAMMERS: - (((Robert W. Bailey) (LinCom) (10/1/90) (Trick-CR-00000) (Initial Release))) -*/ - -/* - * $Log: ip_test.h,v $ - * Revision 7.3 2007-01-08 11:22:22-06 dstrauss - * Bugs in parsing new units specs - * - * Revision 7.2 2006-08-31 13:56:38-05 hchen - * SIM_test_ip error - change the variable name units to units_test due to sys conflict - * - * Revision 7.1 2006-06-22 14:14:15-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:55-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:20 lin - * Bump version number for 04 - * - * Revision 1.3 2003/05/29 18:57:23 vetter - * Add Bitfield Test To IP Test - * - * Revision 1.2 2002/10/07 15:16:27 lin - * Add rcs version info to all trick_models files - * - */ - -#ifndef _IP_TEST_H_ -#define _IP_TEST_H_ - -/*=== THESE DEFINES ARE PARSED AND USABLE IN ARRAY DIMENSIONS ===*/ -#define TWO 2 /* THE Value 2 */ -#define TWO2 (1+1) /* THE Value 2 */ -#define TWO3 2*1 - -/*=== THESE DEFINES ARE IGNORED ===*/ -#define DUMMY_MACRO1(A,B) A = B + 1 -#define DUMMY_MACRO2(A,B) { \ -A = B + 1 ; \ -B++ ; \ -} - -/*==== SYSTEM INCLUDES ARE IGNORED ===*/ -#include /* ignored */ -#include /* ignored */ - -/*==== USER INCLUDES ARE PARSED AND STORED FOR FUTURE REFERENCE ====*/ -#include "ip_c_types.h" - -/*==== ALL GLOBAL DECLARATIONS ARE IGNORED ====*/ -int * int_function() ; /* ignored */ -float real_function( int bogus1 , double *bogus2[] ) ; /* ignored */ - -/*==== THESE TYPEDEFS ARE IGNORED ===*/ -typedef unsigned int Int_Type ; /* ignored */ -typedef double* Double_Ptr ; -typedef void (*Void_Func)() ; /* ignored */ - -typedef enum { /* ENUMERATED TYPES --------------------------------------*/ - - meter = -2 , /* Meters */ - centimeter , /* CentiMeters */ - millimeter , /* MilliMeters */ - kilometer , /* KiloMeters */ - inches = 10 , /* Inches */ - feet , /* Feet */ - yard , /* Yards */ - mile = 5 , /* Miles */ - nautical_mile /* Nautical Miles */ - -} Distance ; /*---------------------------------------------------------------*/ - -typedef struct { /* MEASUREMENT UNITS_TEST SPECIFICATION -----------------*/ - - double second[5] ; /* s Measurement units */ - double meter[10] ; /* M Measurement units */ - double radian[5] ; /* r Measurement units */ - double kilogram[6] ; /* kg Measurement units */ - double newton[5] ; /* N Measurement units */ - double volt[3] ; /* v Measurement units */ - double amp[3] ; /* amp Measurement units */ - double ohm[2] ; /* ohm Measurement units */ - double celsius[4] ; /* C Measurement units */ - double fahrenheit[4] ; /* F Measurement units */ - double temp_rate[4] ; /* K/s Measurement units */ - double area[3] ; /* M2 Measurement units */ - double volume[1+1+1] ; /* M3 Measurement units */ - double velocity[4-1] ; /* M/s Measurement units */ - double velocity_eng[2] ; /* mi/hr Measurement units using non-std units */ - double accel[TWO+1] ; /* M/s2 Measurement units */ - double inertia[3*1] ; /* kg*M2 Measurement units */ - double torque[TWO*2-1] ; /* N*M Measurement units */ - double pressure[3] ; /* N/M2 Measurement units */ - double density[3] ; /* kg/M3 Measurement units */ - Distance measure ; /* -- Distance measurement units */ - -} UNITS_TEST ; /*-------------------------------------------------------------*/ - - -typedef struct { /* COMPOSITE DATA STRUCTURES ----------------------------*/ - -BITS bits[TWO] ; /* -- Two bits, four bits, six bits, a $ */ -C_TYPES c_types ; /* -- Standard C types */ -C_ARR_TYPES c_array_types ; /* -- Arrayed C types */ -C_PTR_TYPES c_pointer_types ; /* -- Pointered C types */ -C_MIX_TYPES c_mixed_types ; /* -- Mixed arrays and pointer types */ -UNITS_TEST **units_test[TWO] ; /* -- Measurement unit test params */ -int strings_good ; /* -- 1-good 0-bad */ - -} IP_TEST ; /*----------------------------------------------------------------*/ - -#endif diff --git a/trick_test/requirements_testing/models/test/ip/src/ip_test.c b/trick_test/requirements_testing/models/test/ip/src/ip_test.c deleted file mode 100644 index eda2e72c..00000000 --- a/trick_test/requirements_testing/models/test/ip/src/ip_test.c +++ /dev/null @@ -1,223 +0,0 @@ -/* -PURPOSE: - (Test the Trick simulation executive 'scheduled' module handling.) -REFERENCE: - (((Bailey, R.W, and Paddock, E.J.) - (Trick Simulation Environment) (NASA:JSC #37943) - (JSC / Engineering Directorate / Automation and Robotics Division) - (Mar 1996) (--))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - (ip_test.o) -PROGRAMMERS: - (((Robert W. Bailey) (LinCom Corp) (9/1/90) (Trick-CR-00000) - (Initial Release.))) -*/ - -/* - * $Log: ip_test.c,v $ - * Revision 7.1 2006-06-22 14:14:13-05 lin - * Bump version number for 07 - * - * Revision 5.2 2005-01-31 15:45:54-06 lin - * remove "register" keyword - * - * Revision 5.1 2004-08-05 13:06:55-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:19 lin - * Bump version number for 04 - * - * Revision 1.2 2002/10/07 15:16:28 lin - * Add rcs version info to all trick_models files - * - */ - -#include -#include -#include "../include/ip_test.h" - -int ip_test( - /* RETURN: -- 0 - Nominal */ -IP_TEST * it ) /* INOUT: -- Executive Input/Output test parameters */ - -{ - -char test_string[128] ; -char* trick_home ; - - /* POINTER SHORTHAND ACCESS */ -C_TYPES * C = &(it->c_types) ; -C_ARR_TYPES * CA = &(it->c_array_types) ; -C_PTR_TYPES * CP = &(it->c_pointer_types) ; -C_MIX_TYPES * CM = &(it->c_mixed_types) ; - -C->i += 1 ; -C->d += 1.0 ; - -CA->sa[0][0][1] += 1 ; -CA->fa[0][1][0] += 1.0 ; - -CP->ipp[0][1][0] += 1 ; -CP->dpp[1][0][1] += 1 ; - -CM->lpa[1][0][0] += 1 ; -CM->dpa[1][1][0] += 1 ; - - -trick_home = getenv("TRICK_HOME"); - -/* Characters */ -sprintf( test_string,"%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c%c", - CA->ca[0][0][0], - CA->ca[0][0][1], - CA->ca[0][1][0], - CA->ca[0][1][1], - CA->ca[1][0][0], - CA->ca[1][0][1], - CA->ca[1][1][0], - CA->ca[1][1][1], - - CA->uca[0][0][0], - CA->uca[0][0][1], - CA->uca[0][1][0], - CA->uca[0][1][1], - CA->uca[1][0][0], - CA->uca[1][0][1], - CA->uca[1][1][0], - CA->uca[1][1][1], - - CM->ucpa[0][0][0], - CM->ucpa[0][0][1], - CM->ucpa[0][1][0], - CM->ucpa[0][1][1], - CM->ucpa[1][0][0], - CM->ucpa[1][0][1], - CM->ucpa[1][1][0], - CM->ucpa[1][1][1] ) ; -if ( strcmp( test_string, "abcdefghijklmnopABCDEFGH" ) ) { - fprintf(stderr, "Error_characters: %s \n", test_string); - it->strings_good = 0 ; -} - -/* The regular string */ -if ( strcmp( C->cp, "Testing Char Pointers.") ) { - if ( strcmp( C->cp, trick_home ) ) { - fprintf(stderr, "Error_character_ptr: %s \n", C->cp); - it->strings_good = 0 ; - } -} - -/* - * The character pointers - */ -if ( strcmp( CP->cpp[0][0][0], "I'd" ) ) { - if ( strcmp( CP->cpp[0][0][0], trick_home ) ) { - if ( strcmp(CP->cpp[0][0][0], "Cat") ) { - fprintf(stderr, "Error_p1: %s \n", CP->cpp[0][0][0]); - it->strings_good = 0 ; - } - } -} -if ( strcmp( CP->cpp[0][0][1], "rather" ) ) { - if ( strcmp( CP->cpp[0][0][1], trick_home ) ) { - if ( strcmp(CP->cpp[0][0][1], "Horse") ) { - fprintf(stderr, "Error_p2: %s \n", CP->cpp[0][0][1]); - it->strings_good = 0 ; - } - } -} -if ( strcmp( CP->cpp[0][1][0], "be" ) ) { - if ( strcmp( CP->cpp[0][1][0], trick_home ) ) { - fprintf(stderr, "Error_p3: %s \n", CP->cpp[0][1][0]); - it->strings_good = 0 ; - } -} -if ( strcmp( CP->cpp[0][1][1], "developing" ) ) { - if ( strcmp( CP->cpp[0][1][1], trick_home ) ) { - fprintf(stderr, "Error_p4: %s \n", CP->cpp[0][1][1]); - it->strings_good = 0 ; - } -} -if ( strcmp( CP->cpp[1][0][0], "than" ) ) { - if ( strcmp( CP->cpp[1][0][0], trick_home ) ) { - fprintf(stderr, "Error_p5: %s \n", CP->cpp[1][0][0]); - it->strings_good = 0 ; - } -} -if ( strcmp( CP->cpp[1][0][1], "testing" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_p6: %s \n", CP->cpp[1][0][1]); - it->strings_good = 0 ; - } -} -if ( strcmp( CP->cpp[1][1][0], "or" ) ) { - if ( strcmp( CP->cpp[1][1][0], trick_home ) ) { - fprintf(stderr, "Error_p7: %s \n", CP->cpp[1][1][0]); - it->strings_good = 0 ; - } -} -if ( strcmp( CP->cpp[1][1][1], "debugging." ) ) { - if ( strcmp( CP->cpp[1][1][1], trick_home ) ) { - fprintf(stderr, "Error_p8: %s \n", CP->cpp[1][1][1]); - it->strings_good = 0 ; - } -} - -/* - * The character arrays - */ -if ( strcmp( CM->cpa[0][0][0], "I" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a1: %s \n", CM->cpa[0][0][0]); - it->strings_good = 0 ; - } -} -if ( strcmp( CM->cpa[0][0][1], "would" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a2: %s \n", CM->cpa[0][0][1]); - it->strings_good = 0 ; - } -} -if ( strcmp( CM->cpa[0][1][0], "rather" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a3: %s \n", CM->cpa[0][1][0]); - it->strings_good = 0 ; - } -} -if ( strcmp( CM->cpa[0][1][1], "be" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a4: %s \n", CM->cpa[0][1][1]); - it->strings_good = 0 ; - } -} -if ( strcmp( CM->cpa[1][0][0], "surfing" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a5: %s \n", CM->cpa[1][0][0]); - it->strings_good = 0 ; - } -} -if ( strcmp( CM->cpa[1][0][1], "today" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a6: %s \n", CM->cpa[1][0][1]); - it->strings_good = 0 ; - } -} -if ( strcmp( CM->cpa[1][1][0], "in" ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a7: %s \n", CM->cpa[1][1][0]); - it->strings_good = 0 ; - } -} -if ( strcmp( CM->cpa[1][1][1], "the blue oceans of Wakiki." ) ) { - if ( strcmp( CP->cpp[1][0][1], trick_home ) ) { - fprintf(stderr, "Error_a8: %s \n", CM->cpa[1][1][1]); - it->strings_good = 0 ; - } -} - -return( 0 ) ; -} diff --git a/trick_test/requirements_testing/models/test/ip2/.checksums b/trick_test/requirements_testing/models/test/ip2/.checksums deleted file mode 100644 index d95579a0..00000000 --- a/trick_test/requirements_testing/models/test/ip2/.checksums +++ /dev/null @@ -1,3 +0,0 @@ -42171 2 ./src/ip.c -2953 4 ./src/ip_test_init.c -8526 28 ./include/ip.h diff --git a/trick_test/requirements_testing/models/test/ip2/include/ip.h b/trick_test/requirements_testing/models/test/ip2/include/ip.h deleted file mode 100644 index a2f4da1c..00000000 --- a/trick_test/requirements_testing/models/test/ip2/include/ip.h +++ /dev/null @@ -1,531 +0,0 @@ - /*********************************** TRICK HEADER ************************** -PURPOSE: (Test ip) -REFERENCES: (None) -ASSUMPTIONS AND LIMITATIONS: (Autocreated by trick_ui) -PROGRAMMERS: ((lin) (Thu Feb 27 14:57:16 CST 2003)) -***************************************************************************/ - -/* - * $Log: ip.h,v $ - * Revision 7.1 2006-06-22 14:14:13-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:56-05 lin - * Bump - * - * Revision 4.2 2004/01/16 21:48:55 lin - * Add a log to all files - * - */ - -#ifndef _ip_h_ -#define _ip_h_ - -#include "sim_services/include/Flag.h" - -typedef struct { - - char c ; /* -- Test integer */ - char c2 ; /* -- Test integer */ - char c3 ; /* -- Test integer */ - - char ca[6] ; /* -- Test integer */ - char ca2[6] ; /* -- Test integer */ - char ca3[6] ; /* -- Test integer */ - - char caa[8][8] ; /* -- Test integer */ - char caa2[8][8] ; /* -- Test integer */ - char caa3[8][8] ; /* -- Test integer */ - - char *cp ; /* -- Test integer */ - char *cp2 ; /* -- Test integer */ - char *cp3 ; /* -- Test integer */ - - char **cpp ; /* -- Test integer */ - char **cpp2 ; /* -- Test integer */ - char **cpp3 ; /* -- Test integer */ - - char ***cppp ; /* -- Test integer */ - char ***cppp2 ; /* -- Test integer */ - char ***cppp3 ; /* -- Test integer */ - -} CHAR_STR ; - -typedef struct { - - unsigned char uc ; /* -- Test integer */ - unsigned char uc2 ; /* -- Test integer */ - unsigned char uc3 ; /* -- Test integer */ - - unsigned char uca[6] ; /* -- Test integer */ - unsigned char uca2[6] ; /* -- Test integer */ - unsigned char uca3[6] ; /* -- Test integer */ - - unsigned char ucaa[8][8] ; /* -- Test integer */ - unsigned char ucaa2[8][8] ; /* -- Test integer */ - unsigned char ucaa3[8][8] ; /* -- Test integer */ - - unsigned char *ucp ; /* -- Test integer */ - unsigned char *ucp2 ; /* -- Test integer */ - unsigned char *ucp3 ; /* -- Test integer */ - - unsigned char **ucpp ; /* -- Test integer */ - unsigned char **ucpp2 ; /* -- Test integer */ - unsigned char **ucpp3 ; /* -- Test integer */ - - unsigned char ***ucppp ; /* -- Test integer */ - unsigned char ***ucppp2 ; /* -- Test integer */ - unsigned char ***ucppp3 ; /* -- Test integer */ - -} UCHAR_STR ; - -typedef struct { - - short s ; /* -- Test integer */ - short s2 ; /* -- Test integer */ - short s3 ; /* -- Test integer */ - - short sa[6] ; /* -- Test integer */ - short sa2[6] ; /* -- Test integer */ - short sa3[6] ; /* -- Test integer */ - - short saa[8][8] ; /* -- Test integer */ - short saa2[8][8] ; /* -- Test integer */ - short saa3[8][8] ; /* -- Test integer */ - - short *sp ; /* -- Test integer */ - short *sp2 ; /* -- Test integer */ - short *sp3 ; /* -- Test integer */ - - short **spp ; /* -- Test integer */ - short **spp2 ; /* -- Test integer */ - short **spp3 ; /* -- Test integer */ - - short ***sppp ; /* -- Test integer */ - short ***sppp2 ; /* -- Test integer */ - short ***sppp3 ; /* -- Test integer */ - -} SHORT_STR ; - -typedef struct { - - unsigned short us ; /* -- Test integer */ - unsigned short us2 ; /* -- Test integer */ - unsigned short us3 ; /* -- Test integer */ - - unsigned short usa[6] ; /* -- Test integer */ - unsigned short usa2[6] ; /* -- Test integer */ - unsigned short usa3[6] ; /* -- Test integer */ - - unsigned short usaa[8][8] ; /* -- Test integer */ - unsigned short usaa2[8][8] ; /* -- Test integer */ - unsigned short usaa3[8][8] ; /* -- Test integer */ - - unsigned short *usp ; /* -- Test integer */ - unsigned short *usp2 ; /* -- Test integer */ - unsigned short *usp3 ; /* -- Test integer */ - - unsigned short **uspp ; /* -- Test integer */ - unsigned short **uspp2 ; /* -- Test integer */ - unsigned short **uspp3 ; /* -- Test integer */ - - unsigned short ***usppp ; /* -- Test integer */ - unsigned short ***usppp2 ; /* -- Test integer */ - unsigned short ***usppp3 ; /* -- Test integer */ - -} USHORT_STR ; - -typedef struct { - - int i ; /* -- Test integer */ - int i2 ; /* -- Test integer */ - int i3 ; /* -- Test integer */ - - int ia[6] ; /* -- Test integer */ - int ia2[6] ; /* -- Test integer */ - int ia3[6] ; /* -- Test integer */ - - int iaa[8][8] ; /* -- Test integer */ - int iaa2[8][8] ; /* -- Test integer */ - int iaa3[8][8] ; /* -- Test integer */ - - int *ip ; /* -- Test integer */ - int *ip2 ; /* -- Test integer */ - int *ip3 ; /* -- Test integer */ - - int **ipp ; /* -- Test integer */ - int **ipp2 ; /* -- Test integer */ - int **ipp3 ; /* -- Test integer */ - - int ***ippp ; /* -- Test integer */ - int ***ippp2 ; /* -- Test integer */ - int ***ippp3 ; /* -- Test integer */ - -} INT_STR ; - -typedef struct { - - unsigned int ui ; /* -- Test integer */ - unsigned int ui2 ; /* -- Test integer */ - unsigned int ui3 ; /* -- Test integer */ - - unsigned int uia[6] ; /* -- Test integer */ - unsigned int uia2[6] ; /* -- Test integer */ - unsigned int uia3[6] ; /* -- Test integer */ - - unsigned int uiaa[8][8] ; /* -- Test integer */ - unsigned int uiaa2[8][8] ; /* -- Test integer */ - unsigned int uiaa3[8][8] ; /* -- Test integer */ - - unsigned int *uip ; /* -- Test integer */ - unsigned int *uip2 ; /* -- Test integer */ - unsigned int *uip3 ; /* -- Test integer */ - - unsigned int **uipp ; /* -- Test integer */ - unsigned int **uipp2 ; /* -- Test integer */ - unsigned int **uipp3 ; /* -- Test integer */ - - unsigned int ***uippp ; /* -- Test integer */ - unsigned int ***uippp2 ; /* -- Test integer */ - unsigned int ***uippp3 ; /* -- Test integer */ - -} UINT_STR ; - -typedef struct { - - long l ; /* -- Test long */ - long l2 ; /* -- Test long */ - long l3 ; /* -- Test long */ - - long la[6] ; /* -- Test long */ - long la2[6] ; /* -- Test long */ - long la3[6] ; /* -- Test long */ - - long laa[8][8] ; /* -- Test long */ - long laa2[8][8] ; /* -- Test long */ - long laa3[8][8] ; /* -- Test long */ - - long *lp ; /* -- Test long */ - long *lp2 ; /* -- Test long */ - long *lp3 ; /* -- Test long */ - - long **lpp ; /* -- Test long */ - long **lpp2 ; /* -- Test long */ - long **lpp3 ; /* -- Test long */ - - long ***lppp ; /* -- Test long */ - long ***lppp2 ; /* -- Test long */ - long ***lppp3 ; /* -- Test long */ - -} LONG_STR ; - -typedef struct { - - unsigned long ul ; /* -- Test long */ - unsigned long ul2 ; /* -- Test long */ - unsigned long ul3 ; /* -- Test long */ - - unsigned long ula[6] ; /* -- Test long */ - unsigned long ula2[6] ; /* -- Test long */ - unsigned long ula3[6] ; /* -- Test long */ - - unsigned long ulaa[8][8] ; /* -- Test long */ - unsigned long ulaa2[8][8] ; /* -- Test long */ - unsigned long ulaa3[8][8] ; /* -- Test long */ - - unsigned long *ulp ; /* -- Test long */ - unsigned long *ulp2 ; /* -- Test long */ - unsigned long *ulp3 ; /* -- Test long */ - - unsigned long **ulpp ; /* -- Test long */ - unsigned long **ulpp2 ; /* -- Test long */ - unsigned long **ulpp3 ; /* -- Test long */ - - unsigned long ***ulppp ; /* -- Test long */ - unsigned long ***ulppp2 ; /* -- Test long */ - unsigned long ***ulppp3 ; /* -- Test long */ - -} ULONG_STR ; - -typedef struct { - - long long ll ; /* -- Test long */ - long long ll2 ; /* -- Test long */ - long long ll3 ; /* -- Test long */ - - long long lla[6] ; /* -- Test long */ - long long lla2[6] ; /* -- Test long */ - long long lla3[6] ; /* -- Test long */ - - long long llaa[8][8] ; /* -- Test long */ - long long llaa2[8][8] ; /* -- Test long */ - long long llaa3[8][8] ; /* -- Test long */ - - long long *llp ; /* -- Test long */ - long long *llp2 ; /* -- Test long */ - long long *llp3 ; /* -- Test long */ - - long long **llpp ; /* -- Test long */ - long long **llpp2 ; /* -- Test long */ - long long **llpp3 ; /* -- Test long */ - - long long ***llppp ; /* -- Test long */ - long long ***llppp2 ; /* -- Test long */ - long long ***llppp3 ; /* -- Test long */ - -} LONG_LONG_STR ; - -typedef struct { - - unsigned long long ull ; /* -- Test long */ - unsigned long long ull2 ; /* -- Test long */ - unsigned long long ull3 ; /* -- Test long */ - - unsigned long long ulla[6] ; /* -- Test long */ - unsigned long long ulla2[6] ; /* -- Test long */ - unsigned long long ulla3[6] ; /* -- Test long */ - - unsigned long long ullaa[8][8] ; /* -- Test long */ - unsigned long long ullaa2[8][8] ; /* -- Test long */ - unsigned long long ullaa3[8][8] ; /* -- Test long */ - - unsigned long long *ullp ; /* -- Test long */ - unsigned long long *ullp2 ; /* -- Test long */ - unsigned long long *ullp3 ; /* -- Test long */ - - unsigned long long **ullpp ; /* -- Test long */ - unsigned long long **ullpp2 ; /* -- Test long */ - unsigned long long **ullpp3 ; /* -- Test long */ - - unsigned long long ***ullppp ; /* -- Test long */ - unsigned long long ***ullppp2 ; /* -- Test long */ - unsigned long long ***ullppp3 ; /* -- Test long */ - -} ULONG_LONG_STR ; - -typedef struct { - - float f ; /* -- Test integer */ - float f2 ; /* -- Test integer */ - float f3 ; /* -- Test integer */ - - float fa[6] ; /* -- Test integer */ - float fa2[6] ; /* -- Test integer */ - float fa3[6] ; /* -- Test integer */ - - float faa[8][8] ; /* -- Test integer */ - float faa2[8][8] ; /* -- Test integer */ - float faa3[8][8] ; /* -- Test integer */ - - float *fp ; /* -- Test integer */ - float *fp2 ; /* -- Test integer */ - float *fp3 ; /* -- Test integer */ - - float **fpp ; /* -- Test integer */ - float **fpp2 ; /* -- Test integer */ - float **fpp3 ; /* -- Test integer */ - - float ***fppp ; /* -- Test integer */ - float ***fppp2 ; /* -- Test integer */ - float ***fppp3 ; /* -- Test integer */ - -} FLOAT_STR ; - -typedef struct { - - double d ; /* -- Test integer */ - double d2 ; /* -- Test integer */ - double d3 ; /* -- Test integer */ - - double da[6] ; /* -- Test integer */ - double da2[6] ; /* -- Test integer */ - double da3[6] ; /* -- Test integer */ - - double daa[8][8] ; /* -- Test integer */ - double daa2[8][8] ; /* -- Test integer */ - double daa3[8][8] ; /* -- Test integer */ - - double *dp ; /* -- Test integer */ - double *dp2 ; /* -- Test integer */ - double *dp3 ; /* -- Test integer */ - - double **dpp ; /* -- Test integer */ - double **dpp2 ; /* -- Test integer */ - double **dpp3 ; /* -- Test integer */ - - double ***dppp ; /* -- Test integer */ - double ***dppp2 ; /* -- Test integer */ - double ***dppp3 ; /* -- Test integer */ - -} DOUBLE_STR ; - -typedef struct { - - CHAR_STR cs ; - CHAR_STR csa[6] ; - CHAR_STR csaa[6][6] ; - CHAR_STR *csp ; - CHAR_STR *csp1 ; - CHAR_STR *csp2 ; - CHAR_STR **cspp ; - CHAR_STR **cspp1 ; - CHAR_STR **cspp2 ; - CHAR_STR ***csppp ; - CHAR_STR ***csppp1 ; - CHAR_STR ***csppp2 ; - - UCHAR_STR ucs ; - UCHAR_STR ucsa[6] ; - UCHAR_STR ucsaa[6][6] ; - UCHAR_STR *ucsp ; - UCHAR_STR *ucsp1 ; - UCHAR_STR *ucsp2 ; - UCHAR_STR **ucspp ; - UCHAR_STR **ucspp1 ; - UCHAR_STR **ucspp2 ; - UCHAR_STR ***ucsppp ; - UCHAR_STR ***ucsppp1 ; - UCHAR_STR ***ucsppp2 ; - - SHORT_STR ss ; - SHORT_STR ssa[6] ; - SHORT_STR ssaa[6][6] ; - SHORT_STR *ssp ; - SHORT_STR *ssp1 ; - SHORT_STR *ssp2 ; - SHORT_STR **sspp ; - SHORT_STR **sspp1 ; - SHORT_STR **sspp2 ; - SHORT_STR ***ssppp ; - SHORT_STR ***ssppp1 ; - - USHORT_STR uss ; - USHORT_STR ussa[6] ; - USHORT_STR ussaa[6][6] ; - USHORT_STR *ussp ; - USHORT_STR *ussp1 ; - USHORT_STR *ussp2 ; - USHORT_STR **usspp ; - USHORT_STR **usspp1 ; - USHORT_STR **usspp2 ; - USHORT_STR ***ussppp ; - USHORT_STR ***ussppp1 ; - - INT_STR is ; - INT_STR isa[6] ; - INT_STR isaa[6][6] ; - INT_STR *isp ; - INT_STR *isp1 ; - INT_STR *isp2 ; - INT_STR **ispp ; - INT_STR **ispp1 ; - INT_STR **ispp2 ; - INT_STR ***isppp ; - INT_STR ***isppp1 ; - INT_STR ***isppp2 ; - - UINT_STR uis ; - UINT_STR uisa[6] ; - UINT_STR uisaa[6][6] ; - UINT_STR *uisp ; - UINT_STR *uisp1 ; - UINT_STR *uisp2 ; - UINT_STR **uispp ; - UINT_STR **uispp1 ; - UINT_STR **uispp2 ; - UINT_STR ***uisppp ; - UINT_STR ***uisppp1 ; - UINT_STR ***uisppp2 ; - - LONG_STR ls ; - LONG_STR lsa[6] ; - LONG_STR lsaa[6][6] ; - LONG_STR *lsp ; - LONG_STR *lsp1 ; - LONG_STR *lsp2 ; - LONG_STR **lspp ; - LONG_STR **lspp1 ; - LONG_STR **lspp2 ; - LONG_STR ***lsppp ; - LONG_STR ***lsppp1 ; - LONG_STR ***lsppp2 ; - - ULONG_STR uls ; - ULONG_STR ulsa[6] ; - ULONG_STR ulsaa[6][6] ; - ULONG_STR *ulsp ; - ULONG_STR *ulsp1 ; - ULONG_STR *ulsp2 ; - ULONG_STR **ulspp ; - ULONG_STR **ulspp1 ; - ULONG_STR **ulspp2 ; - ULONG_STR ***ulsppp ; - ULONG_STR ***ulsppp1 ; - ULONG_STR ***ulsppp2 ; - - LONG_LONG_STR lls ; - LONG_LONG_STR llsa[6] ; - LONG_LONG_STR llsaa[6][6] ; - LONG_LONG_STR *llsp ; - LONG_LONG_STR *llsp1 ; - LONG_LONG_STR *llsp2 ; - LONG_LONG_STR **llspp ; - LONG_LONG_STR **llspp1 ; - LONG_LONG_STR **llspp2 ; - LONG_LONG_STR ***llsppp ; - LONG_LONG_STR ***llsppp1 ; - LONG_LONG_STR ***llsppp2 ; - - ULONG_LONG_STR ulls ; - ULONG_LONG_STR ullsa[6] ; - ULONG_LONG_STR ullsaa[6][6] ; - ULONG_LONG_STR *ullsp ; - ULONG_LONG_STR *ullsp1 ; - ULONG_LONG_STR *ullsp2 ; - ULONG_LONG_STR **ullspp ; - ULONG_LONG_STR **ullspp1 ; - ULONG_LONG_STR **ullspp2 ; - ULONG_LONG_STR ***ullsppp ; - ULONG_LONG_STR ***ullsppp1 ; - ULONG_LONG_STR ***ullsppp2 ; - - FLOAT_STR fs ; - FLOAT_STR fsa[6] ; - FLOAT_STR fsaa[6][6] ; - FLOAT_STR *fsp ; - FLOAT_STR *fsp1 ; - FLOAT_STR *fsp2 ; - FLOAT_STR **fspp ; - FLOAT_STR **fspp1 ; - FLOAT_STR **fspp2 ; - FLOAT_STR ***fsppp ; - FLOAT_STR ***fsppp1 ; - FLOAT_STR ***fsppp2 ; - - DOUBLE_STR ds ; - DOUBLE_STR dsa[6] ; - DOUBLE_STR dsaa[6][6] ; - DOUBLE_STR *dsp ; - DOUBLE_STR *dsp1 ; - DOUBLE_STR *dsp2 ; - DOUBLE_STR **dspp ; - DOUBLE_STR **dspp1 ; - DOUBLE_STR **dspp2 ; - DOUBLE_STR ***dsppp ; - DOUBLE_STR ***dsppp1 ; - DOUBLE_STR ***dsppp2 ; - - Flag fl ; - Flag fla[10] ; - Flag * flp ; -} EVERYTHING ; - -typedef struct LinkedList { - - int i ; - struct LinkedList * next ; - struct LinkedList * prev ; - -} LINKED_LIST ; - -#endif diff --git a/trick_test/requirements_testing/models/test/ip2/src/ip.c b/trick_test/requirements_testing/models/test/ip2/src/ip.c deleted file mode 100644 index 33ea2434..00000000 --- a/trick_test/requirements_testing/models/test/ip2/src/ip.c +++ /dev/null @@ -1,34 +0,0 @@ - -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test ip) -REFERENCES: (none) -ASSUMPTIONS AND LIMITATIONS: (Autocreated by trick_ui) -CLASS: (scheduled) -LIBRARY DEPENDENCY: (ip.o) -PROGRAMMERS: ((lin) (Thu Feb 27 14:57:16 CST 2003)) -***************************************************************************/ - -/* - * $Log: ip.c,v $ - * Revision 7.1 2006-06-22 14:14:12-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:56-05 lin - * Bump - * - * Revision 4.2 2004/01/16 21:48:55 lin - * Add a log to all files - * - */ - -#include -#include "../include/ip.h" - -int ip_test( - /* RETURN: -- Always return zero */ - INT_STR* I) /* INOUT: -- Parameter */ - -{ - - return ( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/ip2/src/ip_test_init.c b/trick_test/requirements_testing/models/test/ip2/src/ip_test_init.c deleted file mode 100644 index c7463c17..00000000 --- a/trick_test/requirements_testing/models/test/ip2/src/ip_test_init.c +++ /dev/null @@ -1,79 +0,0 @@ - -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test ip) -REFERENCES: (none) -ASSUMPTIONS AND LIMITATIONS: (Autocreated by trick_ui) -CLASS: (initialization) -LIBRARY DEPENDENCY: (ip.o) -PROGRAMMERS: ((lin) (Thu Feb 27 14:57:16 CST 2003)) -***************************************************************************/ - -/* - * $Log: ip_test_init.c,v $ - * Revision 7.2 2006-08-15 15:54:44-05 hchen - * SIM_ip2_test needs to be updated for new ip_alloc_type interface - * - * Revision 7.1 2006-06-22 14:14:12-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:56-05 lin - * Bump - * - * Revision 4.2 2004/01/16 21:48:55 lin - * Add a log to all files - * - */ - -#include -#include "../include/ip.h" -#include "sim_services/include/attributes.h" -#include "sim_services/include/exec_proto.h" - -extern ATTRIBUTES attrstruct_LinkedList[] ; - -int ip_test_init( - /* RETURN: -- Always return zero */ - LINKED_LIST** L) /* INOUT: -- Parameter */ - -{ - - LINKED_LIST * new_item ; - - new_item = (LINKED_LIST *)ip_alloc_type( 1 , sizeof(LINKED_LIST), attrstruct_LinkedList, NULL ) ; - new_item->i = 1000 ; - - *L = new_item ; - - new_item = (LINKED_LIST *)ip_alloc_type( 1 , sizeof(LINKED_LIST), attrstruct_LinkedList, NULL ) ; - new_item->i = 2000 ; - - new_item->prev = *L ; - (*L)->next = new_item ; - - new_item = (LINKED_LIST *)ip_alloc_type( 2 , sizeof(LINKED_LIST), attrstruct_LinkedList, NULL ) ; - new_item->i = 500 ; - new_item[1].i = 501 ; - - new_item = (LINKED_LIST *)ip_realloc( (char *)new_item , 8 , sizeof(LINKED_LIST)) ; - new_item->prev = *L ; - (*L)->next->next = new_item ; - new_item[2].i = 502 ; - new_item[3].i = 503 ; - new_item[4].i = 504 ; - new_item[5].i = 505 ; - new_item[6].i = 506 ; - - /* - new_item = (LINKED_LIST *)ip_alloc( 1 , sizeof(LINKED_LIST), attrLINKED_LIST ) ; - new_item->i = 500 ; - - (*L)->prev = new_item ; - - new_item = (LINKED_LIST *)ip_alloc( 1 , sizeof(LINKED_LIST), attrLINKED_LIST ) ; - new_item->i = 4000 ; - - (*L)->next->next = new_item ; - */ - - return ( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/.checksums b/trick_test/requirements_testing/models/test/sched/.checksums deleted file mode 100644 index a8168cfe..00000000 --- a/trick_test/requirements_testing/models/test/sched/.checksums +++ /dev/null @@ -1,19 +0,0 @@ -62466 2 ./src/sched_amf.c -56063 2 ./src/sched_async.c -58898 2 ./src/sched_deriv.c -40625 4 ./src/sched_dyn_event.c -1862 3 ./src/sched_effector.c -60196 2 ./src/sched_effector_emitter.c -60562 2 ./src/sched_effector_receiver.c -63000 2 ./src/sched_environment.c -49220 2 ./src/sched_init.c -23169 3 ./src/sched_integ.c -56365 2 ./src/sched_logging.c -57176 2 ./src/sched_scheduled.c -56062 2 ./src/sched_sensor.c -59482 2 ./src/sched_sensor_emitter.c -59798 2 ./src/sched_sensor_receiver.c -60444 2 ./src/sched_sensor_reflector.c -58851 2 ./include/sched.d -12435 3 ./include/sched.h -32231 3 ./include/sched_integ.d diff --git a/trick_test/requirements_testing/models/test/sched/include/sched.d b/trick_test/requirements_testing/models/test/sched/include/sched.d deleted file mode 100644 index 45525ca9..00000000 --- a/trick_test/requirements_testing/models/test/sched/include/sched.d +++ /dev/null @@ -1,38 +0,0 @@ -/* - * $Log: sched.d,v $ - * Revision 7.1 2006-06-22 14:14:10-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:56-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.4 2003/08/26 20:24:13 vetter - * Add Dynamic Event Class To SIM_test_sched - * - * Revision 1.3 2002/10/07 15:16:28 lin - * Add rcs version info to all trick_models files - * - */ - -SCHEDULE.pos = 5.0 ; -SCHEDULE.vel = 0.0 ; -SCHEDULE.acc = 0.0 ; -SCHEDULE.mass = 1.0 ; -SCHEDULE.amf = 1 ; -SCHEDULE.amf_error = 0 ; - -#define BIG_TGO 10000 -SCHEDULE.rf.lower_set = No ; -SCHEDULE.rf.upper_set = No ; -SCHEDULE.rf.iterations = 0 ; -SCHEDULE.rf.fires = 0 ; -SCHEDULE.rf.x_lower = BIG_TGO ; -SCHEDULE.rf.t_lower = BIG_TGO ; -SCHEDULE.rf.x_upper = BIG_TGO ; -SCHEDULE.rf.t_upper = BIG_TGO ; -SCHEDULE.rf.delta_time = BIG_TGO ; -SCHEDULE.rf.error_tol = 1.0e-6 ; -SCHEDULE.rf.mode = Increasing ; diff --git a/trick_test/requirements_testing/models/test/sched/include/sched.h b/trick_test/requirements_testing/models/test/sched/include/sched.h deleted file mode 100644 index c037b5b2..00000000 --- a/trick_test/requirements_testing/models/test/sched/include/sched.h +++ /dev/null @@ -1,45 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Scheduling test ) -REFERENCES: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched.h,v $ - * Revision 7.1 2006-06-22 14:14:10-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:57-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.4 2003/08/26 20:24:14 vetter - * Add Dynamic Event Class To SIM_test_sched - * - * Revision 1.3 2002/10/07 15:16:28 lin - * Add rcs version info to all trick_models files - * - */ - -#ifndef _SCHEDULE_H_ -#define _SCHEDULE_H_ - -#include "sim_services/include/regula_falsi.h" - -typedef struct { /* SCHEDULE ------------------------------------------------*/ - - double pos ; /* M Position */ - double vel ; /* M/s Velocity */ - double acc ; /* M/s2 Acceleration */ - double mass ; /* kg Mass */ - int amf ; /* -- Just a test variable */ - int amf_error ; /* -- Order error occured in amf job */ - REGULA_FALSI rf ; /* -- Dynamic event */ - -} SCHEDULE ; /*--------------------------------------------------------------*/ - - -#endif diff --git a/trick_test/requirements_testing/models/test/sched/include/sched_integ.d b/trick_test/requirements_testing/models/test/sched/include/sched_integ.d deleted file mode 100644 index cee19733..00000000 --- a/trick_test/requirements_testing/models/test/sched/include/sched_integ.d +++ /dev/null @@ -1,56 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Ball model state integrator default initialization data.) -REFERENCE: - (((Bailey, R.W, and Paddock, E.J.) - (Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((2 dimensional space)) -PROGRAMMERS: - (((Your Name) (Company Name) (Date) (Trick tutorial))) -*******************************************************************************/ - -/* - * $Log: sched_integ.d,v $ - * Revision 7.3 2007-11-06 10:39:22-06 hchen - * Change the way of defining a variable in some .d files related to old style allocation and fix some typos - * - * Revision 7.2 2007-10-23 11:53:06-05 hchen - * Convert the old style allocation statements we have in included sims - * - * Revision 7.1 2006-06-22 14:14:11-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:57-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:18 lin - * Bump version number for 04 - * - * Revision 1.2 2002/10/07 15:16:29 lin - * Add rcs version info to all trick_models files - * - */ - -#define NUM_STEP 12 /* use up to 12 intermediate steps: - 8th order RK Fehlberg */ -#define NUM_VARIABLES 4 /* x,y position state and x,y velocity state */ - -INTEGRATOR.state = alloc(NUM_VARIABLES) ; -INTEGRATOR.deriv = alloc(NUM_STEP) ; -INTEGRATOR.state_ws = alloc(NUM_STEP) ; - -for (int kk = 0 ; kk < NUM_STEP ; kk++ ) { - INTEGRATOR.deriv[kk] = alloc(NUM_VARIABLES) ; - INTEGRATOR.state_ws[kk] = alloc(NUM_VARIABLES) ; -} - -INTEGRATOR.num_state = NUM_VARIABLES ; -INTEGRATOR.option = Runge_Kutta_4 ; /* 4rth order Runge Kutta */ -INTEGRATOR.init = True ; -INTEGRATOR.first_step_deriv = Yes ; - -#undef NUM_STEP -#undef NUM_VARIABLES diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_amf.c b/trick_test/requirements_testing/models/test/sched/src/sched_amf.c deleted file mode 100644 index eb21ad1b..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_amf.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( asynchronous_mustfinish ) -LIBRARY DEPENDENCY: ( sched_amf.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_amf.c,v $ - * Revision 7.1 2006-06-22 14:14:04-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:57-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:13 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:29 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_amf( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - if ( S->amf == 2 ) { - /* Things are in order */ - S->amf = 1 ; - } else { - /* Things are out of order */ - S->amf = 3 ; - S->amf_error = 1 ; - } - - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_async.c b/trick_test/requirements_testing/models/test/sched/src/sched_async.c deleted file mode 100644 index e79ff093..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_async.c +++ /dev/null @@ -1,39 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( asynchronous ) -LIBRARY DEPENDENCY: ( sched_async.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_async.c,v $ - * Revision 7.1 2006-06-22 14:14:04-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:13 lin - * Bump version number for 04 - * - * Revision 1.4 2002/10/07 15:16:30 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_async ( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - - while ( 1 ) { - /* Try and hang the sim... */ - usleep(1000000) ; - } - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_deriv.c b/trick_test/requirements_testing/models/test/sched/src/sched_deriv.c deleted file mode 100644 index c1df428e..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_deriv.c +++ /dev/null @@ -1,37 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( derivative ) -LIBRARY DEPENDENCY: ( sched_deriv.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) (Trick tutorial) ) -*******************************************************************************/ - -/* - * $Log: sched_deriv.c,v $ - * Revision 7.1 2006-06-22 14:14:04-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:13 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:30 lin - * Add rcs version info to all trick_models files - * - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - - -int sched_deriv( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->acc = -1 * S->pos * S->mass ; - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_dyn_event.c b/trick_test/requirements_testing/models/test/sched/src/sched_dyn_event.c deleted file mode 100644 index 1091f517..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_dyn_event.c +++ /dev/null @@ -1,59 +0,0 @@ -/******************************* TRICK HEADER ******************************* -PURPOSE: (Test regula falsi ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( A program has to know its limitations, - that is my assumption :P ) -CLASS: (dynamic_event) -LIBRARY DEPENDENCY: (sched_dyn_event.o) -PROGRAMMERS: ( Keith Vetter a.k.a brillo ) -*****************************************************************************/ - -/* - * $Log: sched_dyn_event.c,v $ - * Revision 7.1 2006-06-22 14:14:05-05 lin - * Bump version number for 07 - * - * Revision 5.2 2006-04-13 14:39:47-05 jkowing - * Export functions to header files. - * - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.2 2004/01/16 21:48:56 lin - * Add a log to all files - * - */ - -#include -#include "../include/sched.h" -#include "sim_services/include/regula_falsi.h" - -double sched_dyn_event( - /* RETURN: s Time to go to event */ -SCHEDULE * S , /* INOUT: -- */ -double *time , /* IN: s Integrator time from the executive */ -int *event_evaluate_tgo ) /* IN: -- Event time to go function eval flag, - 1 = evaluate time to go for event, - 0 = fire event */ -{ - - double tgo ; - - if( *event_evaluate_tgo ) { - - /* CALCULATE TIME TO GO FOR EVENT */ - S->rf.error = S->mass - 1.2 ; - tgo = regula_falsi( *time , &(S->rf) ) ; - - } else { - - /* FIRE EVENT */ - reset_regula_falsi( *time , &(S->rf) ) ; - tgo = 0.0 ; - - /* Make mass zig zag once it hits 1.2kg */ - S->mass = S->mass - 0.01 ; - } - - return( tgo ) ; -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_effector.c b/trick_test/requirements_testing/models/test/sched/src/sched_effector.c deleted file mode 100644 index 829b93c8..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_effector.c +++ /dev/null @@ -1,46 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( effector ) -LIBRARY DEPENDENCY: ( sched_effector.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_effector.c,v $ - * Revision 7.1 2006-06-22 14:14:05-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:14 lin - * Bump version number for 04 - * - * Revision 1.4 2002/10/07 15:16:30 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_effector( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.0000002 + 0.00000002 ; /* Sensor is collecting dust */ - - if ( S->amf == 1 ) { - /* Things are good */ - S->amf = 2 ; - } else { - /* Things are out of order */ - S->amf = 3 ; - S->amf_error = 1 ; - } - - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_effector_emitter.c b/trick_test/requirements_testing/models/test/sched/src/sched_effector_emitter.c deleted file mode 100644 index 8682678a..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_effector_emitter.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( effector_emitter ) -LIBRARY DEPENDENCY: ( sched_effector_emitter.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_effector_emitter.c,v $ - * Revision 7.1 2006-06-22 14:14:06-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:14 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:31 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_effector_emitter( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000003 + 0.000003 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_effector_receiver.c b/trick_test/requirements_testing/models/test/sched/src/sched_effector_receiver.c deleted file mode 100644 index 251e59a9..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_effector_receiver.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( effector_receiver ) -LIBRARY DEPENDENCY: ( sched_effector_receiver.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_effector_receiver.c,v $ - * Revision 7.1 2006-06-22 14:14:06-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:14 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:31 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_effector_receiver( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000004 + 0.000004 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_environment.c b/trick_test/requirements_testing/models/test/sched/src/sched_environment.c deleted file mode 100644 index 89841144..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_environment.c +++ /dev/null @@ -1,37 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( environment ) -LIBRARY DEPENDENCY: ( sched_environment.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_environment.c,v $ - * Revision 7.1 2006-06-22 14:14:06-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:15 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:31 lin - * Add rcs version info to all trick_models files - * - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - - -int sched_environment( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000005 + 0.000005 ; /* Mass growing, dust collection :-) */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_init.c b/trick_test/requirements_testing/models/test/sched/src/sched_init.c deleted file mode 100644 index 90f68049..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_init.c +++ /dev/null @@ -1,32 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_init) -REFERENCES: (none) -ASSUMPTIONS AND LIMITATIONS: (Autocreated by trick_ui) -CLASS: (initialization) -LIBRARY DEPENDENCY: (sched_init.o) -PROGRAMMERS: ((vetter) (Tue Aug 26 13:22:44 CDT 2003)) -***************************************************************************/ - -/* - * $Log: sched_init.c,v $ - * Revision 7.1 2006-06-22 14:14:07-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.2 2004/01/16 21:48:56 lin - * Add a log to all files - * - */ - -#include "../include/sched.h" - -int sched_init( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - S->mass = S->mass*1.0000013 + 0.0000013 ; /* Massive masses */ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_integ.c b/trick_test/requirements_testing/models/test/sched/src/sched_integ.c deleted file mode 100644 index 29f0be4c..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_integ.c +++ /dev/null @@ -1,49 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( integration ) -LIBRARY DEPENDENCY: ( sched_integ.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) (Trick tutorial) ) -*******************************************************************************/ - -/* - * $Log: sched_integ.c,v $ - * Revision 7.1 2006-06-22 14:14:07-05 lin - * Bump version number for 07 - * - * Revision 5.2 2006-04-13 14:39:48-05 jkowing - * Export functions to header files. - * - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:15 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:32 lin - * Add rcs version info to all trick_models files - * - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - -int sched_integ( - /* RETURN: -- Always return zero */ - INTEGRATOR *I , /* INOUT: -- Trick state integration parameters */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - I->state[0] = S->pos ; - I->state[1] = S->vel ; - - I->deriv[I->intermediate_step][0] = S->vel ; - I->deriv[I->intermediate_step][1] = S->acc ; - - integrate( I ) ; - - S->pos = I->state_ws[I->intermediate_step][0] ; - S->vel = I->state_ws[I->intermediate_step][1] ; - - return( I->intermediate_step ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_logging.c b/trick_test/requirements_testing/models/test/sched/src/sched_logging.c deleted file mode 100644 index 976a3b0b..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_logging.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( logging ) -LIBRARY DEPENDENCY: ( sched_logging.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_logging.c,v $ - * Revision 7.1 2006-06-22 14:14:08-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:15 lin - * Bump version number for 04 - * - * Revision 1.4 2002/10/07 15:16:32 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_logging( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000006 + 0.000006 ; /* Sensor is collecting dust */ - - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_scheduled.c b/trick_test/requirements_testing/models/test/sched/src/sched_scheduled.c deleted file mode 100644 index 8f835e5e..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_scheduled.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -LIBRARY DEPENDENCY: ( sched_scheduled.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_scheduled.c,v $ - * Revision 7.1 2006-06-22 14:14:08-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_scheduled( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000007 + 0.000007 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_sensor.c b/trick_test/requirements_testing/models/test/sched/src/sched_sensor.c deleted file mode 100644 index 81cab726..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_sensor.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor ) -LIBRARY DEPENDENCY: ( sched_sensor.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor.c,v $ - * Revision 7.1 2006-06-22 14:14:08-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_sensor( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000008 + 0.000008 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_sensor_emitter.c b/trick_test/requirements_testing/models/test/sched/src/sched_sensor_emitter.c deleted file mode 100644 index 051b85fc..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_sensor_emitter.c +++ /dev/null @@ -1,35 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor_emitter ) -LIBRARY DEPENDENCY: ( sched_sensor_emitter.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor_emitter.c,v $ - * Revision 7.1 2006-06-22 14:14:09-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_sensor_emitter( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000009 + 0.000009 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_sensor_receiver.c b/trick_test/requirements_testing/models/test/sched/src/sched_sensor_receiver.c deleted file mode 100644 index 26490b47..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_sensor_receiver.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor_receiver ) -LIBRARY DEPENDENCY: ( sched_sensor_receiver.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor_receiver.c,v $ - * Revision 7.1 2006-06-22 14:14:09-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:34 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_sensor_receiver( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.00021 + 0.000021 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test/sched/src/sched_sensor_reflector.c b/trick_test/requirements_testing/models/test/sched/src/sched_sensor_reflector.c deleted file mode 100644 index cc603fa1..00000000 --- a/trick_test/requirements_testing/models/test/sched/src/sched_sensor_reflector.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor_reflector ) -LIBRARY DEPENDENCY: ( sched_sensor_reflector.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor_reflector.c,v $ - * Revision 7.1 2006-06-22 14:14:10-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:34 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_sensor_reflector( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.00000022 + 0.0000022 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test1/include/test1.d b/trick_test/requirements_testing/models/test1/include/test1.d deleted file mode 100644 index a9acb4b7..00000000 --- a/trick_test/requirements_testing/models/test1/include/test1.d +++ /dev/null @@ -1,17 +0,0 @@ -TEST1.i = 1; -TEST1.ui = 2; -TEST1.d = 3.0; -TEST1.ss.si = 4; -TEST1.ip = &TEST1.i5; -TEST1.da[0] = 1.0; -TEST1.da[1] = 2.0; -TEST1.da[2] = 3.0; -TEST1.da[3] = 4.0; -TEST1.da[4] = 5.0; -TEST1.da[0] = 5, 4, 3, 2, 1 ; -TEST1.dap = &TEST1.da; -TEST1.s[0] = "default"; - -TEST1.i5 = 5; -TEST1.i55 = 55; -TEST1.i555 = 555; diff --git a/trick_test/requirements_testing/models/test1/include/test1.h b/trick_test/requirements_testing/models/test1/include/test1.h deleted file mode 100644 index 1b8072c8..00000000 --- a/trick_test/requirements_testing/models/test1/include/test1.h +++ /dev/null @@ -1,26 +0,0 @@ -/****************************************************************************** -PURPOSE: (Tests requirements: 3.1.2.9, 3.1.2.9.1-5) -******************************************************************************/ - -#ifndef _test1_h_ -#define _test1_h_ - -typedef struct { - int si; -} SS; - -typedef struct { - int i; - unsigned int ui; - double d; - SS ss; - int* ip; - double da[5]; - double* dap; - char s[15]; - int i5; - int i55; - int i555; -} TEST1; - -#endif diff --git a/trick_test/requirements_testing/models/test1/src/test1_cyclic.c b/trick_test/requirements_testing/models/test1/src/test1_cyclic.c deleted file mode 100644 index d468d4e3..00000000 --- a/trick_test/requirements_testing/models/test1/src/test1_cyclic.c +++ /dev/null @@ -1,14 +0,0 @@ -/***************************************************************************** -PURPOSE: ( TEST 1 ) -*****************************************************************************/ -#include -#include -#include "../include/test1.h" - -int test1_cyclic(TEST1* T) { - - fprintf(stdout,"test1_cyclic.\n"); - - return 0 ; -} - diff --git a/trick_test/requirements_testing/models/test1/src/test1_init.c b/trick_test/requirements_testing/models/test1/src/test1_init.c deleted file mode 100644 index 8ce73b31..00000000 --- a/trick_test/requirements_testing/models/test1/src/test1_init.c +++ /dev/null @@ -1,33 +0,0 @@ -/******************************************************************************* -PURPOSE: (Initialize test 1.) -*******************************************************************************/ -#include -#include -#include "../include/test1.h" - -int test1_init(TEST1* T) { - printf("*****************Initialization routine*****************\n"); - printf("Changing i from %d to %d\n", T->i, 11); - T->i = 11; - printf("Changing ui from %u to %u\n", T->ui, 22); - T->ui = 22; - printf("Changing d from %f to %f\n", T->d, 33.0); - T->d = 33.0; - printf("Changing ss.si from %d to %d\n", T->ss.si, 44); - T->ss.si = 44; - printf("Changing ip from %d to %d\n", *(T->ip), T->i55); - T->ip = &T->i55; - printf("Changing da from {%f, %f, %f, %f, %f} to {%f, %f, %f, %f, %f}\n", - T->da[0], T->da[1], T->da[2], T->da[3], T->da[4], - 11.0, 22.0, 33.0, 44.0, 55.0); - T->da[0] = 11.0; - T->da[1] = 22.0; - T->da[2] = 33.0; - T->da[3] = 44.0; - T->da[4] = 55.0; - printf("Changing dap from %f to %f\n", *(T->dap), T->da[1]); - T->dap = &T->da[1]; - printf("Changing s from '%s' to '%s'\n", T->s, "initialization"); - strcpy(T->s, "initialization"); - return(0); -} diff --git a/trick_test/requirements_testing/models/test1/src/test1_shutdown.c b/trick_test/requirements_testing/models/test1/src/test1_shutdown.c deleted file mode 100644 index d97a7148..00000000 --- a/trick_test/requirements_testing/models/test1/src/test1_shutdown.c +++ /dev/null @@ -1,33 +0,0 @@ -/******************************************************************************* -PURPOSE: (Shutdown test 1.) -*******************************************************************************/ -#include -#include -#include "../include/test1.h" - -int test1_shutdown(TEST1* T) { - printf("********************Shutdown routine********************\n"); - printf("Changing i from %d to %d\n", T->i, 111); - T->i = 111; - printf("Changing ui from %u to %u\n", T->ui, 222); - T->ui = 222; - printf("Changing d from %f to %f\n", T->d, 333.0); - T->d = 333.0; - printf("Changing ss.si from %d to %d\n", T->ss.si, 444); - T->ss.si = 444; - printf("Changing ip from %d to %d\n", *(T->ip), T->i555); - T->ip = &T->i555; - printf("Changing da from {%f, %f, %f, %f, %f} to {%f, %f, %f, %f, %f}\n", - T->da[0], T->da[1], T->da[2], T->da[3], T->da[4], - 111.0, 222.0, 333.0, 444.0, 555.0); - T->da[0] = 111.0; - T->da[1] = 222.0; - T->da[2] = 333.0; - T->da[3] = 444.0; - T->da[4] = 555.0; - printf("Changing dap from %f to %f\n", *(T->dap), T->da[2]); - T->dap = &T->da[2]; - printf("Changing s from '%s' to '%s'\n", T->s, "shutdown"); - strcpy(T->s, "shutdown"); - return(0); -} diff --git a/trick_test/requirements_testing/models/test10/aero/.checksums b/trick_test/requirements_testing/models/test10/aero/.checksums deleted file mode 100644 index d8ba3c5b..00000000 --- a/trick_test/requirements_testing/models/test10/aero/.checksums +++ /dev/null @@ -1,14 +0,0 @@ -17061 3 ./src/cannon_collect_forces.c -64314 2 ./src/cannon_force_cross.c -44875 2 ./src/cannon_force_drag.c -28198 1 ./src/cannon_force_gravity.c -40698 2 ./src/cannon_force_jet.c -60736 4 ./src/cannon_force_lift.c -25578 3 ./src/cannon_impact_aero.c -25704 3 ./src/cannon_impact_monte.c -45188 2 ./src/cannon_init_aero.c -42698 4 ./src/cannon_integ_aero.c -62286 2 ./src/cannon_jet_control.c -64436 2 ./include/cannon_aero.d -51825 7 ./include/cannon_aero.h -31342 1 ./include/cannon_integ_aero.d diff --git a/trick_test/requirements_testing/models/test10/aero/include/cannon_aero.d b/trick_test/requirements_testing/models/test10/aero/include/cannon_aero.d deleted file mode 100644 index 16b2e8dd..00000000 --- a/trick_test/requirements_testing/models/test10/aero/include/cannon_aero.d +++ /dev/null @@ -1,30 +0,0 @@ -CANNON_AERO.slave_init = 0; -CANNON_AERO.slave_shutdown = 0; -CANNON_AERO.master_shutdown = 0; - - - -/* Initialize cannon ball shot */ -CANNON_AERO.lift_method = Smits_Smith ; -CANNON_AERO.coefficient_drag = 0.45 ; -CANNON_AERO.coefficient_cross = 0.044 ; -CANNON_AERO.mass = 0.145 ; -CANNON_AERO.air_density = 1.29 ; -CANNON_AERO.ball_radius {cm} = 3.63 ; -CANNON_AERO.ball_area {cm2} = 41.59 ; -CANNON_AERO.g = -9.81 ; -CANNON_AERO.force_jet_Z_plus {lbf} = 2.0 ; - -/* Regula Falsi impact critter setup */ -#define BIG_TGO 10000 -CANNON_AERO.rf.lower_set = No ; -CANNON_AERO.rf.upper_set = No ; -CANNON_AERO.rf.iterations = 0 ; -CANNON_AERO.rf.fires = 0 ; -CANNON_AERO.rf.x_lower = BIG_TGO ; -CANNON_AERO.rf.t_lower = BIG_TGO ; -CANNON_AERO.rf.x_upper = BIG_TGO ; -CANNON_AERO.rf.t_upper = BIG_TGO ; -CANNON_AERO.rf.delta_time = BIG_TGO ; -CANNON_AERO.rf.error_tol = 1.0e-9 ; -CANNON_AERO.rf.mode = Decreasing ; diff --git a/trick_test/requirements_testing/models/test10/aero/include/cannon_aero.h b/trick_test/requirements_testing/models/test10/aero/include/cannon_aero.h deleted file mode 100644 index d61bbb48..00000000 --- a/trick_test/requirements_testing/models/test10/aero/include/cannon_aero.h +++ /dev/null @@ -1,76 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Tests requirements: 3.1.2.13.2) -***************************************************************************/ -#ifndef _cannon_aero_h_ -#define _cannon_aero_h_ - -#include "sim_services/include/regula_falsi.h" - -typedef enum { - Hard_Coded_Coefficient_Lift, /* You come up with Cl */ - Smits_Smith, /* Cl ~= 0.54*S^0.4 (S = rw/V) */ - Adair_Giordano, /* Lift_Force = mass*0.00041*w_cross_V */ - Tombras /* Cl = 1/(2.022 + 0.981v/w) */ -} Lift_Estimation_Method ; - -typedef struct { - - int slave_init; - int slave_shutdown; - int master_shutdown; - - double pos[3] ; /* M position */ - double vel[3] ; /* M/s velocity */ - double acc[3] ; /* M/s2 acceleration */ - double omega[3] ; /* r/s Angular velocity of cannonball */ - - double theta ; /* r Angle from x-axis to axis rotation */ - double phi ; /* r Angle from z-axis to axis rotation */ - double omega0 ; /* r/s Magnitude of angular velocity about - axis of rotation */ - /* Impact */ - REGULA_FALSI rf ; /* -- Dynamic event params for impact */ - int impact ; /* -- Has impact occured */ - double impact_pos ; /* M How far ball lands in field */ - - /* Forces */ - double force_gravity[3] ; /* N Gravitational force */ - double force_drag[3] ; /* N Drag force opposite dir of velocity */ - double force_magnus[3] ; /* N Force due to spin, dir grav cross drag */ - double force_cross[3] ; /* N Side directional force */ - double force_total[3] ; /* N Sum of all forces */ - - /* Force magnitudes */ - double mag_force_drag ; /* N Magnitude of drag force */ - double mag_force_magnus ; /* N Magnitude of magnus force */ - double mag_force_cross ; /* N Magnitude of cross force */ - double mag_omega ; /* r/s Magnitude of angular velocity */ - - void** force_collect ; /* -- For collect statement */ - - /* Environment and Properties */ - double mass ; /* kg Mass of cannonball */ - double air_density ; /* kg/M3 Air density at 20C */ - double ball_radius ; /* M Radius of cannonball */ - double ball_area ; /* M2 Cross sectional area of ball */ - double spin_parameter ; /* -- S=r*omega/speed */ - double g ; /* M/s2 Gravitational acceleration */ - - /* Coefficients drag, lift and cross */ - Lift_Estimation_Method lift_method ; /* -- How to find lift force */ - double coefficient_drag ; /* -- Drag coefficient */ - double coefficient_lift ; /* -- Lift coefficient */ - double coefficient_cross ; /* -- Cross-Force coefficient */ - - /* Jet */ - int jet_on ; /* -- 0|1 */ - int jet_count ; /* -- How many jet firings? */ - double force_jet[3] ; /* N Jet force per firing */ - double force_jet_Z_plus ; /* N Configurable force of jet in Z+ direction */ - double time_to_fire_jet_1 ; /* s First jet firing time */ - double time_to_fire_jet_2 ; /* s Second jet firing time */ - double time_to_fire_jet_3 ; /* s Third jet firing time */ - double time_to_fire_jet_4 ; /* s Fourth jet firing time */ - -} CANNON_AERO ; -#endif diff --git a/trick_test/requirements_testing/models/test10/aero/include/cannon_integ_aero.d b/trick_test/requirements_testing/models/test10/aero/include/cannon_integ_aero.d deleted file mode 100644 index 49073e11..00000000 --- a/trick_test/requirements_testing/models/test10/aero/include/cannon_integ_aero.d +++ /dev/null @@ -1,24 +0,0 @@ -#define NUM_STEP 12 -#define NUM_VARIABLES 6 - -INTEGRATOR.state = alloc(NUM_VARIABLES) ; -INTEGRATOR.deriv = alloc(NUM_STEP) ; -INTEGRATOR.state_ws = alloc(NUM_STEP) ; - -for (int kk = 0 ; kk < NUM_STEP ; kk++ ) { - INTEGRATOR.deriv[kk] = alloc(NUM_VARIABLES) ; - INTEGRATOR.state_ws[kk] = alloc(NUM_VARIABLES) ; -} - -INTEGRATOR.stored_data = alloc(8) ; -for (int kk = 0 ; kk < 8 ; kk++ ) { - INTEGRATOR.stored_data[kk] = alloc(NUM_VARIABLES) ; -} - -INTEGRATOR.option = Runge_Kutta_4 ; -INTEGRATOR.init = True ; -INTEGRATOR.first_step_deriv = Yes ; -INTEGRATOR.num_state = NUM_VARIABLES ; - -#undef NUM_STEP -#undef NUM_VARIABLES diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_collect_forces.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_collect_forces.c deleted file mode 100644 index 29537ad7..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_collect_forces.c +++ /dev/null @@ -1,31 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Collect all forces and calculate acceleration) -***************************************************************************/ -#include "../include/cannon_aero.h" -#include "sim_services/include/collect_macros.h" - -int cannon_collect_forces( - CANNON_AERO *C ) -{ - double **collected_forces ; - int ii ; - - /* Collect external forces on the ball */ - collected_forces = (double**)(C->force_collect) ; - C->force_total[0] = 0.0 ; - C->force_total[1] = 0.0 ; - C->force_total[2] = 0.0 ; - for( ii = 0 ; ii < NUM_COLLECT(collected_forces) ; ii++ ) { - C->force_total[0] += collected_forces[ii][0] ; - C->force_total[1] += collected_forces[ii][1] ; - C->force_total[2] += collected_forces[ii][2] ; - } - - /* Solve for xyz acceleration */ - C->acc[0] = C->force_total[0] / C->mass ; - C->acc[1] = C->force_total[1] / C->mass ; - C->acc[2] = C->force_total[2] / C->mass ; - - return 0 ; -} - diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_cross.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_force_cross.c deleted file mode 100644 index 3a9035b0..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_cross.c +++ /dev/null @@ -1,27 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Cross Force or Side Force ) -***************************************************************************/ -#include "../include/cannon_aero.h" -#include "trick_utils/math/include/trick_math.h" - -int cannon_force_cross( - CANNON_AERO *C ) -{ - double magnus_cross_drag[3] ; - double norm_magnus_cross_drag[3] ; - double k, speed ; - - /* k = 1/2*rho*Cy*A*V^2 */ - speed = V_MAG( C->vel ) ; - k = (-0.5)*C->air_density*C->coefficient_cross*C->ball_area*speed*speed ; - - /* F = k*(M x D)/|M x D| */ - V_CROSS( magnus_cross_drag, C->force_magnus, C->force_drag ) ; - V_NORM( norm_magnus_cross_drag, magnus_cross_drag ) ; - V_SCALE( C->force_cross, norm_magnus_cross_drag, k) ; - - C->mag_force_cross = V_MAG( C->force_cross ) ; - - return 0 ; -} - diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_drag.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_force_drag.c deleted file mode 100644 index b7d003c2..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_drag.c +++ /dev/null @@ -1,24 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Drag force) -***************************************************************************/ -#include "../include/cannon_aero.h" -#include "trick_utils/math/include/trick_math.h" - -int cannon_force_drag( - CANNON_AERO *C ) -{ - double k ; - double speed ; - - speed = V_MAG( C->vel ) ; - - /* k = -1/2*rho*Cd*A*|V| */ - k = (-0.5)*C->air_density*C->coefficient_drag*C->ball_area*speed ; - - /* Force_drag = k*V = -1/2*rho*Cd*A*|V|*V */ - V_SCALE( C->force_drag, C->vel, k ) ; - - C->mag_force_drag = V_MAG( C->force_drag ) ; - - return 0 ; -} diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_gravity.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_force_gravity.c deleted file mode 100644 index fc1487dd..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_gravity.c +++ /dev/null @@ -1,15 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: ( Gravitational force on cannonball ) -***************************************************************************/ -#include "../include/cannon_aero.h" - -int cannon_force_gravity( - CANNON_AERO *C ) -{ - C->force_gravity[0] = 0.0 ; - C->force_gravity[1] = 0.0 ; - C->force_gravity[2] = C->mass*C->g ; - - return 0 ; -} - diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_jet.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_force_jet.c deleted file mode 100644 index 51781bb4..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_jet.c +++ /dev/null @@ -1,28 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: ( Jet fire force ) -***************************************************************************/ - -/* - * $Log: cannon_force_jet.c,v $ - * Revision 7.1 2006-06-22 14:14:48-05 lin - * Bump version number for 07 - * - * Revision 5.2 2004-08-18 10:49:42-05 lin - * Cleanup cannon_force_jet() In Tutorial - * - */ - -#include "../include/cannon_aero.h" - -int cannon_force_jet( - CANNON_AERO *C ) -{ - if ( C->jet_on && C->jet_count < 4 ) { - C->force_jet[2] = C->force_jet_Z_plus ; - C->jet_count++ ; - C->jet_on = 0 ; - } else { - C->force_jet[2] = 0.0 ; - } - return 0 ; -} diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_lift.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_force_lift.c deleted file mode 100644 index 25ce78b0..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_force_lift.c +++ /dev/null @@ -1,62 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Lift-Magnus Force) -***************************************************************************/ -#include "../include/cannon_aero.h" -#include "trick_utils/math/include/trick_math.h" - -int cannon_force_lift( - CANNON_AERO *C ) -{ - double w_cross_v[3] ; double norm_w_cross_v[3] ; - double k, speed ; - - speed = V_MAG( C->vel ) ; - - if ( speed != 0.0 ) { - C->spin_parameter = C->ball_radius*V_MAG( C->omega )/speed ; - } else { - C->spin_parameter = 0.0000000001 ; - } - - if ( C->lift_method == Smits_Smith ) { - C->coefficient_lift = (0.54)*pow(C->spin_parameter, 0.4) ; - } - - if ( C->lift_method == Tombras ) { - C->coefficient_lift = 1/( 2.022 + 0.981*speed/V_MAG( C->omega)); - } - - switch ( C->lift_method ) { - - case Hard_Coded_Coefficient_Lift: - case Smits_Smith: - case Tombras: - - /* k = 1/2*rho*Cl*A*V^2 */ - k = (0.5)*C->air_density*C->coefficient_lift* - C->ball_area*speed*speed ; - - /* F = k*(w x V)/|w x V| */ - V_CROSS( w_cross_v, C->omega, C->vel ) ; - V_NORM( norm_w_cross_v, w_cross_v ) ; - V_SCALE( C->force_magnus, norm_w_cross_v, k) ; - - break ; - - case Adair_Giordano: - - V_CROSS( w_cross_v, C->omega, C->vel ) ; - k = 0.00041*C->mass ; - V_SCALE( C->force_magnus, w_cross_v, k) ; - - /* Backwards calculation for Cl */ - C->coefficient_lift = (2*k*V_MAG(w_cross_v))/ - (C->air_density*C->ball_area*speed*speed) ; - break ; - } - - C->mag_force_magnus = V_MAG( C->force_magnus ) ; - - return 0 ; -} - diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_impact_aero.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_impact_aero.c deleted file mode 100644 index 7a9843dd..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_impact_aero.c +++ /dev/null @@ -1,47 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Kaboom!!!) -***************************************************************************/ -#include -#include "../include/cannon_aero.h" -#include "sim_services/include/executive.h" -#include "sim_services/include/exec_proto.h" -#include "sim_services/include/regula_falsi.h" -#include "sim_services/include/dr_proto.h" - -double cannon_impact_aero( - - CANNON_AERO* C, - double* time, - int *event_evaluate_tgo ) - -{ - double tgo ; - - EXECUTIVE* E ; - E = exec_get_exec(); - - if( *event_evaluate_tgo ) { - - /* Calculate time to go before impact */ - C->rf.error = C->pos[0] ; - tgo = regula_falsi( *time , &(C->rf) ) ; - - } else { - - /* Ball impact */ - - reset_regula_falsi( *time , &(C->rf) ) ; - tgo = 0.0 ; - - C->vel[0] = 0.0 ; C->vel[1] = 0.0 ; C->vel[2] = 0.0 ; - C->acc[0] = 0.0 ; C->acc[1] = 0.0 ; C->acc[2] = 0.0 ; - C->g = 0.0 ; - - fprintf(stderr, "Impact time, pos : %.9lf %.9lf\n", - *time, C->pos[0] ); - - dr_record_binary( &E->record, &E->record.group[0], *time); - } - - return( tgo ) ; -} diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_impact_monte.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_impact_monte.c deleted file mode 100644 index ded47443..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_impact_monte.c +++ /dev/null @@ -1,47 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Kaboom!!!) -***************************************************************************/ -#include -#include "../include/cannon_aero.h" -#include "sim_services/include/executive.h" -#include "sim_services/include/exec_proto.h" -#include "sim_services/include/regula_falsi.h" -#include "sim_services/include/dr_proto.h" - -double cannon_impact_monte( - - CANNON_AERO* C, - double* time, - int *event_evaluate_tgo ) - -{ - double tgo ; - - EXECUTIVE* E ; - E = exec_get_exec(); - - if( *event_evaluate_tgo ) { - - /* Calculate time to go before impact */ - C->rf.error = C->pos[2] ; - tgo = regula_falsi( *time , &(C->rf) ) ; - - } else { - - /* Ball impact */ - - reset_regula_falsi( *time , &(C->rf) ) ; - tgo = 0.0 ; - - C->vel[0] = 0.0 ; C->vel[1] = 0.0 ; C->vel[2] = 0.0 ; - C->acc[0] = 0.0 ; C->acc[1] = 0.0 ; C->acc[2] = 0.0 ; - C->g = 0.0 ; - - fprintf(stderr, "Impact time, pos : %.9lf %.9lf\n", - *time, C->pos[0] ); - - dr_record_binary( &E->record.group[0], *time); - } - - return( tgo ) ; -} diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_init_aero.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_init_aero.c deleted file mode 100644 index 7dede4ab..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_init_aero.c +++ /dev/null @@ -1,19 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: ( Cannon initialization ) -***************************************************************************/ -#include -#include - -#include "../include/cannon_aero.h" -#include "trick_utils/math/include/trick_math.h" - -int cannon_init_aero( - CANNON_AERO* C) -{ - /* Convert omega from spherical (almost) to rectangular */ - C->omega[0] = C->omega0*sin(M_PI/2.0 - C->phi)*cos(C->theta) ; - C->omega[1] = C->omega0*sin(M_PI/2.0 - C->phi)*sin(C->theta) ; - C->omega[2] = C->omega0*cos(M_PI/2.0 - C->phi) ; - - return ( 0 ); -} diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_integ_aero.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_integ_aero.c deleted file mode 100644 index dda10dc8..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_integ_aero.c +++ /dev/null @@ -1,43 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Cannon integration) -***************************************************************************/ - -#include "sim_services/include/integrator.h" -#include "../include/cannon_aero.h" - -int cannon_integ_aero( - - INTEGRATOR *I, - CANNON_AERO* C) -{ - - /* LOAD STATES (Example Below) */ - I->state[0] = C->pos[0] ; - I->state[1] = C->pos[1] ; - I->state[2] = C->pos[2] ; - I->state[3] = C->vel[0] ; - I->state[4] = C->vel[1] ; - I->state[5] = C->vel[2] ; - - /* LOAD DERIVATIVES (Example Below) */ - I->deriv[I->intermediate_step][0] = C->vel[0] ; - I->deriv[I->intermediate_step][1] = C->vel[1] ; - I->deriv[I->intermediate_step][2] = C->vel[2] ; - I->deriv[I->intermediate_step][3] = C->acc[0] ; - I->deriv[I->intermediate_step][4] = C->acc[1] ; - I->deriv[I->intermediate_step][5] = C->acc[2] ; - - integrate( I ) ; - - /* UNLOAD NEW STATES (Example Below) */ - C->pos[0] = I->state_ws[I->intermediate_step][0] ; - C->pos[1] = I->state_ws[I->intermediate_step][1] ; - C->pos[2] = I->state_ws[I->intermediate_step][2] ; - C->vel[0] = I->state_ws[I->intermediate_step][3] ; - C->vel[1] = I->state_ws[I->intermediate_step][4] ; - C->vel[2] = I->state_ws[I->intermediate_step][5] ; - - - /* RETURN */ - return ( I->intermediate_step ) ; -} diff --git a/trick_test/requirements_testing/models/test10/aero/src/cannon_jet_control.c b/trick_test/requirements_testing/models/test10/aero/src/cannon_jet_control.c deleted file mode 100644 index d43f819f..00000000 --- a/trick_test/requirements_testing/models/test10/aero/src/cannon_jet_control.c +++ /dev/null @@ -1,25 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Controls when jets are fired) -***************************************************************************/ -#include "../include/cannon_aero.h" -#include "sim_services/include/exec_proto.h" -#include "trick_utils/math/include/trick_math.h" - -int cannon_jet_control( CANNON_AERO* C ) -{ - double sim_time ; - -#define CANNON_EQUALS(X,Y) ( fabs(X - Y) < 1.0e-9 ) ? 1 : 0 - - sim_time = exec_get_sim_time(); - - if ( CANNON_EQUALS(sim_time, roundoff(0.1, C->time_to_fire_jet_1)) || - CANNON_EQUALS(sim_time, roundoff(0.1, C->time_to_fire_jet_2)) || - CANNON_EQUALS(sim_time, roundoff(0.1, C->time_to_fire_jet_3)) || - CANNON_EQUALS(sim_time, roundoff(0.1, C->time_to_fire_jet_4)) ) { - - C->jet_on = 1 ; - - } - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test10/optim/.checksums b/trick_test/requirements_testing/models/test10/optim/.checksums deleted file mode 100644 index 935072ca..00000000 --- a/trick_test/requirements_testing/models/test10/optim/.checksums +++ /dev/null @@ -1,7 +0,0 @@ -3416 35 ./src/amoeba.c -29228 1 ./src/cannon_init_amoeba.c -14437 3 ./src/cannon_post_master.c -47141 2 ./src/cannon_post_slave.c -30034 8 ./src/cannon_pre_master.c -54259 2 ./src/cannon_pre_slave.c -5447 6 ./include/amoeba.h diff --git a/trick_test/requirements_testing/models/test10/optim/include/amoeba.h b/trick_test/requirements_testing/models/test10/optim/include/amoeba.h deleted file mode 100644 index c255be24..00000000 --- a/trick_test/requirements_testing/models/test10/optim/include/amoeba.h +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Vetter's implementation of the Nelder-Mead "amoeba" algorithm. - * Was made strictly for Trick tutorial. Was a whim. - * Reference for algorithm (not code): - * http://www.research.ibm.com/infoecon/paps/html/amec99_bundle/node8.html - */ - -#ifndef __amoeba__ -#define __amoeba__ - -#define AMOEBA_ALPHA 1.0 /* reflection constant */ -#define AMOEBA_BETA 1.0 /* expansion constant */ -#define AMOEBA_ZETA 0.5 /* contraction constant */ -#define AMOEBA_ETA 0.5 /* shrinkage constant */ - -typedef enum { - - VERTICES, - CALC_CENTROID_POINT, - CALC_REFLECTION_POINT, - REFLECT, - EXPAND, - CONTRACT, - SHRINK, - -} AMOEBA_STATE ; - -typedef struct { - int debug ; /* -- Turn on some printing */ - int max_steps ; /* -- Even if we don't find solution, break */ - int num_dims ; /* -- Num dims of each vertice */ - int num_vertices ; /* -- Num vertices in simplex */ - double epsilon ; /* -- Bail if max dist simplex < epsilon */ - double** vertices ; /* -- Rows are vectors of num_dims */ - double** init_simplex ; /* -- Initial simplex */ - double* x_cent ; /* -- Center of vertices-exclude worst vertex */ - double* x_refl ; /* -- Point of reflection */ - double* x_expa ; /* -- Point of expansion */ - double* x_cont ; /* -- Point of contraction */ - double* curr_point ; /* -- Current point of interest for sim use: - Simplex vertice, centroid, reflection, - expansion or contraction point */ - int curr_vertex ; /* -- Current vertex for sim state machine */ - AMOEBA_STATE state ; /* -- For sim's amoeba state machine */ -} AMOEBA ; - -/* Prototypes */ -void amoeba_init( AMOEBA* A, int num_dims, double epsilon, int max_steps, - double* simplex_point, double simplex_size ) ; -void amoeba_print( AMOEBA* A ) ; -void amoeba_print_point( int num_dims, double* point ) ; -void amoeba_go( AMOEBA* A ) ; -double my_func( double* point ) ; -void amoeba_quit( AMOEBA* A ) ; -void amoeba_order( AMOEBA* A ) ; -int amoeba_reflect( AMOEBA* A ) ; -void amoeba_calc_reflection_point( AMOEBA* A ) ; -int amoeba_expand( AMOEBA* A ) ; -void amoeba_calc_expansion_point( AMOEBA* A ) ; -int amoeba_contract( AMOEBA* A ) ; -void amoeba_calc_contraction_point( AMOEBA* A ) ; -void amoeba_shrink( AMOEBA* A ) ; -int amoeba_satisfied( AMOEBA* A ) ; -double amoeba_distance_between( int num_dims, double* x, double* y) ; -int amoeba_compare_vertices( const void* a, const void* b) ; - -#endif diff --git a/trick_test/requirements_testing/models/test10/optim/src/amoeba.c b/trick_test/requirements_testing/models/test10/optim/src/amoeba.c deleted file mode 100644 index 7e759723..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/amoeba.c +++ /dev/null @@ -1,566 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: ( Amoeba ) -***************************************************************************/ - -#include -#include -#include -#include "../include/amoeba.h" - -double my_func( double* point ) { - - /* In the case of the simulation, the function value is - * actually stored in the point - */ - int num_dims = 4 ; - - return( point[num_dims] ) ; -} - -void amoeba_go( AMOEBA* A ) { - - int step ; - - step = 1 ; - while( ! amoeba_satisfied(A) && step < A->max_steps ) { - - step++ ; - - amoeba_order( A ) ; - - if ( amoeba_reflect( A ) ) { - continue ; - } - if ( amoeba_expand( A ) ) { - continue ; - } - if ( amoeba_contract( A ) ) { - continue ; - } - - amoeba_shrink( A ) ; - } - amoeba_order( A ) ; - - fprintf(stderr,"\n\nAmoeba search concluded.\n") ; - fprintf(stderr,"Number iterations: %d \n", step) ; - fprintf(stderr,"x=("); - amoeba_print_point( A->num_dims, A->vertices[0] ) ; - fprintf(stderr,")\n"); - fprintf(stderr,"F(x)=%.6lf\n\n", my_func(A->vertices[0])); -} - -void amoeba_shrink( AMOEBA* A ) { - - int ii, jj ; - - double* x ; - double* x_0 ; - double* x_n ; - - x_0 = A->vertices[0] ; - x_n = A->vertices[A->num_dims] ; - - if ( A->debug ) { - fprintf(stderr,"Shrinking simplex...\n"); - amoeba_print( A ) ; - fprintf(stderr,"\n\n"); - } - - for ( ii = 0 ; ii < A->num_vertices ; ii++ ) { - x = A->vertices[ii] ; - for ( jj = 0 ; jj < A->num_dims ; jj++ ) { - x[jj] = x_0[jj] + AMOEBA_ETA*( x[jj] - x_0[jj] ) ; - } - } - - if ( A->debug ) { - fprintf(stderr,"Shrank simplex.\n"); - amoeba_print( A ) ; - fprintf(stderr,"\n\n"); - } -} - -void amoeba_calc_contraction_point( AMOEBA* A ) { - - int ii ; - double* x_c ; - double* x_n ; - double* x_cont ; - - /* Short hand */ - x_c = A->x_cent ; - x_n = A->vertices[A->num_vertices-1] ; - x_cont = A->x_cont ; - - /* Calculate contraction point - * x_contract = x_center + zeta*(x_center - x_worst) - */ - for ( ii = 0 ; ii < A->num_dims ; ii++ ) { - x_cont[ii] = x_c[ii] + AMOEBA_ZETA*(x_c[ii] - x_n[ii]) ; - } -} - - -int amoeba_contract( AMOEBA* A ) { - - int ii ; - double* x_r ; - double* x_n ; - double* x_n_1 ; - double* x_c ; - double* x_cont ; - double* x_e ; - - /* Short hand */ - x_c = A->x_cent ; - x_r = A->x_refl ; - x_n = A->vertices[A->num_vertices-1] ; - x_n_1 = A->vertices[A->num_vertices-2] ; - x_cont = A->x_cont ; - x_e = A->x_expa ; - - if ( A->debug ) { - fprintf(stderr,">> Try contraction.\n"); - } - - /* Contract if F(x_r) < F(x_n-1) */ - if ( my_func(x_r) >= my_func(x_n_1) ) { - if ( A->debug ) { - fprintf(stderr,">> Reject contraction.\n"); - } - return 0 ; - } - - /* Calculate contraction point - * x_contract = x_center + zeta*(x_center - x_worst) - */ - for ( ii = 0 ; ii < A->num_dims ; ii++ ) { - x_cont[ii] = x_c[ii] + AMOEBA_ZETA*(x_c[ii] - x_n[ii]) ; - } - - if ( my_func(x_cont) >= my_func(x_n) ) { - /* Accept contraction point */ - - if ( A->debug ) { - fprintf(stderr,">> Accept contraction about x_cont("); - amoeba_print_point( A->num_dims, x_cont ) ; - fprintf(stderr,") F(x_cont)=%.2lf \n", - my_func(x_cont) ) ; - } - - for ( ii = 0 ; ii < A->num_dims+1 ; ii++ ) { - x_n[ii] = x_cont[ii] ; - } - - return 1 ; - - } else { - /* Reject contraction point */ - if ( A->debug ) { - fprintf(stderr,">> Reject contraction about x_cont("); - amoeba_print_point( A->num_dims, x_cont ) ; - fprintf(stderr,") F(x_cont)=%.2lf \n", - my_func(x_cont) ) ; - } - - return 0 ; - } - -} - -void amoeba_calc_expansion_point( AMOEBA* A ) { - - int ii ; - double* x_r ; - double* x_c ; - double* x_e ; - - /* Short hand */ - x_r = A->x_refl ; - x_c = A->x_cent ; - x_e = A->x_expa ; - - /* Calculate expansion point - * x_expa = x_refl + beta*(x_refl - x_cent) - */ - for ( ii = 0 ; ii < A->num_dims ; ii++ ) { - x_e[ii] = x_r[ii] + AMOEBA_BETA*(x_r[ii] - x_c[ii]) ; - } -} - - -int amoeba_expand( AMOEBA* A ) { - - int ii ; - double* x_0 ; - double* x_r ; - double* x_n ; - double* x_c ; - double* x_e ; - - /* Short hand */ - x_0 = A->vertices[0] ; - x_r = A->x_refl ; - x_n = A->vertices[A->num_vertices-1] ; - x_c = A->x_cent ; - x_e = A->x_expa ; - - if ( A->debug ) { - fprintf(stderr,">> Try expansion.\n"); - } - - /* Expand if F(x_r) > F(x_0) */ - if ( my_func(x_r) <= my_func(x_0) ) { - if ( A->debug ) { - fprintf(stderr,">> Reject expansion.\n"); - } - return 0 ; - } - - if ( A->debug ) { - fprintf(stderr,">> Accept expansion.\n"); - } - - if ( my_func(x_e) >= my_func(x_r) ) { - /* Accept expansion point */ - if ( A->debug ) { - fprintf(stderr,"Accept x_e("); - amoeba_print_point( A->num_dims, x_e ) ; - fprintf(stderr,") F(x_e)=%.2lf \n", my_func(x_e) ) ; - } - - for ( ii = 0 ; ii < A->num_dims+1 ; ii++ ) { - x_n[ii] = x_e[ii] ; - } - } else { - /* Accept reflection point */ - if ( A->debug ) { - fprintf(stderr,"Accept x_r("); - amoeba_print_point( A->num_dims, x_r ) ; - fprintf(stderr,") F(x_r)=%.2lf \n", my_func(x_r) ) ; - } - for ( ii = 0 ; ii < A->num_dims+1 ; ii++ ) { - x_n[ii] = x_r[ii] ; - } - } - - return 1 ; -} - -double amoeba_distance_between( int num_dims, double* x, double* y ) { - - int ii ; - double sum_squares ; - - sum_squares = 0 ; - for ( ii = 0 ; ii < num_dims ; ii++ ) { - sum_squares += (x[ii] - y[ii])*(x[ii] - y[ii]); - } - - return ( sqrt(sum_squares) ) ; -} - -int amoeba_satisfied( AMOEBA* A ) { - - /* - * Find max distance between points in the simplex - * If under epsilon, amoeba satisfied - * If this isn't satisfied, see if F(x) satisfied within epsilon - */ - - int ii, jj ; - double dist, max_dist ; - double* x ; - double* y ; - double f1 ; - double f2 ; - - /* - * Check max dist between points in simplex - * If the amoeba gets too small, no point in shrinking - * infintessimally (sp?). - */ - max_dist = 0.0 ; - for ( ii = 0 ; ii < A->num_vertices - 1 ; ii++ ) { - x = A->vertices[ii] ; - for ( jj = ii+1 ; jj < A->num_vertices ; jj++ ) { - y = A->vertices[jj] ; - dist = amoeba_distance_between( A->num_dims, x, y ) ; - if ( dist > max_dist ) { - max_dist = dist ; - } - } - } - if ( max_dist < A->epsilon ) { - return 1 ; - } - - /* - * See if diff between function vals less than epsilon - */ - max_dist = 0 ; - for ( ii = 0 ; ii < A->num_vertices - 1 ; ii++ ) { - f1 = A->vertices[ii][A->num_dims] ; - for ( jj = ii+1 ; jj < A->num_vertices ; jj++ ) { - f2 = A->vertices[jj][A->num_dims] ; - dist = fabs( f1 - f2 ) ; - if ( dist > max_dist ) { - max_dist = dist ; - } - } - } - if ( max_dist < A->epsilon ) { - return 1 ; - } - - /* - * Unsatisfied amoeba :-( - */ - return 0 ; -} - -void amoeba_calc_reflection_point( AMOEBA* A ) { - - int ii ; - double* x_r ; - double* x_n ; - double* x_c ; - - /* Short hand */ - x_r = A->x_refl ; - x_n = A->vertices[A->num_vertices-1] ; - x_c = A->x_cent ; - - /* Calculate reflection point - * x_refl = x_cent + alpha*(x_cent - x_worst) - */ - for ( ii = 0 ; ii < A->num_dims ; ii++ ) { - x_r[ii] = x_c[ii] + AMOEBA_ALPHA*(x_c[ii] - x_n[ii]) ; - } -} - - -int amoeba_reflect( AMOEBA* A ) { - - int ii ; - double* x_0 ; - double* x_r ; - double* x_n ; - double* x_c ; - - if ( A->debug ) { - fprintf(stderr,">> Try reflection.\n"); - } - - /* Short hand */ - x_0 = A->vertices[0] ; - x_r = A->x_refl ; - x_n = A->vertices[A->num_vertices-1] ; - x_c = A->x_cent ; - - if ( my_func(x_0) >= my_func(x_r) && my_func(x_r) > my_func(x_n) ) { - /* Accept reflection point --- replace worst point with x_r */ - if ( A->debug ) { - fprintf(stderr,"Accept reflection x_r("); - amoeba_print_point( A->num_dims, x_r ) ; - fprintf(stderr,") F(x_r)=%.2lf \n", my_func(x_r) ) ; - } - for ( ii = 0 ; ii < A->num_dims+1 ; ii++ ) { - x_n[ii] = x_r[ii] ; - } - return 1 ; - } else { - if ( A->debug ) { - fprintf(stderr,"Reject reflection x_r("); - amoeba_print_point( A->num_dims, x_r ) ; - fprintf(stderr,") F(x_r)=%.2lf \n", my_func(x_r) ) ; - } - return 0 ; - } -} - -void amoeba_order( AMOEBA* A ) { - - int ii, jj ; - - /* Order vertices based on function results. - * Order from best to worst (i.e. max to min) - */ - qsort( A->vertices, - A->num_vertices, sizeof(double*), - amoeba_compare_vertices) ; - - /* Calculate centroid --- excluding worst point */ - for ( jj = 0 ; jj < A->num_dims ; jj++ ) { - A->x_cent[jj] = 0 ; - } - for ( jj = 0 ; jj < A->num_dims ; jj++ ) { - for ( ii = 0 ; ii < A->num_vertices - 1 ; ii++ ) { - A->x_cent[jj] += A->vertices[ii][jj] ; - } - A->x_cent[jj] /= (double)(A->num_vertices - 1.0 ) ; - } - - if ( A->debug ) { - - fprintf(stderr,"Ordered Amoeba.\n"); - amoeba_print( A ) ; - fprintf(stderr,"\n"); - } -} - -int amoeba_compare_vertices( const void* ap, const void* bp ) { - - double a, b ; - - a = my_func( *((double**) ap) ) ; - b = my_func( *((double**) bp) ) ; - - if ( a > b ) { - return -1 ; - } else if ( a < b ) { - return 1 ; - } else { - return 0 ; - } -} - -/* - * num_dims: Number of dimensions in domain space. - * Example: If the function we are maximizing is F(x,y,z) - * The number of dims is 3. - * - * epsilon: The error tolerance before amoeba algorithm stops - * A good number is something like: 1.0e-9 - * - * max_steps: Even if we don't reach a solution by "max_steps", stop. - * - * We have to create a first simplex to begin amoeba algorithm. - * There are two ways to do this. - * First : Send simplex_point and simplex_size - * This defines a simplex with one vertex at "simplex_point" - * All other points are spaced "simplex_size" in the unit vec direction - * Second : If "simplex_point" is NULL, it is assumed user setup - * A->init_simplex before entering amoeba_init. - */ -void amoeba_init( AMOEBA* A, int num_dims, double epsilon, int max_steps, - double* simplex_point, double simplex_size ) { - - int ii, jj ; - - if ( A->init_simplex == NULL && simplex_point == NULL ) { - fprintf(stderr, "Initial simplex undefined by user.\n" - "Set A->init_simplex or " - "simplex_point and simplex_size\n") ; - exit(-1) ; - } - - A->state = VERTICES ; - A->num_dims = num_dims ; - A->num_vertices = num_dims + 1 ; - A->curr_vertex = 0 ; - A->epsilon = epsilon ; - A->max_steps = max_steps ; - - A->vertices = (double**) malloc (A->num_vertices*sizeof(double)); - for ( ii = 0 ; ii < A->num_vertices ; ii++ ) { - A->vertices[ii] = (double*) malloc - ((A->num_dims+1)*sizeof(double)); - } - - if ( simplex_point != NULL ) { - - /* - * Use "simplex_point" as one vertice of first simplex. Then - * move in "simplex_size" along unit vectors to create the - * rest of the first guess simplex. - * - * First_simplex = simplex_point + simplex_size*unit_vecs - */ - for ( jj = 0 ; jj < A->num_dims ; jj++ ) { - A->vertices[0][jj] = simplex_point[jj] ; - } - /* Load function vals with zero */ - A->vertices[0][jj] = 0.0 ; - - for ( ii = 1 ; ii < A->num_vertices ; ii++ ) { - for ( jj = 0 ; jj < A->num_dims ; jj++ ) { - if ( jj+1 == ii ) { - A->vertices[ii][jj] = - simplex_point[jj] - simplex_size ; - } else { - A->vertices[ii][jj] = simplex_point[jj] ; - } - } - /* Load function vals with zero */ - A->vertices[ii][jj] = 0.0 ; - } - - } else { - - /* Assume user has defined first simplex */ - for ( ii = 0 ; ii < A->num_vertices ; ii++ ) { - for ( jj = 0 ; jj < A->num_dims ; jj++ ) { - A->vertices[ii][jj] = A->init_simplex[ii][jj] ; - } - /* Load function vals with zero */ - A->vertices[ii][jj] = 0.0 ; - } - } - - A->x_cent = (double*) malloc ( (A->num_dims+1) * sizeof(double) ) ; - A->x_refl = (double*) malloc ( (A->num_dims+1) * sizeof(double) ) ; - A->x_expa = (double*) malloc ( (A->num_dims+1) * sizeof(double) ) ; - A->x_cont = (double*) malloc ( (A->num_dims+1) * sizeof(double) ) ; - - /* Init func results */ - A->x_cent[A->num_dims] = 0.0 ; - A->x_refl[A->num_dims] = 0.0 ; - A->x_expa[A->num_dims] = 0.0 ; - A->x_cont[A->num_dims] = 0.0 ; - - - if ( A->debug ) { - fprintf(stderr,"Initial simplex with function evals.\n"); - amoeba_print( A ) ; - fprintf(stderr,"\n\n"); - } -} - -void amoeba_quit( AMOEBA* A ) { - - int ii ; - - for ( ii = 0 ; ii < A->num_vertices ; ii++ ) { - free( A->vertices[ii] ) ; - } - free( A->vertices ) ; - free( A->x_cent ) ; - free( A->x_refl ) ; - free( A->x_expa ) ; - free( A->x_cont ) ; -} - -void amoeba_print_point( int num_dims, double* point ) { - - int ii; - - for ( ii = 0 ; ii < num_dims-1 ; ii++ ) { - fprintf(stderr,"%.2lf ", point[ii]); - } - fprintf(stderr,"%.2lf", point[num_dims-1]); -} - -void amoeba_print( AMOEBA* A ) { - - int ii, jj ; - - for ( ii = 0 ; ii < A->num_vertices ; ii++ ) { - for ( jj = 0 ; jj < A->num_dims ; jj++ ) { - fprintf(stderr,"%.2lf ", A->vertices[ii][jj] ) ; - } - fprintf(stderr," > %.2lf \n", A->vertices[ii][jj]); - } - -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_init_amoeba.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_init_amoeba.c deleted file mode 100644 index 214f8886..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_init_amoeba.c +++ /dev/null @@ -1,15 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: ( Init the Amoeba ) -LIBRARY DEPENDENCY: ((amoeba.o)) -PROGRAMMERS: (Keith) -***************************************************************************/ -#include -#include "../../aero/include/cannon_aero.h" -#include "../include/amoeba.h" - -int cannon_init_amoeba( - AMOEBA* A ) -{ - amoeba_init( A, 4, 1.0e-3, 100, NULL, 0.0 ) ; - return ( 0 ); -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_master_shutdown.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_master_shutdown.c deleted file mode 100644 index 7fe14f02..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_master_shutdown.c +++ /dev/null @@ -1,7 +0,0 @@ -#include "../../aero/include/cannon_aero.h" - -int cannon_master_shutdown(CANNON_AERO *C) { - C->master_shutdown = 1; - printf("cannon_master_shutdown called \n"); - return 0; -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_post_master.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_post_master.c deleted file mode 100644 index 000f1a9d..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_post_master.c +++ /dev/null @@ -1,35 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Read slave's sim evaluation) -LIBRARY DEPENDENCY: ((amoeba.o)) -PROGRAMMER: ((keith)) -***************************************************************************/ -#include -#include "../../aero/include/cannon_aero.h" -#include "../include/amoeba.h" -#include "sim_services/include/executive.h" -#include "sim_services/include/exec_proto.h" - -int cannon_post_master( - CANNON_AERO* C, - AMOEBA* A ) -{ - CANNON_AERO C_curr ; - EXECUTIVE* E ; - E = exec_get_exec(); - - /* Read slave's results */ - tc_read( &E->monte.work.data_conn, - (char*) &C_curr, sizeof(CANNON_AERO) ); - - fprintf(stderr, "%03d> F(", E->monte.work.curr_run); - amoeba_print_point(4, A->curr_point) ; - fprintf(stderr, ") = %.6lf\n", C_curr.pos[0]); - - /* - * Load function result for either: - * simplex vertice, centroid, reflection, contraction or expansion point - */ - A->curr_point[A->num_dims] = C_curr.pos[0] ; - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_post_slave.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_post_slave.c deleted file mode 100644 index 718c4565..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_post_slave.c +++ /dev/null @@ -1,20 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Get slave sim's evaluation of x) -***************************************************************************/ -#include "../../aero/include/cannon_aero.h" -#include "sim_services/include/executive.h" -#include "sim_services/include/exec_proto.h" - -int cannon_post_slave( - /* RETURN: -- Always return zero */ - CANNON_AERO* C) /* INOUT: -- Parameter */ - -{ - EXECUTIVE* E ; - E = exec_get_exec(); - - /* Send slave results */ - tc_write( &E->monte.work.data_conn, (char*) C, sizeof(CANNON_AERO) ); - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_pre_master.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_pre_master.c deleted file mode 100644 index 245625df..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_pre_master.c +++ /dev/null @@ -1,105 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Master optimization) -LIBRARY_DEPENDENCY: (amoeba.o) -PROGRAMMER: (keith) -***************************************************************************/ -#include -#include "../../aero/include/cannon_aero.h" -#include "../include/amoeba.h" -#include "sim_services/include/executive.h" -#include "sim_services/include/exec_proto.h" - -int cannon_pre_master( - /* RETURN: -- Always return zero */ - CANNON_AERO* C, /* INOUT: -- Parameter */ - AMOEBA* A) -{ - - while ( 1 ) { - - switch ( A->state ) { - - case VERTICES: - A->curr_point = A->vertices[A->curr_vertex] ; - if ( A->curr_vertex == A->num_vertices ) { - A->state = CALC_CENTROID_POINT ; - } else { - fprintf(stderr, "V[%d] ", A->curr_vertex); - } - A->curr_vertex++ ; - break ; - - case CALC_CENTROID_POINT: - fprintf(stderr, "CENT "); - amoeba_order( A ) ; - A->curr_point = A->x_cent ; - A->state = CALC_REFLECTION_POINT ; - break ; - - case CALC_REFLECTION_POINT: - fprintf(stderr, "REFL "); - amoeba_calc_reflection_point( A ) ; - A->curr_point = A->x_refl ; - A->state = REFLECT ; - break ; - - case REFLECT: - if ( amoeba_reflect( A ) ) { - A->state = CALC_CENTROID_POINT ; - } else { - fprintf(stderr, "EXPA "); - amoeba_calc_expansion_point( A ) ; - A->curr_point = A->x_expa ; - A->state = EXPAND ; - } - break ; - - case EXPAND: - if ( amoeba_expand( A ) ) { - A->state = CALC_CENTROID_POINT ; - } else { - fprintf(stderr, "CONT "); - amoeba_calc_contraction_point( A ) ; - A->curr_point = A->x_cont ; - A->state = CONTRACT ; - } - break ; - - case CONTRACT: - if ( amoeba_contract( A ) ) { - A->state = CALC_CENTROID_POINT ; - } else { - A->state = SHRINK ; - } - break ; - - case SHRINK: - amoeba_shrink( A ) ; - fprintf(stderr, "V[0] "); - A->curr_point = A->vertices[0] ; - A->curr_vertex = 1 ; - A->state = VERTICES ; - break ; - } - - if ( amoeba_satisfied( A ) && A->state != VERTICES ) { - exec_terminate( "cannon_pre_master", - "Amoeba has found a solution." ) ; - } - - if ( A->state == CALC_CENTROID_POINT || - A->state == SHRINK ) { - continue ; - } else { - break ; - } - } - - - C->time_to_fire_jet_1 = A->curr_point[0] ; - C->time_to_fire_jet_2 = A->curr_point[1] ; - C->time_to_fire_jet_3 = A->curr_point[2] ; - C->time_to_fire_jet_4 = A->curr_point[3] ; - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_pre_slave.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_pre_slave.c deleted file mode 100644 index 589904ef..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_pre_slave.c +++ /dev/null @@ -1,23 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Slave optimization) -LIBRARY_DEPENDENCY: (amoeba.o) -PROGRAMMER: (keith) -***************************************************************************/ -#include "../../aero/include/cannon_aero.h" -#include "sim_services/include/executive.h" -#include "sim_services/include/exec_proto.h" -#include - -int cannon_pre_slave( - /* RETURN: -- Always return zero */ - CANNON_AERO* C) /* INOUT: -- Parameter */ - -{ - fprintf(stderr, "SLAVE POINT: (%.6lf %.6lf %.6lf %.6lf)\n", - C->time_to_fire_jet_1, - C->time_to_fire_jet_2, - C->time_to_fire_jet_3, - C->time_to_fire_jet_4) ; - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_slave_init.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_slave_init.c deleted file mode 100644 index 6e565b0a..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_slave_init.c +++ /dev/null @@ -1,7 +0,0 @@ -#include "../../aero/include/cannon_aero.h" - -int cannon_slave_init(CANNON_AERO *C) { - C->slave_init = 1; - printf("cannon_slave_init called\n"); - return 0; -} diff --git a/trick_test/requirements_testing/models/test10/optim/src/cannon_slave_shutdown.c b/trick_test/requirements_testing/models/test10/optim/src/cannon_slave_shutdown.c deleted file mode 100644 index cea27308..00000000 --- a/trick_test/requirements_testing/models/test10/optim/src/cannon_slave_shutdown.c +++ /dev/null @@ -1,7 +0,0 @@ -#include "../../aero/include/cannon_aero.h" - -int cannon_slave_shutdown(CANNON_AERO *C) { - C->slave_shutdown = 1; - printf("cannon_slave_shutdown called\n"); - return 0; -} diff --git a/trick_test/requirements_testing/models/test11/src/test11_nano.c b/trick_test/requirements_testing/models/test11/src/test11_nano.c deleted file mode 100644 index 4d787f53..00000000 --- a/trick_test/requirements_testing/models/test11/src/test11_nano.c +++ /dev/null @@ -1,6 +0,0 @@ -/******************************************************************************* -PURPOSE: (Tests requirement 3.7.6) -*******************************************************************************/ - -int test11_nano() { -} diff --git a/trick_test/requirements_testing/models/test11/src/test11_sched.c b/trick_test/requirements_testing/models/test11/src/test11_sched.c deleted file mode 100644 index ac108e21..00000000 --- a/trick_test/requirements_testing/models/test11/src/test11_sched.c +++ /dev/null @@ -1,15 +0,0 @@ -/******************************************************************************* -PURPOSE: (Tests requirements: 3.7.1, 3.7.4-6, 3.7.1.1, 3.7.4.1-3, 3.7.4.3.1-2, - 3.7.5.1-2) -*******************************************************************************/ - -#include - -int test11_sched() { - struct timeval wait; - wait.tv_sec = 0; - wait.tv_usec = 55000; - - select(0, 0, 0, 0, &wait); - return(0); -} diff --git a/trick_test/requirements_testing/models/test12/include/test12.h b/trick_test/requirements_testing/models/test12/include/test12.h deleted file mode 100644 index 23ab2cbe..00000000 --- a/trick_test/requirements_testing/models/test12/include/test12.h +++ /dev/null @@ -1,10 +0,0 @@ -#ifndef _test12_h_ -#define _test12_h_ - -typedef struct { - double i; -} TEST12; - - - -#endif diff --git a/trick_test/requirements_testing/models/test12/src/test12_init.c b/trick_test/requirements_testing/models/test12/src/test12_init.c deleted file mode 100644 index 3c7096f0..00000000 --- a/trick_test/requirements_testing/models/test12/src/test12_init.c +++ /dev/null @@ -1 +0,0 @@ -int test12_init() {} diff --git a/trick_test/requirements_testing/models/test12/src/test12_init2.c b/trick_test/requirements_testing/models/test12/src/test12_init2.c deleted file mode 100644 index 7ecb83a1..00000000 --- a/trick_test/requirements_testing/models/test12/src/test12_init2.c +++ /dev/null @@ -1 +0,0 @@ -int test12_init2() {} diff --git a/trick_test/requirements_testing/models/test12/src/test12_init3.c b/trick_test/requirements_testing/models/test12/src/test12_init3.c deleted file mode 100644 index 800e2996..00000000 --- a/trick_test/requirements_testing/models/test12/src/test12_init3.c +++ /dev/null @@ -1 +0,0 @@ -int test12_init3() {} diff --git a/trick_test/requirements_testing/models/test12/src/test12_sched.c b/trick_test/requirements_testing/models/test12/src/test12_sched.c deleted file mode 100644 index a97f299b..00000000 --- a/trick_test/requirements_testing/models/test12/src/test12_sched.c +++ /dev/null @@ -1,6 +0,0 @@ -#include "../include/test12.h" -#include "sim_services/include/exec_proto.h" - -int test12_sched(TEST12 *T) { - T->i = sin(exec_get_sim_time() * 3.14); -} diff --git a/trick_test/requirements_testing/models/test13/.checksums b/trick_test/requirements_testing/models/test13/.checksums deleted file mode 100644 index 5fbfabac..00000000 --- a/trick_test/requirements_testing/models/test13/.checksums +++ /dev/null @@ -1,4 +0,0 @@ -20793 12 ./src/ip_test.c -8488 10 ./include/ip_c_types.h -18178 28 ./include/ip_test.d -57882 9 ./include/ip_test.h diff --git a/trick_test/requirements_testing/models/test13/include/test13.d b/trick_test/requirements_testing/models/test13/include/test13.d deleted file mode 100644 index 8db3a60a..00000000 --- a/trick_test/requirements_testing/models/test13/include/test13.d +++ /dev/null @@ -1,267 +0,0 @@ -int i,j; - -TEST13.c_pointer_types.cpp = alloc(2); -TEST13.c_pointer_types.ucpp = alloc(2); -TEST13.c_pointer_types.spp = alloc(2); -TEST13.c_pointer_types.uspp = alloc(2); -TEST13.c_pointer_types.ipp = alloc(2); -TEST13.c_pointer_types.uipp = alloc(2); -TEST13.c_pointer_types.lpp = alloc(2); -TEST13.c_pointer_types.ulpp = alloc(2); -TEST13.c_pointer_types.fpp = alloc(2); -TEST13.c_pointer_types.dpp = alloc(2); -TEST13.c_pointer_types.llpp = alloc(2); -TEST13.c_pointer_types.ullpp = alloc(2); -TEST13.c_pointer_types.wcpp = alloc(2); -TEST13.c_mixed_types.cpa = alloc(2); -TEST13.c_mixed_types.ucpa = alloc(2); -TEST13.c_mixed_types.spa = alloc(2); -TEST13.c_mixed_types.uspa = alloc(2); -TEST13.c_mixed_types.ipa = alloc(2); -TEST13.c_mixed_types.uipa = alloc(2); -TEST13.c_mixed_types.lpa = alloc(2); -TEST13.c_mixed_types.ulpa = alloc(2); -TEST13.c_mixed_types.fpa = alloc(2); -TEST13.c_mixed_types.dpa = alloc(2); -TEST13.c_mixed_types.llpa = alloc(2); -TEST13.c_mixed_types.ullpa = alloc(2); -TEST13.c_mixed_types.wcpa = alloc(2); -for (i = 0; i < 2; i++) { - TEST13.c_pointer_types.cpp[i] = alloc(2); - TEST13.c_pointer_types.ucpp[i] = alloc(2); - TEST13.c_pointer_types.spp[i] = alloc(2); - TEST13.c_pointer_types.uspp[i] = alloc(2); - TEST13.c_pointer_types.ipp[i] = alloc(2); - TEST13.c_pointer_types.uipp[i] = alloc(2); - TEST13.c_pointer_types.lpp[i] = alloc(2); - TEST13.c_pointer_types.ulpp[i] = alloc(2); - TEST13.c_pointer_types.fpp[i] = alloc(2); - TEST13.c_pointer_types.dpp[i] = alloc(2); - TEST13.c_pointer_types.llpp[i] = alloc(2); - TEST13.c_pointer_types.ullpp[i] = alloc(2); - TEST13.c_pointer_types.wcpp[i] = alloc(2); - TEST13.c_mixed_types.cpa[i] = alloc(2); - TEST13.c_mixed_types.ucpa[i] = alloc(2); - TEST13.c_mixed_types.spa[i] = alloc(2); - TEST13.c_mixed_types.uspa[i] = alloc(2); - TEST13.c_mixed_types.ipa[i] = alloc(2); - TEST13.c_mixed_types.uipa[i] = alloc(2); - TEST13.c_mixed_types.lpa[i] = alloc(2); - TEST13.c_mixed_types.ulpa[i] = alloc(2); - TEST13.c_mixed_types.fpa[i] = alloc(2); - TEST13.c_mixed_types.dpa[i] = alloc(2); - TEST13.c_mixed_types.llpa[i] = alloc(2); - TEST13.c_mixed_types.ullpa[i] = alloc(2); - TEST13.c_mixed_types.wcpa[i] = alloc(2); - for (j=0; j < 2; j++) { - TEST13.c_pointer_types.cpp[i][j] = alloc(2); - TEST13.c_pointer_types.ucpp[i][j] = alloc(2); - TEST13.c_pointer_types.spp[i][j] = alloc(2); - TEST13.c_pointer_types.uspp[i][j] = alloc(2); - TEST13.c_pointer_types.ipp[i][j] = alloc(2); - TEST13.c_pointer_types.uipp[i][j] = alloc(2); - TEST13.c_pointer_types.lpp[i][j] = alloc(2); - TEST13.c_pointer_types.ulpp[i][j] = alloc(2); - TEST13.c_pointer_types.fpp[i][j] = alloc(2); - TEST13.c_pointer_types.dpp[i][j] = alloc(2); - TEST13.c_pointer_types.llpp[i][j] = alloc(2); - TEST13.c_pointer_types.ullpp[i][j] = alloc(2); - TEST13.c_pointer_types.wcpp[i][j] = alloc(2); - TEST13.c_mixed_types.cpa[i][j] = alloc(2); - TEST13.c_mixed_types.ucpa[i][j] = alloc(2); - TEST13.c_mixed_types.spa[i][j] = alloc(2); - TEST13.c_mixed_types.uspa[i][j] = alloc(2); - TEST13.c_mixed_types.ipa[i][j] = alloc(2); - TEST13.c_mixed_types.uipa[i][j] = alloc(2); - TEST13.c_mixed_types.lpa[i][j] = alloc(2); - TEST13.c_mixed_types.ulpa[i][j] = alloc(2); - TEST13.c_mixed_types.fpa[i][j] = alloc(2); - TEST13.c_mixed_types.dpa[i][j] = alloc(2); - TEST13.c_mixed_types.llpa[i][j] = alloc(2); - TEST13.c_mixed_types.ullpa[i][j] = alloc(2); - TEST13.c_mixed_types.wcpa[i][j] = alloc(2); - } -} - -TEST13.c_types.c = 'c' ; -TEST13.c_types.uc = 'u'; -TEST13.c_types.cp = "Test string." ; -TEST13.c_types.s = 0 ; -TEST13.c_types.us = 1 ; -TEST13.c_types.i = 2 ; -TEST13.c_types.ui = 3 ; -TEST13.c_types.l = 4 ; -TEST13.c_types.ul = 5 ; -TEST13.c_types.f = 6 ; -TEST13.c_types.d = 7 ; -TEST13.c_types.ll = 8 ; -TEST13.c_types.ull = 9 ; -TEST13.c_types.wc = 'W' ; -TEST13.c_types.ws = "\u65b9\u4f4d\u89d2" ; - -TEST13.c_array_types.ca[0][0][0] = 'a' , 'b' ; -TEST13.c_array_types.ca[0][1][0] = 'c' , 'd' ; -TEST13.c_array_types.ca[1][0][0] = 'e' , 'f' ; -TEST13.c_array_types.ca[1][1][0] = 'g' , 'h' ; -TEST13.c_array_types.uca[0][0][0] = 'i' , 'j' ; -TEST13.c_array_types.uca[0][1][0] = 'k' , 'l' ; -TEST13.c_array_types.uca[1][0][0] = 'm' , 'n' ; -TEST13.c_array_types.uca[1][1][0] = 'o' , 'p' ; -TEST13.c_array_types.sa[0][0][0] = 0 , 1 ; -TEST13.c_array_types.sa[0][1][0] = 2 , 3 ; -TEST13.c_array_types.sa[1][0][0] = 4 , 5 ; -TEST13.c_array_types.sa[1][1][0] = 6 , 7 ; -TEST13.c_array_types.usa[0][0][0] = 8 , 9 ; -TEST13.c_array_types.usa[0][1][0] = 10 , 11 ; -TEST13.c_array_types.usa[1][0][0] = 12 , 13 ; -TEST13.c_array_types.usa[1][1][0] = 14 , 15 ; -TEST13.c_array_types.ia[0][0][0] = 16 , 17 ; -TEST13.c_array_types.ia[0][1][0] = 18 , 19 ; -TEST13.c_array_types.ia[1][0][0] = 20 , 21 ; -TEST13.c_array_types.ia[1][1][0] = 22 , 23 ; -TEST13.c_array_types.uia[0][0][0] = 24 , 25 ; -TEST13.c_array_types.uia[0][1][0] = 26 , 27 ; -TEST13.c_array_types.uia[1][0][0] = 28 , 29 ; -TEST13.c_array_types.uia[1][1][0] = 30 , 31 ; -TEST13.c_array_types.la[0][0][0] = 32 , 33 ; -TEST13.c_array_types.la[0][1][0] = 34 , 35 ; -TEST13.c_array_types.la[1][0][0] = 36 , 37 ; -TEST13.c_array_types.la[1][1][0] = 38 , 39 ; -TEST13.c_array_types.ula[0][0][0] = 40 , 41 ; -TEST13.c_array_types.ula[0][1][0] = 42 , 43 ; -TEST13.c_array_types.ula[1][0][0] = 44 , 45 ; -TEST13.c_array_types.ula[1][1][0] = 46 , 47 ; -TEST13.c_array_types.fa[0][0][0] = 48 , 49 ; -TEST13.c_array_types.fa[0][1][0] = 50 , 51 ; -TEST13.c_array_types.fa[1][0][0] = 52 , 53 ; -TEST13.c_array_types.fa[1][1][0] = 54 , 55 ; -TEST13.c_array_types.da[0][0][0] = 56 , 57 ; -TEST13.c_array_types.da[0][1][0] = 58 , 59 ; -TEST13.c_array_types.da[1][0][0] = 60 , 61 ; -TEST13.c_array_types.da[1][1][0] = 62 , 63 ; -TEST13.c_array_types.lla[0][0][0] = 64 , 65 ; -TEST13.c_array_types.lla[0][1][0] = 66 , 67 ; -TEST13.c_array_types.lla[1][0][0] = 68 , 69 ; -TEST13.c_array_types.lla[1][1][0] = 70 , 71 ; -TEST13.c_array_types.ulla[0][0][0] = 72 , 73 ; -TEST13.c_array_types.ulla[0][1][0] = 74 , 75 ; -TEST13.c_array_types.ulla[1][0][0] = 76 , 77 ; -TEST13.c_array_types.ulla[1][1][0] = 78 , 79 ; -TEST13.c_array_types.wca[0][0][0] = 'A' , 'B' ; -TEST13.c_array_types.wca[0][1][0] = 'C' , 'D' ; -TEST13.c_array_types.wca[1][0][0] = 'E' , 'F' ; -TEST13.c_array_types.wca[1][1][0] = 'G' , 'H' ; - -TEST13.c_pointer_types.cpp[0][0][0] = "one" , "two" ; -TEST13.c_pointer_types.cpp[0][1][0] = "three" , "four" ; -TEST13.c_pointer_types.cpp[1][0][0] = "five" , "six" ; -TEST13.c_pointer_types.cpp[1][1][0] = "seven" , "eight" ; -TEST13.c_pointer_types.ucpp[0][0][0] = 'a' , 'b' ; -TEST13.c_pointer_types.ucpp[0][1][0] = 'c' , 'd' ; -TEST13.c_pointer_types.ucpp[1][0][0] = 'e' , 'f' ; -TEST13.c_pointer_types.ucpp[1][1][0] = 'g' , 'h' ; -TEST13.c_pointer_types.spp[0][0][0] = 0 , 1 ; -TEST13.c_pointer_types.spp[0][1][0] = 2 , 3 ; -TEST13.c_pointer_types.spp[1][0][0] = 4 , 5 ; -TEST13.c_pointer_types.spp[1][1][0] = 6 , 7 ; -TEST13.c_pointer_types.uspp[0][0][0] = 8 , 9 ; -TEST13.c_pointer_types.uspp[0][1][0] = 10 , 11 ; -TEST13.c_pointer_types.uspp[1][0][0] = 12 , 13 ; -TEST13.c_pointer_types.uspp[1][1][0] = 14 , 15 ; -TEST13.c_pointer_types.ipp[0][0][0] = 16 , 17 ; -TEST13.c_pointer_types.ipp[0][1][0] = 18 , 19 ; -TEST13.c_pointer_types.ipp[1][0][0] = 20 , 21 ; -TEST13.c_pointer_types.ipp[1][1][0] = 22 , 23 ; -TEST13.c_pointer_types.uipp[0][0][0] = 24 , 25 ; -TEST13.c_pointer_types.uipp[0][1][0] = 26 , 27 ; -TEST13.c_pointer_types.uipp[1][0][0] = 28 , 29 ; -TEST13.c_pointer_types.uipp[1][1][0] = 30 , 31 ; -TEST13.c_pointer_types.lpp[0][0][0] = 32 , 33 ; -TEST13.c_pointer_types.lpp[0][1][0] = 34 , 35 ; -TEST13.c_pointer_types.lpp[1][0][0] = 36 , 37 ; -TEST13.c_pointer_types.lpp[1][1][0] = 38 , 39 ; -TEST13.c_pointer_types.ulpp[0][0][0] = 40 , 41 ; -TEST13.c_pointer_types.ulpp[0][1][0] = 42 , 43 ; -TEST13.c_pointer_types.ulpp[1][0][0] = 44 , 45 ; -TEST13.c_pointer_types.ulpp[1][1][0] = 46 , 47 ; -TEST13.c_pointer_types.fpp[0][0][0] = 48 , 49 ; -TEST13.c_pointer_types.fpp[0][1][0] = 50 , 51 ; -TEST13.c_pointer_types.fpp[1][0][0] = 52 , 53 ; -TEST13.c_pointer_types.fpp[1][1][0] = 54 , 55 ; -TEST13.c_pointer_types.dpp[0][0][0] = 56 , 57 ; -TEST13.c_pointer_types.dpp[0][1][0] = 58 , 59 ; -TEST13.c_pointer_types.dpp[1][0][0] = 60 , 61 ; -TEST13.c_pointer_types.dpp[1][1][0] = 62 , 63 ; -TEST13.c_pointer_types.llpp[0][0][0] = 64 , 65 ; -TEST13.c_pointer_types.llpp[0][1][0] = 66 , 67 ; -TEST13.c_pointer_types.llpp[1][0][0] = 68 , 69 ; -TEST13.c_pointer_types.llpp[1][1][0] = 70 , 71 ; -TEST13.c_pointer_types.ullpp[0][0][0] = 72 , 73 ; -TEST13.c_pointer_types.ullpp[0][1][0] = 74 , 75 ; -TEST13.c_pointer_types.ullpp[1][0][0] = 76 , 77 ; -TEST13.c_pointer_types.ullpp[1][1][0] = 78 , 79 ; -//TEST13.c_pointer_types.wcpp[0][0][0] = "ONE" ,"TWO" ; -//TEST13.c_pointer_types.wcpp[0][1][0] = "THREE" , "FOUR" ; -//TEST13.c_pointer_types.wcpp[1][0][0] = "FIVE" , "SIX" ; -//TEST13.c_pointer_types.wcpp[1][1][0] = "SEVEN" , "EIGHT" ; -TEST13.c_pointer_types.wcpp[0][0][0] = 'S' , 'T' ; -TEST13.c_pointer_types.wcpp[0][1][0] = 'U' , 'V' ; -TEST13.c_pointer_types.wcpp[1][0][0] = 'W' , 'X' ; -TEST13.c_pointer_types.wcpp[1][1][0] = 'Y' , 'Z' ; - -TEST13.c_mixed_types.cpa[0][0][0] = "one" , "two" ; -TEST13.c_mixed_types.cpa[0][1][0] = "three" , "four" ; -TEST13.c_mixed_types.cpa[1][0][0] = "five" , "six" ; -TEST13.c_mixed_types.cpa[1][1][0] = "seven" , "eight" ; -TEST13.c_mixed_types.ucpa[0][0][0] = 'a' , 'b' ; -TEST13.c_mixed_types.ucpa[0][1][0] = 'c' , 'd' ; -TEST13.c_mixed_types.ucpa[1][0][0] = 'e' , 'f' ; -TEST13.c_mixed_types.ucpa[1][1][0] = 'g' , 'h' ; -TEST13.c_mixed_types.spa[0][0][0] = 0 , 1 ; -TEST13.c_mixed_types.spa[0][1][0] = 2 , 3 ; -TEST13.c_mixed_types.spa[1][0][0] = 4 , 5 ; -TEST13.c_mixed_types.spa[1][1][0] = 6 , 7 ; -TEST13.c_mixed_types.uspa[0][0][0] = 8 , 9 ; -TEST13.c_mixed_types.uspa[0][1][0] = 10 , 11 ; -TEST13.c_mixed_types.uspa[1][0][0] = 12 , 13 ; -TEST13.c_mixed_types.uspa[1][1][0] = 14 , 15 ; -TEST13.c_mixed_types.ipa[0][0][0] = 16 , 17 ; -TEST13.c_mixed_types.ipa[0][1][0] = 18 , 19 ; -TEST13.c_mixed_types.ipa[1][0][0] = 20 , 21 ; -TEST13.c_mixed_types.ipa[1][1][0] = 22 , 23 ; -TEST13.c_mixed_types.uipa[0][0][0] = 24 , 25 ; -TEST13.c_mixed_types.uipa[0][1][0] = 26 , 27 ; -TEST13.c_mixed_types.uipa[1][0][0] = 28 , 29 ; -TEST13.c_mixed_types.uipa[1][1][0] = 30 , 31 ; -TEST13.c_mixed_types.lpa[0][0][0] = 32 , 33 ; -TEST13.c_mixed_types.lpa[0][1][0] = 34 , 35 ; -TEST13.c_mixed_types.lpa[1][0][0] = 36 , 37 ; -TEST13.c_mixed_types.lpa[1][1][0] = 38 , 39 ; -TEST13.c_mixed_types.ulpa[0][0][0] = 40 , 41 ; -TEST13.c_mixed_types.ulpa[0][1][0] = 42 , 43 ; -TEST13.c_mixed_types.ulpa[1][0][0] = 44 , 45 ; -TEST13.c_mixed_types.ulpa[1][1][0] = 46 , 47 ; -TEST13.c_mixed_types.fpa[0][0][0] = 48 , 49 ; -TEST13.c_mixed_types.fpa[0][1][0] = 50 , 51 ; -TEST13.c_mixed_types.fpa[1][0][0] = 52 , 53 ; -TEST13.c_mixed_types.fpa[1][1][0] = 54 , 55 ; -TEST13.c_mixed_types.dpa[0][0][0] = 56 , 57 ; -TEST13.c_mixed_types.dpa[0][1][0] = 58 , 59 ; -TEST13.c_mixed_types.dpa[1][0][0] = 60 , 61 ; -TEST13.c_mixed_types.dpa[1][1][0] = 62 , 63 ; -TEST13.c_mixed_types.llpa[0][0][0] = 64 , 65 ; -TEST13.c_mixed_types.llpa[0][1][0] = 66 , 67 ; -TEST13.c_mixed_types.llpa[1][0][0] = 68 , 69 ; -TEST13.c_mixed_types.ullpa[0][0][0] = 72 , 73 ; -TEST13.c_mixed_types.ullpa[0][1][0] = 74 , 75 ; -TEST13.c_mixed_types.ullpa[1][0][0] = 76 , 77 ; -TEST13.c_mixed_types.ullpa[1][1][0] = 78 , 79 ; -TEST13.c_mixed_types.ullpa[0][0][0] = 72 , 73 ; -//TEST13.c_mixed_types.wcpa[0][1][0] = "ONE" , "TWO" ; -//TEST13.c_mixed_types.wcpa[0][1][0] = "THREE" , "FOUR" ; -//TEST13.c_mixed_types.wcpa[0][1][0] = "FIVE" , "SIX" ; -//TEST13.c_mixed_types.wcpa[0][1][0] = "SEVEN" , "EIGHT" ; -TEST13.c_mixed_types.wcpa[0][1][0] = 'S' , 'T' ; -TEST13.c_mixed_types.wcpa[0][1][0] = 'U' , 'V' ; -TEST13.c_mixed_types.wcpa[0][1][0] = 'W' , 'X' ; -TEST13.c_mixed_types.wcpa[0][1][0] = 'Y' , 'Z' ; diff --git a/trick_test/requirements_testing/models/test13/include/test13.h b/trick_test/requirements_testing/models/test13/include/test13.h deleted file mode 100644 index 3eba2b0c..00000000 --- a/trick_test/requirements_testing/models/test13/include/test13.h +++ /dev/null @@ -1,79 +0,0 @@ -#ifndef _test13_h_ -#define _test13_h_ - -#include - -typedef struct { /*---- FUNDAMENTAL 'C' DATA TYPES ----------------------------*/ - char c ; /* -- character */ - unsigned char uc ; /* -- unsigned character */ - char * cp ; /* -- string */ - short s ; /* -- short integer */ - unsigned short us ; /* -- unsigned short integer */ - int i ; /* -- integer */ - unsigned int ui ; /* -- unsigned integer */ - long l ; /* -- long integer */ - unsigned long ul ; /* -- unsigned long integer */ - float f ; /* -- single precision floating point value */ - double d ; /* -- double precision floating point value */ - long long ll ; /* -- long long */ - unsigned long long ull ; /* -- unsigned long long */ - wchar_t wc ; /* -- wide character */ - wchar_t * ws ; /* -- wide string */ -} C_TYPES ; /*----------------------------------------------------------------*/ - -typedef struct { /*---- ARRAYS ------------------------------------------------*/ - char ca[2][2][2] ; /* -- characters */ - unsigned char uca[2][2][2] ; /* -- unsigned characters */ - short sa[2][2][2] ; /* -- short integers */ - unsigned short usa[2][2][2] ; /* -- unsigned short integers */ - int ia[2][2][2] ; /* -- integers */ - unsigned int uia[2][2][2] ; /* -- unsigned integers */ - long la[2][2][2] ; /* -- long integers */ - unsigned long ula[2][2][2] ; /* -- unsigned long integers */ - float fa[2][2][2] ; /* -- single precision floating point */ - double da[2][2][2] ; /* -- double precision floating point */ - long long lla[2][2][2] ; /* -- long longs */ - unsigned long long ulla[2][2][2] ; /* -- unsigned long longs */ - wchar_t wca[2][2][2] ; /* -- wide characters */ -} C_ARR_TYPES ; /*------------------------------------------------------------*/ - -typedef struct { /*---- POINTERS -- UNCONSTRAINED ARRAYS ----------------------*/ - char **** cpp ; /* -- strings */ - unsigned char *** ucpp ; /* -- unsigned characters */ - short *** spp ; /* -- short integers */ - unsigned short *** uspp ; /* -- unsigned short integers */ - int *** ipp ; /* -- integers */ - unsigned int *** uipp ; /* -- unsigned integers */ - long *** lpp ; /* -- long integers */ - unsigned long *** ulpp ; /* -- unsigned long integers */ - float *** fpp ; /* -- single precision floating point */ - double *** dpp ; /* -- double precision floating point */ - long long *** llpp ; /* -- long longs */ - unsigned long long *** ullpp ; /* -- unsigned long longs */ - wchar_t **** wcpp ; /* -- wide strings */ -} C_PTR_TYPES ; /*------------------------------------------------------------*/ - -typedef struct { /*---- MIXED POINTERS AND ARRAYS -----------------------------*/ - char *** cpa[2] ; /* -- strings */ - unsigned char ** ucpa[2] ; /* -- unsigned characters */ - short ** spa[2] ; /* -- short integers */ - unsigned short ** uspa[2] ; /* -- unsigned short integers */ - int ** ipa[2] ; /* -- integers */ - unsigned int ** uipa[2] ; /* -- unsigned integers */ - long ** lpa[2] ; /* -- long integers */ - unsigned long ** ulpa[2] ; /* -- unsigned long integers */ - float ** fpa[2] ; /* -- single precision floating points */ - double ** dpa[2] ; /* -- double precision floating points */ - long long ** llpa[2] ; /* -- long longs */ - unsigned long long ** ullpa[2] ; /* -- unsigned long longs */ - wchar_t *** wcpa[2] ; /* -- wide strings */ -} C_MIX_TYPES ; /*------------------------------------------------------------*/ - -typedef struct { /*---- COMPOSITE DATA STRUCTURES ----------------------------*/ -C_TYPES c_types ; /* -- Standard C types */ -C_ARR_TYPES c_array_types ; /* -- Arrayed C types */ -C_PTR_TYPES c_pointer_types ; /* -- Pointered C types */ -C_MIX_TYPES c_mixed_types ; /* -- Mixed arrays and pointer types */ -} TEST13 ; /*-----------------------------------------------------------------*/ - -#endif diff --git a/trick_test/requirements_testing/models/test13/src/test13_init.c b/trick_test/requirements_testing/models/test13/src/test13_init.c deleted file mode 100644 index a6f4e459..00000000 --- a/trick_test/requirements_testing/models/test13/src/test13_init.c +++ /dev/null @@ -1,309 +0,0 @@ -#include "../include/test13.h" - -void test13_init(TEST13 *T) { -T->c_types.c = 'u' ; -T->c_types.uc = 'c'; -T->c_types.cp = strdup(".gnirts tseT") ; -T->c_types.s++ ; -T->c_types.us++ ; -T->c_types.i++ ; -T->c_types.ui++ ; -T->c_types.l++ ; -T->c_types.ul++ ; -T->c_types.f++ ; -T->c_types.d++ ; -T->c_types.ll++ ; -T->c_types.ull++ ; - -T->c_array_types.ca[0][0][0] = 'p' ; -T->c_array_types.ca[0][0][1] = 'o' ; -T->c_array_types.ca[0][1][0] = 'n' ; -T->c_array_types.ca[0][1][1] = 'm' ; -T->c_array_types.ca[1][0][0] = 'l' ; -T->c_array_types.ca[1][0][1] = 'k' ; -T->c_array_types.ca[1][1][0] = 'j' ; -T->c_array_types.ca[1][1][1] = 'i' ; -T->c_array_types.uca[0][0][0] = 'h' ; -T->c_array_types.uca[0][0][1] = 'g' ; -T->c_array_types.uca[0][1][0] = 'f' ; -T->c_array_types.uca[0][1][1] = 'e' ; -T->c_array_types.uca[1][0][0] = 'd' ; -T->c_array_types.uca[1][0][1] = 'c' ; -T->c_array_types.uca[1][1][0] = 'b' ; -T->c_array_types.uca[1][1][1] = 'a' ; -T->c_array_types.sa[0][0][0]++ ; -T->c_array_types.sa[0][0][1]++ ; -T->c_array_types.sa[0][1][0]++ ; -T->c_array_types.sa[0][1][1]++ ; -T->c_array_types.sa[1][0][0]++ ; -T->c_array_types.sa[1][0][1]++ ; -T->c_array_types.sa[1][1][0]++ ; -T->c_array_types.sa[1][1][1]++ ; -T->c_array_types.usa[0][0][0]++ ; -T->c_array_types.usa[0][0][1]++ ; -T->c_array_types.usa[0][1][0]++ ; -T->c_array_types.usa[0][1][1]++ ; -T->c_array_types.usa[1][0][0]++ ; -T->c_array_types.usa[1][0][1]++ ; -T->c_array_types.usa[1][1][0]++ ; -T->c_array_types.usa[1][1][1]++ ; -T->c_array_types.ia[0][0][0]++ ; -T->c_array_types.ia[0][0][1]++ ; -T->c_array_types.ia[0][1][0]++ ; -T->c_array_types.ia[0][1][1]++ ; -T->c_array_types.ia[1][0][0]++ ; -T->c_array_types.ia[1][0][1]++ ; -T->c_array_types.ia[1][1][0]++ ; -T->c_array_types.ia[1][1][1]++ ; -T->c_array_types.uia[0][0][0]++ ; -T->c_array_types.uia[0][0][1]++ ; -T->c_array_types.uia[0][1][0]++ ; -T->c_array_types.uia[0][1][1]++ ; -T->c_array_types.uia[1][0][0]++ ; -T->c_array_types.uia[1][0][1]++ ; -T->c_array_types.uia[1][1][0]++ ; -T->c_array_types.uia[1][1][1]++ ; -T->c_array_types.la[0][0][0]++ ; -T->c_array_types.la[0][0][1]++ ; -T->c_array_types.la[0][1][0]++ ; -T->c_array_types.la[0][1][1]++ ; -T->c_array_types.la[1][0][0]++ ; -T->c_array_types.la[1][0][1]++ ; -T->c_array_types.la[1][1][0]++ ; -T->c_array_types.la[1][1][1]++ ; -T->c_array_types.ula[0][0][0]++ ; -T->c_array_types.ula[0][0][1]++ ; -T->c_array_types.ula[0][1][0]++ ; -T->c_array_types.ula[0][1][1]++ ; -T->c_array_types.ula[1][0][0]++ ; -T->c_array_types.ula[1][0][1]++ ; -T->c_array_types.ula[1][1][0]++ ; -T->c_array_types.ula[1][1][1]++ ; -T->c_array_types.fa[0][0][0]++ ; -T->c_array_types.fa[0][0][1]++ ; -T->c_array_types.fa[0][1][0]++ ; -T->c_array_types.fa[0][1][1]++ ; -T->c_array_types.fa[1][0][0]++ ; -T->c_array_types.fa[1][0][1]++ ; -T->c_array_types.fa[1][1][0]++ ; -T->c_array_types.fa[1][1][1]++ ; -T->c_array_types.da[0][0][0]++ ; -T->c_array_types.da[0][0][1]++ ; -T->c_array_types.da[0][1][0]++ ; -T->c_array_types.da[0][1][1]++ ; -T->c_array_types.da[1][0][0]++ ; -T->c_array_types.da[1][0][1]++ ; -T->c_array_types.da[1][1][0]++ ; -T->c_array_types.da[1][1][1]++ ; -T->c_array_types.lla[0][0][0]++ ; -T->c_array_types.lla[0][0][1]++ ; -T->c_array_types.lla[0][1][0]++ ; -T->c_array_types.lla[0][1][1]++ ; -T->c_array_types.lla[1][0][0]++ ; -T->c_array_types.lla[1][0][1]++ ; -T->c_array_types.lla[1][1][0]++ ; -T->c_array_types.lla[1][1][1]++ ; -T->c_array_types.ulla[0][0][0]++ ; -T->c_array_types.ulla[0][0][1]++ ; -T->c_array_types.ulla[0][1][0]++ ; -T->c_array_types.ulla[0][1][1]++ ; -T->c_array_types.ulla[1][0][0]++ ; -T->c_array_types.ulla[1][0][1]++ ; -T->c_array_types.ulla[1][1][0]++ ; -T->c_array_types.ulla[1][1][1]++ ; - -T->c_pointer_types.cpp[0][0][0] = strdup("eno") ; -T->c_pointer_types.cpp[0][0][1] = strdup("owt") ; -T->c_pointer_types.cpp[0][1][0] = strdup("eerht") ; -T->c_pointer_types.cpp[0][1][1] = strdup("ruof") ; -T->c_pointer_types.cpp[1][0][0] = strdup("evif") ; -T->c_pointer_types.cpp[1][0][1] = strdup("xis") ; -T->c_pointer_types.cpp[1][1][0] = strdup("neves") ; -T->c_pointer_types.cpp[1][1][1] = strdup("thgie") ; -T->c_pointer_types.ucpp[0][0][0] = 'h' ; -T->c_pointer_types.ucpp[0][0][1] = 'g' ; -T->c_pointer_types.ucpp[0][1][0] = 'f' ; -T->c_pointer_types.ucpp[0][1][1] = 'e' ; -T->c_pointer_types.ucpp[1][0][0] = 'd' ; -T->c_pointer_types.ucpp[1][0][1] = 'c' ; -T->c_pointer_types.ucpp[1][1][0] = 'b' ; -T->c_pointer_types.ucpp[1][1][1] = 'a' ; -T->c_pointer_types.spp[0][0][0]++ ; -T->c_pointer_types.spp[0][0][1]++ ; -T->c_pointer_types.spp[0][1][0]++ ; -T->c_pointer_types.spp[0][1][1]++ ; -T->c_pointer_types.spp[1][0][0]++ ; -T->c_pointer_types.spp[1][0][1]++ ; -T->c_pointer_types.spp[1][1][0]++ ; -T->c_pointer_types.spp[1][1][1]++ ; -T->c_pointer_types.uspp[0][0][0]++ ; -T->c_pointer_types.uspp[0][0][1]++ ; -T->c_pointer_types.uspp[0][1][0]++ ; -T->c_pointer_types.uspp[0][1][1]++ ; -T->c_pointer_types.uspp[1][0][0]++ ; -T->c_pointer_types.uspp[1][0][1]++ ; -T->c_pointer_types.uspp[1][1][0]++ ; -T->c_pointer_types.uspp[1][1][1]++ ; -T->c_pointer_types.ipp[0][0][0]++ ; -T->c_pointer_types.ipp[0][0][1]++ ; -T->c_pointer_types.ipp[0][1][0]++ ; -T->c_pointer_types.ipp[0][1][1]++ ; -T->c_pointer_types.ipp[1][0][0]++ ; -T->c_pointer_types.ipp[1][0][1]++ ; -T->c_pointer_types.ipp[1][1][0]++ ; -T->c_pointer_types.ipp[1][1][1]++ ; -T->c_pointer_types.uipp[0][0][0]++ ; -T->c_pointer_types.uipp[0][0][1]++ ; -T->c_pointer_types.uipp[0][1][0]++ ; -T->c_pointer_types.uipp[0][1][1]++ ; -T->c_pointer_types.uipp[1][0][0]++ ; -T->c_pointer_types.uipp[1][0][1]++ ; -T->c_pointer_types.uipp[1][1][0]++ ; -T->c_pointer_types.uipp[1][1][1]++ ; -T->c_pointer_types.lpp[0][0][0]++ ; -T->c_pointer_types.lpp[0][0][1]++ ; -T->c_pointer_types.lpp[0][1][0]++ ; -T->c_pointer_types.lpp[0][1][1]++ ; -T->c_pointer_types.lpp[1][0][0]++ ; -T->c_pointer_types.lpp[1][0][1]++ ; -T->c_pointer_types.lpp[1][1][0]++ ; -T->c_pointer_types.lpp[1][1][1]++ ; -T->c_pointer_types.ulpp[0][0][0]++ ; -T->c_pointer_types.ulpp[0][0][1]++ ; -T->c_pointer_types.ulpp[0][1][0]++ ; -T->c_pointer_types.ulpp[0][1][1]++ ; -T->c_pointer_types.ulpp[1][0][0]++ ; -T->c_pointer_types.ulpp[1][0][1]++ ; -T->c_pointer_types.ulpp[1][1][0]++ ; -T->c_pointer_types.ulpp[1][1][1]++ ; -T->c_pointer_types.fpp[0][0][0]++ ; -T->c_pointer_types.fpp[0][0][1]++ ; -T->c_pointer_types.fpp[0][1][0]++ ; -T->c_pointer_types.fpp[0][1][1]++ ; -T->c_pointer_types.fpp[1][0][0]++ ; -T->c_pointer_types.fpp[1][0][1]++ ; -T->c_pointer_types.fpp[1][1][0]++ ; -T->c_pointer_types.fpp[1][1][1]++ ; -T->c_pointer_types.dpp[0][0][0]++ ; -T->c_pointer_types.dpp[0][0][1]++ ; -T->c_pointer_types.dpp[0][1][0]++ ; -T->c_pointer_types.dpp[0][1][1]++ ; -T->c_pointer_types.dpp[1][0][0]++ ; -T->c_pointer_types.dpp[1][0][1]++ ; -T->c_pointer_types.dpp[1][1][0]++ ; -T->c_pointer_types.dpp[1][1][1]++ ; -T->c_pointer_types.llpp[0][0][0]++ ; -T->c_pointer_types.llpp[0][0][1]++ ; -T->c_pointer_types.llpp[0][1][0]++ ; -T->c_pointer_types.llpp[0][1][1]++ ; -T->c_pointer_types.llpp[1][0][0]++ ; -T->c_pointer_types.llpp[1][0][1]++ ; -T->c_pointer_types.llpp[1][1][0]++ ; -T->c_pointer_types.llpp[1][1][1]++ ; -T->c_pointer_types.ullpp[0][0][0]++ ; -T->c_pointer_types.ullpp[0][0][1]++ ; -T->c_pointer_types.ullpp[0][1][0]++ ; -T->c_pointer_types.ullpp[0][1][1]++ ; -T->c_pointer_types.ullpp[1][0][0]++ ; -T->c_pointer_types.ullpp[1][0][1]++ ; -T->c_pointer_types.ullpp[1][1][0]++ ; -T->c_pointer_types.ullpp[1][1][1]++ ; - -T->c_mixed_types.cpa[0][0][0] = strdup("eno") ; -T->c_mixed_types.cpa[0][0][1] = strdup("owt") ; -T->c_mixed_types.cpa[0][1][0] = strdup("eerht") ; -T->c_mixed_types.cpa[0][1][1] = strdup("ruof") ; -T->c_mixed_types.cpa[1][0][0] = strdup("evif") ; -T->c_mixed_types.cpa[1][0][1] = strdup("xis") ; -T->c_mixed_types.cpa[1][1][0] = strdup("neves") ; -T->c_mixed_types.cpa[1][1][1] = strdup("thgie") ; -T->c_mixed_types.ucpa[0][0][0] = 'h' ; -T->c_mixed_types.ucpa[0][0][1] = 'g' ; -T->c_mixed_types.ucpa[0][1][0] = 'f' ; -T->c_mixed_types.ucpa[0][1][1] = 'e' ; -T->c_mixed_types.ucpa[1][0][0] = 'd' ; -T->c_mixed_types.ucpa[1][0][1] = 'c' ; -T->c_mixed_types.ucpa[1][1][0] = 'b' ; -T->c_mixed_types.ucpa[1][1][1] = 'a' ; -T->c_mixed_types.spa[0][0][0]++ ; -T->c_mixed_types.spa[0][0][1]++ ; -T->c_mixed_types.spa[0][1][0]++ ; -T->c_mixed_types.spa[0][1][1]++ ; -T->c_mixed_types.spa[1][0][0]++ ; -T->c_mixed_types.spa[1][0][1]++ ; -T->c_mixed_types.spa[1][1][0]++ ; -T->c_mixed_types.spa[1][1][1]++ ; -T->c_mixed_types.uspa[0][0][0]++ ; -T->c_mixed_types.uspa[0][0][1]++ ; -T->c_mixed_types.uspa[0][1][0]++ ; -T->c_mixed_types.uspa[0][1][1]++ ; -T->c_mixed_types.uspa[1][0][0]++ ; -T->c_mixed_types.uspa[1][0][1]++ ; -T->c_mixed_types.uspa[1][1][0]++ ; -T->c_mixed_types.uspa[1][1][1]++ ; -T->c_mixed_types.ipa[0][0][0]++ ; -T->c_mixed_types.ipa[0][0][1]++ ; -T->c_mixed_types.ipa[0][1][0]++ ; -T->c_mixed_types.ipa[0][1][1]++ ; -T->c_mixed_types.ipa[1][0][0]++ ; -T->c_mixed_types.ipa[1][0][1]++ ; -T->c_mixed_types.ipa[1][1][0]++ ; -T->c_mixed_types.ipa[1][1][1]++ ; -T->c_mixed_types.uipa[0][0][0]++ ; -T->c_mixed_types.uipa[0][0][1]++ ; -T->c_mixed_types.uipa[0][1][0]++ ; -T->c_mixed_types.uipa[0][1][1]++ ; -T->c_mixed_types.uipa[1][0][0]++ ; -T->c_mixed_types.uipa[1][0][1]++ ; -T->c_mixed_types.uipa[1][1][0]++ ; -T->c_mixed_types.uipa[1][1][1]++ ; -T->c_mixed_types.lpa[0][0][0]++ ; -T->c_mixed_types.lpa[0][0][1]++ ; -T->c_mixed_types.lpa[0][1][0]++ ; -T->c_mixed_types.lpa[0][1][1]++ ; -T->c_mixed_types.lpa[1][0][0]++ ; -T->c_mixed_types.lpa[1][0][1]++ ; -T->c_mixed_types.lpa[1][1][0]++ ; -T->c_mixed_types.lpa[1][1][1]++ ; -T->c_mixed_types.ulpa[0][0][0]++ ; -T->c_mixed_types.ulpa[0][0][1]++ ; -T->c_mixed_types.ulpa[0][1][0]++ ; -T->c_mixed_types.ulpa[0][1][1]++ ; -T->c_mixed_types.ulpa[1][0][0]++ ; -T->c_mixed_types.ulpa[1][0][1]++ ; -T->c_mixed_types.ulpa[1][1][0]++ ; -T->c_mixed_types.ulpa[1][1][1]++ ; -T->c_mixed_types.fpa[0][0][0]++ ; -T->c_mixed_types.fpa[0][0][1]++ ; -T->c_mixed_types.fpa[0][1][0]++ ; -T->c_mixed_types.fpa[0][1][1]++ ; -T->c_mixed_types.fpa[1][0][0]++ ; -T->c_mixed_types.fpa[1][0][1]++ ; -T->c_mixed_types.fpa[1][1][0]++ ; -T->c_mixed_types.fpa[1][1][1]++ ; -T->c_mixed_types.dpa[0][0][0]++ ; -T->c_mixed_types.dpa[0][0][1]++ ; -T->c_mixed_types.dpa[0][1][0]++ ; -T->c_mixed_types.dpa[0][1][1]++ ; -T->c_mixed_types.dpa[1][0][0]++ ; -T->c_mixed_types.dpa[1][0][1]++ ; -T->c_mixed_types.dpa[1][1][0]++ ; -T->c_mixed_types.dpa[1][1][1]++ ; -T->c_mixed_types.llpa[0][0][0]++ ; -T->c_mixed_types.llpa[0][0][1]++ ; -T->c_mixed_types.llpa[0][1][0]++ ; -T->c_mixed_types.llpa[0][1][1]++ ; -T->c_mixed_types.llpa[1][0][0]++ ; -T->c_mixed_types.llpa[1][0][1]++ ; -T->c_mixed_types.llpa[1][1][0]++ ; -T->c_mixed_types.llpa[1][1][1]++ ; -T->c_mixed_types.ullpa[0][0][0]++ ; -T->c_mixed_types.ullpa[0][0][1]++ ; -T->c_mixed_types.ullpa[0][1][0]++ ; -T->c_mixed_types.ullpa[0][1][1]++ ; -T->c_mixed_types.ullpa[1][0][0]++ ; -T->c_mixed_types.ullpa[1][0][1]++ ; -T->c_mixed_types.ullpa[1][1][0]++ ; -T->c_mixed_types.ullpa[1][1][1]++ ; - -} diff --git a/trick_test/requirements_testing/models/test2/.checksums b/trick_test/requirements_testing/models/test2/.checksums deleted file mode 100644 index a8168cfe..00000000 --- a/trick_test/requirements_testing/models/test2/.checksums +++ /dev/null @@ -1,19 +0,0 @@ -62466 2 ./src/sched_amf.c -56063 2 ./src/sched_async.c -58898 2 ./src/sched_deriv.c -40625 4 ./src/sched_dyn_event.c -1862 3 ./src/sched_effector.c -60196 2 ./src/sched_effector_emitter.c -60562 2 ./src/sched_effector_receiver.c -63000 2 ./src/sched_environment.c -49220 2 ./src/sched_init.c -23169 3 ./src/sched_integ.c -56365 2 ./src/sched_logging.c -57176 2 ./src/sched_scheduled.c -56062 2 ./src/sched_sensor.c -59482 2 ./src/sched_sensor_emitter.c -59798 2 ./src/sched_sensor_receiver.c -60444 2 ./src/sched_sensor_reflector.c -58851 2 ./include/sched.d -12435 3 ./include/sched.h -32231 3 ./include/sched_integ.d diff --git a/trick_test/requirements_testing/models/test2/include/sched.d b/trick_test/requirements_testing/models/test2/include/sched.d deleted file mode 100644 index 5335a163..00000000 --- a/trick_test/requirements_testing/models/test2/include/sched.d +++ /dev/null @@ -1,37 +0,0 @@ -/* - * $Log: sched.d,v $ - * Revision 5.1 2004-08-05 13:06:56-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.4 2003/08/26 20:24:13 vetter - * Add Dynamic Event Class To SIM_test_sched - * - * Revision 1.3 2002/10/07 15:16:28 lin - * Add rcs version info to all trick_models files - * - */ - -SCHEDULE.msd.params.initial_pos = 5.0 ; -SCHEDULE.msd.params.initial_vel = 0.0 ; -SCHEDULE.msd.params.mass = 1.0 ; -SCHEDULE.msd.params.damping_const = 0.3 ; -SCHEDULE.msd.params.spring_const = 10.0 ; - -SCHEDULE.async_completion_count = 0 ; -SCHEDULE.amf_completion_count = 0 ; - -#define BIG_TGO 10 -SCHEDULE.msd.numeric.rf.lower_set = No ; -SCHEDULE.msd.numeric.rf.upper_set = No ; -SCHEDULE.msd.numeric.rf.iterations = 0 ; -SCHEDULE.msd.numeric.rf.fires = 0 ; -SCHEDULE.msd.numeric.rf.x_lower = BIG_TGO ; -SCHEDULE.msd.numeric.rf.t_lower = BIG_TGO ; -SCHEDULE.msd.numeric.rf.x_upper = BIG_TGO ; -SCHEDULE.msd.numeric.rf.t_upper = BIG_TGO ; -SCHEDULE.msd.numeric.rf.delta_time = BIG_TGO ; -SCHEDULE.msd.numeric.rf.error_tol = 1.0e-5 ; -SCHEDULE.msd.numeric.rf.mode = Any ; diff --git a/trick_test/requirements_testing/models/test2/include/sched.h b/trick_test/requirements_testing/models/test2/include/sched.h deleted file mode 100644 index d3839655..00000000 --- a/trick_test/requirements_testing/models/test2/include/sched.h +++ /dev/null @@ -1,52 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Tests requirements: 3.1.2.3, 3.1.2.1.1.1-7, 3.1.2.1.2.1-6, - 3.1.2.1.3.1-5, 3.3.2.1.11 ) -*******************************************************************************/ - -#ifndef _SCHEDULE_H_ -#define _SCHEDULE_H_ - -#include "sim_services/include/regula_falsi.h" - -typedef struct { - double pos; /* M Position */ - double vel; /* M/s Velocity */ - double acc; /* M/s2 Acceleration */ - REGULA_FALSI rf ; /* -- Dynamic event */ -} MSD_NUMERIC ; - -typedef struct { - double pos; /* M Position */ - double vel; /* M/s Velocity */ - double omega_n; - double omega_d; - double zeta; - double C1; - double C2; -} MSD_ANALYTIC ; - -typedef struct { - double mass; /* kg Mass */ - double damping_const; /* kg/s Damping constant */ - double spring_const; /* kg/s2 Spring constant */ - double initial_pos; /* M Position */ - double initial_vel; /* M/s Velocity */ -} MSD_PARAMS ; - -typedef struct { - MSD_PARAMS params; - MSD_NUMERIC numeric; - MSD_ANALYTIC analytic; - double delta_pos; /* M Delta Position */ - double delta_vel; /* M/s Delta Velocity */ -} MSD; - -typedef struct { /* SCHEDULE ------------------------------------------------*/ - - MSD msd; - int async_completion_count ; /* -- the number of times sched_async() has run to completion. */ - int amf_completion_count ; /* -- the number of times sched_amf() has run to completion. */ - -} SCHEDULE ; /*--------------------------------------------------------------*/ - -#endif diff --git a/trick_test/requirements_testing/models/test2/include/sched_integ.d b/trick_test/requirements_testing/models/test2/include/sched_integ.d deleted file mode 100644 index cee19733..00000000 --- a/trick_test/requirements_testing/models/test2/include/sched_integ.d +++ /dev/null @@ -1,56 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Ball model state integrator default initialization data.) -REFERENCE: - (((Bailey, R.W, and Paddock, E.J.) - (Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((2 dimensional space)) -PROGRAMMERS: - (((Your Name) (Company Name) (Date) (Trick tutorial))) -*******************************************************************************/ - -/* - * $Log: sched_integ.d,v $ - * Revision 7.3 2007-11-06 10:39:22-06 hchen - * Change the way of defining a variable in some .d files related to old style allocation and fix some typos - * - * Revision 7.2 2007-10-23 11:53:06-05 hchen - * Convert the old style allocation statements we have in included sims - * - * Revision 7.1 2006-06-22 14:14:11-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:57-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:18 lin - * Bump version number for 04 - * - * Revision 1.2 2002/10/07 15:16:29 lin - * Add rcs version info to all trick_models files - * - */ - -#define NUM_STEP 12 /* use up to 12 intermediate steps: - 8th order RK Fehlberg */ -#define NUM_VARIABLES 4 /* x,y position state and x,y velocity state */ - -INTEGRATOR.state = alloc(NUM_VARIABLES) ; -INTEGRATOR.deriv = alloc(NUM_STEP) ; -INTEGRATOR.state_ws = alloc(NUM_STEP) ; - -for (int kk = 0 ; kk < NUM_STEP ; kk++ ) { - INTEGRATOR.deriv[kk] = alloc(NUM_VARIABLES) ; - INTEGRATOR.state_ws[kk] = alloc(NUM_VARIABLES) ; -} - -INTEGRATOR.num_state = NUM_VARIABLES ; -INTEGRATOR.option = Runge_Kutta_4 ; /* 4rth order Runge Kutta */ -INTEGRATOR.init = True ; -INTEGRATOR.first_step_deriv = Yes ; - -#undef NUM_STEP -#undef NUM_VARIABLES diff --git a/trick_test/requirements_testing/models/test2/src/sched_amf.c b/trick_test/requirements_testing/models/test2/src/sched_amf.c deleted file mode 100644 index e4088dfe..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_amf.c +++ /dev/null @@ -1,29 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( asynchronous_mustfinish ) -LIBRARY DEPENDENCY: ( sched_amf.o ) -*******************************************************************************/ - -#include "../include/sched.h" -#include -#include - -int sched_amf( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - - if ((S->amf_completion_count % 2 ) == 0) { - printf("AMF sleeping 1.5 seconds.\n"); - usleep(1500000); /* 1.5 seconds */ - } else { - printf("AMF sleeping 0.5 seconds.\n"); - usleep( 500000); /* 0.5 seconds */ - } - - S->amf_completion_count ++; - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_async.c b/trick_test/requirements_testing/models/test2/src/sched_async.c deleted file mode 100644 index f01ca133..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_async.c +++ /dev/null @@ -1,35 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( asynchronous ) -LIBRARY DEPENDENCY: ( sched_async.o ) -PROGRAMMERS: ( (Penn) (LLL) (10-03-2008) ) -*******************************************************************************/ - -#include "../include/sched.h" -#include -#include - -/* - * Run increasing longer periods of time. - * First time this function is called, it sleeps for 0 seconds; - * second time, 1 second; third, 2 seconds and so forth. - */ - -int sched_async ( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - - int i; - - /* Try and hang the sim... */ - for ( i=0; i < S->async_completion_count; i++) { - /* Sleep for 1 second. */ - usleep(1000000) ; - } - S->async_completion_count += 1; - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_automatic.c b/trick_test/requirements_testing/models/test2/src/sched_automatic.c deleted file mode 100644 index a0b77d3c..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_automatic.c +++ /dev/null @@ -1,32 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_automatic) -***************************************************************************/ -#include "../include/sched.h" -#include -#include "sim_services/include/executive.h" -#include "sim_services/include/jobdata.h" -#include "sim_services/include/module_classes.h" -#include "sim_services/include/exec_proto.h" - -Realtime_Process_ID exec_get_process_id(void); - -extern JOBDATA *exec_jobs[]; - -int sched_automatic( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - EXECUTIVE *E; - EXEC_WORK *EW; - - Realtime_Process_ID process_id; - - E = exec_get_exec(); - EW = &(E->work); - - process_id = exec_get_process_id(); - exec_reschedule(3, EW->job_select[process_id], exec_get_sim_time() + 1.1); - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_automatic_last.c b/trick_test/requirements_testing/models/test2/src/sched_automatic_last.c deleted file mode 100644 index c0eb703b..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_automatic_last.c +++ /dev/null @@ -1,33 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_automatic_last) -***************************************************************************/ -#include "../include/sched.h" -#include -#include "sim_services/include/executive.h" -#include "sim_services/include/jobdata.h" -#include "sim_services/include/module_classes.h" -#include "sim_services/include/exec_proto.h" - -Realtime_Process_ID exec_get_process_id(void); - -extern JOBDATA *exec_jobs[]; - -int sched_automatic_last( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - - EXECUTIVE *E; - EXEC_WORK *EW; - - Realtime_Process_ID process_id; - - E = exec_get_exec(); - EW = &(E->work); - - process_id = exec_get_process_id(); - exec_reschedule(3, EW->job_select[process_id], exec_get_sim_time() + 1.2); - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_checkpoint.c b/trick_test/requirements_testing/models/test2/src/sched_checkpoint.c deleted file mode 100644 index 5ca57339..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_checkpoint.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_checkpoint) -***************************************************************************/ -#include "../include/sched.h" - -int sched_checkpoint( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_deriv.c b/trick_test/requirements_testing/models/test2/src/sched_deriv.c deleted file mode 100644 index e07e8a2a..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_deriv.c +++ /dev/null @@ -1,34 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( derivative ) -LIBRARY DEPENDENCY: ( sched_deriv.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) (Trick tutorial) ) -*******************************************************************************/ - -/* - * $Log: sched_deriv.c,v $ - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:13 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:30 lin - * Add rcs version info to all trick_models files - * - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - -int sched_deriv( - MSD_NUMERIC *N, - MSD_PARAMS *P ) -{ - /* Spring: x'' = - b/m * x' -k/m * x */ - N->acc = - P->damping_const / P->mass * N->vel - P->spring_const/P->mass * N->pos; - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_dyn_event.c b/trick_test/requirements_testing/models/test2/src/sched_dyn_event.c deleted file mode 100644 index 4710936a..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_dyn_event.c +++ /dev/null @@ -1,49 +0,0 @@ -/******************************* TRICK HEADER ******************************* -PURPOSE: (Test regula falsi. This dynamic event function fires - when S->pos passes through 0. ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( ) -CLASS: (dynamic_event) -LIBRARY DEPENDENCY: (sched_dyn_event.o) -*****************************************************************************/ - -/* - * $Log$ - */ - -#include -#include "../include/sched.h" -#include "sim_services/include/regula_falsi.h" -#include "sim_services/include/exec_proto.h" - -double sched_dyn_event( - /* RETURN: s Time to go to event */ -MSD_NUMERIC * N , /* INOUT: -- */ -double *time , /* IN: s Integrator time from the executive */ -int *event_evaluate_tgo ) /* IN: -- Event time to go function eval flag, - 1 = evaluate time to go for event, - 0 = fire event */ -{ - - double tgo ; - - if( *event_evaluate_tgo ) { - - /* We're finding the root of the position function. */ - N->rf.error = N->pos; - tgo = regula_falsi( *time , &(N->rf) ) ; - - } else { - - /* FIRE EVENT */ - reset_regula_falsi( *time , &(N->rf) ) ; - tgo = 0.0 ; - - send_hs(stderr,"************************************\n"); - send_hs(stderr,"** Dynamic event fired at %g\n",*time); - send_hs(stderr,"************************************\n"); - - } - - return( tgo ) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_freeze.c b/trick_test/requirements_testing/models/test2/src/sched_freeze.c deleted file mode 100644 index c22835b3..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_freeze.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_freeze) -***************************************************************************/ -#include "../include/sched.h" - -int sched_freeze( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_freeze_init.c b/trick_test/requirements_testing/models/test2/src/sched_freeze_init.c deleted file mode 100644 index b2de47b8..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_freeze_init.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_freeze_init) -***************************************************************************/ -#include "../include/sched.h" - -int sched_freeze_init( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_init.c b/trick_test/requirements_testing/models/test2/src/sched_init.c deleted file mode 100644 index a6e58e5b..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_init.c +++ /dev/null @@ -1,46 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_init) -REFERENCES: (none) -ASSUMPTIONS AND LIMITATIONS: (Autocreated by trick_ui) -CLASS: (initialization) -LIBRARY DEPENDENCY: (sched_init.o) -PROGRAMMERS: ((vetter) (Tue Aug 26 13:22:44 CDT 2003)) -***************************************************************************/ - -/* - * $Log$ - */ - -#include "../include/sched.h" -#include "sim_services/include/exec_proto.h" - -int sched_init( - /* RETURN: -- Always return zero */ - SCHEDULE *S -) - -{ - // Initialize the analytic model. - S->msd.analytic.pos = S->msd.params.initial_pos; - S->msd.analytic.vel = S->msd.params.initial_vel; - S->msd.analytic.omega_n = sqrt( S->msd.params.spring_const / S->msd.params.mass); - S->msd.analytic.zeta = S->msd.params.damping_const / (2 * S->msd.params.mass * S->msd.analytic.omega_n ); - - if (S->msd.analytic.zeta >= 1) { - printf("Won't work.\n"); - exec_terminate(__FILE__,"This sim doesn't handle the case where the spring is overdamped."); - } - - S->msd.analytic.omega_d = S->msd.analytic.omega_n * sqrt(1 - S->msd.analytic.zeta * S->msd.analytic.zeta); - S->msd.analytic.C1 = S->msd.params.initial_pos; - S->msd.analytic.C2 = (S->msd.params.initial_vel + - S->msd.analytic.zeta * - S->msd.analytic.omega_n * - S->msd.params.initial_pos) / S->msd.analytic.omega_d; - - // Initialize the numeric model. - S->msd.numeric.pos = S->msd.params.initial_pos; - S->msd.numeric.vel = S->msd.params.initial_vel; - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_integ.c b/trick_test/requirements_testing/models/test2/src/sched_integ.c deleted file mode 100644 index 088389ff..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_integ.c +++ /dev/null @@ -1,34 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( integration ) -LIBRARY DEPENDENCY: ( sched_integ.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) (Trick tutorial) ) -*******************************************************************************/ - -/* - * $Log$ - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - -int sched_integ( - /* RETURN: -- Always return zero */ - INTEGRATOR *I , /* INOUT: -- Trick state integration parameters */ - MSD_NUMERIC *N ) /* INOUT: -- Schedule struct */ -{ - I->state[0] = N->pos ; - I->state[1] = N->vel ; - - I->deriv[I->intermediate_step][0] = N->vel ; - I->deriv[I->intermediate_step][1] = N->acc ; - - integrate( I ) ; - - N->pos = I->state_ws[I->intermediate_step][0] ; - N->vel = I->state_ws[I->intermediate_step][1] ; - - return( I->intermediate_step ); -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_logging.c b/trick_test/requirements_testing/models/test2/src/sched_logging.c deleted file mode 100644 index e578d938..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_logging.c +++ /dev/null @@ -1,30 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( logging ) -LIBRARY DEPENDENCY: ( sched_logging.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_logging.c,v $ - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:15 lin - * Bump version number for 04 - * - * Revision 1.4 2002/10/07 15:16:32 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_logging( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_post_integ.c b/trick_test/requirements_testing/models/test2/src/sched_post_integ.c deleted file mode 100644 index 2ce450bd..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_post_integ.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_post_integ) -***************************************************************************/ -#include "../include/sched.h" - -int sched_post_integ( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_pre_load.c b/trick_test/requirements_testing/models/test2/src/sched_pre_load.c deleted file mode 100644 index 210739be..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_pre_load.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_pre_load) -***************************************************************************/ -#include "../include/sched.h" - -int sched_pre_load( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_random.c b/trick_test/requirements_testing/models/test2/src/sched_random.c deleted file mode 100644 index ea7dca05..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_random.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_random) -***************************************************************************/ -#include "../include/sched.h" - -int sched_random( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_restart.c b/trick_test/requirements_testing/models/test2/src/sched_restart.c deleted file mode 100644 index 04767739..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_restart.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_restart) -***************************************************************************/ -#include "../include/sched.h" - -int sched_restart( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_scheduled.c b/trick_test/requirements_testing/models/test2/src/sched_scheduled.c deleted file mode 100644 index 0e86e72b..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_scheduled.c +++ /dev/null @@ -1,34 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -LIBRARY DEPENDENCY: ( sched_scheduled.o ) -*******************************************************************************/ - -/* - * $Log$ - */ - -#include "../include/sched.h" -#include - -int sched_scheduled( - MSD_ANALYTIC *A, - double *time ) - -{ - double t = *time; - double alpha = - (A->zeta) * (A->omega_n); - double beta = A->omega_d ; - - A->pos = exp( alpha * t) * - (A->C1 * cos( beta * t) + A->C2 * sin( beta * t)); - - A->vel = alpha * exp( alpha * t) * - (A->C1 * cos( beta * t) + A->C2 * sin( beta * t)) + - exp( alpha * t) * - (A->C2 * beta * cos( beta * t) - A->C1 * beta * sin( beta * t)) ; - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_scheduled_2.c b/trick_test/requirements_testing/models/test2/src/sched_scheduled_2.c deleted file mode 100644 index 8233d694..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_scheduled_2.c +++ /dev/null @@ -1,24 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -LIBRARY DEPENDENCY: ( sched_scheduled_2.o ) -*******************************************************************************/ - -/* - * $Log$ - */ - -#include "../include/sched.h" -#include - -int sched_scheduled_2( - MSD *M ) - -{ - M->delta_pos = M->analytic.pos - M->numeric.pos ; - M->delta_vel = M->analytic.vel - M->numeric.vel; - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_shutdown.c b/trick_test/requirements_testing/models/test2/src/sched_shutdown.c deleted file mode 100644 index aca5384b..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_shutdown.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_shutdown) -***************************************************************************/ -#include "../include/sched.h" - -int sched_shutdown( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test2/src/sched_unfreeze.c b/trick_test/requirements_testing/models/test2/src/sched_unfreeze.c deleted file mode 100644 index 9eb7e2f6..00000000 --- a/trick_test/requirements_testing/models/test2/src/sched_unfreeze.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_unfreeze) -***************************************************************************/ -#include "../include/sched.h" - -int sched_unfreeze( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test3/include/test3.d b/trick_test/requirements_testing/models/test3/include/test3.d deleted file mode 100644 index 10c9af36..00000000 --- a/trick_test/requirements_testing/models/test3/include/test3.d +++ /dev/null @@ -1,7 +0,0 @@ -TEST3.i = 0; -TEST3.s = 5; -TEST3.ui = 10; -TEST3.l = 15; -TEST3.f = 20.0; -TEST3.d1 = 0.0; -TEST3.d2 = 0.0; diff --git a/trick_test/requirements_testing/models/test3/include/test3.h b/trick_test/requirements_testing/models/test3/include/test3.h deleted file mode 100644 index a1be01e7..00000000 --- a/trick_test/requirements_testing/models/test3/include/test3.h +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************* -PURPOSE: (Tests requirements: 3.1.2.10-12, 3.1.2.10.1-3, 3.1.2.10.3.1, 3.1.2.12.1-5) -*******************************************************************************/ - -#ifndef _test3_h_ -#define _test3_h_ - -typedef struct { - short s; - int i; - unsigned int ui; - long l; - float f; - double d1; - double d2; -} TEST3; - -#endif diff --git a/trick_test/requirements_testing/models/test3/src/test3_sched.c b/trick_test/requirements_testing/models/test3/src/test3_sched.c deleted file mode 100644 index f0e7c054..00000000 --- a/trick_test/requirements_testing/models/test3/src/test3_sched.c +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* -PURPOSE: (Change the data being recorded.) -*******************************************************************************/ - -#include "../include/test3.h" -#include - -int test3_sched(TEST3 *T, - double *time) { - - int integer_time; - - T->s++; /* Changes every time */ - T->i++; - T->ui++; - T->l++; - T->f++; - T->d1 = sin( 3.14159265 * *time); - - integer_time = (int)*time ; - - if ( integer_time % 2 == 0 ) { - T->d2 = *time - integer_time ; - } else { - T->d2 = 0.0 ; - } - - - -} diff --git a/trick_test/requirements_testing/models/test4/include/test4.d b/trick_test/requirements_testing/models/test4/include/test4.d deleted file mode 100644 index 554d54f8..00000000 --- a/trick_test/requirements_testing/models/test4/include/test4.d +++ /dev/null @@ -1,2 +0,0 @@ -TEST4.start_time = -1; -TEST4.stop_time = 1; diff --git a/trick_test/requirements_testing/models/test4/include/test4.h b/trick_test/requirements_testing/models/test4/include/test4.h deleted file mode 100644 index 04200ec8..00000000 --- a/trick_test/requirements_testing/models/test4/include/test4.h +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************* -PURPOSE: (Tests requirements: 3.1.2.4-5, 3.1.2.1.3.7-8, 3.1.2.1.3.7.1, - 3.1.2.1.3.8.1, 3.3.2.1.7) -*******************************************************************************/ - - -#ifndef _test4_h_ -#define _test4_h_ - -typedef struct { - double start_time; - double stop_time; - double cos_pi_t; - double inv_exp_t; - double cos_pi_prev_t; -} TEST4; - -#endif diff --git a/trick_test/requirements_testing/models/test4/src/foo b/trick_test/requirements_testing/models/test4/src/foo deleted file mode 100644 index d9e4ab91..00000000 --- a/trick_test/requirements_testing/models/test4/src/foo +++ /dev/null @@ -1 +0,0 @@ - T->d2 = sin( 3.14159265 / 2.0 * time); diff --git a/trick_test/requirements_testing/models/test4/src/malf_job_1.c b/trick_test/requirements_testing/models/test4/src/malf_job_1.c deleted file mode 100644 index aeb790a8..00000000 --- a/trick_test/requirements_testing/models/test4/src/malf_job_1.c +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int malf_job_1(TEST4* T) { - double time = exec_get_sim_time(); - - printf("%f: ############################### malf_1_job() called.\n", time); - return (0); -} diff --git a/trick_test/requirements_testing/models/test4/src/malf_job_2.c b/trick_test/requirements_testing/models/test4/src/malf_job_2.c deleted file mode 100644 index 2c36e54f..00000000 --- a/trick_test/requirements_testing/models/test4/src/malf_job_2.c +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int malf_job_2(TEST4* T) { - double time = exec_get_sim_time(); - - printf("%f: ############################### malf_job_2() called.\n", time); - return (0); -} diff --git a/trick_test/requirements_testing/models/test4/src/malf_job_3.c b/trick_test/requirements_testing/models/test4/src/malf_job_3.c deleted file mode 100644 index 3c43f2fe..00000000 --- a/trick_test/requirements_testing/models/test4/src/malf_job_3.c +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int malf_job_3(TEST4* T) { - double time = exec_get_sim_time(); - - printf("%f: malf_job_3() called.\n", time); - return (0); -} diff --git a/trick_test/requirements_testing/models/test4/src/malf_job_4.c b/trick_test/requirements_testing/models/test4/src/malf_job_4.c deleted file mode 100644 index 39c07465..00000000 --- a/trick_test/requirements_testing/models/test4/src/malf_job_4.c +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int malf_job_4(TEST4* T) { - double time = exec_get_sim_time(); - - printf("%f: malf_job_4() called.\n", time); - return (0); -} diff --git a/trick_test/requirements_testing/models/test4/src/sched_job_1.c b/trick_test/requirements_testing/models/test4/src/sched_job_1.c deleted file mode 100644 index 7b242c47..00000000 --- a/trick_test/requirements_testing/models/test4/src/sched_job_1.c +++ /dev/null @@ -1,17 +0,0 @@ -/******************************************************************************* -PURPOSE: (Scheduled job.) -*******************************************************************************/ - -#include -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int sched_job_1(TEST4* T) { - double time = exec_get_sim_time(); - - T->cos_pi_prev_t = T->cos_pi_t; - T->cos_pi_t = cos( (3.14159265) * time); - - printf("%f: sched_job_1() called.\n", time); - -} diff --git a/trick_test/requirements_testing/models/test4/src/sched_job_2.c b/trick_test/requirements_testing/models/test4/src/sched_job_2.c deleted file mode 100644 index aaee3819..00000000 --- a/trick_test/requirements_testing/models/test4/src/sched_job_2.c +++ /dev/null @@ -1,14 +0,0 @@ -/******************************************************************************* -PURPOSE: (Scheduled job.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int sched_job_2(TEST4* T) { - double time = exec_get_sim_time(); - - T->inv_exp_t = 1.0 / exp( time); - printf("%f: sched_job_2() called.\n", time); - return (0); -} diff --git a/trick_test/requirements_testing/models/test4/src/sched_job_3.c b/trick_test/requirements_testing/models/test4/src/sched_job_3.c deleted file mode 100644 index 7a5346b1..00000000 --- a/trick_test/requirements_testing/models/test4/src/sched_job_3.c +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Scheduled job.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int sched_job_3(TEST4* T) { - double time = exec_get_sim_time(); - - printf("%f: sched_job_3() called.\n", time); - return (0); -} diff --git a/trick_test/requirements_testing/models/test4/src/sched_job_4.c b/trick_test/requirements_testing/models/test4/src/sched_job_4.c deleted file mode 100644 index cb6aec68..00000000 --- a/trick_test/requirements_testing/models/test4/src/sched_job_4.c +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Scheduled job.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int sched_job_4(TEST4* T) { - double time = exec_get_sim_time(); - - printf("%f: sched_job_4() called.\n", time); - return (0); -} diff --git a/trick_test/requirements_testing/models/test4/src/sched_job_5.c b/trick_test/requirements_testing/models/test4/src/sched_job_5.c deleted file mode 100644 index 09f8f982..00000000 --- a/trick_test/requirements_testing/models/test4/src/sched_job_5.c +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Scheduled job.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int sched_job_5(TEST4* T) { - double time = exec_get_sim_time(); - - printf("%f: sched_job_5() called.\n", time); - return(0); -} diff --git a/trick_test/requirements_testing/models/test4/src/test3_sched.c b/trick_test/requirements_testing/models/test4/src/test3_sched.c deleted file mode 100644 index f0e7c054..00000000 --- a/trick_test/requirements_testing/models/test4/src/test3_sched.c +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* -PURPOSE: (Change the data being recorded.) -*******************************************************************************/ - -#include "../include/test3.h" -#include - -int test3_sched(TEST3 *T, - double *time) { - - int integer_time; - - T->s++; /* Changes every time */ - T->i++; - T->ui++; - T->l++; - T->f++; - T->d1 = sin( 3.14159265 * *time); - - integer_time = (int)*time ; - - if ( integer_time % 2 == 0 ) { - T->d2 = *time - integer_time ; - } else { - T->d2 = 0.0 ; - } - - - -} diff --git a/trick_test/requirements_testing/models/test4/src/trigger_job_1.c b/trick_test/requirements_testing/models/test4/src/trigger_job_1.c deleted file mode 100644 index e672e82d..00000000 --- a/trick_test/requirements_testing/models/test4/src/trigger_job_1.c +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction trigger.) -*******************************************************************************/ - -#include -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int trigger_job_1(TEST4* T) { - double time = exec_get_sim_time(); - static int sign = 0; - int flip = 0; - - printf("%f: trigger_job_1() called: returned ", time); - - if (T->cos_pi_t >= 0.0 ) { - if (sign < 0 ) { - flip = 1; - } - sign = 1; - } else { - if (sign > 0 ) { - flip = 1; - } - sign = -1; - } - - if ( flip ) { - printf("true\n"); - return 1; - } - printf("false\n"); - return 0; -} diff --git a/trick_test/requirements_testing/models/test4/src/trigger_job_2.c b/trick_test/requirements_testing/models/test4/src/trigger_job_2.c deleted file mode 100644 index ed6dcbf7..00000000 --- a/trick_test/requirements_testing/models/test4/src/trigger_job_2.c +++ /dev/null @@ -1,17 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction trigger.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int trigger_job_2(TEST4* T) { - double time = exec_get_sim_time(); - printf("%f: trigger_job_2() called: returned ", time); - if (time >= T->start_time && time <= T->stop_time) { - printf("true\n"); - return 1; - } - printf("false\n"); - return 0; -} diff --git a/trick_test/requirements_testing/models/test4/src/trigger_job_3.c b/trick_test/requirements_testing/models/test4/src/trigger_job_3.c deleted file mode 100644 index 4fcb22ee..00000000 --- a/trick_test/requirements_testing/models/test4/src/trigger_job_3.c +++ /dev/null @@ -1,17 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction trigger.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int trigger_job_3(TEST4* T) { - double time = exec_get_sim_time(); - printf("%f: trigger_job_3 called: returned ", time); - if (time >= T->start_time && time <= T->stop_time) { - printf("true\n"); - return 1; - } - printf("false\n"); - return 0; -} diff --git a/trick_test/requirements_testing/models/test4/src/trigger_job_4.c b/trick_test/requirements_testing/models/test4/src/trigger_job_4.c deleted file mode 100644 index 9053c2b1..00000000 --- a/trick_test/requirements_testing/models/test4/src/trigger_job_4.c +++ /dev/null @@ -1,17 +0,0 @@ -/******************************************************************************* -PURPOSE: (Malfunction trigger.) -*******************************************************************************/ - -#include "../include/test4.h" -#include "sim_services/include/exec_proto.h" - -int trigger_job_4(TEST4* T) { - double time = exec_get_sim_time(); - printf("%f: trigger_job_4 called: returned ", time); - if (time >= T->start_time && time <= T->stop_time) { - printf("true\n"); - return 1; - } - printf("false\n"); - return 0; -} diff --git a/trick_test/requirements_testing/models/test5/.checksums b/trick_test/requirements_testing/models/test5/.checksums deleted file mode 100644 index a8168cfe..00000000 --- a/trick_test/requirements_testing/models/test5/.checksums +++ /dev/null @@ -1,19 +0,0 @@ -62466 2 ./src/sched_amf.c -56063 2 ./src/sched_async.c -58898 2 ./src/sched_deriv.c -40625 4 ./src/sched_dyn_event.c -1862 3 ./src/sched_effector.c -60196 2 ./src/sched_effector_emitter.c -60562 2 ./src/sched_effector_receiver.c -63000 2 ./src/sched_environment.c -49220 2 ./src/sched_init.c -23169 3 ./src/sched_integ.c -56365 2 ./src/sched_logging.c -57176 2 ./src/sched_scheduled.c -56062 2 ./src/sched_sensor.c -59482 2 ./src/sched_sensor_emitter.c -59798 2 ./src/sched_sensor_receiver.c -60444 2 ./src/sched_sensor_reflector.c -58851 2 ./include/sched.d -12435 3 ./include/sched.h -32231 3 ./include/sched_integ.d diff --git a/trick_test/requirements_testing/models/test5/include/sched.d b/trick_test/requirements_testing/models/test5/include/sched.d deleted file mode 100644 index 1d3aafd3..00000000 --- a/trick_test/requirements_testing/models/test5/include/sched.d +++ /dev/null @@ -1,35 +0,0 @@ -/* - * $Log: sched.d,v $ - * Revision 5.1 2004-08-05 13:06:56-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.4 2003/08/26 20:24:13 vetter - * Add Dynamic Event Class To SIM_test_sched - * - * Revision 1.3 2002/10/07 15:16:28 lin - * Add rcs version info to all trick_models files - * - */ - -SCHEDULE.pos = 5.0 ; -SCHEDULE.vel = 0.0 ; -SCHEDULE.acc = 0.0 ; -SCHEDULE.mass = 1.0 ; -SCHEDULE.amf = 1 ; -SCHEDULE.amf_error = 0 ; - -#define BIG_TGO 10000 -SCHEDULE.rf.lower_set = No ; -SCHEDULE.rf.upper_set = No ; -SCHEDULE.rf.iterations = 0 ; -SCHEDULE.rf.fires = 0 ; -SCHEDULE.rf.x_lower = BIG_TGO ; -SCHEDULE.rf.t_lower = BIG_TGO ; -SCHEDULE.rf.x_upper = BIG_TGO ; -SCHEDULE.rf.t_upper = BIG_TGO ; -SCHEDULE.rf.delta_time = BIG_TGO ; -SCHEDULE.rf.error_tol = 1.0e-6 ; -SCHEDULE.rf.mode = Increasing ; diff --git a/trick_test/requirements_testing/models/test5/include/sched.h b/trick_test/requirements_testing/models/test5/include/sched.h deleted file mode 100644 index 9568efe3..00000000 --- a/trick_test/requirements_testing/models/test5/include/sched.h +++ /dev/null @@ -1,42 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Tests requirements: 3.1.2.2, 3.1.2.2.1-7 ) -REFERENCES: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched.h,v $ - * Revision 5.1 2004-08-05 13:06:57-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.4 2003/08/26 20:24:14 vetter - * Add Dynamic Event Class To SIM_test_sched - * - * Revision 1.3 2002/10/07 15:16:28 lin - * Add rcs version info to all trick_models files - * - */ - -#ifndef _SCHEDULE_H_ -#define _SCHEDULE_H_ - -#include "sim_services/include/regula_falsi.h" - -typedef struct { /* SCHEDULE ------------------------------------------------*/ - - double pos ; /* M Position */ - double vel ; /* M/s Velocity */ - double acc ; /* M/s2 Acceleration */ - double mass ; /* kg Mass */ - int amf ; /* -- Just a test variable */ - int amf_error ; /* -- Order error occured in amf job */ - REGULA_FALSI rf ; /* -- Dynamic event */ - -} SCHEDULE ; /*--------------------------------------------------------------*/ - - -#endif diff --git a/trick_test/requirements_testing/models/test5/include/sched_integ.d b/trick_test/requirements_testing/models/test5/include/sched_integ.d deleted file mode 100644 index cee19733..00000000 --- a/trick_test/requirements_testing/models/test5/include/sched_integ.d +++ /dev/null @@ -1,56 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Ball model state integrator default initialization data.) -REFERENCE: - (((Bailey, R.W, and Paddock, E.J.) - (Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((2 dimensional space)) -PROGRAMMERS: - (((Your Name) (Company Name) (Date) (Trick tutorial))) -*******************************************************************************/ - -/* - * $Log: sched_integ.d,v $ - * Revision 7.3 2007-11-06 10:39:22-06 hchen - * Change the way of defining a variable in some .d files related to old style allocation and fix some typos - * - * Revision 7.2 2007-10-23 11:53:06-05 hchen - * Convert the old style allocation statements we have in included sims - * - * Revision 7.1 2006-06-22 14:14:11-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:57-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:18 lin - * Bump version number for 04 - * - * Revision 1.2 2002/10/07 15:16:29 lin - * Add rcs version info to all trick_models files - * - */ - -#define NUM_STEP 12 /* use up to 12 intermediate steps: - 8th order RK Fehlberg */ -#define NUM_VARIABLES 4 /* x,y position state and x,y velocity state */ - -INTEGRATOR.state = alloc(NUM_VARIABLES) ; -INTEGRATOR.deriv = alloc(NUM_STEP) ; -INTEGRATOR.state_ws = alloc(NUM_STEP) ; - -for (int kk = 0 ; kk < NUM_STEP ; kk++ ) { - INTEGRATOR.deriv[kk] = alloc(NUM_VARIABLES) ; - INTEGRATOR.state_ws[kk] = alloc(NUM_VARIABLES) ; -} - -INTEGRATOR.num_state = NUM_VARIABLES ; -INTEGRATOR.option = Runge_Kutta_4 ; /* 4rth order Runge Kutta */ -INTEGRATOR.init = True ; -INTEGRATOR.first_step_deriv = Yes ; - -#undef NUM_STEP -#undef NUM_VARIABLES diff --git a/trick_test/requirements_testing/models/test5/src/CP_out b/trick_test/requirements_testing/models/test5/src/CP_out deleted file mode 100644 index 86a4a967..00000000 --- a/trick_test/requirements_testing/models/test5/src/CP_out +++ /dev/null @@ -1,6 +0,0 @@ -Output for /users/dbankie/trick_dev/07/bin/CP version 07.10.dev-1 at Tue May 13 14:57:31 2008 - -Parsing S_define... - -No S_define file found. Exiting... - diff --git a/trick_test/requirements_testing/models/test5/src/sched_amf.c b/trick_test/requirements_testing/models/test5/src/sched_amf.c deleted file mode 100644 index c78bc961..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_amf.c +++ /dev/null @@ -1,40 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( asynchronous_mustfinish ) -LIBRARY DEPENDENCY: ( sched_amf.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_amf.c,v $ - * Revision 5.1 2004-08-05 13:06:57-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:13 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:29 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_amf( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - if ( S->amf == 2 ) { - /* Things are in order */ - S->amf = 1 ; - } else { - /* Things are out of order */ - S->amf = 3 ; - S->amf_error = 1 ; - } - - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_async.c b/trick_test/requirements_testing/models/test5/src/sched_async.c deleted file mode 100644 index 61d534a5..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_async.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( asynchronous ) -LIBRARY DEPENDENCY: ( sched_async.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_async.c,v $ - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:13 lin - * Bump version number for 04 - * - * Revision 1.4 2002/10/07 15:16:30 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_async ( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - - while ( 1 ) { - /* Try and hang the sim... */ - usleep(1000000) ; - } - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_automatic.c b/trick_test/requirements_testing/models/test5/src/sched_automatic.c deleted file mode 100644 index a0b77d3c..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_automatic.c +++ /dev/null @@ -1,32 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_automatic) -***************************************************************************/ -#include "../include/sched.h" -#include -#include "sim_services/include/executive.h" -#include "sim_services/include/jobdata.h" -#include "sim_services/include/module_classes.h" -#include "sim_services/include/exec_proto.h" - -Realtime_Process_ID exec_get_process_id(void); - -extern JOBDATA *exec_jobs[]; - -int sched_automatic( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - EXECUTIVE *E; - EXEC_WORK *EW; - - Realtime_Process_ID process_id; - - E = exec_get_exec(); - EW = &(E->work); - - process_id = exec_get_process_id(); - exec_reschedule(3, EW->job_select[process_id], exec_get_sim_time() + 1.1); - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_automatic_last.c b/trick_test/requirements_testing/models/test5/src/sched_automatic_last.c deleted file mode 100644 index c0eb703b..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_automatic_last.c +++ /dev/null @@ -1,33 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_automatic_last) -***************************************************************************/ -#include "../include/sched.h" -#include -#include "sim_services/include/executive.h" -#include "sim_services/include/jobdata.h" -#include "sim_services/include/module_classes.h" -#include "sim_services/include/exec_proto.h" - -Realtime_Process_ID exec_get_process_id(void); - -extern JOBDATA *exec_jobs[]; - -int sched_automatic_last( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - - EXECUTIVE *E; - EXEC_WORK *EW; - - Realtime_Process_ID process_id; - - E = exec_get_exec(); - EW = &(E->work); - - process_id = exec_get_process_id(); - exec_reschedule(3, EW->job_select[process_id], exec_get_sim_time() + 1.2); - - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_checkpoint.c b/trick_test/requirements_testing/models/test5/src/sched_checkpoint.c deleted file mode 100644 index 5ca57339..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_checkpoint.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_checkpoint) -***************************************************************************/ -#include "../include/sched.h" - -int sched_checkpoint( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_deriv.c b/trick_test/requirements_testing/models/test5/src/sched_deriv.c deleted file mode 100644 index 969e6ebc..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_deriv.c +++ /dev/null @@ -1,34 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( derivative ) -LIBRARY DEPENDENCY: ( sched_deriv.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) (Trick tutorial) ) -*******************************************************************************/ - -/* - * $Log: sched_deriv.c,v $ - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:13 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:30 lin - * Add rcs version info to all trick_models files - * - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - - -int sched_deriv( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->acc = -1 * S->pos * S->mass ; - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_dyn_event.c b/trick_test/requirements_testing/models/test5/src/sched_dyn_event.c deleted file mode 100644 index d7ece6a2..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_dyn_event.c +++ /dev/null @@ -1,56 +0,0 @@ -/******************************* TRICK HEADER ******************************* -PURPOSE: (Test regula falsi ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( A program has to know its limitations, - that is my assumption :P ) -CLASS: (dynamic_event) -LIBRARY DEPENDENCY: (sched_dyn_event.o) -PROGRAMMERS: ( Keith Vetter a.k.a brillo ) -*****************************************************************************/ - -/* - * $Log: sched_dyn_event.c,v $ - * Revision 5.2 2006-04-13 14:39:47-05 jkowing - * Export functions to header files. - * - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.2 2004/01/16 21:48:56 lin - * Add a log to all files - * - */ - -#include -#include "../include/sched.h" -#include "sim_services/include/regula_falsi.h" - -double sched_dyn_event( - /* RETURN: s Time to go to event */ -SCHEDULE * S , /* INOUT: -- */ -double *time , /* IN: s Integrator time from the executive */ -int *event_evaluate_tgo ) /* IN: -- Event time to go function eval flag, - 1 = evaluate time to go for event, - 0 = fire event */ -{ - - double tgo ; - - if( *event_evaluate_tgo ) { - - /* CALCULATE TIME TO GO FOR EVENT */ - S->rf.error = S->mass - 1.2 ; - tgo = regula_falsi( *time , &(S->rf) ) ; - - } else { - - /* FIRE EVENT */ - reset_regula_falsi( *time , &(S->rf) ) ; - tgo = 0.0 ; - - /* Make mass zig zag once it hits 1.2kg */ - S->mass = S->mass - 0.01 ; - } - - return( tgo ) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_effector.c b/trick_test/requirements_testing/models/test5/src/sched_effector.c deleted file mode 100644 index f72e954c..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_effector.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( effector ) -LIBRARY DEPENDENCY: ( sched_effector.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_effector.c,v $ - * Revision 5.1 2004-08-05 13:06:58-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:14 lin - * Bump version number for 04 - * - * Revision 1.4 2002/10/07 15:16:30 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_effector( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.0000002 + 0.00000002 ; /* Sensor is collecting dust */ - - if ( S->amf == 1 ) { - /* Things are good */ - S->amf = 2 ; - } else { - /* Things are out of order */ - S->amf = 3 ; - S->amf_error = 1 ; - } - - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_effector_emitter.c b/trick_test/requirements_testing/models/test5/src/sched_effector_emitter.c deleted file mode 100644 index f5f262f8..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_effector_emitter.c +++ /dev/null @@ -1,33 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( effector_emitter ) -LIBRARY DEPENDENCY: ( sched_effector_emitter.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_effector_emitter.c,v $ - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:14 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:31 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_effector_emitter( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000003 + 0.000003 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_effector_receiver.c b/trick_test/requirements_testing/models/test5/src/sched_effector_receiver.c deleted file mode 100644 index 9c85b0ea..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_effector_receiver.c +++ /dev/null @@ -1,33 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( effector_receiver ) -LIBRARY DEPENDENCY: ( sched_effector_receiver.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_effector_receiver.c,v $ - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:14 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:31 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_effector_receiver( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000004 + 0.000004 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_environment.c b/trick_test/requirements_testing/models/test5/src/sched_environment.c deleted file mode 100644 index f35ba7c2..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_environment.c +++ /dev/null @@ -1,34 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( environment ) -LIBRARY DEPENDENCY: ( sched_environment.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_environment.c,v $ - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:15 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:31 lin - * Add rcs version info to all trick_models files - * - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - - -int sched_environment( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000005 + 0.000005 ; /* Mass growing, dust collection :-) */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_freeze.c b/trick_test/requirements_testing/models/test5/src/sched_freeze.c deleted file mode 100644 index c22835b3..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_freeze.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_freeze) -***************************************************************************/ -#include "../include/sched.h" - -int sched_freeze( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_freeze_init.c b/trick_test/requirements_testing/models/test5/src/sched_freeze_init.c deleted file mode 100644 index b2de47b8..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_freeze_init.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_freeze_init) -***************************************************************************/ -#include "../include/sched.h" - -int sched_freeze_init( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_init.c b/trick_test/requirements_testing/models/test5/src/sched_init.c deleted file mode 100644 index f241c1aa..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_init.c +++ /dev/null @@ -1,29 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_init) -REFERENCES: (none) -ASSUMPTIONS AND LIMITATIONS: (Autocreated by trick_ui) -CLASS: (initialization) -LIBRARY DEPENDENCY: (sched_init.o) -PROGRAMMERS: ((vetter) (Tue Aug 26 13:22:44 CDT 2003)) -***************************************************************************/ - -/* - * $Log: sched_init.c,v $ - * Revision 5.1 2004-08-05 13:06:59-05 lin - * Bump - * - * Revision 4.2 2004/01/16 21:48:56 lin - * Add a log to all files - * - */ - -#include "../include/sched.h" - -int sched_init( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - S->mass = S->mass*1.0000013 + 0.0000013 ; /* Massive masses */ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_integ.c b/trick_test/requirements_testing/models/test5/src/sched_integ.c deleted file mode 100644 index 6c9a9e0f..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_integ.c +++ /dev/null @@ -1,46 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( integration ) -LIBRARY DEPENDENCY: ( sched_integ.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) (Trick tutorial) ) -*******************************************************************************/ - -/* - * $Log: sched_integ.c,v $ - * Revision 5.2 2006-04-13 14:39:48-05 jkowing - * Export functions to header files. - * - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:15 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:32 lin - * Add rcs version info to all trick_models files - * - */ - -#include "sim_services/include/integrator.h" -#include "../include/sched.h" - -int sched_integ( - /* RETURN: -- Always return zero */ - INTEGRATOR *I , /* INOUT: -- Trick state integration parameters */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - I->state[0] = S->pos ; - I->state[1] = S->vel ; - - I->deriv[I->intermediate_step][0] = S->vel ; - I->deriv[I->intermediate_step][1] = S->acc ; - - integrate( I ) ; - - S->pos = I->state_ws[I->intermediate_step][0] ; - S->vel = I->state_ws[I->intermediate_step][1] ; - - return( I->intermediate_step ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_logging.c b/trick_test/requirements_testing/models/test5/src/sched_logging.c deleted file mode 100644 index 16fa450e..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_logging.c +++ /dev/null @@ -1,33 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( logging ) -LIBRARY DEPENDENCY: ( sched_logging.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_logging.c,v $ - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:15 lin - * Bump version number for 04 - * - * Revision 1.4 2002/10/07 15:16:32 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_logging( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000006 + 0.000006 ; /* Sensor is collecting dust */ - - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_post_integ.c b/trick_test/requirements_testing/models/test5/src/sched_post_integ.c deleted file mode 100644 index 2ce450bd..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_post_integ.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_post_integ) -***************************************************************************/ -#include "../include/sched.h" - -int sched_post_integ( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_pre_load.c b/trick_test/requirements_testing/models/test5/src/sched_pre_load.c deleted file mode 100644 index 210739be..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_pre_load.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_pre_load) -***************************************************************************/ -#include "../include/sched.h" - -int sched_pre_load( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_random.c b/trick_test/requirements_testing/models/test5/src/sched_random.c deleted file mode 100644 index ea7dca05..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_random.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_random) -***************************************************************************/ -#include "../include/sched.h" - -int sched_random( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_restart.c b/trick_test/requirements_testing/models/test5/src/sched_restart.c deleted file mode 100644 index 04767739..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_restart.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_restart) -***************************************************************************/ -#include "../include/sched.h" - -int sched_restart( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_scheduled1.c b/trick_test/requirements_testing/models/test5/src/sched_scheduled1.c deleted file mode 100644 index 70e1c481..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_scheduled1.c +++ /dev/null @@ -1,32 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_scheduled.c,v $ - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_scheduled1( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000007 + 0.000007 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_scheduled2.c b/trick_test/requirements_testing/models/test5/src/sched_scheduled2.c deleted file mode 100644 index c780d222..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_scheduled2.c +++ /dev/null @@ -1,32 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_scheduled.c,v $ - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_scheduled2( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000007 + 0.000007 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_scheduled3.c b/trick_test/requirements_testing/models/test5/src/sched_scheduled3.c deleted file mode 100644 index ebca8f90..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_scheduled3.c +++ /dev/null @@ -1,32 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_scheduled.c,v $ - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_scheduled3( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000007 + 0.000007 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_scheduled4.c b/trick_test/requirements_testing/models/test5/src/sched_scheduled4.c deleted file mode 100644 index 3b122721..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_scheduled4.c +++ /dev/null @@ -1,32 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_scheduled.c,v $ - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_scheduled4( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000007 + 0.000007 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_scheduled5.c b/trick_test/requirements_testing/models/test5/src/sched_scheduled5.c deleted file mode 100644 index 657f6102..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_scheduled5.c +++ /dev/null @@ -1,32 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( scheduled ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_scheduled.c,v $ - * Revision 5.1 2004-08-05 13:07:00-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_scheduled5( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000007 + 0.000007 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_sensor.c b/trick_test/requirements_testing/models/test5/src/sched_sensor.c deleted file mode 100644 index 49bc8422..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_sensor.c +++ /dev/null @@ -1,33 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor ) -LIBRARY DEPENDENCY: ( sched_sensor.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor.c,v $ - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_sensor( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000008 + 0.000008 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_sensor_emitter.c b/trick_test/requirements_testing/models/test5/src/sched_sensor_emitter.c deleted file mode 100644 index f616009b..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_sensor_emitter.c +++ /dev/null @@ -1,32 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor_emitter ) -LIBRARY DEPENDENCY: ( sched_sensor_emitter.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor_emitter.c,v $ - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:16 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:33 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - -int sched_sensor_emitter( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.000009 + 0.000009 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_sensor_receiver.c b/trick_test/requirements_testing/models/test5/src/sched_sensor_receiver.c deleted file mode 100644 index 420a0f5c..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_sensor_receiver.c +++ /dev/null @@ -1,33 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor_receiver ) -LIBRARY DEPENDENCY: ( sched_sensor_receiver.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor_receiver.c,v $ - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:34 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_sensor_receiver( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.00021 + 0.000021 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_sensor_reflector.c b/trick_test/requirements_testing/models/test5/src/sched_sensor_reflector.c deleted file mode 100644 index a57345bd..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_sensor_reflector.c +++ /dev/null @@ -1,33 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: ( Test scheduling ) -REFERENCE: ( None ) -ASSUMPTIONS AND LIMITATIONS: ( None ) -CLASS: ( sensor_reflector ) -LIBRARY DEPENDENCY: ( sched_sensor_reflector.o ) -PROGRAMMERS: ( (Keith Vetter) (Titan) (8-20-2002) ) -*******************************************************************************/ - -/* - * $Log: sched_sensor_reflector.c,v $ - * Revision 5.1 2004-08-05 13:07:01-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:17 lin - * Bump version number for 04 - * - * Revision 1.3 2002/10/07 15:16:34 lin - * Add rcs version info to all trick_models files - * - */ - -#include "../include/sched.h" - - -int sched_sensor_reflector( - /* RETURN: -- Always return zero */ - SCHEDULE *S ) /* INOUT: -- Schedule struct */ -{ - S->mass = S->mass*1.00000022 + 0.0000022 ; /* Sensor is collecting dust */ - - return( 0 ); -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_shutdown.c b/trick_test/requirements_testing/models/test5/src/sched_shutdown.c deleted file mode 100644 index aca5384b..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_shutdown.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_shutdown) -***************************************************************************/ -#include "../include/sched.h" - -int sched_shutdown( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test5/src/sched_unfreeze.c b/trick_test/requirements_testing/models/test5/src/sched_unfreeze.c deleted file mode 100644 index 9eb7e2f6..00000000 --- a/trick_test/requirements_testing/models/test5/src/sched_unfreeze.c +++ /dev/null @@ -1,12 +0,0 @@ -/*********************************** TRICK HEADER ************************** -PURPOSE: (Test sched_unfreeze) -***************************************************************************/ -#include "../include/sched.h" - -int sched_unfreeze( - /* RETURN: -- Always return zero */ - SCHEDULE *S) /* INOUT: -- Parameter */ - -{ - return(0) ; -} diff --git a/trick_test/requirements_testing/models/test6/include/test6.d b/trick_test/requirements_testing/models/test6/include/test6.d deleted file mode 100644 index 52248b31..00000000 --- a/trick_test/requirements_testing/models/test6/include/test6.d +++ /dev/null @@ -1 +0,0 @@ -TEST6.i = 0; diff --git a/trick_test/requirements_testing/models/test6/include/test6.h b/trick_test/requirements_testing/models/test6/include/test6.h deleted file mode 100644 index 89997289..00000000 --- a/trick_test/requirements_testing/models/test6/include/test6.h +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Tests requirements: 3.3.2.1, 3.3.2.1.2, 3.3.2.1.4-6, 3.3.2.1.10, - 3.3.2.1.10.1-3, 3.1.2.6-7) -*******************************************************************************/ - -#ifndef _test6_h_ -#define _test6_h_ - -typedef struct { - int i; -} TEST6; - -#endif diff --git a/trick_test/requirements_testing/models/test6/src/test6_check.c b/trick_test/requirements_testing/models/test6/src/test6_check.c deleted file mode 100644 index 358c40db..00000000 --- a/trick_test/requirements_testing/models/test6/src/test6_check.c +++ /dev/null @@ -1,9 +0,0 @@ -/******************************************************************************* -PURPOSE: (Checkpoint job.) -*******************************************************************************/ - -#include "../include/test6.h" - -int test6_check(TEST6* T) { - T->i += 5; -} diff --git a/trick_test/requirements_testing/models/test6/src/test6_sched.c b/trick_test/requirements_testing/models/test6/src/test6_sched.c deleted file mode 100644 index c7ce8a36..00000000 --- a/trick_test/requirements_testing/models/test6/src/test6_sched.c +++ /dev/null @@ -1,9 +0,0 @@ -/******************************************************************************* -PURPOSE: (Scheduled job.) -*******************************************************************************/ - -#include "../include/test6.h" - -int test6_sched(TEST6* T) { - T->i++; -} diff --git a/trick_test/requirements_testing/models/test7/impexp/.checksums b/trick_test/requirements_testing/models/test7/impexp/.checksums deleted file mode 100644 index ba79f62e..00000000 --- a/trick_test/requirements_testing/models/test7/impexp/.checksums +++ /dev/null @@ -1,5 +0,0 @@ -64414 2 ./src/export_master.c -64733 2 ./src/export_slave.c -63364 2 ./src/import_master.c -3730 3 ./src/import_slave.c -18794 3 ./include/test.h diff --git a/trick_test/requirements_testing/models/test7/impexp/include/test.h b/trick_test/requirements_testing/models/test7/impexp/include/test.h deleted file mode 100644 index afa64d53..00000000 --- a/trick_test/requirements_testing/models/test7/impexp/include/test.h +++ /dev/null @@ -1,56 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - (Tests requirements: 3.3.2.1.6, 3.1.2.8, 3.1.2.8.1-6) -REFERENCES: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (Nov 2001))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: test.h,v $ - * Revision 7.1 2006-06-22 14:14:17-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:53-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:21 lin - * Bump version number for 04 - * - * Revision 3.3 2002/10/07 15:16:24 lin - * Add rcs version info to all trick_models files - * - */ - -#ifndef _TEST_H_ -#define _TEST_H_ - -typedef struct { /* A ------------------------------------------------*/ - - double d ; /* -- A double */ - int i ; /* -- An int */ - int j ; /* -- An int */ - -} A ; /*--------------------------------------------------------------*/ - -typedef struct { /* B ------------------------------------------------*/ - - double d ; /* -- A double */ - int i ; /* -- An int */ - int j ; /* -- An int */ - -} B ; /*--------------------------------------------------------------*/ - -typedef struct { /* TEST ---------------------------------------------*/ - - A a ; /* -- A */ - B b ; /* -- B */ - -} TEST ; /*------------------------------------------------------------*/ - -#endif diff --git a/trick_test/requirements_testing/models/test7/impexp/src/export_master.c b/trick_test/requirements_testing/models/test7/impexp/src/export_master.c deleted file mode 100644 index c2f04c7b..00000000 --- a/trick_test/requirements_testing/models/test7/impexp/src/export_master.c +++ /dev/null @@ -1,48 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((export_master.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: export_master.c,v $ - * Revision 7.1 2006-06-22 14:14:15-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:53-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:20 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:25 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include "../include/test.h" - - /* ENTRY POINT */ -void export_master( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - - T->a.i++ ; - T->a.d += 0.1 ; - - T->b.i-- ; - T->b.d -= 0.1 ; -} diff --git a/trick_test/requirements_testing/models/test7/impexp/src/export_slave.c b/trick_test/requirements_testing/models/test7/impexp/src/export_slave.c deleted file mode 100644 index 05e5741e..00000000 --- a/trick_test/requirements_testing/models/test7/impexp/src/export_slave.c +++ /dev/null @@ -1,47 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((export_slave.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: export_slave.c,v $ - * Revision 7.1 2006-06-22 14:14:16-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:54-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:20 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:25 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include -#include "../include/test.h" - - /* ENTRY POINT */ -void export_slave( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - - /* Do nothing */ - T->a.i = T->a.i ; - -} diff --git a/trick_test/requirements_testing/models/test7/impexp/src/import_master.c b/trick_test/requirements_testing/models/test7/impexp/src/import_master.c deleted file mode 100644 index bc78c7bb..00000000 --- a/trick_test/requirements_testing/models/test7/impexp/src/import_master.c +++ /dev/null @@ -1,44 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((import_master.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: import_master.c,v $ - * Revision 7.1 2006-06-22 14:14:16-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:54-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:20 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:26 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include "../include/test.h" - - /* ENTRY POINT */ -void import_master( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - /* Do nothing */ - T->a.i = T->a.i ; -} diff --git a/trick_test/requirements_testing/models/test7/impexp/src/import_slave.c b/trick_test/requirements_testing/models/test7/impexp/src/import_slave.c deleted file mode 100644 index 79d1b05a..00000000 --- a/trick_test/requirements_testing/models/test7/impexp/src/import_slave.c +++ /dev/null @@ -1,53 +0,0 @@ -/********************************* TRICK HEADER ******************************* -PURPOSE: - ( Testing ) -REFERENCE: - (((Trick Simulation Environment) (NASA:JSC #37943) - (JSC/Engineering Directorate/Automation, Robotics and Simulation Division) - (March 1997))) -ASSUMPTIONS AND LIMITATIONS: - ((None)) -CLASS: - (scheduled) -LIBRARY DEPENDENCY: - ((import_slave.o)) -PROGRAMMERS: - ((Keith Vetter) (LinCom) (November 2001)) -*******************************************************************************/ - -/* - * $Log: import_slave.c,v $ - * Revision 7.1 2006-06-22 14:14:17-05 lin - * Bump version number for 07 - * - * Revision 5.1 2004-08-05 13:06:54-05 lin - * Bump - * - * Revision 4.1 2003/10/21 21:49:21 lin - * Bump version number for 04 - * - * Revision 3.2 2002/10/07 15:16:26 lin - * Add rcs version info to all trick_models files - * - */ - - /* GLOBAL DATA STRUCTURE DECLARATIONS */ -#include -#include "../include/test.h" - - /* ENTRY POINT */ -void import_slave( - /* RETURN: -- NA */ - TEST *T ) /* INOUT: -- TEST */ -{ - - /* Make a saw tooth */ - if ( T->a.i > 20 ) { - T->a.i = 0 ; - T->a.d = 0 ; - - T->b.i = 0 ; - T->b.d = 0 ; - } - -} diff --git a/trick_test/requirements_testing/models/test8/include/test8.d b/trick_test/requirements_testing/models/test8/include/test8.d deleted file mode 100644 index 9853a9dc..00000000 --- a/trick_test/requirements_testing/models/test8/include/test8.d +++ /dev/null @@ -1 +0,0 @@ -TEST8.i = -1; diff --git a/trick_test/requirements_testing/models/test8/include/test8.h b/trick_test/requirements_testing/models/test8/include/test8.h deleted file mode 100644 index 0ab6591c..00000000 --- a/trick_test/requirements_testing/models/test8/include/test8.h +++ /dev/null @@ -1,12 +0,0 @@ -/****************************************************************************** -PURPOSE: (Tests requirements: 3.3.2.1.8, 3.3.2.1.12, 3.3.2.1.12.1-2) -******************************************************************************/ - -#ifndef _test8_h_ -#define _test8_h_ - -typedef struct { - int i; -} TEST8; - -#endif diff --git a/trick_test/requirements_testing/models/test8/src/test8_event3.c b/trick_test/requirements_testing/models/test8/src/test8_event3.c deleted file mode 100644 index e4d4673b..00000000 --- a/trick_test/requirements_testing/models/test8/src/test8_event3.c +++ /dev/null @@ -1,9 +0,0 @@ -/******************************************************************************* -PURPOSE: (Test CALLs from ACTION blocks in events defined in the input file. -*******************************************************************************/ - -#include "sim_services/include/exec_proto.h" - -int test8_event3() { - printf("event3 (%f): This event fires every other second.\n", exec_get_sim_time()); -} diff --git a/trick_test/requirements_testing/models/test8/src/test8_sched.c b/trick_test/requirements_testing/models/test8/src/test8_sched.c deleted file mode 100644 index f3a4b4f4..00000000 --- a/trick_test/requirements_testing/models/test8/src/test8_sched.c +++ /dev/null @@ -1,12 +0,0 @@ -#include "../include/test8.h" -#include "sim_services/include/exec_proto.h" - -int test8_sched(TEST8 *T) { - if (exec_get_sim_time() < 19) { - T->i++; - } - else { - T->i--; - } - //printf("%f: i = %d\n", exec_get_sim_time(), T->i); -} diff --git a/trick_test/requirements_testing/models/test9/include/test9.d b/trick_test/requirements_testing/models/test9/include/test9.d deleted file mode 100644 index 561e0b57..00000000 --- a/trick_test/requirements_testing/models/test9/include/test9.d +++ /dev/null @@ -1 +0,0 @@ -TEST9.d = 0; diff --git a/trick_test/requirements_testing/models/test9/include/test9.h b/trick_test/requirements_testing/models/test9/include/test9.h deleted file mode 100644 index 0514b543..00000000 --- a/trick_test/requirements_testing/models/test9/include/test9.h +++ /dev/null @@ -1,13 +0,0 @@ -/******************************************************************************* -PURPOSE: (Tests requirements: 3.1.2.13, 3.1.2.13.1, 3.1.2.13.3, 3.1.2.1.3.6, - 3.1.2.1.3.6.1-8) -*******************************************************************************/ - -#ifndef _test9_h_ -#define _test9_h_ - -typedef struct { - double d; -} TEST9; - -#endif diff --git a/trick_test/requirements_testing/models/test9/src/test9_master_init.c b/trick_test/requirements_testing/models/test9/src/test9_master_init.c deleted file mode 100644 index 800f66a4..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_master_init.c +++ /dev/null @@ -1 +0,0 @@ -int test9_master_init() {} diff --git a/trick_test/requirements_testing/models/test9/src/test9_master_post.c b/trick_test/requirements_testing/models/test9/src/test9_master_post.c deleted file mode 100644 index 0b0e3061..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_master_post.c +++ /dev/null @@ -1 +0,0 @@ -int test9_master_post() {} diff --git a/trick_test/requirements_testing/models/test9/src/test9_master_pre.c b/trick_test/requirements_testing/models/test9/src/test9_master_pre.c deleted file mode 100644 index 3c247a53..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_master_pre.c +++ /dev/null @@ -1 +0,0 @@ -int test9_master_pre() {} diff --git a/trick_test/requirements_testing/models/test9/src/test9_master_shutdown.c b/trick_test/requirements_testing/models/test9/src/test9_master_shutdown.c deleted file mode 100644 index 3ec81446..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_master_shutdown.c +++ /dev/null @@ -1 +0,0 @@ -int test9_master_shutdown() {} diff --git a/trick_test/requirements_testing/models/test9/src/test9_slave_init.c b/trick_test/requirements_testing/models/test9/src/test9_slave_init.c deleted file mode 100644 index d912b606..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_slave_init.c +++ /dev/null @@ -1 +0,0 @@ -int test9_slave_init() {} diff --git a/trick_test/requirements_testing/models/test9/src/test9_slave_post.c b/trick_test/requirements_testing/models/test9/src/test9_slave_post.c deleted file mode 100644 index b4df51e4..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_slave_post.c +++ /dev/null @@ -1 +0,0 @@ -int test9_slave_post() {} diff --git a/trick_test/requirements_testing/models/test9/src/test9_slave_pre.c b/trick_test/requirements_testing/models/test9/src/test9_slave_pre.c deleted file mode 100644 index 48befb12..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_slave_pre.c +++ /dev/null @@ -1 +0,0 @@ -int test9_slave_pre() {} diff --git a/trick_test/requirements_testing/models/test9/src/test9_slave_shutdown.c b/trick_test/requirements_testing/models/test9/src/test9_slave_shutdown.c deleted file mode 100644 index 568a7ce7..00000000 --- a/trick_test/requirements_testing/models/test9/src/test9_slave_shutdown.c +++ /dev/null @@ -1 +0,0 @@ -int test9_slave_shutdown() {} diff --git a/trick_test/requirements_testing/models/test_wchar/.checksums b/trick_test/requirements_testing/models/test_wchar/.checksums deleted file mode 100644 index 5fbfabac..00000000 --- a/trick_test/requirements_testing/models/test_wchar/.checksums +++ /dev/null @@ -1,4 +0,0 @@ -20793 12 ./src/ip_test.c -8488 10 ./include/ip_c_types.h -18178 28 ./include/ip_test.d -57882 9 ./include/ip_test.h diff --git a/trick_test/requirements_testing/models/test_wchar/include/test_wchar.d b/trick_test/requirements_testing/models/test_wchar/include/test_wchar.d deleted file mode 100644 index 45a77299..00000000 --- a/trick_test/requirements_testing/models/test_wchar/include/test_wchar.d +++ /dev/null @@ -1,13 +0,0 @@ -TEST_WCHAR.c = alloc(2); -TEST_WCHAR.w = alloc(2); -int i, j; -for(i = 0; i < 2; i++) { - TEST_WCHAR.w[i] = alloc(2); - for (j = 0; j < 2; j++) { - TEST_WCHAR.w[i][j] = alloc(2); - } -} - -TEST_WCHAR.c[0] = "Normal", "String"; -//TEST_WCHAR.w[0][0][0] = "Wide", "String"; -TEST_WCHAR.w[0][0][0] = 'W', 'S'; diff --git a/trick_test/requirements_testing/models/test_wchar/include/test_wchar.h b/trick_test/requirements_testing/models/test_wchar/include/test_wchar.h deleted file mode 100644 index 5e7c1b67..00000000 --- a/trick_test/requirements_testing/models/test_wchar/include/test_wchar.h +++ /dev/null @@ -1,13 +0,0 @@ -#ifndef _test_wchar_h_ -#define _test_wchar_h_ - -#include - -typedef struct { - - char ** c; - wchar_t *** w; - -} TEST_WCHAR ; - -#endif diff --git a/trick_test/requirements_testing/sims/SIM_test1/RUN_test/input b/trick_test/requirements_testing/sims/SIM_test1/RUN_test/input deleted file mode 100644 index 51ea276a..00000000 --- a/trick_test/requirements_testing/sims/SIM_test1/RUN_test/input +++ /dev/null @@ -1,27 +0,0 @@ -#include "S_default.dat" - -sys.exec.in.frame_log = Yes; - -sys.exec.in.rt_software_frame {s} = 1.0; -sys.exec.in.rt_itimer = Yes; -sys.exec.in.rt_itimer_pause = Yes; -sys.exec.in.rt_itimer_frame {s} = 1.0; - -// Enable the sim control panel -sys.exec.sim_com.monitor_on = Yes; - -// Start the simulation in freeze mode -sys.exec.in.enable_freeze = Yes; -sys.exec.work.freeze_command = Yes; - -// Requirement 3.1.2.9.3 -sys.exec.in.pre_init_checkpoint = Yes; - -// Requirement 3.1.2.9.4 -sys.exec.in.post_init_checkpoint = Yes; - -// Requirement 3.1.2.9.5 -sys.exec.in.end_checkpoint = Yes; - -stop = 10.0; - diff --git a/trick_test/requirements_testing/sims/SIM_test1/S_define b/trick_test/requirements_testing/sims/SIM_test1/S_define deleted file mode 100644 index b74be0c0..00000000 --- a/trick_test/requirements_testing/sims/SIM_test1/S_define +++ /dev/null @@ -1,19 +0,0 @@ -sim_object { - sim_services/include: EXECUTIVE exec (sim_services/include/executive.d); - - (automatic) sim_services/input_processor: - input_processor(INPUT_PROCESSOR* IP = &sys.exec.ip); -} sys; - -sim_object { - test1: TEST1 test1 (test1/include/test1.d); - - (initialization) test1: - test1_init(TEST1* T = &dyn.test1); - - (1.00, scheduled) test1: - test1_cyclic(TEST1* T = &dyn.test1); - - (shutdown) test1: - test1_shutdown(TEST1* T = &dyn.test1); -} dyn; diff --git a/trick_test/requirements_testing/sims/SIM_test1/Test1Procedure.txt b/trick_test/requirements_testing/sims/SIM_test1/Test1Procedure.txt deleted file mode 100644 index cf9a45f7..00000000 --- a/trick_test/requirements_testing/sims/SIM_test1/Test1Procedure.txt +++ /dev/null @@ -1,82 +0,0 @@ -TEST 1 - -PURPOSE: This test verifies the checkpoint-reload requirements specified -in section 3.1.2.9 of the Trick reuirements document. - -REQUIREMENTS: -3.1.2.9, 3.1.2.9.1, 3.1.2.9.2, 3.1.2.9.3 ,3.1.2.9.4, 3.1.2.9.5 - -TEST STEPS: - -1) Run CP. - - Expected result(s): CP completes successfully. You should see: - - === Simulation make complete === - -2) Type the following and press RETURN: - S_main_{$TRICK_HOST_CPU}.exe RUN_test/input - - Expected result(s): - a) the sim_control panel appears, - b) the sim is in Freeze mode and - c) Run Elapsed Time (RET) is equal to 0.00. - -3) Run the simulation for a few seconds by pressing the Start button - on the sim_control panel, waiting about three seconds and then pressing the Freeze button. - - Expected result(s): - a) the sim is again in freeze mode and - b) RET is non-zero. - -4) Record the value in the RET field. (e.g., 3.00) : _____ - -5) On the sim control panel Press the "Dump Chkpnt" button. - Expected result(s): - A file dialog appears. - -6) Record the name of checkpoint file. (e.g., chk_3.00) : _____ - -7) On the dialog, press the Save button. - Expected result(s): - a) The file dialog disappears. - b) an ASCII file of the name recorded in step 6 is created in the RUN_test/ directory. - -8) Run the simulation for a few more seconds by pressing the Start button -on the sim_control panel, waiting about three seconds and then pressing the Freeze button. - - Expected result(s): - a) the sim is again in freeze mode and - b) RET is greater than that recorded in step 4. - -4) Record the value in the RET field. (e.g., 5.00) : _____ - -9) On the sim control panel Press the "Load Chkpnt" button. - - Expected result(s): - A file dialog appears. - -10) In the "File name" field of the file dialog, enter the name of the -checkpoint file recorded in step 6 and press the Open button. - - Expected result(s): - the value in the RET field returns to the value recorded in step 4. - -11) Press Start. - - Expected result(s): - The simulation runs to completion. - -12) Press Exit. - Expected result(s): - Sim control panel disappears. - -13) Verify that the ASCII file RUN_test/chkpnt_pre_init exists. - -14) Verify that the ASCII file RUN_test/chkpnt_post_init exists. - -15) Verify that the ASCII file RUN_test/chkpnt_end_10.000 exists. - -END OF TEST. - - diff --git a/trick_test/requirements_testing/sims/SIM_test2/DP_Product/DP_spring b/trick_test/requirements_testing/sims/SIM_test2/DP_Product/DP_spring deleted file mode 100644 index b711235f..00000000 --- a/trick_test/requirements_testing/sims/SIM_test2/DP_Product/DP_spring +++ /dev/null @@ -1,93 +0,0 @@ -No title specified - -PLOTS: - -PAGE 1: "Page" - - PLOT 1: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "parent.sched.msd.analytic.pos" - UNITS: "m" - LABEL: "parent.sched.msd.analytic.pos" - TIME_NAME: "sys.exec.out.time" - -PAGE 2: "Page" - - PLOT 1: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "parent.sched.msd.numeric.pos" - UNITS: "m" - LABEL: "parent.sched.msd.numeric.pos" - TIME_NAME: "sys.exec.out.time" - -PAGE 3: "Page" - - PLOT 1: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "parent.sched.msd.analytic.vel" - UNITS: "m/s" - LABEL: "parent.sched.msd.analytic.vel" - TIME_NAME: "sys.exec.out.time" - -PAGE 4: "Page" - - PLOT 1: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "parent.sched.msd.numeric.vel" - UNITS: "m/s" - LABEL: "parent.sched.msd.numeric.vel" - TIME_NAME: "sys.exec.out.time" - -PAGE 5: "Page" - - PLOT 1: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "parent.sched.msd.delta_pos" - UNITS: "m" - LABEL: "parent.sched.msd.delta_pos" - TIME_NAME: "sys.exec.out.time" - -PAGE 6: "Page" - - PLOT 1: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "parent.sched.msd.delta_vel" - UNITS: "m/s" - LABEL: "parent.sched.msd.delta_vel" - TIME_NAME: "sys.exec.out.time" diff --git a/trick_test/requirements_testing/sims/SIM_test2/RUN_A/input b/trick_test/requirements_testing/sims/SIM_test2/RUN_A/input deleted file mode 100644 index 011ce09a..00000000 --- a/trick_test/requirements_testing/sims/SIM_test2/RUN_A/input +++ /dev/null @@ -1,79 +0,0 @@ -#include "S_default.dat" - -#define CLOCK 0 -#define MASTER 1 -#define CHILD1 2 -#define CHILD2 3 -#define CHILD3 4 - -// ***************************************************** -// DATA RECORDING -// ***************************************************** -#ifndef DR_GROUP_ID -#define DR_GROUP_ID sys.exec.record.num_group -#endif - -sys.exec.record.group[DR_GROUP_ID].record = Yes ; -sys.exec.record.group[DR_GROUP_ID].name = "auto" ; -sys.exec.record.group[DR_GROUP_ID].format = DR_Fixed_Ascii ; -sys.exec.record.group[DR_GROUP_ID].freq = DR_Always ; -sys.exec.record.group[DR_GROUP_ID].cycle {s} = 0.1 ; -sys.exec.record.group[DR_GROUP_ID].ref[0] = - "parent.sched.msd.analytic.pos" , - "parent.sched.msd.analytic.vel" , - "parent.sched.msd.numeric.pos" , - "parent.sched.msd.numeric.vel" , - "parent.sched.msd.delta_pos" , - "parent.sched.msd.delta_vel" ; - -DR_GROUP_ID++ ; /* add 1 to DR_GROUP_ID, THIS SETS DR_GROUP_ID UP - * FOR THE NEXT DATA RECORDING FILE */ - -// ***************************************************** -// REAL-TIME CONTROL -// ***************************************************** -sys.exec.in.rt_software_frame {s} = 0.01 ; -sys.exec.in.rt_itimer = No ; -sys.exec.in.rt_itimer_pause = No ; -sys.exec.in.rt_itimer_frame {s} = 0.01 ; - -sys.exec.in.rt_cpu_number[MASTER] = 1 ; -sys.exec.in.rt_lock_memory[MASTER] = Yes ; -sys.exec.in.rt_nond_pri[MASTER] = Yes ; -sys.exec.in.rt_priority[MASTER] = 1 ; -sys.exec.in.rt_lock_to_cpu[MASTER] = Yes ; - -// ***************************************************** -// Start the simulation in freeze mode. -// ***************************************************** -sys.exec.in.enable_freeze = Yes ; -sys.exec.work.freeze_command = Yes ; - -// ***************************************************** -// Use the sim_control panel -// ***************************************************** -sys.exec.sim_com.monitor_on = Yes ; - -sys.exec.in.frame_log = Yes ; -sys.exec.in.frame_log_max_samples = 5000 ; - -sys.exec.rt_log.group[2].record = Yes ; - -sys.exec.in.echo_job = Yes; - -// ***************************************************** -// Mass-Spring-Damper parameters -// ***************************************************** -parent.sched.msd.params.initial_pos = 5.0 ; -parent.sched.msd.params.initial_vel = 0.0 ; -parent.sched.msd.params.mass = 1.0 ; -parent.sched.msd.params.damping_const = 0.3 ; -parent.sched.msd.params.spring_const = 10.0 ; - -// ***************************************************** -// Dump a checkpoint at simulation time = 1.0 seconds. -// ***************************************************** -checkpoint = 1; - -// Stop the simulation after 10 seconds. -stop = 10; diff --git a/trick_test/requirements_testing/sims/SIM_test2/RUN_B/input b/trick_test/requirements_testing/sims/SIM_test2/RUN_B/input deleted file mode 100644 index 195cf5b9..00000000 --- a/trick_test/requirements_testing/sims/SIM_test2/RUN_B/input +++ /dev/null @@ -1,79 +0,0 @@ -#include "S_default.dat" - -#define CLOCK 0 -#define MASTER 1 -#define CHILD1 2 -#define CHILD2 3 -#define CHILD3 4 - -// ***************************************************** -// DATA RECORDING -// ***************************************************** -#ifndef DR_GROUP_ID -#define DR_GROUP_ID sys.exec.record.num_group -#endif - -sys.exec.record.group[DR_GROUP_ID].record = Yes ; -sys.exec.record.group[DR_GROUP_ID].name = "auto" ; -sys.exec.record.group[DR_GROUP_ID].format = DR_Fixed_Ascii ; -sys.exec.record.group[DR_GROUP_ID].freq = DR_Always ; -sys.exec.record.group[DR_GROUP_ID].cycle {s} = 0.1 ; -sys.exec.record.group[DR_GROUP_ID].ref[0] = - "parent.sched.msd.analytic.pos" , - "parent.sched.msd.analytic.vel" , - "parent.sched.msd.numeric.pos" , - "parent.sched.msd.numeric.vel" , - "parent.sched.msd.delta_pos" , - "parent.sched.msd.delta_vel" ; - -DR_GROUP_ID++ ; /* add 1 to DR_GROUP_ID, THIS SETS DR_GROUP_ID UP - * FOR THE NEXT DATA RECORDING FILE */ - -// ***************************************************** -// REAL-TIME CONTROL -// ***************************************************** -sys.exec.in.rt_software_frame {s} = 1.0 ; -sys.exec.in.rt_itimer = No ; -sys.exec.in.rt_itimer_pause = No ; -sys.exec.in.rt_itimer_frame {s} = 1.0 ; - -sys.exec.in.rt_cpu_number[MASTER] = 1 ; -sys.exec.in.rt_lock_memory[MASTER] = Yes ; -sys.exec.in.rt_nond_pri[MASTER] = Yes ; -sys.exec.in.rt_priority[MASTER] = 1 ; -sys.exec.in.rt_lock_to_cpu[MASTER] = Yes ; - -// ***************************************************** -// Start the simulation is freeze mode. -// ***************************************************** -sys.exec.in.enable_freeze = Yes ; -sys.exec.work.freeze_command = No ; - -// ***************************************************** -// Use the sim_control panel -// ***************************************************** -sys.exec.sim_com.monitor_on = Yes ; - -sys.exec.in.frame_log = Yes ; -sys.exec.in.frame_log_max_samples = 5000 ; - -sys.exec.rt_log.group[2].record = Yes ; - -sys.exec.in.echo_job = No; - -// ***************************************************** -// Mass-Spring-Damper parameters -// ***************************************************** -parent.sched.msd.params.initial_pos = 5.0 ; -parent.sched.msd.params.initial_vel = 0.0 ; -parent.sched.msd.params.mass = 1.0 ; -parent.sched.msd.params.damping_const = 0.3 ; -parent.sched.msd.params.spring_const = 10.0 ; - -// ***************************************************** -// Dump a checkpoint at simulation time = 1.0 seconds. -// ***************************************************** -checkpoint = 1; - -// Stop the simulation after 10 seconds. -stop = 10; diff --git a/trick_test/requirements_testing/sims/SIM_test2/S_define b/trick_test/requirements_testing/sims/SIM_test2/S_define deleted file mode 100644 index 49f24d9c..00000000 --- a/trick_test/requirements_testing/sims/SIM_test2/S_define +++ /dev/null @@ -1,119 +0,0 @@ -sim_object { /* TRICK EXECUTIVE ---------------------------------------------*/ - - sim_services/include/: EXECUTIVE exec (sim_services/include/executive.d) ; - - (automatic) sim_services/input_processor: - input_processor( Inout INPUT_PROCESSOR * IP = &sys.exec.ip ) ; - -} sys ; /*-------------------------------------------------------------------*/ - - -sim_object { /* Scheduled ---------------------------------------------------*/ - - sim_services/include: INTEGRATOR integ (test2/include/sched_integ.d) ; - test2: SCHEDULE sched (test2/include/sched.d); - - - /* see Trick Requirement 3.1.2.1.1.1 */ - (initialization) test2: sched_init( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement(s) 3.1.2.1.2.2, 3.1.2.3 */ - (integration) test2: sched_integ( - Inout INTEGRATOR *I = &parent.integ , - Inout MSD_NUMERIC *N = &parent.sched.msd.numeric ) ; - - /* see Trick Requirement 3.1.2.1.2.3 */ - (post_integration) test2: sched_post_integ( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.3.2 */ - (derivative) test2: sched_deriv( - Inout MSD_NUMERIC *N = &parent.sched.msd.numeric, - Inout MSD_PARAMS *P = &parent.sched.msd.params ) ; - - /* see Trick Requirement 3.1.2.1.3.5 */ - (dynamic_event) test2: sched_dyn_event( - Inout MSD_NUMERIC *N = &parent.sched.msd.numeric, - In double *time = &sys.exec.work.integ_time , - In int *event_evaluate_tgo = &sys.exec.work.event_evaluate_tgo ); - - /* see Trick Requirement 3.1.2.1.2.1 */ - (0.1, scheduled) test2: sched_scheduled( - Inout MSD_ANALYTIC *A = &parent.sched.msd.analytic, - In double *time = &sys.exec.work.integ_time ); - - /* Calculate the difference between the analytic and numeric pos and vel calculations. */ - (0.1, scheduled) test2: sched_scheduled_2( - Inout MSD *M = &parent.sched.msd ); - - /* see Trick Requirement 3.1.2.1.3.1 */ - (1.0, random) test2: sched_random( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.1.2 */ - (pre_load_checkpoint) test2: sched_pre_load( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.1.3 */ - (restart) test2: sched_restart( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.1.4 */ - (checkpoint) test2: sched_checkpoint( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.1.5 */ - (shutdown) test2: sched_shutdown( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.1.6 */ - (freeze_init) test2: sched_freeze_init( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.2.4 */ - (freeze) test2: sched_freeze( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.1.7 */ - (unfreeze) test2: sched_unfreeze( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.3.3 */ - (automatic) test2: sched_automatic( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.3.4 */ - (automatic_last) test2: sched_automatic_last( - Inout SCHEDULE *S = &parent.sched ) ; - - (0.9, logging) test2: sched_logging( - Inout SCHEDULE *S = &parent.sched ) ; - -} parent ; /*---------------------------------------------------------------*/ - -integrate (0.01) parent ; - -sim_object { /* Children ---------------------------------------------------*/ - - /* see Requirement(s) 3,1,2,14, 3.1.2.14.1 */ -C1 (0.9, logging) test2: sched_logging( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.2.6 */ -C2 (1.0, asynchronous_mustfinish) test2: sched_amf( - Inout SCHEDULE *S = &parent.sched ) ; - - /* see Trick Requirement 3.1.2.1.2.5 */ -C3 (0.7, asynchronous) test2: sched_async( - Inout SCHEDULE *S = &parent.sched ) ; - -} children ; /*---------------------------------------------------------------*/ - -/* see Trick Requirement 3.1.2.14.2 */ -children: sched_logging() depends on parent: sched_logging() -// children: sched_amf() depends on parent: sched_scheduled() - - -/* see Trick Requirement 3.1.2.1.2.4 */ -freeze (1.0); diff --git a/trick_test/requirements_testing/sims/SIM_test2/Test2Procedure.txt b/trick_test/requirements_testing/sims/SIM_test2/Test2Procedure.txt deleted file mode 100644 index 7f835f69..00000000 --- a/trick_test/requirements_testing/sims/SIM_test2/Test2Procedure.txt +++ /dev/null @@ -1,250 +0,0 @@ -Verification Procedure #2 - -PURPOSE: This test verifies the non-Monte Carlo and non-Malfunction - job class requirements specified in section 3.1.2.1 of the - Trick requirements document. - -TEST PREREQUISITES: - need ability to chown the sim exe to root and set the s bit. - need a machine with a minimum of 2 CPUs. - -REQUIREMENTS: -3.1.2.1.1 -*3.1.2.1.1.1 Initialization job class -*3.1.2.1.1.2 Pre_Load_Checkpoint job class -*3.1.2.1.1.3 Checkpoint restart job class -*3.1.2.1.1.4 Checkpoint job class -*3.1.2.1.1.5 Shutdown job class -*3.1.2.1.1.6 Freeze Init job class -*3.1.2.1.1.7 Unfreeze job class -3.1.2.1.2 -*3.1.2.1.2.1 Scheduled job class -*3.1.2.1.2.2 Integration Job class -*3.1.2.1.2.3 Post integration job class -*3.1.2.1.2.4 Freeze job class -*3.1.2.1.2.5 Asynchronous job class -*3.1.2.1.2.6 Asynchronous must finish job class -3.1.2.1.3 -*3.1.2.1.3.1 Random job class -*3.1.2.1.3.2 Derivative Job class -*3.1.2.1.3.3 Automatic job class -3.1.2.1.3.4 Automatic last job class -*3.1.2.1.3.5 Dynamic event job class -3.1.2.1.3.5.1 -*3.1.2.3 Numeric integration - - -These need to go into a different test. -3.1.2.14 parallel processing -3.1.2.14.1 thread support -3.1.2.14.2 depends on -3.1.2.15 priority assignment -3.1.2.16 processor assignment ( Linux only ) -3.1.2.17 memory locking (Linux only) - - -PROCEDURE: - -1) Run CP. - - Expected result(s): CP completes successfully. You should see: - - === Simulation make complete === - -2) -chown root S_main_{$TRICK_HOST_CPU}.exe -chown +s S_main_{$TRICK_HOST_CPU}.exe - -3) Type the following and press RETURN: - S_main_{$TRICK_HOST_CPU}.exe RUN_A/input - - Expected result(s): - a) the sim_control panel appears, - b) the sim is in Freeze mode - c) Run Elapsed Time (RET) is equal to 0.00. - - Notice: If this test is being run on Mac OSX the following messages will appear: - Warning: Trick on Darwin does not yet support memory locking. - Warning: Trick on Darwin does not yet support processor assignment. - -4) Run the simulation for a few seconds by pressing the Start button - on the sim_control panel, waiting about three seconds and then pressing the Freeze button. - - Expected result(s): - a) the sim is again in freeze mode and - b) RET is non-zero. - c) sched_freeze(), a freeze class job, runs periodically during and only during FREEZE mode () - [Req-3.1.2.1.2.4]. - -5) Record the value in the RET field. : __________ - -6) On the sim control panel Press the "Dump Chkpnt" button. - Expected result(s): - A file dialog appears. - -7) Record the name of checkpoint file. : __________ - -8) On the dialog, press the Save button. - Expected result(s): - a) The file dialog disappears. - b) The Status Messages window indicates that sched_checkpoint() ran once - at the time recorded in step 5. - c) The Status Messages window :Checkpoint file dump complete. - -9) Run the simulation for a few more seconds by pressing the Start button -on the sim_control panel, waiting several seconds and then pressing the Freeze button. - - Expected result(s): - a) the sim is again in freeze mode and - b) RET is greater than that recorded in step 5. - -10) Record the value in the RET field. : __________ - -11) On the sim control panel Press the "Load Chkpnt" button. - - Expected result(s): - A file dialog appears. - -12) In the "File name" field of the file dialog, enter the name of the -checkpoint file recorded in step 7 and press the Open button. - - Expected result(s): - the value in the RET field returns to the value recorded in step 4. - -13) Press Start and let the simulation run to completion. - Expected result(s): - The simulation runs to completion. - - DIAGNOSTIC: - Simulation reached input termination time. - -14) Save the status messages: File->Save Status Msgs... and record the filename: __________. - -15) Press Exit on the Sim Control Panel. - -16) Open the status messages file that was saved in step 14, using your favorite text editor. - It's in the RUN_test directory. - -17) [] Verify that 3 child threads have been created (child 2, 3 and 4). - -18) [] Verify that sched_init() {an Initialization job} ran once at sim time 0.0000 [Req-3.1.2.1.1.1]. - -19) [] Verify that sched_freeze_init(), a freeze_init class job, ran once, - just prior to each transition into FREEZE mode (indicated by the - message "Freeze ON").[Req-3.1.2.1.1.6]. - -20) [] Verify that sched_freeze(), a freeze class job, ran periodically - during and only during FREEZE mode (between "Freeze ON" and "Freeze OFF" - messages.) [Req-3.1.2.1.2.4]. - -21) [] Verify that sched_unfreeze(), an unfreeze class job, ran once, just prior - to each transition from FREEZE mode (Indicated by the message "Freeze OFF") [Req-3.1.2.1.1.7] - -22) [] Verify that sched_checkpoint() ran once, just prior to the checkpoint dump - (Indicated by the message "Checkpoint file dump complete"). [Req-3.1.2.1.1.4] - -23) [] Verify that sched_pre_load() ran once, just prior to the checkpoint reload - ( Indicated by the message "Checkpoint file load complete" ) [Req-3.1.2.1.1.2] - -24) [] Verify that sched_restart() ran once, just after the checkpoint reload - ( Indicated by the message "Checkpoint file load complete" ) [Req-3.1.2.1.1.3] - -25) [] Verify that sched_scheduled(), a scheduled class job, ran once every 0.1 - seconds (as specified in the S_define file). [Req-3.1.2.1.2.1] - -26) [] Verify that sched_random() runs at time 0.0, 0.0+ some random amount, 1.0 plus or - minus some random amount, 2.0 plus or minus some random amount, and so forth. - -27) [] Verify that sched_deriv() {a Derivative job} ran once at sim time 0.0000 and - thereafter four times per integration period. [Req-3.1.2.1.3.2]. - -Note: The S_define for this test specifies that the integration period is 0.01 seconds. -Note: The derivative job sched_deriv() is called four times per integration period - because the sim associated with this test uses the default Runge Kutta 4 integration algorithm. - -28) [] Verify that sched_integ(), an Integration job, ran four times per integration - period, following sched_deriv(). sched_integ() did not run at sim time = 0.0000 [Req-3.1.2.1.2.2]. - -29) [] Verify that sched_post_integ(), a post_integration class job, ran once - per integration period, following the sched_deriv() and sched_integ() - job calls during that period. [Req-3.1.2.1.2.3] - -NOTE: The scheduler does not wait for ASYNCHRONUS class jobs to complete. When - an ASYNCHRONUS job does complete, it is rescheduled at the next multiple of - its specified scheduling period. The function sched_async(), an asynchronous - job, has a scheduling period of 0.7. When sched_async() is first called, it - simply sleeps for 0 seconds. The next time it sleeps for 1 sec, then 2 secs - and so forth. So sched_async() should be first scheduled at 0.0 seconds, will - run for ~0 secs, be rescheduled at 0.7 secs, sleep for 1 sec, be scheduled at - 2.1 secs, sleep for 2 secs, be scheduled at 4.2 secs, and so forth. It will - then be scheduled at the next multiple of 0.7 seconds, that is 0.7 seconds. - sched_async will sleep for 1.0 second (). - -30) [] Verify that sched_async() ran at 0.0 seconds, 0.7 seconds, 2.1 seconds, - 4.2 seconds, etc [Req-3.1.2.1.2.5] - -NOTE: The function sched_automatic(), an automatic class job, reshedules itself 1.1 seconds - in the future. - -31) [] Verify that sched_automatic() runs at 0.0000 seconds and thereafter at multiples of - 1.1000 seconds. [Req-3.1.2.1.3.3] - -Add Test for AUTOMATIC_LAST job class. [Req-3.1.2.1.3.4] - -Add test for Random job class [Req-3.1.2.1.3.1] - -NOTE: In order to verify that Trick numeric integration and Trick dynamic events work correctly, - the test2 simulation compares numeric and analytic solutions for a - spring-mass-damper model. The analytic solution represents the "truth" values against which - we can compare Trick's numeric integration. - - In the test2 simulation, sched_dyn_event() , a dynamic event class job is coded to trigger - a dynamic event when the variable parent.sched.msd.numeric.pos passes through zero. - -32) [] Verify that the Dynamic event {sched_dyn_event()} fired at 0.515, 1.505, - 2.505, 3.495, 4.495 (+/- 0.005 seconds) . [Req-3.1.2.1.3.5] - -33) Close the status messages file that was opened in step ##. - -NOTE: - The variable parent.sched.msd.analytic.pos represents the value that the position "should" be. - The variable parent.sched.msd.numeric.pos represents the position estimated using Trick's numeric - integration capabilities. The difference between these ( parent.sched.msd.delta_pos ) should be small. - [Req-3.1.2.3] - -34) [] Using trick_dp, verify that parent.sched.msd.delta_pos is not more than about 1e-06 meters (m). - -NOTE: -The variable parent.sched.msd.delta_vel is the difference between the analytic and numeric velocity values. - -35) [] Verify that parent.sched.msd.delta_vel (velocity) is not more than about 1e-06 meters (m/s). - -36) Close the status messages file opened in step 16. - - -The function sched_amf() is written to alternately run for 1.5 and then 0.5 seconds. -In the S_define, it is scheduled at 1.0 seconds. - -37) Again run the sim but this time using RUN_B/input. - Type the following and press RETURN: - - S_main_{$TRICK_HOST_CPU}.exe RUN_B/input - - Expected result(s): - a) the sim_control panel appears, - b) the sim is in Freeze mode - c) Run Elapsed Time (RET) is equal to 0.00. - -37) Press Start and let the simulation run to completion. - Expected result(s): - The simulation runs to completion. - - DIAGNOSTIC: - Simulation reached input termination time. - -38) WHAT IS THE EXPECTED BEHAVIOR OF ASYNCHRONOUS MUST FINISH, THESE DAYS.? - - - -END OF TEST. - diff --git a/trick_test/requirements_testing/sims/SIM_test3/DP_Product/DP_test3_dr_changes b/trick_test/requirements_testing/sims/SIM_test3/DP_Product/DP_test3_dr_changes deleted file mode 100644 index e3d576f6..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/DP_Product/DP_test3_dr_changes +++ /dev/null @@ -1,31 +0,0 @@ -No title specified - -PLOTS: - -PAGE 1: "Page" - - PLOT 1: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "dyn.test3.d1" - UNITS: "--" - LABEL: "dyn.test3.d1" - TIME_NAME: "sys.exec.out.time" - - PLOT 2: "Plot" - Y_AXIS_FORMAT: "%g" - - X_variable: "sys.exec.out.time" - UNITS: "s" - TIME_NAME: "sys.exec.out.time" - LABEL: "sys.exec.out.time" - - Y_variable: "dyn.test3.d2" - UNITS: "--" - LABEL: "dyn.test3.d2" - TIME_NAME: "sys.exec.out.time" diff --git a/trick_test/requirements_testing/sims/SIM_test3/DP_Product/DP_test3_table b/trick_test/requirements_testing/sims/SIM_test3/DP_Product/DP_test3_table deleted file mode 100644 index 53495dfa..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/DP_Product/DP_test3_table +++ /dev/null @@ -1,29 +0,0 @@ -No title specified - -TABLES: - - TABLE 1: "" - - VARIABLE: "sys.exec.out.time" - UNITS: "s" - LABEL: "time" - - VARIABLE: "dyn.test3.s" - UNITS: "--" - LABEL: "s" - - VARIABLE: "dyn.test3.i" - UNITS: "--" - LABEL: "i" - - VARIABLE: "dyn.test3.ui" - UNITS: "--" - LABEL: "ui" - - VARIABLE: "dyn.test3.l" - UNITS: "--" - LABEL: "l" - - VARIABLE: "dyn.test3.f" - UNITS: "--" - LABEL: "f" diff --git a/trick_test/requirements_testing/sims/SIM_test3/Modified_data/realtime.d b/trick_test/requirements_testing/sims/SIM_test3/Modified_data/realtime.d deleted file mode 100644 index 239f24c9..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/Modified_data/realtime.d +++ /dev/null @@ -1,10 +0,0 @@ -sys.exec.in.frame_log = Yes; - -sys.exec.in.rt_software_frame {s} = 1.00; -sys.exec.in.rt_itimer = No; -sys.exec.in.rt_itimer_pause = Yes; -sys.exec.in.rt_itimer_frame {s} = 1.00; - -sys.exec.sim_com.monitor_on = No; -sys.exec.in.enable_freeze = No; -sys.exec.work.freeze_command = No; diff --git a/trick_test/requirements_testing/sims/SIM_test3/Modified_data/test3_A.dr b/trick_test/requirements_testing/sims/SIM_test3/Modified_data/test3_A.dr deleted file mode 100644 index e2061102..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/Modified_data/test3_A.dr +++ /dev/null @@ -1,69 +0,0 @@ -sys.exec.record.num_group = 6; - -// Buffered -sys.exec.record.group[0].name = "Group0" ; -sys.exec.record.group[0].cycle = .1 ; -sys.exec.record.group[0].record = Yes ; -sys.exec.record.group[0].single_prec_only = No ; -sys.exec.record.group[0].freq = DR_Always ; -sys.exec.record.group[0].format = DR_Binary ; -sys.exec.record.group[0].buffering = DR_Buffer ; -sys.exec.record.group[0].ref[0] = - "dyn.test3.s" ; - -// Non-buffered -sys.exec.record.group[1].name = "Group1" ; -sys.exec.record.group[1].cycle = .2; -sys.exec.record.group[1].record = Yes ; -sys.exec.record.group[1].single_prec_only = No ; -sys.exec.record.group[1].freq = DR_Always ; -sys.exec.record.group[1].format = DR_Binary ; -sys.exec.record.group[1].buffering = DR_No_Buffer ; -sys.exec.record.group[1].ref[0] = - "dyn.test3.i" ; - -// Ring Buffer -sys.exec.record.group[2].name = "Group2" ; -sys.exec.record.group[2].cycle = .3 ; -sys.exec.record.group[2].record = Yes ; -sys.exec.record.group[2].single_prec_only = No ; -sys.exec.record.group[2].freq = DR_Always ; -sys.exec.record.group[2].format = DR_Binary ; -sys.exec.record.group[2].buffering = DR_Ring_Buffer ; -sys.exec.record.group[2].ref[0] = - "dyn.test3.ui" ; - -// More than one variable -sys.exec.record.group[3].name = "Group3" ; -sys.exec.record.group[3].cycle = .5 ; -sys.exec.record.group[3].record = Yes ; -sys.exec.record.group[3].single_prec_only = No ; -sys.exec.record.group[3].freq = DR_Always ; -sys.exec.record.group[3].format = DR_Binary ; -sys.exec.record.group[3].buffering = DR_No_Buffer ; -sys.exec.record.group[3].ref[0] = - "dyn.test3.l" , - "dyn.test3.f" ; - -// Alternating Sawtooth for DR_Changes demonstration. -sys.exec.record.group[4].name = "Group4" ; -sys.exec.record.group[4].cycle = 0.01 ; -sys.exec.record.group[4].record = Yes ; -sys.exec.record.group[4].single_prec_only = No ; -sys.exec.record.group[4].freq = DR_Always ; -sys.exec.record.group[4].format = DR_Binary ; -sys.exec.record.group[4].buffering = DR_Buffer ; -sys.exec.record.group[4].ref[0] = - "dyn.test3.d2" ; - -// Sine function for DR_Changes demonstration. -sys.exec.record.group[5].name = "Group5" ; -sys.exec.record.group[5].cycle = 0.01 ; -sys.exec.record.group[5].record = Yes ; -sys.exec.record.group[5].single_prec_only = No ; -sys.exec.record.group[5].freq = DR_Always ; -sys.exec.record.group[5].format = DR_Binary ; -sys.exec.record.group[5].buffering = DR_Buffer ; -sys.exec.record.group[5].ref[0] = - "dyn.test3.d1" ; - diff --git a/trick_test/requirements_testing/sims/SIM_test3/Modified_data/test3_B.dr b/trick_test/requirements_testing/sims/SIM_test3/Modified_data/test3_B.dr deleted file mode 100644 index 103ae4b3..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/Modified_data/test3_B.dr +++ /dev/null @@ -1,26 +0,0 @@ -sys.exec.record.num_group = 2; - -// Alternating Sawtooth -sys.exec.record.group[0].name = "Group0" ; -sys.exec.record.group[0].cycle = 0.01 ; -sys.exec.record.group[0].record = Yes ; -sys.exec.record.group[0].single_prec_only = No ; -sys.exec.record.group[0].freq = DR_Always ; -sys.exec.record.group[0].format = DR_Binary ; -sys.exec.record.group[0].buffering = DR_Buffer ; -sys.exec.record.group[0].ref[0] = - "dyn.test3.d2" ; - -// Changes Demo -sys.exec.record.group[1].name = "Group1" ; -sys.exec.record.group[1].cycle = 0.01 ; -sys.exec.record.group[1].record = Yes ; -sys.exec.record.group[1].single_prec_only = No ; -sys.exec.record.group[1].freq = DR_Changes ; -sys.exec.record.group[1].format = DR_Binary ; -sys.exec.record.group[1].buffering = DR_Buffer ; -sys.exec.record.group[1].ref[0] = - "dyn.test3.d1" ; -sys.exec.record.group[1].change_ref[0] = - "dyn.test3.d2" ; - diff --git a/trick_test/requirements_testing/sims/SIM_test3/RUN_A/input b/trick_test/requirements_testing/sims/SIM_test3/RUN_A/input deleted file mode 100644 index 648ba005..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/RUN_A/input +++ /dev/null @@ -1,19 +0,0 @@ -#include "S_default.dat" -#include "Modified_data/test3_A.dr" -#include "Modified_data/realtime.d" - -// ***************************************************** -// Start the simulation in freeze mode. -// ***************************************************** -sys.exec.in.enable_freeze = Yes ; -sys.exec.work.freeze_command = Yes ; - -// ***************************************************** -// Use the sim_control panel -// ***************************************************** -sys.exec.sim_com.monitor_on = Yes; - -// ***************************************************** -// Stop the simulation after 30 seconds. -// ***************************************************** -stop = 30; diff --git a/trick_test/requirements_testing/sims/SIM_test3/RUN_B/input b/trick_test/requirements_testing/sims/SIM_test3/RUN_B/input deleted file mode 100644 index 102c8bdd..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/RUN_B/input +++ /dev/null @@ -1,19 +0,0 @@ -#include "S_default.dat" -#include "Modified_data/test3_B.dr" -// nclude "Modified_data/realtime.d" - -// ***************************************************** -// Start the simulation in freeze mode. -// ***************************************************** -sys.exec.in.enable_freeze = No ; -sys.exec.work.freeze_command = No ; - -// ***************************************************** -// Use the sim_control panel -// ***************************************************** -sys.exec.sim_com.monitor_on = No; - -// ***************************************************** -// Stop the simulation after 30 seconds. -// ***************************************************** -stop = 30; diff --git a/trick_test/requirements_testing/sims/SIM_test3/S_define b/trick_test/requirements_testing/sims/SIM_test3/S_define deleted file mode 100644 index 9d0af6a0..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/S_define +++ /dev/null @@ -1,14 +0,0 @@ -sim_object { - sim_services/include: EXECUTIVE exec (sim_services/include/executive.d); - - (automatic) sim_services/input_processor: - input_processor(INPUT_PROCESSOR* IP = &sys.exec.ip); -} sys; - -sim_object { - test3: TEST3 test3 (test3/include/test3.d); - - (0.01, scheduled) test3: - test3_sched(TEST3 * T = &dyn.test3, - double *time = &sys.exec.out.time ); -} dyn; diff --git a/trick_test/requirements_testing/sims/SIM_test3/Test3Procedure.txt b/trick_test/requirements_testing/sims/SIM_test3/Test3Procedure.txt deleted file mode 100644 index c9bcd506..00000000 --- a/trick_test/requirements_testing/sims/SIM_test3/Test3Procedure.txt +++ /dev/null @@ -1,206 +0,0 @@ -TEST 3 - Data Recording - -PURPOSE: Demonstrate by testing and inspection that Trick provides a data recording - capability during simulation runs. - -Trick is required to provide the ability to record simulation data. How the data is recorded -is specified in one or more Log groups. A Log group is a collection of variables -whose time tagged values are recorded to a disk file in a specified manner. The -specifications include: - -1) The rate at which the data is logged -2) The format in which the data is logged. -3) Whether data is recorded at each timestep or only when the values of it's variables change. -4) When the data is written to disk: - a) asynchronously (DR_Buffer {synonymous with DR_thread_buffer}) - b) synchronously (DR_No_Buffer) and - c) at the end of the simulation run {DR_ring_buffer}. - -The purpose of this procedure is to demonstrate and verify these requirements by -inspection and by testing, using a test-simulation designed specifically for this -purpose. - - -Requirements References: - -Trick-080 3.1.2.10 Data Recording -Trick-081 3.1.2.10.1 DR_Buffer -Trick-082 3.1.2.10.2 DR_Thread_Buffer -Trick-083 3.1.2.10.3 DR_Ring_Buffer -Trick-084 3.1.2.10.3.1 DR_Ring_Buffer -Trick-085 3.1.2.11 DR_No_Buffer -Trick-086 3.1.2.12 One or more variables -Trick-087 3.1.2.12.1 Freq -Trick-088 3.1.2.12.2 Changes -Trick-089 3.1.2.12.3 Multiple log groups -Trick-090 3.1.2.12.4 Realtime Performance -Trick-091 3.1.2.12.5 Time tagged - -Procedure Steps: - -1) Change to simulation directory and list it's contents : - - % cd $TRICK_HOME/trick_test/requirements_testing/sims/SIM_test3/ - -2) Build the test simulation: - - % CP - - Expected result(s): CP completes successfully. You should see: - - === Simulation make complete === - -3) Run the test simulation as follows: - - % S_main_{$TRICK_HOST_CPU}.exe RUN_A/input - - Expected result(s): - a) the sim_control panel appears, - b) the sim is in Freeze mode - c) Run Elapsed Time (RET) is equal to 0.00. - -4) In a new terminal window, cd to RUN_A/ - - [] Verify that the following log files have been created, one for each group - specified in Modified_data/test3.dr as well as RT performance logs when - sys.exec.in.frame_log = Yes;: - -log_Group0.trk log_Group2.trk log_Group4.trk log_frame.trk log_mem_stats.trk -log_Group1.trk log_Group3.trk log_Group5.trk log_jobs.trk - -[Trick-089] - -The next two steps must be completed within 30 seconds. Read these steps before performing them. - -5) On the sim control panel press Start. - -6) In the RUN_A directory, type ls -l every couple of seconds, until the - simulation completes, to verify that: - -[] log_Group0.trk and log_Group1.trk are increasing in size over time. - [Trick-081, Trick-082] - -[] The size of log_Group2.trk does not change until the sim finishes running, - after 30 seconds. [Trick-083, Trick-084] - -7) Close the new terminal, opened in step 4, if you like. - -8) When the simulation completes, press Exit on the sim control panel. - - [] The sim control panel disappears. - -7) Using trick_dp, select SIM_test3/RUN_A and DP_test3_table, and then - press the "Tabular data" button. - - [] Verify using the table that appears that, as specified in Modified_data/test3_A.dr: - - [] dyn.test3.l and dyn.test3.f (specified in "Group3") are both logged [Trick-086] - - [] dyn.test3.s was logged every 0.1 seconds [Trick-087, Trick-089] - [] dyn.test3.i was logged every 0.2 seconds [Trick-087, Trick-089] - [] dyn.test3.ui was logged every 0.3 seconds [Trick-087, Trick-089] - [] dyn.test3.l was logged every 0.5 seconds [Trick-087, Trick-089] - [] dyn.test3.f was logged every 0.5 seconds [Trick-087, Trick-089] - - -8) Press Exit Tables in the small window. - -Setting sys.exec.in.frame_log = Yes enables simulation performance profiling, as described -in section 7.3 of the Trick User's Guide. - -9) Using trick_dp, select SIM_test3/RUN_A, and the following data product specifications - that are automatically generated for display of real-time performance data. - - DP_rt_frame - DP_rt_timer - DP_rt_jobs - -10) Select the "Single" plot icon. - - [] Verify that these display real-time perfomance data of the Trick executive - and model jobs in the simulation. [Trick-090] - -11) Exit plots - - The plots disappear. - -12) Deselect the "DP_rt_frame", "DP_rt_timer" and "DP_rt_jobs" data product specifications. - -The next couple of steps demonstrate the ability to log variable data only when another -(or the same) variable changes. This is described in section 7.4.2 of the Trick User's -Guide. - -For comparison, we'll first look at normal data recording, with -sys.exec.record.group[#].freq = DR_Always. Then, the same data will be recorded -with sys.exec.record.group[#].freq = DR_Changes. - -Note that RUN_A/input includes Modified_data/test3_A.dr and that in test3_A.dr, -in the "Group5" specification, that dyn.test3.d1 is recorded with DR_Always. - -13) Using trick_dp, select SIM_test3/RUN_A and DP_test3_dr_changes, and then - press the "Single" plot button. - - [] Observe that the plot of dyn.test3.d1 represents a sine curve. - [] Observe that the plot of dyn.test3.d2 represents a sawtooth pattern. It changes - between 0 and 1, 2 and 3, 4 and 5, etc., and it doesn't change - between 1 and 2, 3 and 4, 5 and 6, etc. - - -14) Exit Plots - - The plots disappear. - -15) Close trick_dp. - - -Note that RUN_B/input includes Modified_data/test3_A.dr and that in test3_A.dr, -in the "Group5" specification, that dyn.test3.d1 is recorded with DR_Always. - -16) Run the simulation again using RUN_B/input : - % S_main_{$TRICK_HOST_CPU}.exe RUN_B/input - - Expected result(s): - Simulation runs to completion. - - DIAGNOSTIC: Simulation reached input termination time. - -17) Using trick_dp, select SIM_test3/RUN_B and DP_test3_dr_changes, and then - press the "Single" plot button. - - Verify that: - [] between 0 and 1, 2 and 3, 4 and 5, etc., where dyn.test3.d2 is changing, - dyn.test3.d1 (the sine curve) was logged. - [] between 1 and 2, 3 and 4, 5 and 6, etc., where dyn.test3.d2 is not changing, - dyn.test3.d1 was not logged (the negative part of the sine curve is cut off) . - [Trick-088] - -18) Close trick_dp. - -19) In order to see by inspection that DR_Thread_Buffer uses a fixed size buffer in memory, -open $TRICK_HOME/trick_source/sim_services/exec/data_record_init.c - -Search for "switch (G->buffering)", then for case "case DR_Thread_Buffer". - -[] Verify that the buffer for the group is allocated using calloc() and that -it's size is determined the number of records that will fit within the max_buffer_size. -[Req. Trick-081] - -20) In order to see by inspection that DR_Thread_Buffer writes to disk using a separate thread of execution, open $TRICK_HOME/trick_source/sim_services/exec/exec_init_data_recording.c. - -Search for occurances of "start_writer". You'll see a number of places where it's set to 1. - -[] Verify that start_writer is set on the condition that buffering is set to - DR_Thread_buffer (or synonymously DR_Buffer). [Trick-082] - -[] Verify that on the condition that start_writer is true (non-zero) that pthread_create is called, to start a dr_writer thread. [Trick-082] - -21) In order to see by inspection that DR_No_Buffer writes to disk directly rather than - using a separate thread, open $TRICK_HOME/trick_source/sim_services/exec/data_record.c. - -Search for "switch (G->buffering)", then for case "case DR_No_Buffer". - -[] Verify that for the case of DR_No_Buffer, data_record() writes data to the - data recording file (G->fp) directly. Compare to the cases of DR_Thread_buffer - or DR_ring_buffer which let the writer thread do the writing to disk. [Trick-085] - -END OF TEST. diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/hold_test.malf b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/hold_test.malf deleted file mode 100644 index bc55a9c2..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/hold_test.malf +++ /dev/null @@ -1,23 +0,0 @@ -/*______________________________________________ - - Verify overall malfunction syntax... - ______________________________________________*/ - -/* - * Author : dbankie - * Date : Wed Jun 11 08:44:31 AM CDT 2008 - * Info : Auto generated by MTV - */ - -BEGIN MALFUNCTION hold_test { - TRIGGER { - CONDITION: sys.exec.out.time == 0 ; - INSERT_BEFORE: dyn.test4_sched1(&dyn.test4)(1) ; - HOLD: Yes ; - } - /*=== ACTIONS ===*/ - ACTION { - INSERT_BEFORE: dyn.test4_sched2(&dyn.test4) ; - printf("Holding active.\n"); - } -} ; /* end hold_test */ diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_1.malf b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_1.malf deleted file mode 100644 index c33ef457..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_1.malf +++ /dev/null @@ -1,20 +0,0 @@ -/*______________________________________________ - - Verify overall malfunction syntax... - ______________________________________________*/ - -/* - * Author : dbankie - * Date : Wed Jun 04 09:14:06 AM CDT 2008 - * Info : Auto generated by MTV - */ - -BEGIN MALFUNCTION malf_1 { - TRIGGER { - JOB: dyn.test4_trig_before1(&dyn.test4) ; - INSERT_BEFORE: dyn.test4_sched1(&dyn.test4) ; - HOLD: No ; - } - /*=== ACTIONS ===*/ - CALL dyn.test4_malf_before1(&dyn.test4) BEFORE dyn.test4_sched1(&dyn.test4) ; -} ; /* end malf_1 */ diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_2.malf b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_2.malf deleted file mode 100644 index 200b8165..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_2.malf +++ /dev/null @@ -1,16 +0,0 @@ - -/* - * Author : dbankie - * Date : Wed May 14 02:09:05 PM CDT 2008 - * Info : Auto generated by MTV - */ - -BEGIN MALFUNCTION malf_2 { - TRIGGER { - JOB: dyn.test4_trig_before2(&dyn.test4) ; - INSERT_BEFORE: dyn.test4_sched2(&dyn.test4) ; - HOLD: No ; - } - /*=== ACTIONS ===*/ - CALL dyn.test4_malf_after2(&dyn.test4) AFTER dyn.test4_sched2(&dyn.test4) ; -} ; /* end malf_2 */ diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_3.malf b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_3.malf deleted file mode 100644 index b57e121f..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_3.malf +++ /dev/null @@ -1,16 +0,0 @@ - -/* - * Author : dbankie - * Date : Wed May 14 02:09:44 PM CDT 2008 - * Info : Auto generated by MTV - */ - -BEGIN MALFUNCTION malf_3 { - TRIGGER { - JOB: dyn.test4_trig_after3(&dyn.test4) ; - INSERT_AFTER: dyn.test4_sched3(&dyn.test4) ; - HOLD: No ; - } - /*=== ACTIONS ===*/ - CALL dyn.test4_malf_before4(&dyn.test4) BEFORE dyn.test4_sched4(&dyn.test4) ; -} ; /* end malf_3 */ diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_4.malf b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_4.malf deleted file mode 100644 index daf0315a..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_4.malf +++ /dev/null @@ -1,16 +0,0 @@ - -/* - * Author : dbankie - * Date : Wed May 14 02:10:21 PM CDT 2008 - * Info : Auto generated by MTV - */ - -BEGIN MALFUNCTION malf_4 { - TRIGGER { - JOB: dyn.test4_trig_after4(&dyn.test4) ; - INSERT_AFTER: dyn.test4_sched4(&dyn.test4) ; - HOLD: No ; - } - /*=== ACTIONS ===*/ - CALL dyn.test4_malf_after4(&dyn.test4) AFTER dyn.test4_sched4(&dyn.test4) ; -} ; /* end malf_4 */ diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_5.malf b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_5.malf deleted file mode 100644 index 81ee6715..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/malf_5.malf +++ /dev/null @@ -1,20 +0,0 @@ -/*______________________________________________ - - Verify overall malfunction syntax... - ______________________________________________*/ - -/* - * Author : dbankie - * Date : Thu May 15 08:24:56 AM CDT 2008 - * Info : Auto generated by MTV - */ - -BEGIN MALFUNCTION malf_5 { - TRIGGER { - JOB: dyn.test4_trig_after3(&dyn.test4) ; - INSERT_AFTER: dyn.test4_sched3(&dyn.test4) ; - HOLD: No ; - } - /*=== ACTIONS ===*/ - CALL dyn.test4_malf_after3(&dyn.test4) AFTER dyn.test4_sched3(&dyn.test4) ; -} ; /* end malf_5 */ diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/realtime.d b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/realtime.d deleted file mode 100644 index e615b37f..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/realtime.d +++ /dev/null @@ -1,6 +0,0 @@ -sys.exec.in.frame_log = Yes; -sys.exec.in.rt_software_frame {s} = 0.01; -sys.exec.in.rt_itimer = Yes; -sys.exec.in.rt_itimer_pause = Yes; -sys.exec.in.rt_itimer_frame {s} = 0.01; - diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/test4.dr b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/test4.dr deleted file mode 100644 index 7857fc25..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/test4.dr +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Author : penn - * Date : Wed Oct 29 16:50:48 CDT 2008 - * Info : Auto generated by dre.tcl a.k.a Dr. Dre - */ - -#ifndef DR_GROUP_ID - #define DR_GROUP_ID sys.exec.record.num_group -#endif - -sys.exec.record.group = alloc( DR_GROUP_ID + 1 ) ; - -sys.exec.record.group[DR_GROUP_ID].name = "malfs" ; -sys.exec.record.group[DR_GROUP_ID].cycle = 0.1 ; -sys.exec.record.group[DR_GROUP_ID].record = Yes ; -sys.exec.record.group[DR_GROUP_ID].single_prec_only = No ; -sys.exec.record.group[DR_GROUP_ID].freq = DR_Always ; -sys.exec.record.group[DR_GROUP_ID].format = DR_Binary ; -sys.exec.record.group[DR_GROUP_ID].buffering = DR_Buffer ; -sys.exec.record.group[DR_GROUP_ID].ref[0] = - "dyn.test4.cos_pi_t" , - "dyn.test4.inv_exp_t" , - "dyn.test4.stop_time" , - "dyn.test4.start_time" ; - -DR_GROUP_ID ++ ; diff --git a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/triggerless_test.malf b/trick_test/requirements_testing/sims/SIM_test4/Modified_data/triggerless_test.malf deleted file mode 100644 index 93ca3394..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Modified_data/triggerless_test.malf +++ /dev/null @@ -1,6 +0,0 @@ -BEGIN_MALFUNCTION triggerless_test { - ACTION { - INSERT_BEFORE: dyn.test4_sched2(&dyn.test4); - printf("Wao...\n"); - } -}; diff --git a/trick_test/requirements_testing/sims/SIM_test4/RUN_A/input b/trick_test/requirements_testing/sims/SIM_test4/RUN_A/input deleted file mode 100644 index 2b44d1ff..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/RUN_A/input +++ /dev/null @@ -1,239 +0,0 @@ -#include "S_default.dat" -#include "Modified_data/realtime.d" -#include "Modified_data/test4.dr" - -// ################################################################### -// PURPOSE: -// Test Trick MALFUNCTION TRIGGER -// ################################################################### - -STOP = 5.0 ; - -// ---------------------------------------------------------- -// Malfunction "malf_1" tests a TRIGGER CONDITION which: -// * uses a LOGICAL operator -// * is evaluated BEFORE the associated job -// * is NOT held TRUE. -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_1 { - TRIGGER { - CONDITION: sys.exec.out.time == 1.0; - INSERT_BEFORE: dyn.sched_job_1(&dyn.test4) ; - } - ACTION { - INSERT_BEFORE: dyn.sched_job_1(&dyn.test4) ; - printf("############################### ACTION FOR malf_1.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_1 DISABLE_TRIGGER ; - } -} ; - -// ---------------------------------------------------------- -// Malfunction "malf_2" tests a TRIGGER CONDITION which: -// * uses a LOGICAL operator -// * is evaluated AFTER the associated job -// * is held TRUE. -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_2 { - TRIGGER { - CONDITION: sys.exec.out.time == 2.0; - INSERT_AFTER: dyn.sched_job_2(&dyn.test4) ; - HOLD: Yes ; - } - ACTION { - INSERT_BEFORE: dyn.sched_job_2(&dyn.test4) ; - printf("############################### ACTION FOR malf_2.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_2 DISABLE_TRIGGER ; - } -} ; - -// ---------------------------------------------------------- -// Malfunction "malf_3" tests a TRIGGER CONDITION which: -// * uses a TRIP operator -// * is evaluated BEFORE the associated job -// * is held TRUE. -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_3 { - TRIGGER { - CONDITION: sys.exec.out.time TRIP: 3.0; - INSERT_BEFORE: dyn.sched_job_3(&dyn.test4) ; - HOLD: Yes ; - } - ACTION { - INSERT_BEFORE: dyn.sched_job_3(&dyn.test4) ; - printf("############################### ACTION FOR malf_3.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_3 DISABLE_TRIGGER ; - } -} ; - -// ---------------------------------------------------------- -// Malfunction "malf_4" tests a TRIGGER CONDITION which: -// * uses a TRIP operator -// * is evaluated AFTER the associated job -// * is NOT held TRUE. -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_4 { - TRIGGER { - CONDITION: sys.exec.out.time TRIP: 4.0; - INSERT_AFTER: dyn.sched_job_4(&dyn.test4) ; - HOLD: No ; - } - ACTION { - INSERT_BEFORE: dyn.sched_job_4(&dyn.test4) ; - printf("############################### ACTION FOR malf_4.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_4 DISABLE_TRIGGER ; - } -} ; - -// ---------------------------------------------------------- -// TOLERANCE tests: -// "malf_5" and "malf_6" test TOLERANCE in a TRIGGER CONDITION. -// The trigger conditions of both are met when the function -// 1/exp(time) decays to the point that it is close to 0 -// ( as determined by TOLERANCE.) -// NOTE: 1/exp(time) == TOLERANCE at time = ln (1/TOLERANCE). -// For TOLERANCE = 0.1, time = 2.30258, so trigger should happen -// when sys.exec.out.time = 2.4. -// For TOLERANCE = 0.01, time = 4.60517, so trigger should happen -// when sys.exec.out.time = 4.7. -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_5 { - TRIGGER { - CONDITION: dyn.test4.inv_exp_t == 0.0 TOLERANCE: 0.1; - INSERT_AFTER: dyn.sched_job_2(&dyn.test4) ; - HOLD: No ; - } - ACTION { - INSERT_AFTER: dyn.sched_job_2(&dyn.test4) ; - printf("############################### ACTION FOR malf_5.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_5 DISABLE_TRIGGER ; - } -} ; - -BEGIN_MALFUNCTION malf_6 { - TRIGGER { - CONDITION: dyn.test4.inv_exp_t == 0.0 TOLERANCE: 0.01; - INSERT_AFTER: dyn.sched_job_2(&dyn.test4) ; - HOLD: No ; - } - ACTION { - INSERT_AFTER: dyn.sched_job_2(&dyn.test4) ; - printf("############################### ACTION FOR malf_6.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_6 DISABLE_TRIGGER ; - } -} ; - -// ---------------------------------------------------------- -// SLOPE tests: -// "malf_7" and "malf_8" test SLOPE in a TRIGGER CONDITION. -// Note that SLOPE is only used with TRIP:. -// The trigger condition of malf_7 is met when the function -// cos(PI* time) == 0 and its slope is positive, so trigger -// should happen when sys.exec.out.time = 1.5. -// The trigger condition of malf_8 is met when the function -// cos(PI* time) == 0 and its slope is negative, so trigger -// should happen when sys.exec.out.time = 0.5. -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_7 { - TRIGGER { - CONDITION: dyn.test4.cos_pi_t TRIP: 0.0 ; - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - HOLD: No ; - } - ACTION { - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - printf("############################### ACTION FOR malf_7.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_7 DISABLE_TRIGGER ; - } -} ; - -BEGIN_MALFUNCTION malf_8 { - TRIGGER { - CONDITION: dyn.test4.cos_pi_t TRIP: 0.0 ; - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - HOLD: Yes ; - } - ACTION { - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - printf("############################### ACTION FOR malf_8.\n"); - // Make this a one shot trigger - MALFUNCTION_CMD malf_8 DISABLE_TRIGGER ; - } -} ; - -// ---------------------------------------------------------- -// Trigger Jobs: -// "malf_9" trigger job "dyn.trigger_job_1" returns TRUE when -// the value cos_pi_t changes sign (passes through zero). -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_9 { - TRIGGER { - JOB: dyn.trigger_job_1(&dyn.test4) ; - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - HOLD: No ; - } - ACTION { - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - printf("############################### ACTION FOR malf_9.\n"); - // Make this a one shot trigger - // MALFUNCTION_CMD malf_9 DISABLE_TRIGGER ; - } -} ; - - -// ---------------------------------------------------------- -// Action = ... -// ---------------------------------------------------------- - -BEGIN_MALFUNCTION malf_10 { - TRIGGER { - CONDITION: sys.exec.out.time == 2.0 ; - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - HOLD: No ; - } - dyn.test4.velocity { - UNITS: {m/s} ; - SCALE_FACTOR: 1.0 ; - BIAS: 1.0 ; - } -} ; - -// ---------------------------------------------------------- -// Action = CALL BEFORE|AFTER [(duplication_id)] ; -// ---------------------------------------------------------- - -BEGIN_MALFUNCTION malf_11 { - TRIGGER { - CONDITION: sys.exec.out.time == 3.0 ; - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - HOLD: No ; - } - CALL dyn.malf_job_1(&dyn.test4) BEFORE dyn.sched_job_5(&dyn.test4)(1) ; -} ; - -BEGIN_MALFUNCTION malf_12 { - TRIGGER { - CONDITION: sys.exec.out.time == 4.0 ; - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - HOLD: No ; - } - CALL dyn.malf_job_2(&dyn.test4) AFTER dyn.sched_job_5(&dyn.test4)(2) ; -} ; - -// ---------------------------------------------------------- -// Action = JOB = On | Off ; -// ---------------------------------------------------------- -BEGIN_MALFUNCTION malf_12 { - TRIGGER { - CONDITION: sys.exec.out.time == 4.0 ; - INSERT_AFTER: dyn.sched_job_1(&dyn.test4) ; - HOLD: No ; - } - CALL dyn.malf_job_2(&dyn.test4) AFTER dyn.sched_job_5(&dyn.test4)(2) ; -} ; diff --git a/trick_test/requirements_testing/sims/SIM_test4/S_define b/trick_test/requirements_testing/sims/SIM_test4/S_define deleted file mode 100644 index d087d2dd..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/S_define +++ /dev/null @@ -1,65 +0,0 @@ -sim_object { - sim_services/include: EXECUTIVE exec (sim_services/include/executive.d); - - (automatic) sim_services/input_processor: - input_processor(INPUT_PROCESSOR* IP = &sys.exec.ip); -} sys; - -sim_object { - test4: TEST4 test4 (test4/include/test4.d); - - /******************************************/ - /** Scheduled Jobs **/ - /******************************************/ - (0.1, scheduled) test4: - sched_job_1(TEST4* T = &dyn.test4); - - (0.1, scheduled) test4: - sched_job_2(TEST4* T = &dyn.test4); - - (0.1, scheduled) test4: - sched_job_3(TEST4* T = &dyn.test4); - - (0.1, scheduled) test4: - sched_job_4(TEST4* T = &dyn.test4); - - (0.1, scheduled) test4: - sched_job_5(TEST4* T = &dyn.test4); - - /* Duplicate sched_job_5() ****************/ - (0.1, scheduled) test4: - sched_job_5(TEST4* T = &dyn.test4); - - - /******************************************/ - /** Malfunction trigger jobs **/ - /******************************************/ - (malfunction_trigger) test4: - trigger_job_1(TEST4* T = &dyn.test4); - - (malfunction_trigger) test4: - trigger_job_2(TEST4* T = &dyn.test4); - - (malfunction_trigger) test4: - trigger_job_3(TEST4* T = &dyn.test4); - - (malfunction_trigger) test4: - trigger_job_4(TEST4* T = &dyn.test4); - - - /******************************************/ - /** Malfunction jobs **/ - /******************************************/ - (malfunction) test4: - malf_job_1(TEST4* T = &dyn.test4); - - (malfunction) test4: - malf_job_2(TEST4* T = &dyn.test4); - - (malfunction) test4: - malf_job_3(TEST4* T = &dyn.test4); - - (malfunction) test4: - malf_job_4(TEST4* T = &dyn.test4); - -} dyn; diff --git a/trick_test/requirements_testing/sims/SIM_test4/Test4Procedure.txt b/trick_test/requirements_testing/sims/SIM_test4/Test4Procedure.txt deleted file mode 100644 index 69810a90..00000000 --- a/trick_test/requirements_testing/sims/SIM_test4/Test4Procedure.txt +++ /dev/null @@ -1,17 +0,0 @@ -trigger - ( condition | job ) - insert_(before | after) - hold(Yes| No) - -Action: - variable - call - job - action - -MALFUNCTION_CMD MANUAL_ON ; -MALFUNCTION_CMD MANUAL_OFF ; -MALFUNCTION_CMD REMOVE_MANUAL ; -MALFUNCTION_CMD DISABLE_TRIGGER ; -MALFUNCTION_CMD DISABLE_TRIGGER ; -