|
|
@ -322,8 +322,6 @@ void MainWindow::construct_reg_table() { // |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "record_sig_gen_ttlin_trigger_sig_source", reg::record_sig_gen_ttlin_trigger_sig_source, 0, kreg_val_type_decimal); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "record_sig_gen_ttlin_trigger_level", reg::record_sig_gen_ttlin_trigger_level, 0, kreg_val_type_decimal); |
|
|
|
|
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "record_sig_gen_exposure_time", reg::record_sig_gen_exposure_time, 0, kreg_val_type_decimal); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "record_sig_gen_exposure_offset_time", reg::record_sig_gen_exposure_offset_time, 0, kreg_val_type_decimal); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "record_sig_gen_manual_ctrl", reg::record_sig_gen_manual_ctrl, 0, kreg_val_type_decimal); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "record_sig_gen_timecode_snapshot0", reg::record_sig_gen_timecode_snapshot0, 0, kreg_val_type_decimal); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "record_sig_gen_timecode_snapshot1", reg::record_sig_gen_timecode_snapshot1, 0, kreg_val_type_decimal); |
|
|
@ -331,6 +329,11 @@ void MainWindow::construct_reg_table() { // |
|
|
|
|
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "camera_sync_module", reg::camera_sync_module, 0, kreg_val_type_hex); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "camera_sync_pulse_mode_valid_len", reg::camera_sync_pulse_mode_valid_len, 0, kreg_val_type_decimal); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "delayer_module", reg::delayer_module, 0, kreg_val_type_hex); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "delayer_delay_sig_index", reg::delayer_delay_sig_index, 0, kreg_val_type_decimal); |
|
|
|
push_reg(ui->gridLayoutWidget, regoff++, "delayer_delay_us", reg::delayer_delay_us, 0, kreg_val_type_decimal); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
auto qrect = ui->gridLayoutWidget->geometry(); |
|
|
|
qrect.setHeight(31 * regoff - 1); |
|
|
@ -381,6 +384,9 @@ void MainWindow::UI_TTLPageConstruct() { |
|
|
|
list.push_back(QString::fromStdString(SignalType2Str(SIGNAL_SYS_TIMECODE_FREQ_OUTPUT))); |
|
|
|
list.push_back(QString::fromStdString(SignalType2Str(SIGNAL_BUSINESS_RECORD_SIG))); |
|
|
|
list.push_back(QString::fromStdString(SignalType2Str(SIGNAL_BUSINESS_RECORD_EXPOSURE_SIG))); |
|
|
|
list.push_back(QString::fromStdString(SignalType2Str(SIGNAL_BUSINESS_RECORD_EN_RSING_EDGE))); |
|
|
|
list.push_back(QString::fromStdString(SignalType2Str(SIGNAL_BUSINESS_RECORD_EN_FALLING_EDGE))); |
|
|
|
list.push_back(QString::fromStdString(SignalType2Str(SIGNAL_BUSINESS_RECORD_EN_EDGE))); |
|
|
|
|
|
|
|
ui->TTLOutputModule_SrcSigType_1->clear(); |
|
|
|
ui->TTLOutputModule_SrcSigType_1->addItems(list); |
|
|
@ -393,6 +399,26 @@ void MainWindow::UI_TTLPageConstruct() { |
|
|
|
|
|
|
|
ui->TTLOutputModule_SrcSigType_4->clear(); |
|
|
|
ui->TTLOutputModule_SrcSigType_4->addItems(list); |
|
|
|
|
|
|
|
ui->TTLOutputModule_TriggerEdge_1->clear(); |
|
|
|
ui->TTLOutputModule_TriggerEdge_1->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_RISING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_1->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_FALLING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_1->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_BOTH))); |
|
|
|
|
|
|
|
ui->TTLOutputModule_TriggerEdge_2->clear(); |
|
|
|
ui->TTLOutputModule_TriggerEdge_2->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_RISING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_2->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_FALLING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_2->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_BOTH))); |
|
|
|
|
|
|
|
ui->TTLOutputModule_TriggerEdge_3->clear(); |
|
|
|
ui->TTLOutputModule_TriggerEdge_3->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_RISING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_3->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_FALLING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_3->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_BOTH))); |
|
|
|
|
|
|
|
ui->TTLOutputModule_TriggerEdge_4->clear(); |
|
|
|
ui->TTLOutputModule_TriggerEdge_4->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_RISING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_4->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_FALLING))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_4->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_BOTH))); |
|
|
|
} |
|
|
|
void MainWindow::UI_GenlockPageConstruct() { |
|
|
|
//
|
|
|
@ -418,6 +444,11 @@ void MainWindow::UI_SysClockPageConstruct() { |
|
|
|
ui->SysClock_Src->addItem(QString::fromStdString(SignalType2Str(SIGNAL_INTERNAL_CLOCK_SIG))); |
|
|
|
ui->SysClock_Src->addItem(QString::fromStdString(SignalType2Str(SIGNAL_SYS_GENLOCK_OUTPUT))); |
|
|
|
ui->SysClock_Src->addItem(QString::fromStdString(SignalType2Str(SIGNAL_SYS_TIMECODE_FREQ_OUTPUT))); |
|
|
|
|
|
|
|
ui->SysClock_TriggerEdge->clear(); |
|
|
|
ui->SysClock_TriggerEdge->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_RISING))); |
|
|
|
ui->SysClock_TriggerEdge->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_FALLING))); |
|
|
|
ui->SysClock_TriggerEdge->addItem(QString::fromStdString(TriggerEdge2Str(TRIGGER_EDGE_BOTH))); |
|
|
|
} |
|
|
|
void MainWindow::UI_RecordSigGenConstruct() { |
|
|
|
ui->RecordSigGenerator_ContrlMode->clear(); |
|
|
@ -644,6 +675,9 @@ void MainWindow::on_tabWidget_currentChanged(int index) { |
|
|
|
} |
|
|
|
|
|
|
|
void MainWindow::on_TTLPage_Read_clicked() { |
|
|
|
/*******************************************************************************
|
|
|
|
* TTL输入页面 * |
|
|
|
*******************************************************************************/ |
|
|
|
{ |
|
|
|
float freq1 = 0; |
|
|
|
float freq2 = 0; |
|
|
@ -662,64 +696,110 @@ void MainWindow::on_TTLPage_Read_clicked() { |
|
|
|
ui->TTLinModule_ttl_freq_4->setText(QString::number(freq4, 'f', 2)); |
|
|
|
} |
|
|
|
|
|
|
|
/*******************************************************************************
|
|
|
|
* TTL输出组件 * |
|
|
|
*******************************************************************************/ |
|
|
|
|
|
|
|
SignalType_t source; |
|
|
|
TriggerEdge_t edge; |
|
|
|
uint32_t div; |
|
|
|
uint32_t multi; |
|
|
|
|
|
|
|
uint32_t PluseWidth; |
|
|
|
uint32_t OffsetTime; |
|
|
|
uint32_t outPolarity; |
|
|
|
|
|
|
|
float infreq; |
|
|
|
float outfreq; |
|
|
|
|
|
|
|
{ |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_getSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_getFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_getFreqMultiplication(multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_readInFreq(infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_readOutFreq(outfreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getSrcSigType(1, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getTriggerEdge(1, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqDivision(1, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqMultiplication(1, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPluseWidth(1, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getOffsetTime(1, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPolarity(1, outPolarity)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readInFreq(1, infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readOutFreq(1, outfreq)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_SrcSigType_1->setCurrentText(QString::fromStdString(SignalType2Str(source))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_1->setCurrentText(QString::fromStdString(TriggerEdge2Str(edge))); |
|
|
|
ui->TTLOutputModule_FreqDivision_1->setText(QString::number(div)); |
|
|
|
ui->TTLOutputModule_FreqMultiplication_1->setText(QString::number(multi)); |
|
|
|
ui->TTLOutputModule_PluseWidth_1->setText(QString::number(PluseWidth)); |
|
|
|
ui->TTLOutputModule_OffsetTime_1->setText(QString::number(OffsetTime)); |
|
|
|
ui->TTLOutputModule_Polarity_1->setText(QString::number(outPolarity)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_InFreq_1->setText(QString::number(infreq, 'f', 2)); |
|
|
|
ui->TTLOutputModule_OutFreq_1->setText(QString::number(outfreq, 'f', 2)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_getSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_getFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_getFreqMultiplication(multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_readInFreq(infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_readOutFreq(outfreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getSrcSigType(2, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getTriggerEdge(2, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqDivision(2, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqMultiplication(2, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPluseWidth(2, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getOffsetTime(2, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPolarity(2, outPolarity)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readInFreq(2, infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readOutFreq(2, outfreq)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_SrcSigType_2->setCurrentText(QString::fromStdString(SignalType2Str(source))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_2->setCurrentText(QString::fromStdString(TriggerEdge2Str(edge))); |
|
|
|
ui->TTLOutputModule_FreqDivision_2->setText(QString::number(div)); |
|
|
|
ui->TTLOutputModule_FreqMultiplication_2->setText(QString::number(multi)); |
|
|
|
ui->TTLOutputModule_PluseWidth_2->setText(QString::number(PluseWidth)); |
|
|
|
ui->TTLOutputModule_OffsetTime_2->setText(QString::number(OffsetTime)); |
|
|
|
ui->TTLOutputModule_Polarity_2->setText(QString::number(outPolarity)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_InFreq_2->setText(QString::number(infreq, 'f', 2)); |
|
|
|
ui->TTLOutputModule_OutFreq_2->setText(QString::number(outfreq, 'f', 2)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_getSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_getFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_getFreqMultiplication(multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_readInFreq(infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_readOutFreq(outfreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getSrcSigType(3, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getTriggerEdge(3, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqDivision(3, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqMultiplication(3, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPluseWidth(3, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getOffsetTime(3, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPolarity(3, outPolarity)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readInFreq(3, infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readOutFreq(3, outfreq)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_SrcSigType_3->setCurrentText(QString::fromStdString(SignalType2Str(source))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_3->setCurrentText(QString::fromStdString(TriggerEdge2Str(edge))); |
|
|
|
ui->TTLOutputModule_FreqDivision_3->setText(QString::number(div)); |
|
|
|
ui->TTLOutputModule_FreqMultiplication_3->setText(QString::number(multi)); |
|
|
|
ui->TTLOutputModule_PluseWidth_3->setText(QString::number(PluseWidth)); |
|
|
|
ui->TTLOutputModule_OffsetTime_3->setText(QString::number(OffsetTime)); |
|
|
|
ui->TTLOutputModule_Polarity_3->setText(QString::number(outPolarity)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_InFreq_3->setText(QString::number(infreq, 'f', 2)); |
|
|
|
ui->TTLOutputModule_OutFreq_3->setText(QString::number(outfreq, 'f', 2)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_getSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_getFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_getFreqMultiplication(multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_readInFreq(infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_readOutFreq(outfreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getSrcSigType(4, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getTriggerEdge(4, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqDivision(4, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getFreqMultiplication(4, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPluseWidth(4, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getOffsetTime(4, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_getPolarity(4, outPolarity)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readInFreq(4, infreq)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_readOutFreq(4, outfreq)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_SrcSigType_4->setCurrentText(QString::fromStdString(SignalType2Str(source))); |
|
|
|
ui->TTLOutputModule_TriggerEdge_4->setCurrentText(QString::fromStdString(TriggerEdge2Str(edge))); |
|
|
|
ui->TTLOutputModule_FreqDivision_4->setText(QString::number(div)); |
|
|
|
ui->TTLOutputModule_FreqMultiplication_4->setText(QString::number(multi)); |
|
|
|
ui->TTLOutputModule_PluseWidth_4->setText(QString::number(PluseWidth)); |
|
|
|
ui->TTLOutputModule_OffsetTime_4->setText(QString::number(OffsetTime)); |
|
|
|
ui->TTLOutputModule_Polarity_4->setText(QString::number(outPolarity)); |
|
|
|
|
|
|
|
ui->TTLOutputModule_InFreq_4->setText(QString::number(infreq, 'f', 2)); |
|
|
|
ui->TTLOutputModule_OutFreq_4->setText(QString::number(outfreq, 'f', 2)); |
|
|
|
} |
|
|
@ -727,42 +807,73 @@ void MainWindow::on_TTLPage_Read_clicked() { |
|
|
|
void MainWindow::on_TTLPage_Write_clicked() { |
|
|
|
{ |
|
|
|
auto source = Str2SignalType(ui->TTLOutputModule_SrcSigType_1->currentText().toStdString()); |
|
|
|
auto edge = Str2TriggerEdge(ui->TTLOutputModule_TriggerEdge_1->currentText().toStdString()); |
|
|
|
auto div = ui->TTLOutputModule_FreqDivision_1->text().toUInt(); |
|
|
|
auto multi = ui->TTLOutputModule_FreqMultiplication_1->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_setSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_setFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule1_setFreqMultiplication(multi)); |
|
|
|
auto PluseWidth = ui->TTLOutputModule_PluseWidth_1->text().toUInt(); |
|
|
|
auto OffsetTime = ui->TTLOutputModule_OffsetTime_1->text().toUInt(); |
|
|
|
auto outPolarity = ui->TTLOutputModule_Polarity_1->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setSrcSigType(1, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setTriggerEdge(1, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqDivision(1, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqMultiplication(1, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPluseWidth(1, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setOffsetTime(1, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPolarity(1, outPolarity)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
auto source = Str2SignalType(ui->TTLOutputModule_SrcSigType_2->currentText().toStdString()); |
|
|
|
auto edge = Str2TriggerEdge(ui->TTLOutputModule_TriggerEdge_2->currentText().toStdString()); |
|
|
|
auto div = ui->TTLOutputModule_FreqDivision_2->text().toUInt(); |
|
|
|
auto multi = ui->TTLOutputModule_FreqMultiplication_2->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_setSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_setFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule2_setFreqMultiplication(multi)); |
|
|
|
auto PluseWidth = ui->TTLOutputModule_PluseWidth_2->text().toUInt(); |
|
|
|
auto OffsetTime = ui->TTLOutputModule_OffsetTime_2->text().toUInt(); |
|
|
|
auto outPolarity = ui->TTLOutputModule_Polarity_2->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setSrcSigType(2, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setTriggerEdge(2, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqDivision(2, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqMultiplication(2, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPluseWidth(2, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setOffsetTime(2, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPolarity(2, outPolarity)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
auto source = Str2SignalType(ui->TTLOutputModule_SrcSigType_3->currentText().toStdString()); |
|
|
|
auto edge = Str2TriggerEdge(ui->TTLOutputModule_TriggerEdge_3->currentText().toStdString()); |
|
|
|
auto div = ui->TTLOutputModule_FreqDivision_3->text().toUInt(); |
|
|
|
auto multi = ui->TTLOutputModule_FreqMultiplication_3->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_setSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_setFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule3_setFreqMultiplication(multi)); |
|
|
|
auto PluseWidth = ui->TTLOutputModule_PluseWidth_3->text().toUInt(); |
|
|
|
auto OffsetTime = ui->TTLOutputModule_OffsetTime_3->text().toUInt(); |
|
|
|
auto outPolarity = ui->TTLOutputModule_Polarity_3->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setSrcSigType(3, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setTriggerEdge(3, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqDivision(3, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqMultiplication(3, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPluseWidth(3, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setOffsetTime(3, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPolarity(3, outPolarity)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
auto source = Str2SignalType(ui->TTLOutputModule_SrcSigType_4->currentText().toStdString()); |
|
|
|
auto edge = Str2TriggerEdge(ui->TTLOutputModule_TriggerEdge_4->currentText().toStdString()); |
|
|
|
auto div = ui->TTLOutputModule_FreqDivision_4->text().toUInt(); |
|
|
|
auto multi = ui->TTLOutputModule_FreqMultiplication_4->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_setSrcSigType(source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_setFreqDivision(div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule4_setFreqMultiplication(multi)); |
|
|
|
auto PluseWidth = ui->TTLOutputModule_PluseWidth_4->text().toUInt(); |
|
|
|
auto OffsetTime = ui->TTLOutputModule_OffsetTime_4->text().toUInt(); |
|
|
|
auto outPolarity = ui->TTLOutputModule_Polarity_4->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setSrcSigType(4, source)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setTriggerEdge(4, edge)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqDivision(4, div)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setFreqMultiplication(4, multi)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPluseWidth(4, PluseWidth)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setOffsetTime(4, OffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->TTLOutputModule_setPolarity(4, outPolarity)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
@ -772,6 +883,11 @@ void MainWindow::on_GenlockPage_Read_clicked() { |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->InternalGenlock_getFormat(format)); |
|
|
|
ui->InternalGenlock_Format->setCurrentText(QString::fromStdString(GenlockFormatToStr(format))); |
|
|
|
} |
|
|
|
{ |
|
|
|
float freq; |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->InternalGenlock_readFreq(freq)); |
|
|
|
ui->InternalGenlock_Freq->setText(QString::number(freq, 'f', 2)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
float freq; |
|
|
@ -811,6 +927,12 @@ void MainWindow::on_SysClockPage_Read_clicked() { |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
float freq; |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->InternalClock_readOutFreq(freq)); |
|
|
|
ui->InternalClock_OutFreq->setText(QString::number(freq, 'f', 2)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
SignalType_t src; |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->SysClock_getSrc(src)); |
|
|
|
ui->SysClock_Src->setCurrentText(QString::fromStdString(SignalType2Str(src))); |
|
|
@ -839,6 +961,12 @@ void MainWindow::on_SysClockPage_Read_clicked() { |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->SysClock_readOutSigFreq(freq)); |
|
|
|
ui->SysClock_OutSigFreq->setText(QString::number(freq, 'f', 2)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
TriggerEdge_t edge; |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->SysClock_getTriggerEdge(edge)); |
|
|
|
ui->SysClock_TriggerEdge->setCurrentText(QString::fromStdString(TriggerEdge2Str(edge))); |
|
|
|
} |
|
|
|
} |
|
|
|
void MainWindow::on_SysClockPage_Wirte_clicked() { |
|
|
|
{ |
|
|
@ -860,6 +988,11 @@ void MainWindow::on_SysClockPage_Wirte_clicked() { |
|
|
|
auto multi = ui->SysClock_FreqMultiplication->text().toUInt(); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->SysClock_setFreqMultiplication(multi)); |
|
|
|
} |
|
|
|
|
|
|
|
{ |
|
|
|
TriggerEdge_t edge = Str2TriggerEdge(ui->SysClock_TriggerEdge->currentText().toStdString()); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->SysClock_setTriggerEdge(edge)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
void MainWindow::on_RecordSigGen_Read_clicked() { |
|
|
@ -881,8 +1014,6 @@ void MainWindow::on_RecordSigGen_Read_clicked() { |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_getTimecodeCtrlFlag(autoStart, autoStop)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_getExternalTTLTriggerSrc(ttlPortNum)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_getExternalTTLTriggerPolarity(polarity)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_getRecordExposureTime(exposureTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_getRecordExposureOffsetTime(exposureOffsetTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_getRecordState(state)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_readTimecodeSnapshot(timecode_snapshot)); |
|
|
|
|
|
|
@ -893,8 +1024,8 @@ void MainWindow::on_RecordSigGen_Read_clicked() { |
|
|
|
ui->RecordSigGenerator_TimecodeCtrlFlag1->setChecked(autoStop); |
|
|
|
ui->RecordSigGenerator_ExternalTTLTriggerSrc->setCurrentText(QString::fromStdString(InputInterface2Str(ttlPortNum))); |
|
|
|
ui->RecordSigGenerator_ExternalTTLTriggerPolarity->setText(QString::number(polarity)); |
|
|
|
ui->RecordSigGenerator_RecordExposureTime->setText(QString::number(exposureTime)); |
|
|
|
ui->RecordSigGenerator_RecordExposureOffsetTime->setText(QString::number(exposureOffsetTime)); |
|
|
|
// ui->RecordSigGenerator_RecordExposureTime->setText(QString::number(exposureTime));
|
|
|
|
// ui->RecordSigGenerator_RecordExposureOffsetTime->setText(QString::number(exposureOffsetTime));
|
|
|
|
ui->RecordSigGenerator_RecordState->setText(QString::number(state)); |
|
|
|
ui->RecordSigGenerator_TimecodeSnapshot->setText(QString(XsyncTimecodeToStr(timecode_snapshot).c_str())); |
|
|
|
} |
|
|
@ -906,8 +1037,8 @@ void MainWindow::on_RecordSigGen_Write_clicked() { |
|
|
|
uint32_t autoStop = ui->RecordSigGenerator_TimecodeCtrlFlag1->isChecked(); |
|
|
|
InputInterface_t ttlPortNum = Str2InputInterface(ui->RecordSigGenerator_ExternalTTLTriggerSrc->currentText().toStdString()); |
|
|
|
uint32_t polarity = ui->RecordSigGenerator_ExternalTTLTriggerPolarity->text().toUInt(); |
|
|
|
uint32_t exposureTime = ui->RecordSigGenerator_RecordExposureTime->text().toUInt(); |
|
|
|
uint32_t exposureOffsetTime = ui->RecordSigGenerator_RecordExposureOffsetTime->text().toUInt(); |
|
|
|
// uint32_t exposureTime = ui->RecordSigGenerator_RecordExposureTime->text().toUInt();
|
|
|
|
// uint32_t exposureOffsetTime = ui->RecordSigGenerator_RecordExposureOffsetTime->text().toUInt();
|
|
|
|
|
|
|
|
// RecordSigGenerator_readTimecodeSnapshot
|
|
|
|
|
|
|
@ -917,8 +1048,8 @@ void MainWindow::on_RecordSigGen_Write_clicked() { |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_setTimecodeCtrlFlag(autoStart, autoStop)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_setExternalTTLTriggerSrc(ttlPortNum)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_setExternalTTLTriggerPolarity(polarity)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_setRecordExposureTime(exposureTime)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_setRecordExposureOffsetTime(exposureOffsetTime)); |
|
|
|
// DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_setRecordExposureTime(exposureTime));
|
|
|
|
// DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_setRecordExposureOffsetTime(exposureOffsetTime));
|
|
|
|
} |
|
|
|
void MainWindow::on_RecordSigGenerator_manualStart_clicked() { DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_manualStart()); } |
|
|
|
void MainWindow::on_RecordSigGenerator_manualStop_clicked() { DO_XSYNC_FUNC(XsyncIns()->RecordSigGenerator_manualStop()); } |
|
|
@ -960,3 +1091,23 @@ void MainWindow::on_Reboot_clicked() { DO_XSYNC_FUNC(XsyncIns()->reboot()); } |
|
|
|
|
|
|
|
void MainWindow::on_InternalSigSrouce_start_clicked() { DO_XSYNC_FUNC(XsyncIns()->InternalSigSrouce_start()); } |
|
|
|
void MainWindow::on_InternalSigSrouce_stop_clicked() { DO_XSYNC_FUNC(XsyncIns()->InternalSigSrouce_stop()); } |
|
|
|
|
|
|
|
void MainWindow::on_DelayContrl_Read_clicked() { |
|
|
|
uint32_t DelayContrl_InputDelay; |
|
|
|
uint32_t DelayContrl_OutputDelay; |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->DelayContrl_getInputDelay(DelayContrl_InputDelay)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->DelayContrl_getOutputDelay(DelayContrl_OutputDelay)); |
|
|
|
|
|
|
|
ui->DelayContrl_InputDelay->setText(QString::number(DelayContrl_InputDelay)); |
|
|
|
ui->DelayContrl_OutputDelay->setText(QString::number(DelayContrl_OutputDelay)); |
|
|
|
} |
|
|
|
|
|
|
|
void MainWindow::on_DelayContrl_Update_clicked() { |
|
|
|
uint32_t DelayContrl_InputDelay = ui->DelayContrl_InputDelay->text().toUInt(); |
|
|
|
uint32_t DelayContrl_OutputDelay = ui->DelayContrl_OutputDelay->text().toUInt(); |
|
|
|
|
|
|
|
DO_XSYNC_FUNC(XsyncIns()->DelayContrl_setInputDelay(DelayContrl_InputDelay)); |
|
|
|
DO_XSYNC_FUNC(XsyncIns()->DelayContrl_setOutputDelay(DelayContrl_OutputDelay)); |
|
|
|
|
|
|
|
} |