TBApiSendMacroSynchronous API Call

 

Description

Sends data to the controller associated with the specified device using the UPDD macro language.

Parameters

Device handle, macro to send and length of macro command, return buffer and size.

Returns

0 = fail, 1 = OK.

Notes

For more details of the UPDD macro language, see the on-line UPDD documentation.

 

Visual C++ Declaration/example

 

BOOL TBAPI  TBApiSendMacroSynchronous(HTBDEVICE aDeviceHandle, const TBCHAR* aMacro, void* aUSBRetBuffer, DWORD aUSBRetBufferSize);

 

unsigned char response[64];

TBApiSendMacroSynchronous(aDevice,_T("[USB type=CLASS_INTERFACE flags=0 req=9 val=0303 idx=0 len=8]21 04 03 00 00 00 00 00[END]"), response,sizeof(response));

 

The options for USB type are

 

                  "CLASS_DEVICE"

                  "CLASS_INTERFACE"

                  "CLASS_ENDPOINT"

                  "CLASS_OTHER"

                  "VENDOR_DEVICE"

                  "VENDOR_INTERFACE"

                  "VENDOR_ENDPOINT"

                  "VENDOR_OTHER"