Skip to content

Commit 7f8e0b5

Browse files
committed
TektronixOscilloscope: finished initial doxygen pass
1 parent 7fae672 commit 7f8e0b5

File tree

2 files changed

+78
-8
lines changed

2 files changed

+78
-8
lines changed

scopehal/TektronixOscilloscope.cpp

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2687,7 +2687,11 @@ void TektronixOscilloscope::PullTrigger()
26872687
}
26882688

26892689
/**
2690-
@brief Parses a trigger level message
2690+
@brief Determine the current trigger level
2691+
2692+
@param chan The channel selected as the trigger source
2693+
2694+
@return The current trigger level, in volts
26912695
*/
26922696
float TektronixOscilloscope::ReadTriggerLevelMSO56(OscilloscopeChannel* chan)
26932697
{
@@ -2983,7 +2987,7 @@ void TektronixOscilloscope::PullRuntTrigger()
29832987
}
29842988

29852989
/**
2986-
@brief Reads settings for a runt trigger from the instrument
2990+
@brief Reads settings for a slew rate trigger from the instrument
29872991
*/
29882992
void TektronixOscilloscope::PullSlewRateTrigger()
29892993
{
@@ -3144,6 +3148,11 @@ void TektronixOscilloscope::PushTrigger()
31443148
LogWarning("Unknown trigger type (not an edge)\n");
31453149
}
31463150

3151+
/**
3152+
@brief Push the current trigger voltage level to hardware
3153+
3154+
@param trig The trigger to push
3155+
*/
31473156
void TektronixOscilloscope::SetTriggerLevelMSO56(Trigger* trig)
31483157
{
31493158
auto chan = trig->GetInput(0).m_channel;
@@ -3159,6 +3168,8 @@ void TektronixOscilloscope::SetTriggerLevelMSO56(Trigger* trig)
31593168

31603169
/**
31613170
@brief Pushes settings for an edge trigger to the instrument
3171+
3172+
@param trig The trigger to push
31623173
*/
31633174
void TektronixOscilloscope::PushEdgeTrigger(EdgeTrigger* trig)
31643175
{
@@ -3202,6 +3213,11 @@ void TektronixOscilloscope::PushEdgeTrigger(EdgeTrigger* trig)
32023213
}
32033214
}
32043215

3216+
/**
3217+
@brief Pushes settings for a pulse width trigger to the instrument
3218+
3219+
@param trig The trigger to push
3220+
*/
32053221
void TektronixOscilloscope::PushPulseWidthTrigger(PulseWidthTrigger* trig)
32063222
{
32073223
switch(m_family)
@@ -3263,6 +3279,8 @@ void TektronixOscilloscope::PushPulseWidthTrigger(PulseWidthTrigger* trig)
32633279

32643280
/**
32653281
@brief Pushes settings for a dropout trigger to the instrument
3282+
3283+
@param trig The trigger to push
32663284
*/
32673285
void TektronixOscilloscope::PushDropoutTrigger(DropoutTrigger* trig)
32683286
{
@@ -3306,6 +3324,8 @@ void TektronixOscilloscope::PushDropoutTrigger(DropoutTrigger* trig)
33063324

33073325
/**
33083326
@brief Pushes settings for a runt trigger to the instrument
3327+
3328+
@param trig The trigger to push
33093329
*/
33103330
void TektronixOscilloscope::PushRuntTrigger(RuntTrigger* trig)
33113331
{
@@ -3377,7 +3397,9 @@ void TektronixOscilloscope::PushRuntTrigger(RuntTrigger* trig)
33773397
}
33783398

33793399
/**
3380-
@brief Pushes settings for a runt trigger to the instrument
3400+
@brief Pushes settings for a slew rate trigger to the instrument
3401+
3402+
@param trig The trigger to push
33813403
*/
33823404
void TektronixOscilloscope::PushSlewRateTrigger(SlewRateTrigger* trig)
33833405
{
@@ -3445,7 +3467,9 @@ void TektronixOscilloscope::PushSlewRateTrigger(SlewRateTrigger* trig)
34453467
}
34463468

34473469
/**
3448-
@brief Pushes settings for a runt trigger to the instrument
3470+
@brief Pushes settings for a window trigger to the instrument
3471+
3472+
@param trig The trigger to push
34493473
*/
34503474
void TektronixOscilloscope::PushWindowTrigger(WindowTrigger* trig)
34513475
{

scopehal/TektronixOscilloscope.h

Lines changed: 50 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -355,10 +355,16 @@ class TektronixOscilloscope
355355
//The lane number for each flex channel
356356
std::map<OscilloscopeChannel*, size_t> m_flexChannelLanes;
357357

358+
///@brief Starting index for digital channels
358359
size_t m_digitalChannelBase;
360+
361+
///@brief Starting index for spectrum channels
359362
size_t m_spectrumChannelBase;
360363

364+
///@brief True if trigger is armed, false if idle
361365
bool m_triggerArmed;
366+
367+
///@brief True if trigger is single or forced, false if continuous
362368
bool m_triggerOneShot;
363369

364370
void PullEdgeTrigger();
@@ -377,10 +383,23 @@ class TektronixOscilloscope
377383
float ReadTriggerLevelMSO56(OscilloscopeChannel* chan);
378384
void SetTriggerLevelMSO56(Trigger* trig);
379385

380-
//Helpers for figuring out type of a channel by the index
386+
/**
387+
@brief Check if a channel is analog given the index
388+
389+
@param index Channel number
390+
391+
@return True if analog, false if spectrum or digital
392+
*/
381393
bool IsAnalog(size_t index)
382394
{ return index < m_analogChannelCount; }
383395

396+
/**
397+
@brief Check if a channel is digital given the index
398+
399+
@param index Channel number
400+
401+
@return True if digital, false if spectrum or analog
402+
*/
384403
bool IsDigital(size_t index)
385404
{
386405
if(index < m_digitalChannelBase)
@@ -390,6 +409,13 @@ class TektronixOscilloscope
390409
return true;
391410
}
392411

412+
/**
413+
@brief Check if a channel is spectrum given the index
414+
415+
@param index Channel number
416+
417+
@return True if spectrum, false if analog or digital
418+
*/
393419
bool IsSpectrum(size_t index)
394420
{
395421
if(index < m_spectrumChannelBase)
@@ -399,17 +425,23 @@ class TektronixOscilloscope
399425
return true;
400426
}
401427

402-
///Maximum bandwidth we support, in MHz
428+
///@brief Maximum bandwidth we support, in MHz
403429
unsigned int m_maxBandwidth;
404430

431+
///@brief Type of scope we're connected to
405432
enum Family
406433
{
434+
///@brief MSO5 series
407435
FAMILY_MSO5,
436+
437+
///@brief MSO6 series
408438
FAMILY_MSO6,
439+
440+
///@brief Other or unknown
409441
FAMILY_UNKNOWN
410442
} m_family;
411443

412-
//Installed software options
444+
///@brief True if we have the DVM option installed
413445
bool m_hasDVM;
414446

415447
/**
@@ -430,14 +462,28 @@ class TektronixOscilloscope
430462
bool IsEnableStateDirty(size_t chan);
431463
void FlushChannelEnableStates();
432464

433-
//Function generator state
465+
///@brief True if we have the AFG option installed
434466
bool m_hasAFG;
467+
468+
///@brief True if the AFG is currently outputting a waveform
435469
bool m_afgEnabled;
470+
471+
///@brief Amplitude of the AFG output, in volts
436472
float m_afgAmplitude;
473+
474+
///@brief DC offset of the AFG output, in volts
437475
float m_afgOffset;
476+
477+
///@brief Frequency of the AFG output, in Hz
438478
float m_afgFrequency;
479+
480+
///@brief Duty cycle of the AFG output (0-1)
439481
float m_afgDutyCycle;
482+
483+
///@brief Waveform the AFG is outputting
440484
FunctionGenerator::WaveShape m_afgShape;
485+
486+
///@brief Impedance selected for the AFG output
441487
FunctionGenerator::OutputImpedance m_afgImpedance;
442488

443489
public:

0 commit comments

Comments
 (0)