LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_lla_ref_cmd()
void edit_lla_ref_cmd()
{
int err;
double old_lat, old_lon, old_alt;

   old_lat = precise_lat;
   old_lon = precise_lon;
   old_alt = precise_alt;

   precise_lat = ref_lat;
   precise_lon = ref_lon;
   precise_alt = ref_alt;

   err = parse_lla(&edit_buffer[0]);
   if     (err == BAD_LAT)     edit_error("Bad latitude value");
   else if(err == BAD_LON)     edit_error("Bad longitude value");
   else if(err == BAD_ALT)     edit_error("Bad altitude value");
   else if(err == LLA_MISSING) edit_error("Must enter three lat lon alt values (separated by spaces)");
   else if(err == NO_AVERAGE)  edit_error("No LLA data available to average");
   else if(err) ;
   else { // save current position with high accuracy
      ref_lat = precise_lat;
      ref_lon = precise_lon;
      ref_alt = precise_alt;
      user_set_ref_lla = 1;

      rebuild_lla_plot(0);
      need_redraw = 3201;
   }

   precise_lat = old_lat;
   precise_lon = old_lon;
   precise_alt = old_alt;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
leaq 0x3092c9(%rip), %rax    # 0x33b2f0
movsd (%rax), %xmm0
movsd %xmm0, -0x40(%rbp)
leaq 0x3092c1(%rip), %r14    # 0x33b2f8
movsd (%r14), %xmm0
movsd %xmm0, -0x38(%rbp)
leaq 0x3092b8(%rip), %r15    # 0x33b300
movsd (%r15), %xmm0
movsd %xmm0, -0x30(%rbp)
leaq 0x3092b7(%rip), %r12    # 0x33b310
movsd (%r12), %xmm0
movsd %xmm0, (%rax)
leaq 0x3092ae(%rip), %r13    # 0x33b318
movsd (%r13), %xmm0
movsd %xmm0, (%r14)
leaq 0x3092a4(%rip), %rbx    # 0x33b320
movsd (%rbx), %xmm0
movsd %xmm0, (%r15)
leaq 0x30d254(%rip), %rdi    # 0x33f2e0
callq 0x315ca
cmpl $0x5, %eax
ja 0x32124
movl %eax, %eax
leaq 0xd9f59(%rip), %rcx     # 0x10bffc
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x30923d(%rip), %rax    # 0x33b2f0
movsd (%rax), %xmm0
movsd %xmm0, (%r12)
movsd (%r14), %xmm0
movsd %xmm0, (%r13)
movsd (%r15), %xmm0
movsd %xmm0, (%rbx)
leaq 0x309268(%rip), %rax    # 0x33b340
movl $0x1, (%rax)
xorl %edi, %edi
callq 0xfc4c8
leaq 0x1e6758(%rip), %rax    # 0x218844
movl $0xc81, (%rax)          # imm = 0xC81
jmp 0x32124
leaq 0xe3025(%rip), %rdi     # 0x115120
jmp 0x3211f
leaq 0xe2ff5(%rip), %rdi     # 0x1150f9
jmp 0x3211f
leaq 0xe3000(%rip), %rdi     # 0x11510d
jmp 0x3211f
leaq 0xe2fd0(%rip), %rdi     # 0x1150e6
jmp 0x3211f
leaq 0xe303b(%rip), %rdi     # 0x11515a
callq 0x23027
leaq 0x3091c5(%rip), %rax    # 0x33b2f0
movsd -0x40(%rbp), %xmm0
movsd %xmm0, (%rax)
movsd -0x38(%rbp), %xmm0
movsd %xmm0, (%r14)
movsd -0x30(%rbp), %xmm0
movsd %xmm0, (%r15)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_lla_cmd(int)
void edit_lla_cmd(int type)
{
int err;

   err = parse_lla(&edit_buffer[0]);
   if     (err == BAD_LAT)     edit_error("Bad latitude value");
   else if(err == BAD_LON)     edit_error("Bad longitude value");
   else if(err == BAD_ALT)     edit_error("Bad altitude value");
   else if(err == LLA_MISSING) edit_error("Must enter three lat lon alt values (separated by spaces)");
   else if(err == NO_AVERAGE)  edit_error("No LLA data available to average");
   else if(err) return;
   else { // save current position with high accuracy
      // !!!!! should we set ref_lat/lon/alt? gggggggg
      if(luxor) {
         set_lla(precise_lat, precise_lon, precise_alt);
      }
      else {
         #ifdef PRECISE_STUFF
            stop_precision_survey(10); // stop any precision survey
            stop_self_survey(10);      // stop any self survey
            save_precise_posn(type);   // do single point surveys until we get close enough
         #else
            set_lla(precise_lat, precise_lon, precise_alt);
         #endif
      }
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %edi, %ebx
leaq 0x30d17a(%rip), %rdi    # 0x33f2e0
callq 0x315ca
cmpl $0x5, %eax
ja 0x321f4
movl %eax, %eax
leaq 0xd9e97(%rip), %rcx     # 0x10c014
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x20cdb1(%rip), %rax    # 0x23ef3e
cmpb $0x0, (%rax)
je 0x321fb
leaq 0x309157(%rip), %rax    # 0x33b2f0
movsd (%rax), %xmm0
leaq 0x309154(%rip), %rax    # 0x33b2f8
movsd (%rax), %xmm1
leaq 0x309151(%rip), %rax    # 0x33b300
movsd (%rax), %xmm2
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x674dc
leaq 0xe2f5b(%rip), %rdi     # 0x115120
jmp 0x321e9
leaq 0xe2f2b(%rip), %rdi     # 0x1150f9
jmp 0x321e9
leaq 0xe2f36(%rip), %rdi     # 0x11510d
jmp 0x321e9
leaq 0xe2f06(%rip), %rdi     # 0x1150e6
jmp 0x321e9
leaq 0xe2f71(%rip), %rdi     # 0x11515a
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x23027
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
movl $0xa, %edi
callq 0xfb285
movl $0xa, %edi
callq 0x71618
movl %ebx, %edi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0xfb5cf
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_option_switch()
void edit_option_switch()
{
int cmd_err;
char *s;
int i;
char cmd[256+1];

   // process what is normally command line only options from the keyboard
   not_safe = 0;
   keyboard_cmd = 1;
   s = &edit_buffer[0];

   while(*s) {
      while(*s) {  // skip leading white space
         if(*s == 0) break;
         else if(*s == ' ') ++s;
         else if(*s == '\t') ++s;
         else break;
      }
      if(*s == 0) break;

      i = 0;
      cmd[i] = 0;
      while(*s) {  // extract the next option string
         if(*s == ' ') break;
         else if(*s == '\t') break;
         else if(i >= 256) break;

         cmd[i++] = *s;
         cmd[i] = 0;
         ++s;
      }

      if(1) ;
      else if(cmd[0] == '-');
      else if(cmd[0] == '/');
      else if(cmd[0]) {
         strcpy(out, "/");
         strcat(out, cmd);
         strcpy(cmd, out);
      }

      cmd_err = option_switch(&cmd[0]);  // process the option

      if(cmd_err) {
         sprintf(out, "Unknown or bad command line option: %s.  Type ? for command line help.", &cmd[0]);
         edit_error(out);
         break;
      }
//    else if(not_safe == 1) {
      else if(not_safe) {      // xyzzy
         config_options();
      }
   }

   need_redraw = 1200;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x110, %rsp            # imm = 0x110
leaq 0x2db87f(%rip), %r14    # 0x30de6d
movb $0x0, (%r14)
leaq 0x2db873(%rip), %rax    # 0x30de6c
movb $0x1, (%rax)
leaq 0x30ccdd(%rip), %r15    # 0x33f2e0
movb (%r15), %al
testb %al, %al
je 0x326b2
leaq -0x130(%rbp), %rbx
cmpb $0x9, %al
je 0x3265f
movzbl %al, %eax
cmpl $0x20, %eax
je 0x3265f
testl %eax, %eax
je 0x326b2
movb $0x0, -0x130(%rbp)
xorl %r12d, %r12d
movzbl (%r15,%r12), %eax
testb $-0x21, %al
je 0x32668
cmpq $0xff, %r12
ja 0x32668
cmpb $0x9, %al
je 0x32668
movb %al, -0x130(%rbp,%r12)
movb $0x0, -0x12f(%rbp,%r12)
incq %r12
jmp 0x32633
movb 0x1(%r15), %al
incq %r15
jmp 0x32615
movq %rbx, %rdi
callq 0x326cf
testl %eax, %eax
jne 0x3268b
cmpb $0x0, (%r14)
je 0x3267f
callq 0xd9c4
addq %r12, %r15
movb (%r15), %al
testb %al, %al
jne 0x32615
jmp 0x326b2
leaq 0x309b8e(%rip), %rbx    # 0x33c220
leaq 0xe2b8d(%rip), %rsi     # 0x115226
leaq -0x130(%rbp), %rdx
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9060
movq %rbx, %rdi
callq 0x23027
leaq 0x1e618b(%rip), %rax    # 0x218844
movl $0x4b0, (%rax)          # imm = 0x4B0
addq $0x110, %rsp            # imm = 0x110
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: option_switch(char*)
int option_switch(char *arg)  
{   
char c, d;

   // process a command line option parameter
   d = 0;
   c = tolower(arg[1]);
   if(c) d = tolower(arg[2]);

   if((arg[0] == '=') || (arg[0] == '$')) {  // it is a hex byte to send to the tbolt
      save_cmd_bytes(arg);
   }
   else if(isdigit(c)) {  // /digit - rcvr port number or dotted IP address
      if(keyboard_cmd) kill_com(RCVR_PORT,3017);
      config_port(RCVR_PORT, &arg[1]);
   }
   // we break up the command line processing big 'if' statement 
   // into two parts so the DOS compiler heap does not overflow
   else if((c >= 'a') && (c <= 'o')) {   // first half of command line options
      return cmd_a_to_o(arg);           
   }
   else {                                // all the other command line options
      return cmd_other(arg);
   }

   return 0;  // we did something useful
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movzbl (%rdi), %eax
cmpl $0x3d, %eax
je 0x326e6
cmpl $0x24, %eax
jne 0x326f5
movq %rbx, %rdi
callq 0x47407
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x1(%rbx), %r14
movsbl (%r14), %edi
callq 0x9580
movsbl %al, %eax
leal -0x30(%rax), %ecx
cmpl $0x9, %ecx
ja 0x32737
leaq 0x2db758(%rip), %rax    # 0x30de6c
cmpb $0x0, (%rax)
je 0x32728
movl $0xa, %edi
movl $0xbc9, %esi            # imm = 0xBC9
callq 0xb025
movl $0xa, %edi
movq %r14, %rsi
callq 0x4d64f
jmp 0x326ee
addl $-0x61, %eax
movq %rbx, %rdi
cmpl $0xe, %eax
ja 0x3274b
popq %rbx
popq %r14
popq %rbp
jmp 0x4dc0d
popq %rbx
popq %r14
popq %rbp
jmp 0x53106
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: set_osc_units()
void set_osc_units()
{
   if(rcvr_type == BRANDY_RCVR) ;
   else if(rcvr_type == PRS_RCVR) ;
   else if(rcvr_type == TSIP_RCVR) ;
   else return;

   if(show_euro_ppt) {
      ppb_string = "e-9 ";
      ppt_string = "e-12";
      if(strstr(plot[OSC].units, "ppt")) plot[OSC].units = "e-12";
      if(rcvr_type == BRANDY_RCVR) plot[SEVEN].units = "e-12";
   }
   else {
      ppb_string = " ppb";
      ppt_string = " ppt";
      if(strstr(plot[OSC].units, "e-12")) plot[OSC].units = "ppt";
      if(rcvr_type == BRANDY_RCVR) plot[SEVEN].units = "ppt";
   }
   plot[OSC].units = ppt_string;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x1e6171(%rip), %rax    # 0x2188d0
movq (%rax), %rax
cmpq $0x1, %rax
je 0x3277c
cmpq $0x1000000, %rax        # imm = 0x1000000
je 0x3277c
cmpq $0x40000, %rax          # imm = 0x40000
jne 0x32804
leaq 0x2db935(%rip), %rcx    # 0x30e0b8
cmpb $0x0, (%rcx)
je 0x327b7
leaq 0xe2ade(%rip), %rcx     # 0x11526d
leaq 0x30ce82(%rip), %rdx    # 0x33f618
movq %rcx, (%rdx)
leaq 0xe2ad2(%rip), %rdx     # 0x115272
leaq 0x30ce79(%rip), %rcx    # 0x33f620
movq %rdx, (%rcx)
movq %rdx, %rcx
cmpq $0x40000, %rax          # imm = 0x40000
je 0x327e8
jmp 0x327f6
leaq 0xe2ab9(%rip), %rcx     # 0x115277
leaq 0x30ce53(%rip), %rdx    # 0x33f618
movq %rcx, (%rdx)
leaq 0xe4022(%rip), %rcx     # 0x1167f1
leaq 0x30ce4a(%rip), %rdx    # 0x33f620
movq %rcx, (%rdx)
cmpq $0x40000, %rax          # imm = 0x40000
jne 0x327f6
leaq 0xe400a(%rip), %rdx     # 0x1167f2
leaq 0x12b541(%rip), %rax    # 0x15dd30
movq %rdx, 0x918(%rax)
leaq 0x12b533(%rip), %rax    # 0x15dd30
movq %rcx, 0xf0(%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: toggle_plot(int)
void toggle_plot(int id)
{
   if((id < 0) || (id >= (NUM_PLOTS+DERIVED_PLOTS))) return;
   if(id != FFT) pre_fft_plot = id;

   selected_plot = id;
   plot[selected_plot].show_plot = toggle_value(plot[selected_plot].show_plot);
   plot[selected_plot].user_set_show = 1;

if((selected_plot == FFT) && (plot[selected_plot].show_plot == 0)) { // just turned off FFT plot
   selected_plot = pre_fft_plot;
}

   if(USES_PLOT_THREE) ;
   else if((graph_lla == 0) && (selected_plot == THREE) && (luxor == 0)) {  //!!!! debug_plots
      if(plot[DAC].sum_yy && stat_count) {
          d_scale = sqrt(plot[TEMP].sum_yy/stat_count) / sqrt(plot[DAC].sum_yy/stat_count);
      }
      else d_scale = 0.0;
if(title_type != USER) {
   sprintf(plot_title, "DAC_scale=%f", d_scale);
   title_type = OTHER;
}
   }

   config_extra_plots();
   if(luxor && (id == AUXV)) need_redraw = 1301;
}

// Assembly:
cmpl $0x13, %edi
ja 0x32ffb
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %ebx
cmpl $0xe, %edi
je 0x32f5a
leaq 0x30ce0c(%rip), %rax    # 0x33fd64
movl %ebx, (%rax)
leaq 0x30cdf7(%rip), %r15    # 0x33fd58
movl %ebx, (%r15)
movl %ebx, %eax
imulq $0xe8, %rax, %rax
leaq 0x12adbc(%rip), %r14    # 0x15dd30
movzbl 0x18(%r14,%rax), %edi
callq 0x34013
movzbl %al, %ecx
movslq (%r15), %rax
imulq $0xe8, %rax, %rdx
movl %ecx, 0x18(%r14,%rdx)
movl $0x1, 0xe0(%r14,%rdx)
cmpq $0xe, %rax
jne 0x32fbe
movl $0xe, %eax
cmpl $0x0, 0xcc8(%r14)
jne 0x32fbe
leaq 0x30cdab(%rip), %rax    # 0x33fd64
movl (%rax), %eax
movl %eax, (%r15)
leaq 0x1e590b(%rip), %rcx    # 0x2188d0
testl $0x101b1b00, 0x1(%rcx)  # imm = 0x101B1B00
je 0x32ffc
callq 0x13dfe
cmpl $0xd, %ebx
jne 0x32ff1
leaq 0x20bf5f(%rip), %rax    # 0x23ef3e
cmpb $0x0, (%rax)
je 0x32ff1
leaq 0x1e5859(%rip), %rax    # 0x218844
movl $0x515, (%rax)          # imm = 0x515
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x3082c1(%rip), %rcx    # 0x33b2c4
cmpb $0x0, (%rcx)
jne 0x32fce
cmpl $0x6, %eax
jne 0x32fce
leaq 0x20bf2a(%rip), %rax    # 0x23ef3e
cmpb $0x0, (%rax)
jne 0x32fce
movsd 0x248(%r14), %xmm0
xorpd %xmm3, %xmm3
ucomisd %xmm3, %xmm0
jne 0x3302e
jnp 0x3309c
leaq 0x2d9f5b(%rip), %r15    # 0x30cf90
movsd (%r15), %xmm1
xorpd %xmm2, %xmm2
ucomisd %xmm2, %xmm1
jne 0x33046
jnp 0x3309c
movsd 0x330(%r14), %xmm0
divsd %xmm1, %xmm0
ucomisd %xmm2, %xmm0
jb 0x33062
xorps %xmm3, %xmm3
sqrtsd %xmm0, %xmm3
jmp 0x3306b
callq 0x9270
movapd %xmm0, %xmm3
movsd 0x248(%r14), %xmm0
divsd (%r15), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x33089
sqrtsd %xmm0, %xmm0
jmp 0x33098
movsd %xmm3, -0x20(%rbp)
callq 0x9270
movsd -0x20(%rbp), %xmm3
divsd %xmm0, %xmm3
leaq 0x30c66d(%rip), %rax    # 0x33f710
movsd %xmm3, (%rax)
leaq 0x30c21e(%rip), %r14    # 0x33f2cc
cmpl $0x2, (%r14)
je 0x32fce
leaq 0x30b791(%rip), %rdi    # 0x33e850
leaq 0xe21b6(%rip), %rsi     # 0x11527c
movapd %xmm3, %xmm0
movb $0x1, %al
callq 0x9060
movl $0x3, (%r14)
jmp 0x32fce
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: dump_mtie_data()
void dump_mtie_data()
{
FILE *file;

   if(edit_buffer[0] == 0) {
      file = topen("mtie.dat", "w");
      if(file == 0) {
         sprintf(out, "ERROR: could not write file: mtie.dat");
         edit_error(out);
         return;
      }
   }
   else {
      if(strstr(edit_buffer, ".") == 0) strcat(edit_buffer, ".dat");
      file = topen(edit_buffer, "w");
      if(file == 0) {
         sprintf(out, "ERROR: could not write file: %s", edit_buffer);
         edit_error(out);
         return;
      }
   }
   if(file == 0) return;

   dump_mtie(CHA_MTIE, file);
   dump_mtie(CHB_MTIE, file);
   dump_mtie(CHC_MTIE, file);
   dump_mtie(CHD_MTIE, file);


   fclose(file);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x30bf66(%rip), %rax    # 0x33f2e0
cmpb $0x0, (%rax)
je 0x333eb
leaq 0x30bf5a(%rip), %rbx    # 0x33f2e0
movq %rbx, %rdi
movl $0x2e, %esi
callq 0x9100
testq %rax, %rax
jne 0x333ac
movq %rbx, %rdi
callq 0x9120
movl $0x7461642e, (%rbx,%rax) # imm = 0x7461642E
movb $0x0, 0x4(%rbx,%rax)
leaq 0x30bf2d(%rip), %rdi    # 0x33f2e0
leaq 0xee001(%rip), %rsi     # 0x1213bb
callq 0x9a47
testq %rax, %rax
jne 0x33403
leaq 0x308e55(%rip), %rbx    # 0x33c220
leaq 0xe1efc(%rip), %rsi     # 0x1152ce
leaq 0x30bf07(%rip), %rdx    # 0x33f2e0
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9060
movq %rbx, %rdi
jmp 0x3346f
leaq 0xe2133(%rip), %rdi     # 0x115525
leaq 0xedfc2(%rip), %rsi     # 0x1213bb
callq 0x9a47
testq %rax, %rax
je 0x33445
movq %rax, %rbx
xorl %edi, %edi
movq %rax, %rsi
callq 0xfe403
movl $0x1, %edi
movq %rbx, %rsi
callq 0xfe403
movl $0x2, %edi
movq %rbx, %rsi
callq 0xfe403
movl $0x3, %edi
movq %rbx, %rsi
callq 0xfe403
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x9370
movups 0xe20cc(%rip), %xmm0    # 0x115518
leaq 0x308dcd(%rip), %rdi    # 0x33c220
movaps %xmm0, 0x10(%rdi)
movups 0xe20aa(%rip), %xmm0    # 0x115508
movaps %xmm0, (%rdi)
movabsq $0x7461642e656974, %rax # imm = 0x7461642E656974
movq %rax, 0x1e(%rdi)
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x23027
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: get_cable_val(char*)
double get_cable_val(char *s)
{
double val;

   if(s == 0) return 0.0F;

   while(s > &edit_buffer[0]) { // backup over leading white space
      --s;
      if((*s != ' ') && (*s != '\t')) break;
   }
   while(s > &edit_buffer[0]) { // backup to the value
      --s;
      if((*s == ' ') || (*s == '\t')) break;
   }
   if(s == 0) return 0.0;

   val = atof(s);
   return val;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
testq %rdi, %rdi
je 0x33a9b
cmpq 0x11c4c1(%rip), %rdi    # 0x14ff00
jbe 0x33a67
leaq 0x30b898(%rip), %rax    # 0x33f2e0
decq %rdi
movzbl (%rdi), %ecx
cmpl $0x20, %ecx
je 0x33a58
cmpl $0x9, %ecx
jne 0x33a67
leaq -0x1(%rdi), %rcx
cmpq %rax, %rdi
movq %rcx, %rdi
ja 0x33a4b
movq %rax, %rdi
cmpq 0x11c492(%rip), %rdi    # 0x14ff00
jbe 0x33a95
decq %rdi
leaq 0x30b866(%rip), %rax    # 0x33f2e0
movq %rdi, %rcx
movq %rcx, %rdi
movb (%rcx), %cl
cmpb $0x20, %cl
je 0x33a95
cmpb $0x9, %cl
je 0x33a95
leaq -0x1(%rdi), %rcx
cmpq %rax, %rdi
ja 0x33a7d
popq %rbp
jmp 0x9470
xorps %xmm0, %xmm0
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_cable_delay(int)
void edit_cable_delay(int kbd_cmd)
{
double val;
double vf;
char *s, *sf, *squote;

   if(edit_buffer[0] == 0) return;

   vf = VELOCITY_FACTOR;  // 0.66 vp coax
   strupr(edit_buffer);


   s = strchr(edit_buffer, 'V');  // look for velocity factor setting
   if(s) {
      vf = get_cable_val(s);
      if((vf <= 0.0) || (vf > 1.0)) {
         if(kbd_cmd) edit_error("Invalid velocity factor specified.");
         return;
      }
   }

   s = strchr(edit_buffer, 'M');  // look for meters
   sf = strchr(edit_buffer, 'F');
   squote = strchr(edit_buffer, '\'');
   if(s) {
      val = get_cable_val(s);
      val *= FEET_PER_METER;
      val = (val / 983571056.0) / vf;
   }
   else if(sf) {
      val = get_cable_val(sf);
      val = (val / 983571056.0) / vf;
   }
   else if(squote) {
      val = get_cable_val(squote);
      val = (val / 983571056.0) / vf;
   }
   else {
      val = atof(edit_buffer);
      val /= 1.0E9;
   }

   delay_value = val;

   if(kbd_cmd) {
      set_pps(user_pps_enable, pps_polarity,  delay_value,  pps1_delay, pps_threshold, 1);
      request_pps_info();
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
leaq 0x30b82a(%rip), %rax    # 0x33f2e0
cmpb $0x0, (%rax)
je 0x33bee
movl %edi, %ebx
leaq 0x30b818(%rip), %r14    # 0x33f2e0
movq %r14, %rdi
callq 0x9899
movq %r14, %rdi
movl $0x56, %esi
callq 0x9100
testq %rax, %rax
je 0x33b1e
movq %rax, %rdi
callq 0x33a2f
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
jae 0x33afe
ucomisd 0xd5574(%rip), %xmm0    # 0x109070
jbe 0x33b26
testl %ebx, %ebx
je 0x33bee
leaq 0xe1b6b(%rip), %rdi     # 0x115678
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x23027
movsd 0xd7e52(%rip), %xmm0    # 0x10b978
movsd %xmm0, -0x28(%rbp)
leaq 0x30b7ae(%rip), %r12    # 0x33f2e0
movq %r12, %rdi
movl $0x4d, %esi
callq 0x9100
movq %rax, %r14
movq %r12, %rdi
movl $0x46, %esi
callq 0x9100
movq %rax, %r15
movq %r12, %rdi
movl $0x27, %esi
callq 0x9100
testq %r14, %r14
je 0x33b76
movq %r14, %rdi
callq 0x33a2f
mulsd 0xd7d34(%rip), %xmm0    # 0x10b8a8
jmp 0x33b8d
testq %r15, %r15
je 0x33b80
movq %r15, %rdi
jmp 0x33b88
testq %rax, %rax
je 0x33bfb
movq %rax, %rdi
callq 0x33a2f
divsd 0xd7deb(%rip), %xmm0    # 0x10b980
divsd -0x28(%rbp), %xmm0
leaq 0x2da21f(%rip), %rax    # 0x30ddc0
movsd %xmm0, (%rax)
testl %ebx, %ebx
je 0x33bee
leaq 0x2da171(%rip), %rax    # 0x30dd21
movzbl (%rax), %edi
leaq 0x2da15e(%rip), %rax    # 0x30dd18
movzbl (%rax), %esi
leaq 0x2da214(%rip), %rax    # 0x30ddd8
movsd (%rax), %xmm1
leaq 0x2da14d(%rip), %rax    # 0x30dd1c
movss (%rax), %xmm2
movl $0x1, %edx
callq 0x6add8
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x6ab01
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x30b6de(%rip), %rdi    # 0x33f2e0
callq 0x9470
divsd 0xd5419(%rip), %xmm0    # 0x109028
jmp 0x33b9a
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: clear_pid_display()
void clear_pid_display()
{
   if(pid_debug == 0) {
      debug_text[0] = 0;
      debug_text2[0] = 0;
      redraw_screen();
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x30ba24(%rip), %rax    # 0x33f640
cmpb $0x0, (%rax)
je 0x33c23
popq %rbp
retq
leaq 0x30ad76(%rip), %rax    # 0x33e9a0
xorl %ecx, %ecx
movb %cl, (%rax)
leaq 0x30aebb(%rip), %rax    # 0x33eaf0
movb %cl, (%rax)
popq %rbp
jmp 0xfa97
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: toggle_value(unsigned char)
u08 toggle_value(u08 x)
{
int c;

   // commands that normally toggle the parameter can be forced on or off
   // by following them with a 0,1,y,n when they are in script files
   // i.e.  gu  - toggles graph update mode
   //       gu1 - sets graph update mode
   //       gun - clears graph update mode
   if(script_file && (script_pause == 0)) {
      c = get_script();
      if     ((c == '1') || (c == 'y') || (c == 'Y')) return 1;
      else if((c == '0') || (c == 'n') || (c == 'N')) return 0;
   }

   return (x & 1) ^ 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edi, %ebx
leaq 0x20ae95(%rip), %rax    # 0x23eeb8
cmpq $0x0, (%rax)
je 0x3406f
leaq 0x20aea0(%rip), %rax    # 0x23eed0
cmpb $0x0, (%rax)
jne 0x3406f
movb $0x1, %r14b
callq 0x1d08f
leal -0x30(%rax), %ecx
cmpl $0x3e, %ecx
ja 0x3406a
movabsq $0x4000000040000001, %rdx # imm = 0x4000000040000001
btq %rcx, %rdx
jae 0x3405a
xorl %r14d, %r14d
jmp 0x34077
movabsq $0x20000000002, %rdx    # imm = 0x20000000002
btq %rcx, %rdx
jb 0x34077
cmpl $0x79, %eax
je 0x34077
notb %bl
andb $0x1, %bl
movl %ebx, %r14d
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: clear_osc_pid_display()
void clear_osc_pid_display()
{
   if(osc_pid_debug == 0) {
      debug_text[0] = 0;
      debug_text2[0] = 0;
      redraw_screen();
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x30b60e(%rip), %rax    # 0x33f698
cmpb $0x0, (%rax)
je 0x34091
popq %rbp
retq
leaq 0x30a908(%rip), %rax    # 0x33e9a0
xorl %ecx, %ecx
movb %cl, (%rax)
leaq 0x30aa4d(%rip), %rax    # 0x33eaf0
movb %cl, (%rax)
popq %rbp
jmp 0xfa97
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: go_full()
void go_full()
{
   // setup to go to a full screen mode
   not_safe = 1;
   go_fullscreen ^= 1;        // toggle full screen mode
   kill_deco = go_fullscreen; // disable X11 window decorations
   need_screen_init = 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x2d9b20(%rip), %rax    # 0x30de6d
movb $0x1, (%rax)
leaq 0x1e4489(%rip), %rax    # 0x2187e0
movl (%rax), %ecx
xorl $0x1, %ecx
movl %ecx, (%rax)
leaq 0x1e44bf(%rip), %rax    # 0x218824
movl %ecx, (%rax)
leaq 0x1e447a(%rip), %rax    # 0x2187e8
movl $0x1, (%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: change_screen_res()
void change_screen_res()
{
int k;

   reset_first_key(22);
   prot_menu = 0;
   eofs = 1;
   adjust_screen_options();
   init_screen(9100);

   if     (rcvr_type != SCPI_RCVR);  // NEW_RCVR - mostly polled receivers here
   else if(rcvr_type != UCCM_RCVR);
   else if(rcvr_type != STAR_RCVR);
   else if(rcvr_type != TRUE_RCVR);
   else if(rcvr_type != ZYFER_RCVR);
   else init_messages(40, 0);  // zorky


   // set where the first point in the graphs will be
   last_count_y = PLOT_ROW + (PLOT_HEIGHT - VERT_MINOR);
   for(k=0; k<NUM_PLOTS+DERIVED_PLOTS; k++) {
      plot[k].last_y = PLOT_ROW+PLOT_CENTER;
   }

   redraw_screen();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
callq 0x275c7
leaq 0x1e6c03(%rip), %rax    # 0x21b158
movb $0x0, (%rax)
leaq 0x20a9e1(%rip), %rax    # 0x23ef40
movl $0x1, (%rax)
callq 0x34376
movl $0x238c, %edi           # imm = 0x238C
callq 0xbe88
leaq 0x1e4301(%rip), %rax    # 0x21887c
movl (%rax), %eax
leaq 0x1e4304(%rip), %rcx    # 0x218888
leaq 0x1e42e5(%rip), %rdx    # 0x218870
movl (%rcx), %ecx
addl %eax, %ecx
subl (%rdx), %ecx
leaq 0x1e430c(%rip), %rdx    # 0x2188a4
movl %ecx, (%rdx)
leaq 0x1e42f3(%rip), %rcx    # 0x218894
addl (%rcx), %eax
movl $0xc0, %ecx
leaq 0x129781(%rip), %rdx    # 0x15dd30
movl %eax, (%rdx,%rcx)
addq $0xe8, %rcx
cmpq $0x12e0, %rcx           # imm = 0x12E0
jne 0x345af
popq %rbp
jmp 0xfa97
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: update_check()
void update_check()
{
// if(strchr(edit_buffer, 'u') || strchr(edit_buffer, 'U')) {
   if(!strchr(edit_buffer, 'u') && !strchr(edit_buffer, 'U')) {
      pause_data = 0;    // release data pause
      dont_reset_queues = 0;
      new_queue(RESET_ALL_QUEUES, 11);  // erase the data queue
      update_stop = 1;   // stop updating data at end of run
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x30a90b(%rip), %rdi    # 0x33f2e0
movl $0x75, %esi
callq 0x9100
testq %rax, %rax
jne 0x34a2d
leaq 0x30a8f5(%rip), %rdi    # 0x33f2e0
movl $0x55, %esi
callq 0x9100
testq %rax, %rax
jne 0x34a2d
leaq 0x1e6833(%rip), %rax    # 0x21b234
movb $0x0, (%rax)
leaq 0x13c255(%rip), %rax    # 0x170c60
movl $0x0, (%rax)
movl $0x7, %edi
movl $0xb, %esi
callq 0x1118c
leaq 0x2d84b1(%rip), %rax    # 0x30ced8
movl $0x1, (%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: set_cc_mode(int, double)
void set_cc_mode(int mode, DATA_SIZE volts)
{
   if(cc_val) {
      cc_mode = mode;
      lipo_volts = volts;
      cc_state = 0;
      cc_pwm = 0.0F;
      update_check();
   }
   else {
      cc_mode = 0;
      lipo_volts = 0.0F;
      cc_state = 0;
      sweep_stop = 0.0F;
      update_stop = 0;
   }
   cc_pwm = 0.0F;
   set_batt_pwm(0x0000);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x2d81ca(%rip), %rax    # 0x30cea0
movsd (%rax), %xmm1
xorpd %xmm2, %xmm2
leaq 0x2d81a3(%rip), %rax    # 0x30ce88
ucomisd %xmm2, %xmm1
jne 0x34ced
jnp 0x34d1a
movb %dil, (%rax)
leaq 0x2d8199(%rip), %rax    # 0x30ce90
movsd %xmm0, (%rax)
leaq 0x2d8187(%rip), %rax    # 0x30ce89
movb $0x0, (%rax)
leaq 0x2d819c(%rip), %rax    # 0x30cea8
movq $0x0, (%rax)
callq 0x349ca
jmp 0x34d48
xorl %ecx, %ecx
movb %cl, (%rax)
leaq 0x2d816b(%rip), %rax    # 0x30ce90
movq %rcx, (%rax)
leaq 0x2d815a(%rip), %rax    # 0x30ce89
movb %cl, (%rax)
leaq 0x2d8190(%rip), %rax    # 0x30cec8
movq %rcx, (%rax)
leaq 0x2d8196(%rip), %rax    # 0x30ced8
movl $0x0, (%rax)
leaq 0x2d8159(%rip), %rax    # 0x30cea8
movq $0x0, (%rax)
xorl %edi, %edi
popq %rbp
jmp 0x7c189
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: set_terminal_params()
void set_terminal_params()
{
char *s;

   // setup terminal emulattor port and hex/ascii flag

   strupr(edit_buffer);
   s = trim_whitespace(edit_buffer);
   if(s == 0) return;

   if(isdigit(s[0])) {
      term_port = atoi(s);
   }
   if(strchr(s, 'D')) term_port = DAC_PORT;
   if(strchr(s, 'E')) term_port = ECHO_PORT;
   if(strchr(s, 'F')) term_port = FAN_PORT;
   if(strchr(s, 'I')) term_port = TICC_PORT;
   if(strchr(s, 'K')) term_port = NMEA_PORT;
   if(strchr(s, 'N')) term_port = THERMO_PORT;
   if(strchr(s, 'R')) term_port = RCVR_PORT;
   if(strchr(s, 'T')) term_port = TRACK_PORT;

   if(strchr(s, 'A')) term_hex = 0;
   if(strchr(s, 'H')) term_hex = 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x309f88(%rip), %rbx    # 0x33f2e0
movq %rbx, %rdi
callq 0x9899
movq %rbx, %rdi
callq 0x9fcd
testq %rax, %rax
je 0x354c6
movq %rax, %rbx
movsbl (%rax), %eax
addl $-0x30, %eax
cmpl $0x9, %eax
ja 0x35390
movq %rbx, %rdi
callq 0x95e0
leaq 0x2d8f46(%rip), %rcx    # 0x30e2d4
movl %eax, (%rcx)
movq %rbx, %rdi
movl $0x44, %esi
callq 0x9100
testq %rax, %rax
je 0x353af
leaq 0x2d8f2b(%rip), %rax    # 0x30e2d4
movl $0x10, (%rax)
movq %rbx, %rdi
movl $0x45, %esi
callq 0x9100
testq %rax, %rax
je 0x353ce
leaq 0x2d8f0c(%rip), %rax    # 0x30e2d4
movl $0xb, (%rax)
movq %rbx, %rdi
movl $0x46, %esi
callq 0x9100
testq %rax, %rax
je 0x353ed
leaq 0x2d8eed(%rip), %rax    # 0x30e2d4
movl $0x11, (%rax)
movq %rbx, %rdi
movl $0x49, %esi
callq 0x9100
testq %rax, %rax
je 0x3540c
leaq 0x2d8ece(%rip), %rax    # 0x30e2d4
movl $0xd, (%rax)
movq %rbx, %rdi
movl $0x4b, %esi
callq 0x9100
testq %rax, %rax
je 0x3542b
leaq 0x2d8eaf(%rip), %rax    # 0x30e2d4
movl $0xc, (%rax)
movq %rbx, %rdi
movl $0x4e, %esi
callq 0x9100
testq %rax, %rax
je 0x3544a
leaq 0x2d8e90(%rip), %rax    # 0x30e2d4
movl $0xf, (%rax)
movq %rbx, %rdi
movl $0x52, %esi
callq 0x9100
testq %rax, %rax
je 0x35469
leaq 0x2d8e71(%rip), %rax    # 0x30e2d4
movl $0xa, (%rax)
movq %rbx, %rdi
movl $0x54, %esi
callq 0x9100
testq %rax, %rax
je 0x35488
leaq 0x2d8e52(%rip), %rax    # 0x30e2d4
movl $0x12, (%rax)
movq %rbx, %rdi
movl $0x41, %esi
callq 0x9100
testq %rax, %rax
je 0x354a7
leaq 0x208f9f(%rip), %rax    # 0x23e440
movl $0x0, (%rax)
movq %rbx, %rdi
movl $0x48, %esi
callq 0x9100
testq %rax, %rax
je 0x354c6
leaq 0x208f80(%rip), %rax    # 0x23e440
movl $0x1, (%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: set_monitor_params()
void set_monitor_params()
{
char *s;

   // setup monitor port and hex/ascii flag

   strupr(edit_buffer);

   s = trim_whitespace(edit_buffer);
   if(s == 0) return;

   if(isdigit(s[0])) {
      monitor_port = atoi(s);
   }
   if(strchr(s, 'D')) monitor_port = DAC_PORT;
   if(strchr(s, 'E')) monitor_port = ECHO_PORT;
   if(strchr(s, 'F')) monitor_port = FAN_PORT;
   if(strchr(s, 'I')) monitor_port = TICC_PORT;
   if(strchr(s, 'K')) monitor_port = NMEA_PORT;
   if(strchr(s, 'N')) monitor_port = THERMO_PORT;
   if(strchr(s, 'R')) monitor_port = RCVR_PORT;
   if(strchr(s, 'T')) monitor_port = TRACK_PORT;

   if(strchr(s, 'A')) monitor_hex = 0;
   if(strchr(s, 'H')) monitor_hex = 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x309e06(%rip), %rbx    # 0x33f2e0
movq %rbx, %rdi
callq 0x9899
movq %rbx, %rdi
callq 0x9fcd
testq %rax, %rax
je 0x35648
movq %rax, %rbx
movsbl (%rax), %eax
addl $-0x30, %eax
cmpl $0x9, %eax
ja 0x35512
movq %rbx, %rdi
callq 0x95e0
leaq 0x2d8dc0(%rip), %rcx    # 0x30e2d0
movl %eax, (%rcx)
movq %rbx, %rdi
movl $0x44, %esi
callq 0x9100
testq %rax, %rax
je 0x35531
leaq 0x2d8da5(%rip), %rax    # 0x30e2d0
movl $0x10, (%rax)
movq %rbx, %rdi
movl $0x45, %esi
callq 0x9100
testq %rax, %rax
je 0x35550
leaq 0x2d8d86(%rip), %rax    # 0x30e2d0
movl $0xb, (%rax)
movq %rbx, %rdi
movl $0x46, %esi
callq 0x9100
testq %rax, %rax
je 0x3556f
leaq 0x2d8d67(%rip), %rax    # 0x30e2d0
movl $0x11, (%rax)
movq %rbx, %rdi
movl $0x49, %esi
callq 0x9100
testq %rax, %rax
je 0x3558e
leaq 0x2d8d48(%rip), %rax    # 0x30e2d0
movl $0xd, (%rax)
movq %rbx, %rdi
movl $0x4b, %esi
callq 0x9100
testq %rax, %rax
je 0x355ad
leaq 0x2d8d29(%rip), %rax    # 0x30e2d0
movl $0xc, (%rax)
movq %rbx, %rdi
movl $0x4e, %esi
callq 0x9100
testq %rax, %rax
je 0x355cc
leaq 0x2d8d0a(%rip), %rax    # 0x30e2d0
movl $0xf, (%rax)
movq %rbx, %rdi
movl $0x52, %esi
callq 0x9100
testq %rax, %rax
je 0x355eb
leaq 0x2d8ceb(%rip), %rax    # 0x30e2d0
movl $0xa, (%rax)
movq %rbx, %rdi
movl $0x54, %esi
callq 0x9100
testq %rax, %rax
je 0x3560a
leaq 0x2d8ccc(%rip), %rax    # 0x30e2d0
movl $0x12, (%rax)
movq %rbx, %rdi
movl $0x41, %esi
callq 0x9100
testq %rax, %rax
je 0x35629
leaq 0x208e21(%rip), %rax    # 0x23e444
movl $0x0, (%rax)
movq %rbx, %rdi
movl $0x48, %esi
callq 0x9100
testq %rax, %rax
je 0x35648
leaq 0x208e02(%rip), %rax    # 0x23e444
movl $0x1, (%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_mode()
void edit_ticc_mode()
{
int i;
unsigned port;

   if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   strupr(edit_buffer);
   i = edit_buffer[0];
   if     (i == 'T') ; // timestamp
   else if(i == 'I') ; // interval
   else if(i == 'P') ; // period
   else if(i == 'F') { // frequency
      if(ticc_type == TAPR_TICC) goto bad_mode;   // frequency
   }
   else if(i == 'H') { // phase
      if(ticc_type == TAPR_TICC) goto bad_mode;   // phase
   }
   else if(ticc_type != TAPR_TICC) {
      goto bad_mode;
   }
   else if(i == 'D') ;
   else if(i == 'L') ;
   else {
      bad_mode:
      sprintf(out, "Invalid TICC mode: %c", i);
      edit_error(out);
      return;
   }

   if(ticc_type != TAPR_TICC) {
      ticc_mode = i;
      have_ticc_mode = i;
      new_queue(RESET_ALL_QUEUES, 222);
   }
   else {
      sprintf(out, "M%c", i);
      set_ticc_config(port, out);
      get_ticc_config(port);
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1e3273(%rip), %rax    # 0x2188d0
movl $0xa, %ebx
cmpq $0x10000, (%rax)        # imm = 0x10000
je 0x3567d
callq 0x702e7
movl $0xd, %ebx
testl %eax, %eax
je 0x3570d
leaq 0x309c5c(%rip), %r14    # 0x33f2e0
movq %r14, %rdi
callq 0x9899
movzbl (%r14), %eax
movsbl %al, %edx
cmpl $0x48, %eax
jle 0x356b5
cmpl $0x49, %eax
je 0x356a7
cmpl $0x50, %eax
je 0x356a7
cmpl $0x54, %eax
jne 0x3571d
leaq 0x1e325a(%rip), %rax    # 0x218908
cmpl $0x54, (%rax)
jne 0x356e8
jmp 0x3572f
cmpl $0x46, %eax
je 0x356bf
cmpl $0x48, %eax
jne 0x3571d
leaq 0x1e3242(%rip), %rax    # 0x218908
cmpl $0x54, (%rax)
jne 0x356e8
leaq 0x306b4e(%rip), %rbx    # 0x33c220
leaq 0xe03a2(%rip), %rsi     # 0x115a7b
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9060
movq %rbx, %rdi
jmp 0x35714
leaq 0x2d761d(%rip), %rax    # 0x30cd0c
movl %edx, (%rax)
leaq 0x2d7618(%rip), %rax    # 0x30cd10
movl %edx, (%rax)
movl $0x7, %edi
movl $0xde, %esi
popq %rbx
popq %r14
popq %rbp
jmp 0x1118c
leaq 0xe0351(%rip), %rdi     # 0x115a65
popq %rbx
popq %r14
popq %rbp
jmp 0x23027
andb $-0x9, %al
cmpb $0x44, %al
jne 0x356cb
leaq 0x1e31de(%rip), %rax    # 0x218908
cmpl $0x54, (%rax)
jne 0x356cb
leaq 0x306aea(%rip), %r14    # 0x33c220
leaq 0xe0354(%rip), %rsi     # 0x115a91
movq %r14, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r14, %rsi
callq 0x64550
movl %ebx, %edi
popq %rbx
popq %r14
popq %rbp
jmp 0x646d3
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_sync()
void edit_ticc_sync()
{
int i;
unsigned port;

   if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   strupr(edit_buffer);  // aaaacccc
   i = edit_buffer[0];
   if     (i == 'M') ;
   else if(i == 'S') ;
   else {
      sprintf(out, "Invalid TICC sync mode: %c", i);
      edit_error(out);
   }
   sprintf(out, "Y%c", i);

   set_ticc_config(port, out);
   get_ticc_config(port);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
leaq 0x1e3163(%rip), %rax    # 0x2188d0
movl $0xa, %ebx
cmpq $0x10000, (%rax)        # imm = 0x10000
je 0x35789
callq 0x702e7
movl $0xd, %ebx
testl %eax, %eax
je 0x35803
leaq 0x309b50(%rip), %r14    # 0x33f2e0
movq %r14, %rdi
callq 0x9899
movzbl (%r14), %eax
movsbl %al, %r14d
cmpl $0x4d, %eax
je 0x357cd
cmpl $0x53, %eax
je 0x357cd
leaq 0x306a6f(%rip), %r15    # 0x33c220
leaq 0xe02dd(%rip), %rsi     # 0x115a95
movq %r15, %rdi
movl %r14d, %edx
xorl %eax, %eax
callq 0x9060
movq %r15, %rdi
callq 0x23027
leaq 0x306a4c(%rip), %r15    # 0x33c220
leaq 0xe02d5(%rip), %rsi     # 0x115ab0
movq %r15, %rdi
movl %r14d, %edx
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r15, %rsi
callq 0x64550
movl %ebx, %edi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x646d3
leaq 0xe025b(%rip), %rdi     # 0x115a65
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x23027
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_fudge()
void edit_ticc_fudge()
{
double val1, val2, val3, val4;
unsigned port;

   if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   val1 = fudge_a;  // aaaacccc
   val2 = fudge_b;
   val3 = fudge_c;
   val4 = fudge_d;
   sscanf(edit_buffer, "%lf %lf %lf %lf", &val1, &val2, &val3, &val4);

   sprintf(out, "GA%d", (int) val1);
   set_ticc_config(port, out);

   sprintf(out, "GB%d", (int) val2);
   set_ticc_config(port, out);

   get_ticc_config(port);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
leaq 0x1e30a3(%rip), %rax    # 0x2188d0
movl $0xa, %ebx
cmpq $0x10000, (%rax)        # imm = 0x10000
je 0x3584d
callq 0x702e7
movl $0xd, %ebx
testl %eax, %eax
je 0x35911
leaq 0x2d74fc(%rip), %rax    # 0x30cd50
movsd (%rax), %xmm0
leaq -0x38(%rbp), %r15
movsd %xmm0, (%r15)
leaq 0x2d74f0(%rip), %rax    # 0x30cd58
movsd (%rax), %xmm0
leaq -0x30(%rbp), %r14
movsd %xmm0, (%r14)
leaq 0x2d74e4(%rip), %rax    # 0x30cd60
movsd (%rax), %xmm0
leaq -0x28(%rbp), %r8
movsd %xmm0, (%r8)
leaq 0x2d74d8(%rip), %rax    # 0x30cd68
movsd (%rax), %xmm0
leaq -0x20(%rbp), %r9
movsd %xmm0, (%r9)
leaq 0x309a3c(%rip), %rdi    # 0x33f2e0
leaq 0xe0209(%rip), %rsi     # 0x115ab4
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x9360
cvttsd2si (%r15), %edx
leaq 0x30695c(%rip), %r15    # 0x33c220
leaq 0xe01f9(%rip), %rsi     # 0x115ac4
movq %r15, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r15, %rsi
callq 0x64550
cvttsd2si (%r14), %edx
leaq 0xe01de(%rip), %rsi     # 0x115ac9
movq %r15, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r15, %rsi
callq 0x64550
movl %ebx, %edi
callq 0x646d3
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0xe014d(%rip), %rdi     # 0x115a65
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x23027
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_time2()
void edit_ticc_time2()
{
int val1, val2, val3, val4;
unsigned port;

   if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   val1 = time2_a;  // aaaacccc
   val2 = time2_b;
   val3 = time2_c;
   val4 = time2_d;
   sscanf(edit_buffer, "%d %d %d %d", &val1, &val2, &val3, &val4);

   sprintf(out, "FA%d", (int) val1);
   set_ticc_config(port, out);

   sprintf(out, "FB%d", (int) val2);
   set_ticc_config(port, out);

   get_ticc_config(port);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
leaq 0x1e2f95(%rip), %rax    # 0x2188d0
movl $0xa, %ebx
cmpq $0x10000, (%rax)        # imm = 0x10000
je 0x3595b
callq 0x702e7
movl $0xd, %ebx
testl %eax, %eax
je 0x35a0b
leaq 0x2d7426(%rip), %rax    # 0x30cd88
movl (%rax), %eax
leaq -0x28(%rbp), %r15
movl %eax, (%r15)
leaq 0x2d741a(%rip), %rax    # 0x30cd8c
movl (%rax), %eax
leaq -0x24(%rbp), %r14
movl %eax, (%r14)
leaq 0x2d740e(%rip), %rax    # 0x30cd90
movl (%rax), %eax
leaq -0x20(%rbp), %r8
movl %eax, (%r8)
leaq 0x2d7402(%rip), %rax    # 0x30cd94
movl (%rax), %eax
leaq -0x1c(%rbp), %r9
movl %eax, (%r9)
leaq 0x30993e(%rip), %rdi    # 0x33f2e0
leaq 0xd416b(%rip), %rsi     # 0x109b14
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x9360
movl (%r15), %edx
leaq 0x306860(%rip), %r15    # 0x33c220
leaq 0xe0107(%rip), %rsi     # 0x115ace
movq %r15, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r15, %rsi
callq 0x64550
movl (%r14), %edx
leaq 0xe00ee(%rip), %rsi     # 0x115ad3
movq %r15, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r15, %rsi
callq 0x64550
movl %ebx, %edi
callq 0x646d3
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0xe0053(%rip), %rdi     # 0x115a65
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x23027
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_tune()
void edit_ticc_tune()
{
unsigned port;
int val;
int min_time;

   dac_dac = 0;
   min_time = 30;
   if(rcvr_type == X72_RCVR) {
      port = RCVR_PORT;
      min_time = 600;
   }
   else if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   val = (int) atof(edit_buffer);

   if(val >= min_time) {  // start analyzing pps drift
      ticc_tune_time = val;
      dac_dac = 1;
   }
   else if(val) {
      sprintf(out, "Autotune time must be >= %d seconds.", min_time);
      edit_error(out);
   }
   else if(dac_dac) {
      dac_dac = 0;
      edit_error("Auto tune canceled");
   }

   return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x305ded(%rip), %r14    # 0x33b81c
movl $0x0, (%r14)
leaq 0x1e2e93(%rip), %rax    # 0x2188d0
movq (%rax), %rax
cmpq $0x2000000, %rax        # imm = 0x2000000
je 0x35a57
cmpq $0x10000, %rax          # imm = 0x10000
jne 0x35a5e
movl $0x1e, %ebx
jmp 0x35a6c
movl $0x258, %ebx            # imm = 0x258
jmp 0x35a6c
callq 0x702e7
movl $0x1e, %ebx
testl %eax, %eax
je 0x35ace
leaq 0x30986d(%rip), %rdi    # 0x33f2e0
callq 0x9470
cvttsd2si %xmm0, %eax
cmpl %eax, %ebx
jle 0x35aa3
testl %eax, %eax
je 0x35ab8
leaq 0x306795(%rip), %r14    # 0x33c220
leaq 0xe0046(%rip), %rsi     # 0x115ad8
movq %r14, %rdi
movl %ebx, %edx
xorl %eax, %eax
callq 0x9060
movq %r14, %rdi
jmp 0x35ad5
leaq 0x2d71e6(%rip), %rcx    # 0x30cc90
movl %eax, (%rcx)
movl $0x1, (%r14)
popq %rbx
popq %r14
popq %rbp
retq
cmpl $0x0, (%r14)
je 0x35ab3
movl $0x0, (%r14)
leaq 0xe0031(%rip), %rdi     # 0x115afd
jmp 0x35ad5
leaq 0xdff90(%rip), %rdi     # 0x115a65
popq %rbx
popq %r14
popq %rbp
jmp 0x23027
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_dilat()
void edit_ticc_dilat()
{
int val1, val2, val3, val4;
unsigned port;

   if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   val1 = dilat_a;  // aaaacccc
   val2 = dilat_b;
   val3 = dilat_c;
   val4 = dilat_d;
   sscanf(edit_buffer, "%d %d %d %d", &val1, &val2, &val3, &val4);

   sprintf(out, "DA%d", (int) val1);
   set_ticc_config(port, out);

   sprintf(out, "DB%d", (int) val2);
   set_ticc_config(port, out);

   get_ticc_config(port);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
leaq 0x1e2dde(%rip), %rax    # 0x2188d0
movl $0xa, %ebx
cmpq $0x10000, (%rax)        # imm = 0x10000
je 0x35b12
callq 0x702e7
movl $0xd, %ebx
testl %eax, %eax
je 0x35bc2
leaq 0x2d7283(%rip), %rax    # 0x30cd9c
movl (%rax), %eax
leaq -0x28(%rbp), %r15
movl %eax, (%r15)
leaq 0x2d7277(%rip), %rax    # 0x30cda0
movl (%rax), %eax
leaq -0x24(%rbp), %r14
movl %eax, (%r14)
leaq 0x2d726b(%rip), %rax    # 0x30cda4
movl (%rax), %eax
leaq -0x20(%rbp), %r8
movl %eax, (%r8)
leaq 0x2d725f(%rip), %rax    # 0x30cda8
movl (%rax), %eax
leaq -0x1c(%rbp), %r9
movl %eax, (%r9)
leaq 0x309787(%rip), %rdi    # 0x33f2e0
leaq 0xd3fb4(%rip), %rsi     # 0x109b14
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x9360
movl (%r15), %edx
leaq 0x3066a9(%rip), %r15    # 0x33c220
leaq 0xdff92(%rip), %rsi     # 0x115b10
movq %r15, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r15, %rsi
callq 0x64550
movl (%r14), %edx
leaq 0xdff79(%rip), %rsi     # 0x115b15
movq %r15, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r15, %rsi
callq 0x64550
movl %ebx, %edi
callq 0x646d3
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0xdfe9c(%rip), %rdi     # 0x115a65
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x23027
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_edge()
void edit_ticc_edge()
{
char e[4];
char c;
unsigned port;
unsigned i, j;

   if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   e[0] = edge_a;   // aaaacccc
   e[1] = edge_b;
   e[2] = edge_c;
   e[3] = edge_d;

   j = 0;
   strupr(edit_buffer);
   for(i=0; i<strlen(edit_buffer); i++) {  // get R/F chars
      c = edit_buffer[i];
      if(c == 'R') {
         e[j++] = c;
         if(j > 3) break;
      }
      else if(c == 'F') {
         e[j++] = c;
         if(j > 3) break;
      }
      else if(c == ' ') ;
      else if(c == '\t') ;
      else {
         sprintf(out, "%c is not a valid edge select", c);
         edit_error(out);
         return;
      }
   }

   if(e[0]) {
      sprintf(out, "EA %c", e[0]);
      set_ticc_config(port, out);
   }

   if(e[1]) {
      sprintf(out, "EB %c", e[1]);
      set_ticc_config(port, out);
   }

   get_ticc_config(port);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
leaq 0x1e2ce7(%rip), %rax    # 0x2188d0
movl $0xa, %ebx
cmpq $0x10000, (%rax)        # imm = 0x10000
je 0x35c09
callq 0x702e7
movl $0xd, %ebx
testl %eax, %eax
je 0x35cfb
leaq 0x2d7164(%rip), %rax    # 0x30cd74
movb (%rax), %r15b
movb %r15b, -0x1c(%rbp)
leaq 0x2d715a(%rip), %rax    # 0x30cd78
movb (%rax), %al
movb %al, -0x1b(%rbp)
leaq 0x3096b6(%rip), %r14    # 0x33f2e0
movq %r14, %rdi
callq 0x9899
movq %r14, %rdi
callq 0x9120
testq %rax, %rax
je 0x35c95
xorl %esi, %esi
movl $0x1, %ecx
xorl %edx, %edx
movzbl (%r14,%rsi), %esi
cmpl $0x45, %esi
jg 0x35c61
cmpl $0x9, %esi
je 0x35c88
cmpl $0x20, %esi
je 0x35c88
jmp 0x35d04
cmpl $0x46, %esi
je 0x35c7a
cmpl $0x52, %esi
jne 0x35d04
movl %edx, %esi
incl %edx
movb $0x52, -0x1c(%rbp,%rsi)
jmp 0x35c83
movl %edx, %esi
incl %edx
movb $0x46, -0x1c(%rbp,%rsi)
cmpl $0x3, %edx
ja 0x35c91
movl %ecx, %esi
incl %ecx
cmpq %rsi, %rax
ja 0x35c48
movb -0x1c(%rbp), %r15b
testb %r15b, %r15b
je 0x35cc0
movsbl %r15b, %edx
leaq 0x30657b(%rip), %r14    # 0x33c220
leaq 0xdfe8c(%rip), %rsi     # 0x115b38
movq %r14, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r14, %rsi
callq 0x64550
movsbl -0x1b(%rbp), %edx
testl %edx, %edx
je 0x35cea
leaq 0x306551(%rip), %r14    # 0x33c220
leaq 0xdfe68(%rip), %rsi     # 0x115b3e
movq %r14, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r14, %rsi
callq 0x64550
movl %ebx, %edi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x646d3
leaq 0xdfd63(%rip), %rdi     # 0x115a65
jmp 0x35d23
movsbl %sil, %edx
leaq 0x306511(%rip), %rbx    # 0x33c220
leaq 0xdfe04(%rip), %rsi     # 0x115b1a
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9060
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x23027
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathui.cpp
// Function: edit_ticc_cal()
void edit_ticc_cal()
{
unsigned port;
int val;

   if(rcvr_type == TICC_RCVR) port = RCVR_PORT;
   else if(ticc_port_open())  port = TICC_PORT;
   else {
      edit_error("No TICC device found.");
      return;
   }

   val = (int) atof(edit_buffer);
   if     (val == 2) ;
   else if(val == 10) ;
   else if(val == 20) ;
   else if(val == 40) ;
   else {
      edit_error("Cal periods must be 2, 10, 20, or 40");
      return;
   }
   sprintf(out, "P%d", val);
   set_ticc_config(port, out);

   get_ticc_config(port);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1e2b90(%rip), %rax    # 0x2188d0
movl $0xa, %ebx
cmpq $0x10000, (%rax)        # imm = 0x10000
je 0x35d5c
callq 0x702e7
movl $0xd, %ebx
testl %eax, %eax
je 0x35dae
leaq 0x30957d(%rip), %rdi    # 0x33f2e0
callq 0x9470
cvttsd2si %xmm0, %edx
cmpl $0x28, %edx
ja 0x35db7
movabsq $0x10000100404, %rax    # imm = 0x10000100404
btq %rdx, %rax
jae 0x35db7
leaq 0x306498(%rip), %r14    # 0x33c220
leaq 0xedf23(%rip), %rsi     # 0x123cb2
movq %r14, %rdi
xorl %eax, %eax
callq 0x9060
movl %ebx, %edi
movq %r14, %rsi
callq 0x64550
movl %ebx, %edi
popq %rbx
popq %r14
popq %rbp
jmp 0x646d3
leaq 0xdfcb0(%rip), %rdi     # 0x115a65
jmp 0x35dbe
leaq 0xdfd86(%rip), %rdi     # 0x115b44
popq %rbx
popq %r14
popq %rbp
jmp 0x23027