User Space Control Class for the MityCAM test_pattern_gen FPGA block.
More...
#include <TestPatternGenerator.h>
User Space Control Class for the MityCAM test_pattern_gen FPGA block.
◆ teTestPatternMode
Types of available test patterns the core can generate.
Enumerator |
---|
eeGradientX | horizontal gradient
|
eeGradientY | vertical gradient
|
eeStaticCountUp | incrementing count for each new pixel in raster order. Count starts at static pixel value
|
eeFrameNumberCountUp | incrementing count for each new pixel in raster order. Count starts at frames count
|
eeStaticVal | constant pixel value
|
eeDEAD | 0x0000DEAD
|
◆ tcTestPatternGenerator()
tcTestPatternGenerator::tcTestPatternGenerator |
( |
uint32_t |
anControlAddress | ) |
|
Construct a new tc Test Pattern Generator::tc Test Pattern Generator object.
- Parameters
-
anControlAddress | 32 bit physical address the core is mapped to |
◆ ~tcTestPatternGenerator()
tcTestPatternGenerator::~tcTestPatternGenerator |
( |
| ) |
|
|
virtual |
Destroy the tc Test Pattern Generator::tc Test Pattern Generator object.
◆ dumpState()
void tcTestPatternGenerator::dumpState |
( |
void |
| ) |
|
Dump state of CORE to INFO status text.
◆ getPatternMode()
- Returns
- the current set test pattenr mode.
◆ getStaticVal()
uint32_t tcTestPatternGenerator::getStaticVal |
( |
void |
| ) |
|
- Returns
- the programmed static value for test pattern generation logic.
◆ initialized()
bool tcTestPatternGenerator::initialized |
( |
| ) |
|
check and ensure the core has been properly inialized
- Returns
- true when memory map access has been established to the core
-
false when memory map access to the core was not established
◆ reset()
int32_t tcTestPatternGenerator::reset |
( |
bool |
abOn | ) |
|
Enable / Disable core reset.
- Note
- the reset bit does not halt the test pattern data generation engine, it only disables the output frame creation from running (header_create block). In a similar way, asserting reset will also not stop frames from flowing if the passthru mode is enabled. You should probably make the appropriate calls to setPassThru() and startTestPattern() when using this routine.
- Parameters
-
abOn | when true, reset the core. |
- Returns
- non-zero on error.
◆ setPassThru()
int tcTestPatternGenerator::setPassThru |
( |
bool |
abPassThru | ) |
|
Enables passthru mode. This will override testpattern mode if it is enabled and could create a break in the stream data if the core is running test pattern data and not in reset.
- Parameters
-
abPassThru | when true, enable pass through mode. |
- Returns
- non-zero on error.
◆ setPatternMode()
Set the test pattern type.
- Parameters
-
- Returns
- non-zero on error.
◆ setPatternTiming()
int tcTestPatternGenerator::setPatternTiming |
( |
uint16_t |
anWidth, |
|
|
uint16_t |
anHeight, |
|
|
int |
anPixelsPerClock, |
|
|
float |
anClockRateMHz, |
|
|
const std::chrono::microseconds & |
anTargetFrameInterval, |
|
|
unsigned int |
anVertBlankLines = 2 |
|
) |
| |
Configure the width, height, horizontal (backside) and vertical (frontside) porch timing for test pattern generation based on the provided parameters.
- Parameters
-
anWidth | width of output in pixels |
anHeight | height of output in pixels |
anPixelsPerClock | number of pixels per clock in the pipeline (must be known) |
anClockRateMHz | the clock rate of the pipeline |
anTargetFrameInterval | the desired frame interval time, in microseconds |
anVertBlankLines | the desired number of blanking rows (default of 2) |
- Returns
- non-zero on error.
◆ setStaticVal()
int tcTestPatternGenerator::setStaticVal |
( |
uint32_t |
val | ) |
|
Sets the static value for the test pattern generation logic.
- Parameters
-
- Returns
- non-zero on error.
◆ startTestPattern()
int tcTestPatternGenerator::startTestPattern |
( |
bool |
abStart | ) |
|
Start Test Pattern Engine. Start the test pattern engine internal data generation. This will have no effect if pass through is enabled. If reset is enabled, the output will not be generated until reset is released.
- Parameters
-
abStart | when true start test pattern generator data. |
- Returns
- non-zero on error.
The documentation for this class was generated from the following files: