User manual
Table Of Contents
- Einleitung
- Hardware Beschreibung
- Software
- DELIB API Referenz
- Anhang

DELIB API Referenz |Seite 52
DapiClearLastError();
return TRUE;
}
return FALSE;
}
//***************************************************************************
//***************************************************************************
//***************************************************************************
//***************************************************************************
//***************************************************************************
void main(void)
{
unsigned long handle;
unsigned long data;
// --------------------------------------------------------------------
// Open Module
handle = DapiOpenModule(USB_TTL_32,0);
printf("Module handle = %x\n", handle);
// --------------------------------------------------------------------
// Module not found!
if (handle==0)
{
printf("Could not open module!\n");
printf("Press any key to exit\n");
getch();
return;
}
// -------------------------------------------------------------------
// Module found!
printf("Module has been opened\n");
// -------------------------------------------------------------------
// Switch i/o to inputs
DapiSpecialCommand(handle, DAPI_SPECIAL_CMD_SET_DIR_DX_8, 0, 0, 0);
IsError();
printf("Channel 0-7 has been set to inputs\n");
printf("Press any key to continue\n");
getch();
// -------------------------------------------------------------------
// Read value of inputs 0-7
data = DapiDIGet8(handle, 0);
IsError();