Skip to content
Snippets Groups Projects

Resolve L2SDP-437

Merged Pieter Donker requested to merge L2SDP-437 into master
2 files
+ 113
1
Compare changes
  • Side-by-side
  • Inline
Files
2
+ 7
1
@@ -53,7 +53,7 @@ TranslatorMap::TranslatorMap()
translatorMap->add_register("TR_fpga_mask_RW", "-", SD.n_fpgas, 1, "RW", REG_FORMAT_BOOLEAN);
translatorMap->add_register("TR_software_version_R", "-", 1, 1, "RO", REG_FORMAT_STRING);
translatorMap->add_register("TR_start_time_R", "-", 1, 1, "RO", REG_FORMAT_INT64);
// translatorMap->add_register("TR_tod_client_status_R", "-", 1, 1, "RO", REG_FORMAT_BOOLEAN); // TODO: PTP client is part of linux, can I get a status?
translatorMap->add_register("TR_tod_ptp_status_R", "-", 1, 1, "RO", REG_FORMAT_BOOLEAN); // TODO: PTP client is part of linux, can I get a status?
translatorMap->add_register("TR_tod_R", "-", 1, 2, "RO", REG_FORMAT_INT64);
translatorMap->add_register("TR_tod_pps_delta_R", "-", 1, 1, "RO", REG_FORMAT_DOUBLE);
translatorMap->add_register("TR_fpga_communication_error_R", "-", SD.n_fpgas, 1, "RO", REG_FORMAT_BOOLEAN);
@@ -151,6 +151,12 @@ bool TranslatorMap::translator(TermOutput& termout, const char cmd, const string
}
*ptr_out = pps_delta;
}
else if (addr == "TR_tod_ptp_status_R") {
bool ptp_status = true;
// TODO: get status from ptp deamon
bool *ptr_out = (bool *)termout.val;
*ptr_out = ptp_status;
}
else if (addr == "TR_start_time_R") {
uint32_t *ptr_out = (uint32_t *)termout.val;
*ptr_out = (uint32_t)SD.start_time;
Loading