Xxusb_Flashblock_Program - Wiener VM-USB User Manual

Hide thumbs Also See for VM-USB:
Table of Contents

Advertisement

pData
[out] pointer to an array storing the data to be sent; the array may be declared as byte,
unsigned short, or unsigned long.
wDataLen
[in] Number of bytes to read. This number must be not less than the number of bytes
stored in the output FIFO.
wTimeout
[in] Time in milliseconds, after which the I/O operation is canceled, should there be no
data available for the readout.
Return Values
On success, the function returns the number of bytes read from XX-USB. Function returns a
negative number on a failure, which in most cases signifies a timeout condition.
Remarks
Depending upon the actual need, the function may be used to pass to xxusb the data in a form
of an array of bytes, unsigned short integers (16 bits), or unsigned long integers (32 bits).

6.15 xxusb_flashblock_program

The xxusb_flashblock_program function programs one sector of 256 bytes of the flash
memory (FPGA configuration memory)
WORD xxusb_usbfifo_read{
HANDLE hDevice,
UCHAR *pData,
};
Parameters
hDevice
[in] Handle to the XX-USB device.
pData
[out] Pointer to the configuration (byte) data array.
Return Values
On success, the function returns the number of bytes written to XX-USB – the correct
number is 518.
Function returns a negative number on a failure, which in most cases signifies a timeout
condition.
Remarks
To program the flash memory, one must call repeatedly xxusb_flashblock_program, while
pausing for at least 30ms between consecutive calls and incrementing the pointer to the data
array by 256 on each consecutive call. The device must be in programming mode with the
rotary selector in one of the 4 "P" positions and with the red "Fail" LED on.
WIENER, Plein & Baus GmbH
45
www.wiener-d.com

Advertisement

Table of Contents
loading

Related Products for Wiener VM-USB

Table of Contents