DUNE-DAQ
DUNE Trigger and Data Acquisition software
|
I2C slave class to control SFP transceivers. More...
#include <I2CSFPNode.hpp>
Public Member Functions | |
I2CSFPSlave (const I2CMasterNode *i2c_master, uint8_t i2c_device_address) | |
virtual | ~I2CSFPSlave () |
void | sfp_reachable () const |
Check if SFP responds. | |
void | ddm_available () const |
Check if DDM is supported. | |
std::pair< double, double > | read_calibration_parameter_pair (uint32_t calib_parameter_id) const |
Read the raw SFP temperature. | |
double | read_temperature_raw () const |
Read the raw SFP temperature. | |
double | read_temperature () const |
Read the calibrated SFP temperature. | |
double | read_voltage_raw () const |
Read the raw SFP voltage. | |
double | read_voltage () const |
Read the calibrated SFP voltage. | |
double | read_rx_power_raw () const |
Read the raw SFP temperature. | |
double | read_rx_ower () const |
Read the raw SFP temperature. | |
double | read_tx_power_raw () const |
Read the raw SFP tx power. | |
double | read_tx_power () const |
Read the calibrated SFP tx power. | |
double | read_current_raw () const |
Read the raw SFP current. | |
double | read_current () const |
Read the calibrated SFP current. | |
std::string | read_vendor_name () const |
Read the vendor name. | |
std::string | read_vendor_part_number () const |
Read the vendor name. | |
std::string | read_serial_number () const |
Read the SFP serial number. | |
bool | read_ddm_support_bit () const |
Find out if SFP supports DDM. | |
bool | read_soft_tx_control_support_bit () const |
Find out if SFP supports soft tx laser disable. | |
bool | read_soft_tx_control_state () const |
Read the value of the soft tx disable control bit. | |
bool | read_tx_disable_pin_state () const |
Read the state of the tx disable control pin. | |
bool | read_i2c_reg_addressSwapBit () const |
Read whether the SFP has seperate I2C addresses, or if a special I2C address swap is required. True = address swap required. | |
void | switch_soft_tx_control_bit (bool turn_on) const |
Switch on or off the SFP tx laser via the soft control bit. | |
std::string | get_status (bool print_out=false) const |
Get SFP status. | |
![]() | |
virtual | ~I2CSlave () |
uint8_t | get_i2c_address () const |
uint8_t | read_i2c (uint32_t i2c_device_address, uint32_t i2c_reg_address) const |
comodity functions | |
uint8_t | read_i2c (uint32_t i2c_reg_address) const |
void | write_i2c (uint32_t i2c_device_address, uint32_t i2c_reg_address, uint8_t data, bool send_stop=true) const |
void | write_i2c (uint32_t i2c_reg_address, uint8_t data, bool send_stop=true) const |
std::vector< uint8_t > | read_i2cArray (uint32_t i2c_device_address, uint32_t i2c_reg_address, uint32_t number_of_words) const |
std::vector< uint8_t > | read_i2cArray (uint32_t i2c_reg_address, uint32_t number_of_words) const |
void | write_i2cArray (uint32_t i2c_device_address, uint32_t i2c_reg_address, std::vector< uint8_t > data, bool send_stop=true) const |
void | write_i2cArray (uint32_t i2c_reg_address, std::vector< uint8_t > data, bool send_stop=true) const |
std::vector< uint8_t > | read_i2cPrimitive (uint32_t number_of_bytes) const |
void | write_i2cPrimitive (const std::vector< uint8_t > &data, bool send_stop=true) const |
bool | ping () const |
std::string | get_master_id () const |
Protected Attributes | |
const std::vector< uint32_t > | m_calibration_parameter_start_addresses |
Get and fill SFP hardware data. | |
Additional Inherited Members | |
![]() | |
I2CSlave (const I2CMasterNode *i2c_master, uint8_t i2c_device_address) | |
I2C slave class to control SFP transceivers.
Definition at line 37 of file I2CSFPNode.hpp.
dunedaq::timing::I2CSFPSlave::I2CSFPSlave | ( | const I2CMasterNode * | i2c_master, |
uint8_t | i2c_device_address ) |
Definition at line 21 of file I2CSFPNode.cpp.
|
virtual |
Definition at line 28 of file I2CSFPNode.cpp.
void dunedaq::timing::I2CSFPSlave::ddm_available | ( | ) | const |
Check if DDM is supported.
Definition at line 43 of file I2CSFPNode.cpp.
std::string dunedaq::timing::I2CSFPSlave::get_status | ( | bool | print_out = false | ) | const |
Get SFP status.
Definition at line 327 of file I2CSFPNode.cpp.
std::pair< double, double > dunedaq::timing::I2CSFPSlave::read_calibration_parameter_pair | ( | uint32_t | calib_parameter_id | ) | const |
Read the raw SFP temperature.
Definition at line 57 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_current | ( | ) | const |
Read the calibrated SFP current.
Definition at line 190 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_current_raw | ( | ) | const |
Read the raw SFP current.
Definition at line 180 of file I2CSFPNode.cpp.
bool dunedaq::timing::I2CSFPSlave::read_ddm_support_bit | ( | ) | const |
Find out if SFP supports DDM.
Definition at line 245 of file I2CSFPNode.cpp.
bool dunedaq::timing::I2CSFPSlave::read_i2c_reg_addressSwapBit | ( | ) | const |
Read whether the SFP has seperate I2C addresses, or if a special I2C address swap is required. True = address swap required.
Definition at line 291 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_rx_ower | ( | ) | const |
Read the raw SFP temperature.
Definition at line 131 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_rx_power_raw | ( | ) | const |
Read the raw SFP temperature.
Definition at line 121 of file I2CSFPNode.cpp.
std::string dunedaq::timing::I2CSFPSlave::read_serial_number | ( | ) | const |
Read the SFP serial number.
Definition at line 230 of file I2CSFPNode.cpp.
bool dunedaq::timing::I2CSFPSlave::read_soft_tx_control_state | ( | ) | const |
Read the value of the soft tx disable control bit.
Definition at line 269 of file I2CSFPNode.cpp.
bool dunedaq::timing::I2CSFPSlave::read_soft_tx_control_support_bit | ( | ) | const |
Find out if SFP supports soft tx laser disable.
Definition at line 257 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_temperature | ( | ) | const |
Read the calibrated SFP temperature.
Definition at line 91 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_temperature_raw | ( | ) | const |
Read the raw SFP temperature.
Definition at line 78 of file I2CSFPNode.cpp.
bool dunedaq::timing::I2CSFPSlave::read_tx_disable_pin_state | ( | ) | const |
Read the state of the tx disable control pin.
Definition at line 280 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_tx_power | ( | ) | const |
Read the calibrated SFP tx power.
Definition at line 170 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_tx_power_raw | ( | ) | const |
Read the raw SFP tx power.
Definition at line 160 of file I2CSFPNode.cpp.
std::string dunedaq::timing::I2CSFPSlave::read_vendor_name | ( | ) | const |
Read the vendor name.
Definition at line 200 of file I2CSFPNode.cpp.
std::string dunedaq::timing::I2CSFPSlave::read_vendor_part_number | ( | ) | const |
Read the vendor name.
Definition at line 215 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_voltage | ( | ) | const |
Read the calibrated SFP voltage.
Definition at line 111 of file I2CSFPNode.cpp.
double dunedaq::timing::I2CSFPSlave::read_voltage_raw | ( | ) | const |
Read the raw SFP voltage.
Definition at line 101 of file I2CSFPNode.cpp.
void dunedaq::timing::I2CSFPSlave::sfp_reachable | ( | ) | const |
void dunedaq::timing::I2CSFPSlave::switch_soft_tx_control_bit | ( | bool | turn_on | ) | const |
Switch on or off the SFP tx laser via the soft control bit.
Definition at line 303 of file I2CSFPNode.cpp.
|
protected |
Get and fill SFP hardware data.
Definition at line 190 of file I2CSFPNode.hpp.