Vault 7: Projects
This publication series is about specific projects related to the Vault 7 main publication.
Description
Retreives the status of the buffer ownership. This function will indicate if the previous transfer is complete or not.
This function will take the input handle (pointer to a BDT entry) and will check the UOWN bit. If the UOWN bit is set then that
indicates that the transfer is not complete and the USB module still owns the data memory. If the UOWN bit is clear that
means that the transfer is complete and that the CPU now owns the data memory.
For more information about the BDT, please refer to the appropriate datasheet for the device in use.
Typical Usage:
//make sure that the last transfer isn't busy by checking the handle
if(!HIDTxHandleBusy(USBInHandle))
{
//Send the data contained in the ToSendDataBuffer[] array out on
// endpoint HID_EP
USBInHandle =
HIDTxPacket(HID_EP,(uint8_t*)&ToSendDataBuffer[0],sizeof(ToSendDataBuffer));
}
Remarks
None
Preconditions
None.
Parameters
Parameters Description
USB_HANDLE handle the handle for the transfer in question. The handle is
returned by the HIDTxPacket() and HIDRxPacket() functions.
Please insure that USB_HANDLE objects are initialized to
NULL.
Return Values
Return Values Description
TRUE the HID handle is still busy
FALSE the HID handle is not busy and is ready to send additional
data.
Function
bool HIDTxHandleBusy( USB_HANDLE handle)
1.4.1.4.1.4 HIDTxPacket Macro
Sends the specified data out the specified endpoint
File
usb_device_hid.h
Syntax
#define HIDTxPacket USBTxOnePacket
Description
This function sends the specified data out the specified endpoint and returns a handle to the transfer information.
Typical Usage:
//make sure that the last transfer isn't busy by checking the handle
if(!HIDTxHandleBusy(USBInHandle))
{
//Send the data contained in the ToSendDataBuffer[] array out on
1.4 Library Interface MLA - USB Library Help Device/Peripheral
90
Protego_Release_01_05-Related-OEM-Documentation-MLA_v2013_12_20-help_mla_usb.pdf