Added Altium Project files

git-svn-id: file:///srv/dev-disk-by-uuid-17e88007-4d0c-45e0-8757-cacfcc458630/repositories/svn/Diplomarbeit@131 9fe90eed-be63-e94b-8204-d34ff4c2ff93
This commit is contained in:
Matthias
2009-01-15 10:28:29 +00:00
parent e92b94654b
commit f468e09499
66 changed files with 3619 additions and 60 deletions
@@ -69,53 +69,71 @@ BOOLEAN remoteDigitalLinetestMBExecute (void)
BOOLEAN remoteDigitalOutput;
BOOLEAN remoteDigitalInput;
/* Call mainboard digital output test and print out result afterwards */
remoteDigitalOutput = remoteDigitalOutputTest_MB();
sendString (SerOutPort, TRUE, resultMessage,
"remote digital_mb output test: ", f_tab, BoolRestoStr(remoteDigitalOutput));
"remote digital_mb output: ", f_tab, BoolRestoStr(remoteDigitalOutput));
/* Call mainboard digital input test and print out result afterwards */
remoteDigitalInput = remoteDigitalInputTest_MB();
sendString (SerOutPort, TRUE, resultMessage,
"remote digital_mb input test: ", f_tab, BoolRestoStr(remoteDigitalInput));
"remote digital_mb input: ", f_tab, BoolRestoStr(remoteDigitalInput));
/* Calculate test result */
if ((remoteDigitalOutput == TRUE) && (remoteDigitalInput == TRUE))
{
/* Test is passed */
returnValue = TRUE;
}
else
{
/* Test is passed */
returnValue = FALSE;
}
sendString (SerOutPort, TRUE, resultMessage,
"remote digital_mb test: ", f_tab, BoolRestoStr(remoteDigitalInput));
return (returnValue);
}
BOOLEAN remoteDigitalLinetestEBExecute (void)
{
// \MARK NEW PINSETTINGS FOR TESTER (2)
#if (PINSET_TESTER == 2)
#if (PINSET_TESTER == 2)
/* Extensionboard Test is available only on the specified test device */
BOOLEAN returnValue;
BOOLEAN remoteDigitalOutput;
BOOLEAN remoteDigitalInput;
/* Call extensionboard digital output test and print result afterwards */
remoteDigitalOutput = remoteDigitalOutputTest_EB();
sendString (SerOutPort, TRUE, resultMessage,
"remote digital_eb output test: ", f_tab, BoolRestoStr(remoteDigitalOutput));
/* Call extensionboard digital input test and print result afterwards */
remoteDigitalInput = remoteDigitalInputTest_EB();
sendString (SerOutPort, TRUE, resultMessage,
"remote digital_eb input test: ", f_tab, BoolRestoStr(remoteDigitalInput));
/* Calculate test result */
if ((remoteDigitalOutput == TRUE) && (remoteDigitalInput == TRUE))
{
/* Test is passed */
returnValue = TRUE;
}
else
{
/* Test is failed */
returnValue = FALSE;
}
return (returnValue);
#else
/* If other board than specific tester, printf out "test unavailable" text */
sendString (SerOutPort, TRUE, importantMessage,
"Extension Board test not available on this device", Dummy, Dummy);
@@ -136,11 +154,13 @@ BOOLEAN remoteDigitalOutputTest_MB (void)
/* Reset all remote digital outputs to LOW/OFF */
remoteDioWriteAll(remoteDeviceNumber, digital_mb, FALSE);
vTaskDelay (200);
vTaskDelay (500); /* Wait for reset remote outputs*/
/* Test each channel individually within a loop
* Loop-condition is the number of digital outputs on the test item
*/
for (channelcnt = 0; channelcnt < NUMBER_OF_DO_MB; channelcnt++)
{
{
/* Read remote digital channel value for LOW test */
if (dioRead(thisDeviceNumber, channelcnt) == FALSE)
{
@@ -192,11 +212,12 @@ BOOLEAN remoteDigitalOutputTest_MB (void)
}
}
/* Re-set remote digital output to LOW */
remoteDioWrite(remoteDeviceNumber, channelcnt, FALSE);
/* Message out Test Results */
sendString (SerOutPort, TRUE, testMessage,
"\tLinetest for Digital Input ", ItoDStr(channelcnt), ": ");
"\tLinetest for Digital Output (MB) ", ItoDStr(channelcnt), ": ");
sendString (SerOutPort, FALSE, testMessage,
" ", Dummy, BoolRestoStr (Low_Test));
sendString (SerOutPort, FALSE, testMessage,
@@ -205,13 +226,16 @@ BOOLEAN remoteDigitalOutputTest_MB (void)
" ", Dummy, BoolRestoStr (High_Test));
vTaskDelay (50);
/* If one of the individual tests fails, calculate a negative
* over-all test result
*/
if ((Low_Test == FALSE) || (High_Test == FALSE) || (AllOther_Test == FALSE))
{
returnResult = FALSE;
}
}
return (returnResult);
return (returnResult); /* Return test result to caller */
}
BOOLEAN remoteDigitalInputTest_MB (void)
@@ -225,8 +249,11 @@ BOOLEAN remoteDigitalInputTest_MB (void)
BOOLEAN AllOther_Test = TRUE;
dioClean(); /* Clean local digital outputs */
vTaskDelay (500);
vTaskDelay (500); /* Wait for local outputs */
/* Test each channel individually within a loop
* Loop-condition is the number of digital inputs on the test item
*/
for (channelcnt = 0; channelcnt < NUMBER_OF_DI_MB; channelcnt++)
{
if (remoteDioRead(remoteDeviceNumber, channelcnt) == FALSE)
@@ -239,21 +266,20 @@ BOOLEAN remoteDigitalInputTest_MB (void)
/* read back a HIGH Value, which is incorrect - LOW test failed */
Low_Test = FALSE;
}
vTaskDelay (200);
dioWrite(thisDeviceNumber, channelcnt, TRUE);
vTaskDelay(200);
/* Write local output to HIGH state */
dioWrite(thisDeviceNumber, channelcnt, TRUE);
vTaskDelay(200); /* Wait for local output */
if (remoteDioRead(remoteDeviceNumber, channelcnt) == TRUE)
{
/* Read back a HIGH Value, which is correct - HIGH test passed */
vTaskDelay(500);
High_Test = TRUE;
}
else
{
/* read back a LOW Value, which is incorrect - HIGH test failed */
vTaskDelay(500);
High_Test = FALSE;
}
@@ -286,7 +312,7 @@ BOOLEAN remoteDigitalInputTest_MB (void)
/* Message out Test Results */
sendString (SerOutPort, TRUE, testMessage,
"\tLinetest for Digital Input ", ItoDStr(channelcnt), ": ");
"\tLinetest for Digital Input (MB) ", ItoDStr(channelcnt), ": ");
sendString (SerOutPort, FALSE, testMessage,
" ", Dummy, BoolRestoStr (Low_Test));
sendString (SerOutPort, FALSE, testMessage,
@@ -295,13 +321,16 @@ BOOLEAN remoteDigitalInputTest_MB (void)
" ", Dummy, BoolRestoStr (High_Test));
vTaskDelay (50);
/* If one of the individual tests fails, calculate a negative
* over-all test result
*/
if ((Low_Test == FALSE) || (High_Test == FALSE) || (AllOther_Test == FALSE))
{
returnResult = FALSE;
}
}
return (returnResult);
return (returnResult); /* Return test result */
}
@@ -317,6 +346,7 @@ BOOLEAN remoteDigitalOutputTest_EB (void)
// \MARK NEW PINSETTINGS FOR TESTER (2)
#if (PINSET_TESTER == 2)
/* Necessary due to compiling on alternative boards */
dio_inMuxEn (TRUE); /* Switch dio to Extension Board*/
#endif
@@ -324,6 +354,14 @@ BOOLEAN remoteDigitalOutputTest_EB (void)
remoteDioWriteAll(remoteDeviceNumber, digital_eb, FALSE);
vTaskDelay (200);
/* Test each channel individually within a loop
* Loop-condition is the total number of digital outputs on the test item
* The remote digital write/read function counts up to 12 (8 MB + 4 EB),
* the local write/read only to 8. The 4 extension board connections
* must be switche manually. That is why the loop counting starts with
* the number of the mainboard outputs, which represents the first
* extensionboard output.
*/
for (channelcnt = NUMBER_OF_DO_MB; channelcnt < NUMBER_OF_TOTAL_DO; channelcnt++)
{
if (dioRead(thisDeviceNumber, (channelcnt - NUMBER_OF_DO_MB)) == FALSE)
@@ -376,7 +414,7 @@ BOOLEAN remoteDigitalOutputTest_EB (void)
}
/* Message out Test Results */
sendString (SerOutPort, TRUE, testMessage,
"\tLinetest for Digital Input ", ItoDStr(channelcnt), ": ");
"\tLinetest for Digital Ouput(EB) ", ItoDStr(channelcnt), ": ");
sendString (SerOutPort, FALSE, testMessage,
" ", Dummy, BoolRestoStr (Low_Test));
sendString (SerOutPort, FALSE, testMessage,
@@ -385,6 +423,9 @@ BOOLEAN remoteDigitalOutputTest_EB (void)
" ", Dummy, BoolRestoStr (High_Test));
vTaskDelay (50);
/* If one of the individual tests fails, calculate a negative
* over-all test result
*/
if ((Low_Test == FALSE) || (High_Test == FALSE) || (AllOther_Test == FALSE))
{
returnResult = FALSE;
@@ -393,10 +434,11 @@ BOOLEAN remoteDigitalOutputTest_EB (void)
// \MARK NEW PINSETTINGS FOR TESTER (2)
#if (PINSET_TESTER == 2)
/* Necessary due to compiling on alternative boards */
dio_inMuxEn (FALSE); /* Switch dio back to main Board*/
#endif
return (returnResult);
return (returnResult); /* Return test result */
}
@@ -412,12 +454,21 @@ BOOLEAN remoteDigitalInputTest_EB (void)
// \MARK NEW PINSETTINGS FOR TESTER (2)
#if (PINSET_TESTER == 2)
/* Necessary due to compiling on alternative boards */
dio_outMuxEn (TRUE); /* Switch dio to Extension Board*/
#endif
dioClean(); /* Clean local digital outputs */
vTaskDelay (500);
vTaskDelay (500); /* assure that cleaning is done */
/* Test each channel individually within a loop
* Loop-condition is the number of digital inputs available on the
* extension board. The remote digital write/read function counts up
* to 12 (8 MB + 4 EB), the local write/read only to 8. The 4 extension
* board connections must be switched manually (first 4 local inputs).
* This is why the remote channel number is added with the number of
* the digital inputs available on the mainboard.
*/
for (channelcnt = 0; channelcnt < NUMBER_OF_DI_EB; channelcnt++)
{
if (remoteDioRead(remoteDeviceNumber, (channelcnt + NUMBER_OF_DI_MB)) == FALSE)
@@ -431,8 +482,9 @@ BOOLEAN remoteDigitalInputTest_EB (void)
Low_Test = FALSE;
}
vTaskDelay (200);
/* Set local digital output to HIGH stat */
dioWrite(thisDeviceNumber, channelcnt, TRUE);
vTaskDelay(200); /* Wait for command is finished */
if (remoteDioRead(remoteDeviceNumber, (channelcnt + NUMBER_OF_DI_MB)) == TRUE)
{
@@ -445,8 +497,9 @@ BOOLEAN remoteDigitalInputTest_EB (void)
High_Test = FALSE;
}
/* Read all remote digital inputs */
remoteDioReadAll(remoteDeviceNumber, digital_eb);
vTaskDelay (200);
vTaskDelay (200); /* Wait for command is finished */
for (loopcnt = 0; loopcnt < NUMBER_OF_DI_EB; loopcnt++)
{
@@ -474,7 +527,7 @@ BOOLEAN remoteDigitalInputTest_EB (void)
/* Message out Test Results */
sendString (SerOutPort, TRUE, testMessage,
"\tLinetest for Digital Input ", ItoDStr(channelcnt), ": ");
"\tLinetest for Digital Input (EB) ", ItoDStr(channelcnt), ": ");
sendString (SerOutPort, FALSE, testMessage,
" ", Dummy, BoolRestoStr (Low_Test));
sendString (SerOutPort, FALSE, testMessage,
@@ -483,6 +536,9 @@ BOOLEAN remoteDigitalInputTest_EB (void)
" ", Dummy, BoolRestoStr (High_Test));
vTaskDelay (50);
/* If one of the individual tests fails, calculate a negative
* over-all test result
*/
if ((Low_Test == FALSE) || (High_Test == FALSE) || (AllOther_Test == FALSE))
{
returnResult = FALSE;
@@ -491,9 +547,10 @@ BOOLEAN remoteDigitalInputTest_EB (void)
// \MARK NEW PINSETTINGS FOR TESTER (2)
#if (PINSET_TESTER == 2)
/* Necessary due to compiling on alternative boards */
dio_outMuxEn (FALSE); /* Switch dio back to main Board*/
#endif
return (returnResult);
return (returnResult); /* Return test result */
}