// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: decode_nvs_message()
void decode_nvs_message()
{
u08 id;

   flush_debug();

   msg_fault = 0x00;
   tsip_rptr = 0;
   id = get_next_tsip();

   subcode = 0x00;
   first_msg = 0;
   last_msg = msg_id;
   ++wakeup_tsip_msg; // we have seen a TSIP message
   tsip_error = 0;    // this flag gets set if we see something wrong in a message
   early_end = 0;
   new_packet(0);

   if     (id == 0x41) parse_nvs_speed();
   else if(id == 0x43) parse_nvs_test();
   else if(id == 0x46) parse_nvs_date();
   else if(id == 0x47) parse_nvs_disable();
   else if(id == 0x4A) parse_nvs_iono();
   else if(id == 0x4B) parse_nvs_gnss_timescale();
   else if(id == 0x51) parse_nvs_config();
   else if(id == 0x52) parse_nvs_sats();
   else if(id == 0x55) parse_nvs_mode();
   else if(id == 0x60) parse_nvs_dops();
   else if(id == 0x61) parse_nvs_pvtdops();
   else if(id == 0x70) parse_nvs_version();
   else if(id == 0x72) parse_nvs_time();
   else if(id == 0x73) parse_nvs_survey();
   else if(id == 0x74) parse_nvs_timescale();
   else if(id == 0x88) parse_nvs_pvt();
   else if(id == 0x93) parse_nvs_used();
   else if(id == 0xE7) parse_nvs_rcvr_config();
   else if(id == 0xF5) parse_nvs_raw();
   else if(id == 0xF7) parse_nvs_ephem();

   if(sim_file && sim_delay) {  // throttle sim file messages
      Sleep(sim_delay);
   }
   saw_rcvr_msg = 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x194fcc(%rip), %rax    # 0x23e390
movq (%rax), %rdi
testq %rdi, %rdi
je 0xa93dd
leaq 0x195055(%rip), %rax    # 0x23e428
cmpl $0x0, (%rax)
je 0xa93dd
callq 0x9420
leaq 0x195b88(%rip), %rax    # 0x23ef6c
movl $0x0, (%rax)
leaq 0x28ee63(%rip), %rax    # 0x338254
movw $0x0, (%rax)
leaq 0x28ee55(%rip), %rcx    # 0x338252
cmpw $0x0, (%rcx)
je 0xa9413
movw $0x1, (%rax)
leaq 0x28de41(%rip), %rax    # 0x337250
movb (%rax), %bl
jmp 0xa9415
xorl %ebx, %ebx
leaq 0x195b42(%rip), %rax    # 0x23ef5e
xorl %ecx, %ecx
movb %cl, (%rax)
leaq 0x28dc02(%rip), %rax    # 0x337029
movb %cl, (%rax)
leaq 0x195b2c(%rip), %rax    # 0x23ef5c
movzwl (%rax), %eax
leaq 0x195b5e(%rip), %rcx    # 0x23ef98
incq (%rcx)
movl %eax, 0x2c2981(%rip)    # 0x36bdc4
leaq 0x195b26(%rip), %rax    # 0x23ef70
movl $0x0, (%rax)
movw $0x0, 0x2c2967(%rip)    # 0x36bdc0
xorl %edi, %edi
callq 0x7f20c
movzbl %bl, %eax
cmpl $0x60, %eax
jg 0xa948e
leal -0x41(%rax), %ecx
cmpl $0x14, %ecx
ja 0xa950c
leaq 0x76725(%rip), %rax     # 0x11fba0
movslq (%rax,%rcx,4), %rcx
addq %rax, %rcx
jmpq *%rcx
callq 0xa8086
jmp 0xa9584
cmpl $0x87, %eax
jg 0xa94b7
leal -0x70(%rax), %ecx
cmpl $0x4, %ecx
ja 0xa9518
leaq 0x76750(%rip), %rax     # 0x11fbf4
movslq (%rax,%rcx,4), %rcx
addq %rax, %rcx
jmpq *%rcx
callq 0xa88e8
jmp 0xa9584
cmpl $0xe6, %eax
jle 0xa94e8
cmpl $0xe7, %eax
je 0xa9578
cmpl $0xf5, %eax
je 0xa9571
cmpl $0xf7, %eax
jne 0xa9584
leaq 0x7cb6d(%rip), %rdi     # 0x126053
jmp 0xa9505
cmpl $0x88, %eax
je 0xa957f
cmpl $0x93, %eax
jne 0xa9584
leaq 0x7caf1(%rip), %rdi     # 0x125ff6
callq 0x58dc2
jmp 0xa9584
cmpl $0x60, %eax
jne 0xa9584
callq 0xa8820
jmp 0xa9584
cmpl $0x61, %eax
jne 0xa9584
callq 0xa8890
jmp 0xa9584
callq 0xa89fe
jmp 0xa9584
callq 0xa8aed
jmp 0xa9584
callq 0xa8ba3
jmp 0xa9584
callq 0xa8419
jmp 0xa9584
callq 0xa830d
jmp 0xa9584
callq 0xa80e4
jmp 0xa9584
callq 0xa822f
jmp 0xa9584
callq 0xa81bb
jmp 0xa9584
callq 0xa835d
jmp 0xa9584
callq 0xa859c
jmp 0xa9584
callq 0xa876a
jmp 0xa9584
callq 0xa90e1
jmp 0xa9584
callq 0xa8eb4
jmp 0xa9584
callq 0xa8cd3
leaq 0x194e35(%rip), %rax    # 0x23e3c0
cmpq $0x0, (%rax)
setne %al
leaq 0x17a067(%rip), %rcx    # 0x223600
movq (%rcx), %rdi
testq %rdi, %rdi
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0xa95ae
callq 0xafe8
leaq 0x1959eb(%rip), %rax    # 0x23efa0
movl $0x1, (%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq