// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: parse_star_inv()
void parse_star_inv()    
{
   // hardware version info
   log_packet_id("Star inventory");

   if(star_type == OSA_TYPE) {
      msg_col = 5;     // index of next char to get from nmea buffer
      if(get_fixed_field(12)) {
         strcpy(star_module, msg_field);
         osa_model = atoi(star_module);
         if(set_al_mask) {  // set alarm mask the first time through here
            set_al_mask = 0;
            if(osa_model != 4530) queue_star_cmd("AL_MASK=0000000", STAR_ALMASK_MSG); // enable all alarms !!!! 4531
            else                  queue_star_cmd("AL_MASK=000000", STAR_ALMASK_MSG); // enable all alarms !!!! 4531
            queue_star_cmd("AL_MASK", STAR_ALMASK_MSG);
         }
      }
      if(get_fixed_field(12)) {
         strcpy(star_article, msg_field);
      }
      if(get_fixed_field(6)) {
         strcpy(star_commercial, msg_field);
      }
      if(get_fixed_field(5)) {
         strcpy(star_sn, msg_field);
      }
      if(get_fixed_field(2)) {  // layout version
         strcpy(star_layout, msg_field);
      }
      if(get_fixed_field(4)) {
         strcpy(star_fw, msg_field);
      }
      if(get_fixed_field(8)) {
         strcpy(star_test_date, msg_field);
      }
      if(get_fixed_field(8)) {  // reserved
      }
      if(get_fixed_field(4)) {
         strcpy(star_test_version, msg_field);
      }
      if(get_fixed_field(10)) {
         strcpy(star_osc, msg_field);
      }

      have_info |= ALL_ID_INFO;
   }
   else {
      if(get_msg_field()) {  // a: name of module (12 chars)
         msg_field[12] = 0;
         if(star_module[0] == 0) need_redraw = 5478;  // just got the inventory
         strcpy(star_module, msg_field);
         if(strstr(msg_field, "NEC")) star_type = NEC_TYPE;
         else star_type = STAR4_TYPE;
      }

      if(get_msg_field()) {  // b: article number (6 chars) 
         msg_field[6] = 0;
         strcpy(star_article, msg_field);
      }

      if(get_msg_field()) {  // c: serial number (6 chars) 
         msg_field[6] = 0;
         strcpy(star_sn, msg_field);
      }

      if(get_msg_field()) {  // d: hardware version (2 chars) 
         msg_field[2] = 0;
         strcpy(star_hw_ver, msg_field);
      }

      if(get_msg_field()) {  // e: firmware article (6 chars) 
         msg_field[6] = 0;
         strcpy(star_fw_article, msg_field);
      }

      if(get_msg_field()) {  // f: fw version
         msg_field[12] = 0;
         strcpy(star_fw, msg_field);
      }

      if(get_msg_field()) {  // g: date of test (ddmmyyyy)
         msg_field[8] = 0;
         strcpy(star_test_date, msg_field);
      }

      if(get_msg_field()) {  // h: test system version (4 chars) 
         msg_field[4] = 0;
         strcpy(star_test_version, msg_field);
      }

      if(get_msg_field()) {  // i: osc type (10 chars) 
         msg_field[10] = 0;
         strcpy(star_osc, msg_field);
      }

      if(get_msg_field()) {  // j: fpga version
         msg_field[12] = 0;
         strcpy(star_fpga, msg_field);
      }

      have_info |= ALL_ID_INFO;
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x91d3e(%rip), %rdi     # 0x124498
callq 0x58dc2
leaq 0x188882(%rip), %r14    # 0x21afe8
cmpl $0x4f, (%r14)
jne 0x92906
leaq 0x2a94cd(%rip), %rax    # 0x33bc44
movl $0x5, (%rax)
movl $0xc, %edi
callq 0x83d8c
testl %eax, %eax
je 0x927f7
leaq 0x2ab4e4(%rip), %rbx    # 0x33dc76
leaq 0x2a92a7(%rip), %rsi    # 0x33ba40
movq %rbx, %rdi
callq 0x9340
movq %rbx, %rdi
callq 0x95e0
leaq 0x18883c(%rip), %rcx    # 0x21afec
movl %eax, (%rcx)
cmpl $0x0, 0x2da46f(%rip)    # 0x36cc28
je 0x927f7
movl $0x0, 0x2da463(%rip)    # 0x36cc28
cmpl $0x11b2, %eax           # imm = 0x11B2
leaq 0x91ce6(%rip), %rax     # 0x1244b7
leaq 0x91ccf(%rip), %rdi     # 0x1244a7
cmoveq %rax, %rdi
movl $0xc9, %esi
callq 0x5edda
leaq 0x91cd9(%rip), %rdi     # 0x1244c6
movl $0xc9, %esi
callq 0x5edda
movl $0xc, %edi
callq 0x83d8c
testl %eax, %eax
je 0x92818
leaq 0x2ab477(%rip), %rdi    # 0x33dc83
leaq 0x2a922d(%rip), %rsi    # 0x33ba40
callq 0x9340
movl $0x6, %edi
callq 0x83d8c
testl %eax, %eax
je 0x92839
leaq 0x2ab4a4(%rip), %rdi    # 0x33dcd1
leaq 0x2a920c(%rip), %rsi    # 0x33ba40
callq 0x9340
movl $0x5, %edi
callq 0x83d8c
testl %eax, %eax
je 0x9285a
leaq 0x2ab442(%rip), %rdi    # 0x33dc90
leaq 0x2a91eb(%rip), %rsi    # 0x33ba40
callq 0x9340
movl $0x2, %edi
callq 0x83d8c
testl %eax, %eax
je 0x9287b
leaq 0x2ab455(%rip), %rdi    # 0x33dcc4
leaq 0x2a91ca(%rip), %rsi    # 0x33ba40
callq 0x9340
movl $0x4, %edi
callq 0x83d8c
testl %eax, %eax
je 0x9289c
leaq 0x2ab427(%rip), %rdi    # 0x33dcb7
leaq 0x2a91a9(%rip), %rsi    # 0x33ba40
callq 0x9340
movl $0x8, %edi
callq 0x83d8c
testl %eax, %eax
je 0x928bd
leaq 0x2ab42d(%rip), %rdi    # 0x33dcde
leaq 0x2a9188(%rip), %rsi    # 0x33ba40
callq 0x9340
movl $0x8, %edi
callq 0x83d8c
movl $0x4, %edi
callq 0x83d8c
testl %eax, %eax
je 0x928e8
leaq 0x2ab40f(%rip), %rdi    # 0x33dceb
leaq 0x2a915d(%rip), %rsi    # 0x33ba40
callq 0x9340
movl $0xa, %edi
callq 0x83d8c
testl %eax, %eax
je 0x92a92
leaq 0x2ab3f7(%rip), %rdi    # 0x33dcf8
jmp 0x92a86
callq 0x810b1
testl %eax, %eax
je 0x9296b
leaq 0x2a912a(%rip), %rax    # 0x33ba40
movb $0x0, 0xc(%rax)
leaq 0x2ab355(%rip), %rax    # 0x33dc76
cmpb $0x0, (%rax)
jne 0x92933
leaq 0x185f17(%rip), %rax    # 0x218844
movl $0x1566, (%rax)         # imm = 0x1566
leaq 0x2ab33c(%rip), %rdi    # 0x33dc76
leaq 0x2a90ff(%rip), %rbx    # 0x33ba40
movq %rbx, %rsi
callq 0x9340
leaq 0x91b7e(%rip), %rsi     # 0x1244ce
movq %rbx, %rdi
callq 0x9090
testq %rax, %rax
movl $0x34, %eax
movl $0x4e, %ecx
cmovel %eax, %ecx
movl %ecx, (%r14)
callq 0x810b1
testl %eax, %eax
je 0x9298b
leaq 0x2a90c5(%rip), %rsi    # 0x33ba40
movb $0x0, 0x6(%rsi)
leaq 0x2ab2fd(%rip), %rdi    # 0x33dc83
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x929ab
leaq 0x2a90a5(%rip), %rsi    # 0x33ba40
movb $0x0, 0x6(%rsi)
leaq 0x2ab2ea(%rip), %rdi    # 0x33dc90
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x929cb
leaq 0x2a9085(%rip), %rsi    # 0x33ba40
movb $0x0, 0x2(%rsi)
leaq 0x2ab2d7(%rip), %rdi    # 0x33dc9d
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x929eb
leaq 0x2a9065(%rip), %rsi    # 0x33ba40
movb $0x0, 0x6(%rsi)
leaq 0x2ab2c4(%rip), %rdi    # 0x33dcaa
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x92a0b
leaq 0x2a9045(%rip), %rsi    # 0x33ba40
movb $0x0, 0xc(%rsi)
leaq 0x2ab2b1(%rip), %rdi    # 0x33dcb7
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x92a2b
leaq 0x2a9025(%rip), %rsi    # 0x33ba40
movb $0x0, 0x8(%rsi)
leaq 0x2ab2b8(%rip), %rdi    # 0x33dcde
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x92a4b
leaq 0x2a9005(%rip), %rsi    # 0x33ba40
movb $0x0, 0x4(%rsi)
leaq 0x2ab2a5(%rip), %rdi    # 0x33dceb
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x92a6b
leaq 0x2a8fe5(%rip), %rsi    # 0x33ba40
movb $0x0, 0xa(%rsi)
leaq 0x2ab292(%rip), %rdi    # 0x33dcf8
callq 0x9340
callq 0x810b1
testl %eax, %eax
je 0x92a92
leaq 0x2a8fc5(%rip), %rax    # 0x33ba40
movb $0x0, 0xc(%rax)
leaq 0x2ab27f(%rip), %rdi    # 0x33dd05
leaq 0x2a8fb3(%rip), %rsi    # 0x33ba40
callq 0x9340
leaq 0x27aedb(%rip), %rax    # 0x30d974
orb $0xf, (%rax)
popq %rbx
popq %r14
popq %rbp
retq