📄 4001.c
字号:
/* COB SAMPLE PIN ASSIGNMENT:
------------
T1 1 -|1 |--| 20|- UR1
T2 2 -|2 19|- UR2
PMUF2 VDD -|3 18|- UR3
T4 4 -|4 17|- UR4
T5 5 -|5 16|- UR5
T6 6 -|6 15|- PMUS2
T7 7 -|7 14|- UR6
GNDSINGLE GND -|8 13|-
T9 9 -|9 12|-
T10 10 -|10 11|- 5V POWER
-------------
HF4001
REMARKS:
1). OSC FREQUENCE : 50 HZ( NF FORMAT )
2).
*/
/* 34 PIN CONNECTOR ASSIGNMENT( ):
------------------------------------------------------------------------------------
-DUT1- -DUT2-
T1 1 PIN1 - 470K - VDD(UR1) | PIN34 UR6
T2 2 PIN3 50HZ | PIN32 RR7
PMUF2 VDD PIN5 - | PIN30
T4 4 PIN7 - 1K - VDD(UR2,6) | PIN28
T5 5 PIN9 | PIN26
T6 6 PIN11 - 3M - VDD(UR3,5) | PIN24
T7 7 PIN13 | PIN22
GND SINGLE PIN15 | PIN20
T9 9 PIN17 - 5.5K - GND(UR4) | PIN18
T10 10 PIN19 | PIN16
UR1 PIN21 | PIN14
UR2 PIN23 | PIN12
UR3 PIN25 | PIN10
UR4 PIN27 | PIN8
UR5 PIN29 | PIN6
PMUS2 PIN31 | PIN4
5V POWER PIN33 | PIN2
------------------------------------------------------------------------------------
*/
/* PIN ASSIGNMENT :
IC Pin Pad Test channel
------------------------------------------------
1 T1 (PMUSF1)
2 T2 (PMUSF1)
3 VDD PMUSF2
4 T4 (PMUSF1)
5 T5 (PMUSF1)
6 T6 (PMUSF1)
7 T7 (PMUSF1)
8 GND GNDSINGLE
9 T9 (PMUSF1)
10 T10 (PMUSF1)
*/
#include <tr-6010.h>
//#include <EGRS232.H>
/**********************************************************************************/
//--------------------------Here for user define for HKE14003---------------------
/************************** *********************/
#define FUNCTION "func_003"
#define SETLIDD_MAX 0.020 // 20UA
#define SETSIDD_MAX 0.30 // 300UA
#define SETDIDD_MAX 0.40 // 400UA
/************************** *********************/
//----------------------------------------------------------------------------------
/**********************************************************************************/
//#define Continuity_test_debug
//#define Lidd_test_debug
//#define Sidd_test_debug
//#define Didd_test_debug
//#define Function_test_debug
long int addrfunction;
test()
{
Lidd_test();
Sidd_test();
Didd_test();
Iih_test();
Function_test();
BIN(1);
}
Lidd_test()
{
float Sidd;
char buffer[100];
SETUR(0,"1-16");
SETDUTR(0,"1-16"); // initial code
SETUR(0,"1-6"); //
DLYMS(5);
PMUTODUT(2,1);
DLYMS(2); //5
FVPMU(2,0.3,18,15,-15,1); //initial code here
DLYMS(2); //5
FVPMU(2,0.3,0.20,SETLIDD_MAX,-0.10,2); /* SIDD< 20 uA */ //0.010
DLYMS(2); //10
#ifdef Lidd_test_debug
DEBUGMODE("Here SIDD_test() debug");
MESSAGE("SIDD_test() test here");
#endif
CHECKPMU(2,FB2);
}
Sidd_test()
{
float Sidd;
char buffer[100];
SETUR(0,"1-16");
SETDUTR(0,"1-16"); // initial code
SETUR(0,"1-6"); //
DLYMS(5);
PMUTODUT(2,1);
DLYMS(2); //5
FVPMU(2,6.0,18,15,-15,1); //initial code here
DLYMS(2); //5
FVPMU(2,6.0,1.0,SETSIDD_MAX,-0.3,1); /* SIDD< 300 uA */ //0.010
DLYMS(2); //10
#ifdef Sidd_test_debug
DEBUGMODE("Here SIDD_test() debug");
MESSAGE("SIDD_test() test here");
#endif
CHECKPMU(2,FB3);
}
Didd_test()
{
float Sidd;
char buffer[100];
SETUR(0,"1-16");
SETDUTR(0,"1-16"); // initial code
SETUR(1,"1"); // 470 kohm Resistor on
PMUTODUT(2,1);
DLYMS(2); //5
FVPMU(2,6.0,18,15,-15,1); //initial code here
DLYMS(2); //5
FVPMU(2,6.0,1.0,SETDIDD_MAX,-0.40,1); /* DIDD< 400 uA */ //0.010
DLYMS(2); //10
#ifdef Didd_test_debug
DEBUGMODE("Here SIDD_test() debug");
MESSAGE("SIDD_test() test here");
#endif
CHECKPMU(2,FB4);
}
Iih_test()
{
SETUR(0,"1-16");
SETDUTR(0,"1-16"); // initial code
DLYMS(5);
PMUTOANA(1,0);
SETPMUR(1,"2");
PMUTODUT(2,1);
DLYMS(2); //5
FVPMU("2",6.0,18,15,-15,1); //initial code here
DLYMS(2); //5
FVPMU("1",6.0,20,10,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
DLYMS(2); //5
FVPMU("1",0.0,20,1,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
// DEBUGMODE("debug for Iih");
/*************END OF PIN2**************/
SETPMUR(0,"1-10");
DLYMS(5);
SETPMUR(1,"5");
DLYMS(2);
FVPMU("1",6.0,20,12,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
DLYMS(2); //5
FVPMU("1",0.0,20,1,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
/*************END OF PIN5*************/
SETPMUR(0,"1-10");
DLYMS(5);
SETPMUR(1,"6");
DLYMS(2);
FVPMU("1",6.0,20,12,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
/*
DLYMS(2); //5
FVPMU("1",0.0,20,1,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
*/
/*************END OF PIN6*************/
SETPMUR(0,"1-10");
DLYMS(5);
SETPMUR(1,"7");
DLYMS(2);
FVPMU("1",6.0,20,1,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
DLYMS(2); //5
FVPMU("1",0.0,20,1,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
/*************END OF PIN7*************/
SETPMUR(0,"1-10");
DLYMS(5);
SETPMUR(1,"10");
DLYMS(2);
FVPMU("1",6.0,20,1,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
DLYMS(2); //5
FVPMU("1",0.0,20,1,-1,1); //initial code here
DLYMS(2);
CHECKPMU(1,FB5);
/*************END OF PIN10*************/
}
Function_test()
{
unsigned count;
char str[20];
eotest();
// PMUTODUT(1,0);
SETUR(0,"1-16");
SETDUTR(0,"1-16"); // initial code
// DLYMS(5);
PMUTOANA(1,0);
SETPMUR(0,"1-16");
SETTP(2000);//2US
SETTSTART(0,0,100);
SETTSTOP(0,0,1100);
SETTSTROBE(0,0,1400);
SETVIH(1,6.0);
SETVIL(1,0.0); // driver
SETVOH(1,5.0); //max 1.35,1.3
SETVOL(1,1.0);
SETRTZ("1");
SETNF("2,4,9");
SETUR(1,"1-3,5,7");
SETPMUR(1,"5");
PMUTODUT("2,3",1);
FVPMU("2",6.0,18,15,-15,1); // VDD = 6 V
FVPMU("3",6.0,110,110,-15,0); // VDD = 6 V
DLYMS(5);
// FIPMU("1",0.0,3.0,2.5,-1);
// DLYMS(2);
// DEBUGMODE("VOLTAGE debug for PIN5");
// CHECKPMU(1,FB6);
SETUR(1,"4");
SETPMUR(0,"5");
DLYMS(2);
SETPMUR(1,"9");
FIPMU("1",0.0,7.0,6.0,4.8);
DLYMS(2);
CHECKPMU(1,FB6);
SETPMUR(0,"1-10");
SETDUTR(1,"2,4,9");
DLYMS(20);
FTEST(1,3,NB);
DLYMS(350);
MESSAGE("1111 debug for function");
// DEBUGMODE("debug for function");
FTEST(4,6,FB7);
count=GETCOUNT();
sprintf(str,"count= %d",count);
MESSAGE(str);
if(count>3700||count<2400) //2400--3700
{ BIN(7);
}
/* FTEST(1,3,NB);
DLYMS(200);
MESSAGE("2222 debug for function");
DEBUGMODE("debug for function");
FTEST(4,6,FB8);
count=GETCOUNT();
sprintf(str,"count= %d",count);
MESSAGE(str);
if(count>850||count<100)
{ BIN(8);
}
FTEST(1,3,NB);
DLYMS(200);
MESSAGE("3333 debug for function");
DEBUGMODE("debug for function");
FTEST(4,6,FB8);
count=GETCOUNT();
sprintf(str,"count= %d",count);
MESSAGE(str);
if(count>850||count<100)
{ BIN(8);
}
*/
}/* end of function_test() */
eotest()
{
FVPMU("1-4",0,0,0,0,0);
PMUTODUT("1-4",0);
SETPMUR(0,"1-32");
SETDUTR(0,"1-32");
SETUR(0,"1-32");
PMUTOANA(0,0);
DLYMS(10);
/* Add end-of-test code here */
}
init()
{
VERSION("HF4001");
EGinit();
SETVIH(1,3.0); //1.5
SETVIL(1,0.0); // driver
SETVOH(1,2.0); //max 1.35,1.3
SETVOL(1,2.0);
SETVIH(2,3.0);
SETVIL(2,0.0);
SETVOH(2,2.0); //1.0
SETVOL(2,2.0); // comparater
SETNF("1-12,17"); // format
SETNF("4");
SETBIN(1,"PASS");
SETBIN(2,"Lidd_fail");
SETBIN(3,"Sidd_fail");
SETBIN(4,"Didd_fail");
SETBIN(5,"Iih_fail");
SETBIN(6,"Pin5_vol_fail");
SETBIN(7,"Func_fail");
addrfunction=LMLOAD(1,"4001");
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -