// File: jkingan[P]ladyheather/heathgps.cpp
// Function: show_brandy_info(int, int)
int show_brandy_info(int row, int col)
{
int max_row;
int color;

   color = WHITE;
   max_row = MOUSE_ROW;
   if(zoom_screen == 'D') {
      max_row = (SCREEN_HEIGHT / TEXT_HEIGHT) - 3;
      col = 3;
   }

   color = WHITE;
   sprintf(out, "Instant phase:   %g          ", inst_phase); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "Phase control:   %.6f        ", phase_control_val); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "Average phase:   %.6f        ", avg_phase); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "Freq control:    %-6d         ", (int) freq_control_val); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "Last freq corr:  %g          ", last_freq_corr); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "Freq trend:      %g          ", freq_trend); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "Last correction: %s          ", last_correction); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "Phase status:    0x%02X      ", phase_status); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "PLL constraint:  0x%02X      ", pll_constraint);
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   sprintf(out, "OSC type:        %s          ", brandy_osc); 
   out[32] = 0;
   vidstr(row++, col, color, out);
   if(row >= max_row) return row;

   return row;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl $0xf, -0x14(%rbp)
leaq 0x18a3cc(%rip), %rax    # 0x277988
movl (%rax), %eax
movl %eax, -0x10(%rbp)
leaq 0x27e3c0(%rip), %rax    # 0x36b988
movzbl (%rax), %eax
cmpl $0x44, %eax
jne 0xed5f0
leaq 0x18a40d(%rip), %rax    # 0x2779e4
movl (%rax), %eax
leaq 0x18a414(%rip), %rcx    # 0x2779f4
cltd
idivl (%rcx)
subl $0x3, %eax
movl %eax, -0x10(%rbp)
movl $0x3, -0xc(%rbp)
movl $0xf, -0x14(%rbp)
leaq 0x2adb8a(%rip), %rax    # 0x39b188
movsd (%rax), %xmm0
leaq 0x2addf7(%rip), %rdi    # 0x39b400
leaq 0x9c51e(%rip), %rsi     # 0x189b2e
movb $0x1, %al
callq 0x9060
leaq 0x2adde2(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2addc6(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed655
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2adb34(%rip), %rax    # 0x39b190
movsd (%rax), %xmm0
leaq 0x2add99(%rip), %rdi    # 0x39b400
leaq 0x9c4de(%rip), %rsi     # 0x189b4c
movb $0x1, %al
callq 0x9060
leaq 0x2add84(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2add68(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed6b3
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2adade(%rip), %rax    # 0x39b198
movsd (%rax), %xmm0
leaq 0x2add3b(%rip), %rdi    # 0x39b400
leaq 0x9c49e(%rip), %rsi     # 0x189b6a
movb $0x1, %al
callq 0x9060
leaq 0x2add26(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2add0a(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed711
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2ada88(%rip), %rax    # 0x39b1a0
cvttsd2si (%rax), %edx
leaq 0x2adcdd(%rip), %rdi    # 0x39b400
leaq 0x9c45e(%rip), %rsi     # 0x189b88
movb $0x0, %al
callq 0x9060
leaq 0x2adcc8(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2adcac(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed76f
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2ada32(%rip), %rax    # 0x39b1a8
movsd (%rax), %xmm0
leaq 0x2adc7f(%rip), %rdi    # 0x39b400
leaq 0x9c41f(%rip), %rsi     # 0x189ba7
movb $0x1, %al
callq 0x9060
leaq 0x2adc6a(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2adc4e(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed7cd
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2ad9dc(%rip), %rax    # 0x39b1b0
movsd (%rax), %xmm0
leaq 0x2adc21(%rip), %rdi    # 0x39b400
leaq 0x9c3df(%rip), %rsi     # 0x189bc5
movb $0x1, %al
callq 0x9060
leaq 0x2adc0c(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2adbf0(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed82b
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2adbce(%rip), %rdi    # 0x39b400
leaq 0x9c3aa(%rip), %rsi     # 0x189be3
leaq 0x2ad980(%rip), %rdx    # 0x39b1c0
movb $0x0, %al
callq 0x9060
leaq 0x2adbb2(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2adb96(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed885
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2ad958(%rip), %rax    # 0x39b1e4
movl (%rax), %edx
leaq 0x2adb6b(%rip), %rdi    # 0x39b400
leaq 0x9c365(%rip), %rsi     # 0x189c01
movb $0x0, %al
callq 0x9060
leaq 0x2adb56(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2adb3a(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed8e1
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2ad900(%rip), %rax    # 0x39b1e8
movl (%rax), %edx
leaq 0x2adb0f(%rip), %rdi    # 0x39b400
leaq 0x9c327(%rip), %rsi     # 0x189c1f
movb $0x0, %al
callq 0x9060
leaq 0x2adafa(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2adade(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed93a
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
leaq 0x2adabf(%rip), %rdi    # 0x39b400
leaq 0x9c2f5(%rip), %rsi     # 0x189c3d
leaq 0x2ad661(%rip), %rdx    # 0x39afb0
movb $0x0, %al
callq 0x9060
leaq 0x2adaa3(%rip), %rax    # 0x39b400
movb $0x0, 0x20(%rax)
movl -0x8(%rbp), %edi
movl %edi, %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
movl -0xc(%rbp), %esi
movl -0x14(%rbp), %eax
leaq 0x2ada87(%rip), %rcx    # 0x39b400
movzbl %al, %edx
callq 0x10ee0
movl -0x8(%rbp), %eax
cmpl -0x10(%rbp), %eax
jl 0xed991
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xed997
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq