I want to use MPUSBWrite and MPUSBRead to talk to my LAC USB device. The functions are declared in a header file. The following is a snippet code:
mpusbapi.h snippet code
DWORD (*MPUSBRead)(HANDLE handle, // Input
PVOID pData, // Output
DWORD dwLen, // Input
PDWORD pLength, // Output
DWORD dwMilliseconds); // Input
DWORD (*MPUSBWrite)(HANDLE handle, // Input
PVOID pData, // Input
DWORD dwLen, // Input
PDWORD pLength, // Output
DWORD dwMilliseconds); // Input
You can assume that in my test.cpp, I have linked the .dll and opened connection to the device correctly (which I have).
Now I want to use MPUSBWrite() and MPUSBRead(). The data formatting for the device is found on page 6 of LAC Advanced Config. Please advise on how to send and receive data from the device! Thanks!
go to mikrocontroller.net/attachment/9321/MPUSBAPI.txt and it describes the variables.