This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DLP3010EVM-LC: two cameras and one DLP3010-evm projector setup for 3D scanning purpose

Part Number: DLP3010EVM-LC

Hi Team,

Good day! I am posting this in behalf of our customer and we appreciate your assistance on this query. 

Here is the full details of inquiry:

I have two cameras and one DLP3010-evm projector setup for 3D scanning purpose. In order to capture images simultaneously, I'm using the cameras in hardware trigger mode where the trigger source is projector's "Trigger Out 2". When I use Splash Pattern Mode using the "DLP EVM GUI 3.1.0.5", everything works fine as expected (please see the attached picture.)

The sent commands are listed in "Command Log". I used the list to implement a C++ program to do the same as what GUI does. The problem is, in this situation cameras do not start capturing. Here are the commands listed in Command Log:



I have used provided samples codes and API. The implementation has been attached.

#include "dlpc347x_samples.h"
#include
#include
#include

using namespace std;

int main()
{
InitConnectionAndCommandLayer();
bool Status = CYPRESS_I2C_RequestI2CBusAccess();
if (Status != true)
return -1;
DLPC34XX_ControllerDeviceId_e DeviceId = (DLPC34XX_ControllerDeviceId_e)0;
if (DLPC34XX_ReadControllerDeviceId(&DeviceId) != 0)
return -1;
uint16_t PixelsPerLine, LinesPerFrame;
if (DLPC34XX_ReadInputImageSize(&PixelsPerLine, &LinesPerFrame) != 0)
return -1;
size_t exposure_time = 793;
/// Read Validate Exposure Time
DLPC34XX_ValidateExposureTime_s valid_exposure_time;
int ret_valid_exposure = DLPC34XX_ReadValidateExposureTime(DLPC34XX_PatternMode_e::DLPC34XX_PM_SPLASH,
DLPC34XX_SequenceType_e::DLPC34XX_ST_ONE_BIT_MONO, exposure_time, &valid_exposure_time);
if (ret_valid_exposure != 0)
return -1;
/// Write Image Freeze
if (DLPC34XX_WriteImageFreeze(true) != 0)
return -1;
/// Write Trigger Out Configuration
int trigger_out2_delay = 0;
DLPC34XX_WriteTriggerOutConfiguration(
DLPC34XX_TriggerType_e::DLPC34XX_TT_TRIGGER1,
DLPC34XX_TriggerEnable_e::DLPC34XX_TE_ENABLE,
DLPC34XX_TriggerInversion_e::DLPC34XX_TI_NOT_INVERTED,
0);
if (DLPC34XX_WriteTriggerOutConfiguration(
DLPC34XX_TriggerType_e::DLPC34XX_TT_TRIGGER2,
DLPC34XX_TriggerEnable_e::DLPC34XX_TE_ENABLE,
DLPC34XX_TriggerInversion_e::DLPC34XX_TI_NOT_INVERTED,
trigger_out2_delay) != 0)
return -1;
///Write Pattern Configuration
DLPC34XX_PatternConfiguration_s pat_config;
pat_config.RedIlluminator = DLPC34XX_IlluminatorEnable_e::DLPC34XX_IE_DISABLE;
pat_config.GreenIlluminator = DLPC34XX_IlluminatorEnable_e::DLPC34XX_IE_ENABLE;
pat_config.BlueIlluminator = DLPC34XX_IlluminatorEnable_e::DLPC34XX_IE_DISABLE;
pat_config.IlluminationTime = 171;
pat_config.PreIlluminationDarkTime = 793;
pat_config.PostIlluminationDarkTime = 31;
pat_config.SequenceType = DLPC34XX_SequenceType_e::DLPC34XX_ST_ONE_BIT_MONO;
pat_config.NumberOfPatterns = 16;
DLPC34XX_WritePatternConfiguration(&pat_config);
///Read Splash Header
uint32_t splash_image_index = 0;
DLPC34XX_SplashScreenHeader_s splash_screen_header;
DLPC34XX_ReadSplashScreenHeader(splash_image_index, &splash_screen_header);
/// Write Input Image Size
uint16_t pixels_per_line = splash_screen_header.WidthInPixels;
uint16_t lines_per_frame = splash_screen_header.HeightInPixels;
if (DLPC34XX_WriteInputImageSize(pixels_per_line, lines_per_frame) != 0)
return -1;
/// Write Image Crop
uint16_t capture_start_pixel = 0;
uint16_t capture_start_line = 0;
if (DLPC34XX_WriteImageCrop(capture_start_pixel, capture_start_line, pixels_per_line, lines_per_frame) != 0)
return -1;
/// Write Display Size
uint16_t start_pixel = 0;
uint16_t start_line = 0;
if (DLPC34XX_WriteDisplaySize(start_pixel, start_line, pixels_per_line, lines_per_frame) != 0)
return -1;
/// Write Splash Screen Select
if (DLPC34XX_WriteSplashScreenSelect(splash_image_index) != 0)
return -1;
/// Write Operating Mode Select
if (DLPC34XX_WriteOperatingModeSelect(DLPC34XX_OM_SENS_SPLASH_PATTERN) != 0)
return -1;
/// Write Spalsh Screen Execute
if (DLPC34XX_WriteSplashScreenExecute() != 0)
return -1;
/// Write Image Freeze
if (DLPC34XX_WriteImageFreeze(false) != 0)
return -1;
/// Read Operating Mode Select
DLPC34XX_OperatingMode_e operating_mode;
if (DLPC34XX_ReadOperatingModeSelect(&operating_mode) != 0)
return -1;
CYPRESS_I2C_RelinquishI2CBusAccess();
return 0;
}

Thank you in advance for the support. 

Best regards,

Jonathan

  • Jonathan,

    Based on the summary above, it sounds like the cameras are not triggering. Is that correct?

    If so, you should probably check that the interface between the DLP chipset and the camera is good. Have you verified that the trigger out signal is actually appearing with a scope? If so, can you confirm whether the camera is actually receiving said signal? If both are true, then you may want to verify whether the camera is properly configured to trigger on said trigger signal.

    Regards,

    Philippe

  • Hi Philippe,

    Thank you for your response. I got the feedback from our customer and here it is. 

    "Please note that everything works fine when we use DLP EVM GUI in our setup and the cameras capture as expected. The problem is when we write a C++ code to generate the exact same commands that are shown in the "Command Log" tab of the GUI (see attached picture).In this case, the cameras do not capture properly. We debugged our setup and it looks like the cameras receive the commands generated by each C++ API call properly. We suspect that the commands that are shown in the "Command Log" are not complete and there are some commands that the GUI sends for capturing that does not show up in the Command Log tab. So maybe something that might help us is the answer to this questions: How can we replicate the exact behavior of the GUI using a C++ code?"

    Best regards,

    Jonathan

  • Jonathan,

    Thanks for the feedback. Was the team able to sniff the I2C bus to see the transactions taking place (outside of just looking at the command log)? This may indicate what extra functionality is taking place.

    I will also follow up with the team to see if they can provide insight directly.

    Regards,

    Philippe

  • Hi Philippe,

    Customer was not able to  sniff the I2C bus to see what are the exact commands that sent. Kindly guide us here with the specific tool that we can use to sniff the I2C bus? Thank you.

    Best regards,

    Jonathan

  • Jonathan,

    This depends on what you have available. The easiest tool to use is something like a digital logic analyzer (there are many brands available on the market). Usually, these kinds of tools have accompanying software that lets you decode the digital signal using a known protocol (in this case I2C) so that you can have a readable log of what commands are being sent.

    Regards,

    Philippe