?? main.c
字號:
/******************************************************************************
C H E A D E R F I L E
ALL RIGHTS RESERVED
*******************************************************************************
Project Name : BONO System Test Program
Project No. :
Title :
File Name : main.c
Last Modified: 12/27/2005
(MM/DD/YYYY)
Description : Prototype definition header for BONO silicon system test program.
Assumptions :
Dependency Comments :
Project Specific Data :
History (MM/DD/YYYY) :
12/27/2005 - Initial Proposal
******************************************************************************/
#include <stdio.h>
#include "common.h"
#include "bono_memory_map_defines.h"
#include "testcase.h"
//#include "your_module.h"
/* Modify the following data structure to contain the test cases to perform */
//testcase_t gTestCaseArray[] = {
// {case1, 1},
// {case2, 2},
// {case3, 3},
/* {case4, 4},
{case5, 5},
{case6, 6},
{case7, 7},
{case8, 8},
{case9, 9},
{case10, 10},*/
//};
/****************************************************************
Private Functions
****************************************************************/
//---------------------------------------------------------------
// Function : handleError
//
// Description : Handles error according to caseNum and the error
//
// Return Value : None
//
//---------------------------------------------------------------
/*static void handleError
(
uint8_t* index, // IN/OUT: index into gTestCaseArray[]
status_t status // IN: the error status to handle
)
{
switch(status)
{
case ERR_TIMEOUT:
printf("\n -- Time out!! --\n");
// say, we want to retry....
printf("Retrying Case %d....\n", gTestCaseArray[*index - 1].caseNum);
*index -= 1; // do this to retry
break;
default:
printf("\n -- Error --\n");
}
}*/
/*****************************************************************
Public Functions
*****************************************************************/
#include <stdio.h>
#include <stdlib.h>
/* Modify SysInit() for different system initialization settings */
extern int SysInit(void);
extern void pcmcia_isr(void);
typedef void (*funct_t)(void);
extern funct_t vect_IRQ[64];
extern U32 gError;
int MEMtest(void);
void test_exit(int err);
int main(void)
{
int rc=0;
unsigned short htmp;
unsigned short *phtmp;
printf ("START_TEST\n");
/*
phtmp = (unsigned short *)0xB40000002;
htmp = *phtmp;
phtmp = (unsigned short *)0xB40000004;
htmp = *phtmp;
phtmp = (unsigned short *)0xB40000006;
htmp = *phtmp;
*/
// Init timer
// GPT1Init(500);
rc = MEMtest();
test_exit(rc);
return rc;
}
void test_exit(int err)
{
if (err)
printf("TEST FAILED!\n");
else
printf("\nTEST PASSED!\n");
printf ("END_TEST\n");
exit (err);
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -