fix
This commit is contained in:
27
main.cpp
27
main.cpp
@ -2157,6 +2157,8 @@ int run(const Config& cfg) {
|
||||
uint64_t packet_clock_count = 0;
|
||||
uint64_t packet_di2_high_clocks = 0;
|
||||
uint64_t packet_di2_low_clocks = 0;
|
||||
uint64_t packet_di8_high_clocks = 0;
|
||||
uint64_t packet_di8_low_clocks = 0;
|
||||
|
||||
bool capture_started = false;
|
||||
bool stop_loop_requested = false;
|
||||
@ -2464,6 +2466,8 @@ int run(const Config& cfg) {
|
||||
packet_clock_count = 0;
|
||||
packet_di2_high_clocks = 0;
|
||||
packet_di2_low_clocks = 0;
|
||||
packet_di8_high_clocks = 0;
|
||||
packet_di8_low_clocks = 0;
|
||||
if (!fast_tty_avg_stream_mode) {
|
||||
current_packet.reset(target_frames, cfg.channel_count);
|
||||
}
|
||||
@ -2531,8 +2535,12 @@ int run(const Config& cfg) {
|
||||
<< ", close_reason=" << packet_close_reason_to_string(reason)
|
||||
<< ", clocks=" << packet_clock_count
|
||||
<< ", di2_high_clocks=" << packet_di2_high_clocks
|
||||
<< ", di2_low_clocks=" << packet_di2_low_clocks
|
||||
<< ", avg_steps=" << packet_avg_steps
|
||||
<< ", di2_low_clocks=" << packet_di2_low_clocks;
|
||||
if (cfg.do8_freq_ref) {
|
||||
std::cout << ", di8_high_clocks=" << packet_di8_high_clocks
|
||||
<< ", di8_low_clocks=" << packet_di8_low_clocks;
|
||||
}
|
||||
std::cout << ", avg_steps=" << packet_avg_steps
|
||||
<< "\n";
|
||||
} else {
|
||||
current_packet.channels[0].resize(frames);
|
||||
@ -2568,6 +2576,10 @@ int run(const Config& cfg) {
|
||||
<< ", clocks=" << packet_clock_count
|
||||
<< ", di2_high_clocks=" << packet_di2_high_clocks
|
||||
<< ", di2_low_clocks=" << packet_di2_low_clocks;
|
||||
if (cfg.do8_freq_ref) {
|
||||
std::cout << ", di8_high_clocks=" << packet_di8_high_clocks
|
||||
<< ", di8_low_clocks=" << packet_di8_low_clocks;
|
||||
}
|
||||
if (cfg.di1_mode == Di1Mode::ZeroOnChange) {
|
||||
std::cout << ", zeroed_on_DI1_change=" << zeroed_fraction << "% ("
|
||||
<< current_packet.zeroed_samples << "/" << current_packet.stored_samples << ")";
|
||||
@ -2628,6 +2640,8 @@ int run(const Config& cfg) {
|
||||
packet_clock_count = 0;
|
||||
packet_di2_high_clocks = 0;
|
||||
packet_di2_low_clocks = 0;
|
||||
packet_di8_high_clocks = 0;
|
||||
packet_di8_low_clocks = 0;
|
||||
if (!fast_tty_avg_stream_mode) {
|
||||
current_packet.reset(target_frames, cfg.channel_count);
|
||||
}
|
||||
@ -2898,6 +2912,15 @@ int run(const Config& cfg) {
|
||||
}
|
||||
++packet_clock_count;
|
||||
|
||||
if (cfg.do8_freq_ref) {
|
||||
const bool di8_raw = (din_value & kE502Digital8Mask) != 0U;
|
||||
if (di8_raw) {
|
||||
++packet_di8_high_clocks;
|
||||
} else {
|
||||
++packet_di8_low_clocks;
|
||||
}
|
||||
}
|
||||
|
||||
const bool di8_level = cfg.do8_freq_ref
|
||||
? ((din_value & kE502Digital8Mask) != 0U)
|
||||
: false;
|
||||
|
||||
Reference in New Issue
Block a user