// File: /workspace/github_cpp_makefile_star2_O2/jkingan[P]ladyheather/heathui.cpp
// Function: config_msg_ofs()
void config_msg_ofs()
{
   //  This routine sets the end-of-message arrival time offset vs the timing
   //  message time values.
   // NEW_RCVR

   if(user_set_tsx) {
   }
   else if(rcvr_type == ACRON_RCVR) {
      time_sync_offset = (600.0);  // !!!!!! we need to measure this and set a proper value
   }
   else if(ACUTIME && !ACU_GG && !ACU_360) {
      time_sync_offset = (67.0);  // (157.2);
   }
   else if(rcvr_type == BRANDY_RCVR) {
      time_sync_offset = (750.1);
   }
   else if(rcvr_type == CS_RCVR) {
      time_sync_offset = (330.0);
   }
   else if(rcvr_type == ESIP_RCVR) {
      time_sync_offset = (199.0);
   }
   else if(rcvr_type == FURUNO_RCVR) {
      time_sync_offset = (195.0);
   }
   else if(rcvr_type == GPSD_RCVR) {
      time_sync_offset = (TIME_SYNC_AVG-27.7);
   }
   else if(rcvr_type == MOTO_RCVR) {
      if(moto_chans == 12) time_sync_offset = (208.5);
      else if(moto_chans == 8) time_sync_offset = (262.7);  // average of 8 chan units
      else time_sync_offset = (249.15);  // average of different models
   }
   else if(rcvr_type == NMEA_RCVR) {
      time_sync_offset = (222.0);  // typical NMEA value
   }
   else if(rcvr_type == NO_RCVR) {
      time_sync_offset = (0.0);
   }
   else if(rcvr_type == NVS_RCVR) {
     time_sync_offset = 40.7;
   }
   else if(rcvr_type == PRS_RCVR) {
     time_sync_offset = 0.0;
   }
   else if(rcvr_type == RFTG_RCVR) {
     time_sync_offset = (-663.0);
   }
   else if(rcvr_type == SCPI_RCVR) {
      time_sync_offset = (-964.7); // Z3801:-979.8  Z3812:-949.6
   }
   else if(rcvr_type == SIRF_RCVR) {
      time_sync_offset = (417.0);
   }
   else if((rcvr_type == STAR_RCVR) && (star_type == OSA_TYPE)) {
      time_sync_offset = (337.0);
   }
   else if(rcvr_type == STAR_RCVR) {
      time_sync_offset = (215.0);
   }
   else if(rcvr_type == TAIP_RCVR) {
      time_sync_offset = (-175.0);
   }
   else if(rcvr_type == THERMO_RCVR) {
      time_sync_offset = (0.0);
   }
   else if(rcvr_type == TIDE_RCVR) {
      time_sync_offset = (0.0);
   }
   else if(rcvr_type == TRUE_RCVR) {
      time_sync_offset = (32.5);
   }
   else if(rcvr_type == TSIP_RCVR) {
      if(res_t) {
         if(res_t == RES_T) time_sync_offset = (99.4);
         else if(res_t == RES_T_SMT) time_sync_offset = (393.2);
         else time_sync_offset = (246.3); // !!!!! we need actual timings
      }
      else if(tsip_type == STARLOC_TYPE) {
         time_sync_offset = (266.0);
      }
      else {  // tbolt, ACUTIME GOLD
         time_sync_offset = (53.00);
      }
   }
   else if(rcvr_type == UBX_RCVR) {
      time_sync_offset = (197.3);
   }
   else if(rcvr_type == UCCM_RCVR) {
      time_sync_offset = (231.4);
   }
   else if(rcvr_type == VENUS_RCVR) {
      if(lte_lite) {
         time_sync_offset = 252.1;
      }
      else if(com[RCVR_PORT].baud_rate == 9600) {
         if(saw_timing_msg) time_sync_offset = (208.3);
         else               time_sync_offset = (225.3);
      }
      else {  // 115200 baud
         if(saw_timing_msg) time_sync_offset = (153.8);
         else               time_sync_offset = (170.8);
      }
   }
   else if(rcvr_type == X72_RCVR) {
     time_sync_offset = 0.0;
   }
   else if(rcvr_type == Z12_RCVR) {  // !!!!!
      time_sync_offset = 0.0; // TIME_SYNC_AVG;  // 200.0
   }
   else if(rcvr_type == ZODIAC_RCVR) {
      time_sync_offset = (1238.85);  // Pico = 1232.2, Jupiter-T = 1245.5
   }
   else if(rcvr_type == ZYFER_RCVR) {
      time_sync_offset = (65.00);  // Nanosync 380
   }
   else {
      time_sync_offset = TIME_SYNC_AVG;  // 200.0
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x2b4635(%rip), %rax    # 0x2f7ed8
cmpl $0x0, (%rax)
jne 0x438cd
leaq 0x1bf021(%rip), %rax    # 0x2028d0
movq (%rax), %rax
cmpq $0x4000, %rax           # imm = 0x4000
jne 0x438cf
movsd 0xb21f6(%rip), %xmm0    # 0xf5ab8
leaq 0x2b45ff(%rip), %rax    # 0x2f7ec8
movsd %xmm0, (%rax)
popq %rbp
retq
cmpq $0x1, %rax
sete %dl
leaq 0x1c16f7(%rip), %rcx    # 0x204fd4
movl (%rcx), %ecx
cmpl $0x41, %ecx
sete %sil
andb %dl, %sil
cmpb $0x1, %sil
jne 0x4392f
leaq 0x1bf002(%rip), %rdx    # 0x2028f8
movl (%rdx), %edx
cmpl $0x33, %edx
je 0x43906
cmpl $0x47, %edx
jne 0x43a74
leaq 0x1c16db(%rip), %rsi    # 0x204fe8
xorl %edx, %edx
cmpl $0x4f, (%rsi)
sete %sil
cmpq $0x1000, %rax           # imm = 0x1000
je 0x439d2
movsd 0xb21f6(%rip), %xmm0    # 0xf5b20
jmp 0x439e1
cmpq $0x2, %rax
je 0x43afc
cmpq $0x10, %rax
je 0x43abb
cmpq $0x20, %rax
je 0x43a81
cmpq $0x40, %rax
je 0x43b16
cmpq $0x200, %rax            # imm = 0x200
je 0x43ac8
cmpq $0x400, %rax            # imm = 0x400
je 0x43a6c
cmpq $0x800, %rax            # imm = 0x800
je 0x43ae2
movl $0x80000000, %edx       # imm = 0x80000000
cmpq %rdx, %rax
je 0x43b09
cmpq $0x40000, %rax          # imm = 0x40000
je 0x43aef
cmpq $0x400000, %rax         # imm = 0x400000
je 0x43aae
cmpq $0x1000000, %rax        # imm = 0x1000000
je 0x43a6c
cmpq $0x20000000, %rax       # imm = 0x20000000
je 0x43ad5
cmpq $0x20000, %rax          # imm = 0x20000
jne 0x43906
movsd 0xb2143(%rip), %xmm0    # 0xf5b10
jmp 0x438c2
movb %sil, %dl
leaq 0xb35e4(%rip), %rsi     # 0xf6fc0
movsd (%rsi,%rdx,8), %xmm0
je 0x438c2
cmpq $0x1, %rax
je 0x43b57
cmpq $0x4, %rax
je 0x43b4a
cmpq $0x8, %rax
je 0x43bbb
cmpq $0x80, %rax
je 0x43b95
cmpq $0x100, %rax            # imm = 0x100
je 0x43b30
cmpq $0x8000, %rax           # imm = 0x8000
je 0x43bae
movabsq $0x100000000, %rcx      # imm = 0x100000000
cmpq %rcx, %rax
je 0x43a6c
cmpq $0x100000, %rax         # imm = 0x100000
je 0x43b88
cmpq $0x200000, %rax         # imm = 0x200000
je 0x43b3d
cmpq $0x800000, %rax         # imm = 0x800000
je 0x43a6c
cmpq $0x2000000, %rax        # imm = 0x2000000
je 0x43a6c
cmpq $0x80000, %rax          # imm = 0x80000
jne 0x43bc8
xorps %xmm0, %xmm0
jmp 0x438c2
movsd 0xb209c(%rip), %xmm0    # 0xf5b18
jmp 0x438c2
leaq 0x1c159c(%rip), %rax    # 0x205024
movl (%rax), %edx
xorl %eax, %eax
cmpl $0x8, %edx
sete %cl
cmpl $0xc, %edx
je 0x43b23
movb %cl, %al
leaq 0xb350c(%rip), %rcx     # 0xf6fb0
movsd (%rcx,%rax,8), %xmm0
jmp 0x438c2
movsd 0xb2022(%rip), %xmm0    # 0xf5ad8
jmp 0x438c2
movsd 0xb200d(%rip), %xmm0    # 0xf5ad0
jmp 0x438c2
movsd 0xb2028(%rip), %xmm0    # 0xf5af8
jmp 0x438c2
movsd 0xb2023(%rip), %xmm0    # 0xf5b00
jmp 0x438c2
movsd 0xb1ff6(%rip), %xmm0    # 0xf5ae0
jmp 0x438c2
movsd 0xb1fc9(%rip), %xmm0    # 0xf5ac0
jmp 0x438c2
movsd 0xb1fe4(%rip), %xmm0    # 0xf5ae8
jmp 0x438c2
movsd 0xb1ff7(%rip), %xmm0    # 0xf5b08
jmp 0x438c2
movsd 0xb1faa(%rip), %xmm0    # 0xf5ac8
jmp 0x438c2
movsd 0xb1fc5(%rip), %xmm0    # 0xf5af0
jmp 0x438c2
movsd 0xb2000(%rip), %xmm0    # 0xf5b38
jmp 0x438c2
movsd 0xb202b(%rip), %xmm0    # 0xf5b70
jmp 0x438c2
movsd 0xb1ffe(%rip), %xmm0    # 0xf5b50
jmp 0x438c2
leaq 0x1beda6(%rip), %rax    # 0x202904
movzbl (%rax), %eax
testl %eax, %eax
je 0x43c0e
cmpl $0x1, %eax
je 0x43c01
cmpl $0x2, %eax
jne 0x43c22
movsd 0xb1fdd(%rip), %xmm0    # 0xf5b60
jmp 0x438c2
movsd 0xb1fa0(%rip), %xmm0    # 0xf5b30
jmp 0x438c2
leaq 0x1c1434(%rip), %rax    # 0x204fd0
cmpl $0x0, (%rax)
je 0x43bd5
movsd 0xb1f97(%rip), %xmm0    # 0xf5b40
jmp 0x438c2
movsd 0xb1f72(%rip), %xmm0    # 0xf5b28
jmp 0x438c2
movsd 0xb1f85(%rip), %xmm0    # 0xf5b48
jmp 0x438c2
movsd 0xb1fa8(%rip), %xmm0    # 0xf5b78
jmp 0x438c2
leaq 0x2b4704(%rip), %rax    # 0x2f82e0
cmpl $0x2580, 0x159d0(%rax)  # imm = 0x2580
leaq 0x2b383b(%rip), %rax    # 0x2f7428
movl (%rax), %eax
jne 0x43c2f
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
leaq 0xb33e1(%rip), %rax     # 0xf6fe0
jmp 0x43c3d
movsd 0xb1f4f(%rip), %xmm0    # 0xf5b58
jmp 0x438c2
xorl %eax, %eax
cmpl $0x53, %ecx
sete %al
leaq 0xb33d3(%rip), %rcx     # 0xf6ff0
jmp 0x43aa4
movsd 0xb1f3e(%rip), %xmm0    # 0xf5b68
jmp 0x438c2
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
leaq 0xb3393(%rip), %rax     # 0xf6fd0
movsd (%rax,%rcx,8), %xmm0
jmp 0x438c2