MIL_FPGA_CONTEXT FpgaCommandContext, | //in |
MIL_INT64 RegisterSection, | //in |
MIL_INT Offset, | //in |
MIL_INT Length, | //in |
void *ValuePtr, | //out |
MIL_INT64 WriteAccessFlag | //in |
This function writes values to FPGA registers of the PU associated with the specified command context. A maximum of four MfpgaSetRegister() calls can be made with any FPGA command context, although you can set the contents of multiple registers in each call. For a Matrox PU, you should consult the register file of the PU in the Matrox FPGA Components Reference. You can specify whether write accesses will be collected and made before processing. Note that for those PUs that have interrupts you can specify that write accesses will be collected after the PU issues its end-of-processing interrupt.
For Matrox PUs and custom PUs created using the Matrox Processing Unit Designer, a C structure is created to represent each register of the PU. The structures are supplied in header files (fpga_*.h), located in the \Matrox Imaging\MIL\Examples\SoliosFDK\Include directory for Matrox Solios and in the Matrox Imaging\radient\src\headers\local\fpga_*.h directory for Matrox Radient. You must include the appropriate header file to use the structures. See the Setting and retrieving results from PU registers section of Chapter 34: Using MIL with a Processing FPGA for more information on the Matrox register structure.
Specifies the offset from the start of the specified register section, from which to begin writing, in bytes. The offset must be a multiple of 4 bytes.
Specifies the number of bytes to write in the register. The length must be a multiple of 4 bytes.
Specifies the address of the variable in which to write the value to be sent to the register.
Specifies when the register write access must take place. This parameter must be set to one of the following values:
For specifying when to access the
register
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
MIL system-specific tooltip (†) |
|||||||||||||||||||||||||||||||||||||
M_WHEN_COMPLETED |
Accesses the registers after the PU issues its end-of-processing interrupt. |
† | j | k | l | m | p | q | r | ||||||||||||||||||||||||||||||
M_WHEN_DISPATCHED |
Accesses the registers during PU setup, prior to the start of processing. |
† | j | k | l | m | p | q | r |
Header | Include mil.h; milfpga.h. |
Library | Use mil.lib; milfpga.lib. |
DLL | Requires mil.dll; milfpga.dll. |