Skip to content

Commit

Permalink
Added Hardware timestamp support
Browse files Browse the repository at this point in the history
  • Loading branch information
mensinda committed Aug 20, 2017
1 parent ab03a7e commit 134a9d4
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 1 deletion.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ See INSTALL.md for instructions

## Features

### Hardware timestamps

Hardware timestamps (if supported) can offer more accurate timestamps.

To enable hardware timestamps check the box in Settings --> Backend --> General --> Enable Hardware timestamps.

### Pre SoC Cycles

In some scenarios debugging the network traffic that came before
Expand Down
2 changes: 2 additions & 0 deletions libEPLViz/src/settings/SettingsProfileItem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ QString SettingsProfileItem::getName() { return name; }

bool SettingsProfileItem::writeCfg(AbstractWriter *writer) {
writer->setValue("EPL_DC/xddDir", cfg.backConf.xddDir.c_str());
writer->setValue("EPL_DC/enableHardwareTimestamps", cfg.backConf.enableHardwareTimestamps);
writer->setValue("pauseWhilePlayingFile", cfg.pauseWhilePlayingFile);
writer->setValue("immidiateCycleChange", cfg.immidiateCycleChange);
writer->setValue("invertTimeLineZoom", cfg.invertTimeLineZoom);
Expand Down Expand Up @@ -141,6 +142,7 @@ bool SettingsProfileItem::writeCfg(AbstractWriter *writer) {

bool SettingsProfileItem::readCfg(AbstractWriter *writer) {
cfg.backConf.xddDir = writer->value("EPL_DC/xddDir").toString().toStdString();
cfg.backConf.enableHardwareTimestamps = writer->value("EPL_DC/enableHardwareTimestamps").toBool();
cfg.pauseWhilePlayingFile = writer->value("pauseWhilePlayingFile").toBool();
cfg.immidiateCycleChange = writer->value("immidiateCycleChange").toBool();
cfg.invertTimeLineZoom = writer->value("invertTimeLineZoom").toBool();
Expand Down
2 changes: 2 additions & 0 deletions libEPLViz/src/settings/SettingsWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ SettingsWindow::~SettingsWindow() {
void SettingsWindow::updateView(bool updateNodes) {
SettingsProfileItem *prof = profiles[currentProfile].get();
ui->G_XDDDir->setText(prof->cfg.backConf.xddDir.c_str());
ui->G_EnableHWTs->setCheckState(prof->cfg.backConf.enableHardwareTimestamps ? Qt::Checked : Qt::Unchecked);
ui->G_PausePlay->setCheckState(prof->cfg.pauseWhilePlayingFile ? Qt::Checked : Qt::Unchecked);
ui->TL_ChancheCycleImm->setCheckState(prof->cfg.immidiateCycleChange ? Qt::Checked : Qt::Unchecked);
ui->TL_Invert->setCheckState(prof->cfg.invertTimeLineZoom ? Qt::Checked : Qt::Unchecked);
Expand Down Expand Up @@ -237,6 +238,7 @@ void SettingsWindow::updateView(bool updateNodes) {
void SettingsWindow::saveIntoProfiles() {
SettingsProfileItem *prof = profiles[currentProfile].get();
prof->cfg.backConf.xddDir = ui->G_XDDDir->text().toStdString();
prof->cfg.backConf.enableHardwareTimestamps = ui->G_EnableHWTs->checkState() == Qt::Checked;
prof->cfg.pauseWhilePlayingFile = ui->G_PausePlay->checkState() == Qt::Checked;
prof->cfg.immidiateCycleChange = ui->TL_ChancheCycleImm->checkState() == Qt::Checked;
prof->cfg.invertTimeLineZoom = ui->TL_Invert->checkState() == Qt::Checked;
Expand Down
26 changes: 26 additions & 0 deletions libEPLViz/ui/settingswindow.ui
Original file line number Diff line number Diff line change
Expand Up @@ -3027,6 +3027,32 @@
</layout>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_49">
<property name="text">
<string>Enable Hardware timestamps in live capture</string>
</property>
</widget>
</item>
<item row="2" column="2">
<widget class="QWidget" name="widget_5" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_24">
<item>
<widget class="QCheckBox" name="G_EnableHWTs">
<property name="text">
<string/>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
</item>
Expand Down

0 comments on commit 134a9d4

Please sign in to comment.