/* ndemo2 : generate 2 starting clock demo */ /* step 1 : all clock sources select external_clock */ /* step 2 : run NDEMO2.EXE */ /* step 3 : read the counter value of counter1 to counter12 */ /* ----------------------------------------------------------- */ #include "PCITMC12.H" WORD wBaseAddr,wIrq,wPLX; WORD pci_tmc12_do(WORD wDo); WORD pci_tmc12_do2(WORD wXor); WORD pci_tmc12_select8254(char cChip); WORD pci_tmc12_c0(char cConfig, char cLow, char cHigh); WORD pci_tmc12_c1(char cConfig, char cLow, char cHigh); WORD pci_tmc12_c2(char cConfig, char cLow, char cHigh); void read_c0(int B); void read_c1(int B); void read_c2(int B); int main() { int i,j; WORD wBoards,wRetVal; char c; clrscr(); wRetVal=PTMC12_DriverInit(&wBoards); printf("\n(1) Threr are %d PCI-TMC12 Cards in this PC",wBoards); if ( wBoards==0 ) { putch(0x07); putch(0x07); putch(0x07); printf("(1) There are no PCI-TMC12 card in this PC !!!\n"); exit(0); } printf("\n(2) Show the Configuration Space of all PCI-TMC12:"); for(i=0; i