I set TNT4882 in one-chip mode,and it works when useing MAX,
PC procedure use VIVA read and write VI in LabView,
if intervals between write and read is less than 5ms ,it is OK,
when it is longer ,an Timeout error occured.what is the reason??
thanks for your help!
this is the code in TNT4882:
// init_TNT4882( )
CMDR=0x22; //reset 4882
// Place the TNT4882 in Turbo+7210 Mode
SPMR=0x80;//Write 80 (hex) to offset 6.
AUXMR=0x80;//Write 80 (hex) to offset A (hex).
delay();
SPMR=0x99;//Write 99 (hex) to offset 6.
AUXMR=0x99;//Write 99 (hex) to offset A (hex).
delay();
HSSEL=0x11; //Configure the TNT4882 one chip
AUXMR=0x02; //Make Sure that the Local Power-On Message is Asserted
delay();
//Configure the TNT4882 for GPIB Operation
ADMR =0x31; //Set dual primary addressing mode
ADR=Addr; //Load the primary GPIB address
ADR=0xE0; //no secondary address,
KEYREG=0;
SPMR =0x17; //Write the Initial Serial Poll Response
AUXMR=0x09;
delay();
PPR=0x6a;
delay(); //Configure the Initial Parallel Response
IMR0 =0xA8;
IMR1 =0x94;
IMR2 =0x01;
IMR3 =0x02;
AUXMR=0x00;
///SetGPIBWrite( )
CMDR =0x08; //TNT4882 stop
CMDR =0x10; //reset fifo
CFG =0x00; //set GPIB write
AUXMR=0x9D;
delay();
EOSR=0x3B; //end byte
CNT0 =(char)(cnt);
CNT1 =(char)(cnt>>8);
///host procedure flow
after reset ,TNT4882 as a listener,when it received data from PC,
it would be seted as a talker, at the same time,host send data to FIFOS in TNT4882.
///PC procedure flow
ibwrite(***)
delay(10ms)
ibread()