user: 请将以下的汇编代码转换成C语言代码:

```asm
<fc8300_set_cal_front_1seg>:
  endbr64
  push   %r12
  mov    %rdi,%r12
  push   %rbp
  sub    $0x8,%rsp
  cmp    $0x19000,%edx
  je     L517
  ja     L76
  cmp    $0x186a0,%edx
  je     L193
  jbe    L28
  cmp    $0x18b82,%edx
  je     L270
  jbe    L112
  cmp    $0x18c00,%edx
  je     L108
  cmp    $0x18d44,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x2dea,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3d5f3,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x215ecccd,%ecx
  nopl   (%rax)
L283:
  mov    $0x103c,%edx
  mov    %ebp,%esi
  mov    %r12,%rdi
  call   <bbm_long_write@plt>
  xor    %eax,%eax
L337:
  add    $0x8,%rsp
  pop    %rbp
  pop    %r12
  ret
L112:
  cmp    $0x1898e,%edx
  je     L403
  cmp    $0x189c0,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x2e53,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3deb8,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x21133333,%ecx
  jmp    L283
  nopl   0x0(%rax,%rax,1)
L28:
  cmp    $0x18000,%edx
  je     L347
  jbe    L51
  cmp    $0x18006,%edx
  je     L505
  cmp    $0x182b8,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x2f2b,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3f0bb,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x207c0000,%ecx
  jmp    L283
  nopl   0x0(%rax)
L76:
  cmp    $0x1a405,%edx
  je     L5
  jbe    L280
  cmp    $0x1b3f0,%edx
  je     L286
  jbe    L496
  cmp    $0x1b580,%edx
  je     L138
  cmp    $0x1b648,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x299e,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x37a0f,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x24d0cccd,%ecx
  jmp    L283
  xchg   %ax,%ax
L51:
  cmp    $0x17e53,%edx
  je     L61
  cmp    $0x17f7f,%edx
  jne    L320
  movzwl %si,%ebp
  mov    $0x2f90,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3f935,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x2036b333,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L496:
  cmp    $0x1a5e0,%edx
  je     L321
  cmp    $0x1af40,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x2a4c,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x38892,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x2439999a,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L280:
  cmp    $0x19640,%edx
  je     L16
  jbe    L98
  cmp    $0x19c80,%edx
  je     L381
  cmp    $0x1a2f2,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x2b8a,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3a323,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x23310000,%ecx
  jmp    L283
  nopl   0x0(%rax)
L320:
  cmp    $0x17d72,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x2fd1,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3fead,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x200a999a,%ecx
  jmp    L283
  xchg   %ax,%ax
L98:
  cmp    $0x191c2,%edx
  je     L117
  cmp    $0x192d5,%edx
  jne    L282
  movzwl %si,%ebp
  mov    $0x2d48,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3c862,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x21d68000,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L517:
  movzwl %si,%ebp
  mov    $0x2d9a,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3cf3d,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x2199999a,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L117:
  movzwl %si,%ebp
  mov    $0x2d67,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3caf9,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x21bf6666,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L381:
  movzwl %si,%ebp
  mov    $0x2c38,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3b1af,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x22a66666,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L16:
  movzwl %si,%ebp
  mov    $0x2ce6,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3c03c,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x22200000,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L321:
  movzwl %si,%ebp
  mov    $0x2b3c,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x39cac,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x23700000,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L61:
  movzwl %si,%ebp
  mov    $0x2fb5,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3fc53,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x201d8000,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L138:
  movzwl %si,%ebp
  mov    $0x29b1,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x37ba5,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x24c00000,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L286:
  movzwl %si,%ebp
  mov    $0x29d7,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x37ed8,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x249e6666,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L5:
  movzwl %si,%ebp
  mov    $0x2b6d,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3a0c1,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x2348199a,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L505:
  movzwl %si,%ebp
  mov    $0x2f7f,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3f7d0,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x20420a3d,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L347:
  movzwl %si,%ebp
  mov    $0x2f80,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3f7df,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x20418937,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L403:
  movzwl %si,%ebp
  mov    $0x2e59,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3df36,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x210f0000,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L108:
  movzwl %si,%ebp
  mov    $0x2e10,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3d917,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x21439581,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L270:
  movzwl %si,%ebp
  mov    $0x2e1e,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3da51,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x21390000,%ecx
  jmp    L283
  nopw   0x0(%rax,%rax,1)
L193:
  movzwl %si,%ebp
  mov    $0x2eb2,%ecx
  mov    $0x1032,%edx
  mov    %ebp,%esi
  call   <bbm_word_write@plt>
  mov    $0x3e6a5,%ecx
  mov    %ebp,%esi
  mov    %r12,%rdi
  mov    $0x2008,%edx
  call   <bbm_long_write@plt>
  mov    $0x20d00000,%ecx
  jmp    L283
L282:
  mov    $0x1,%eax
  jmp    L337
```

assistant: ```c
int fc8300_set_cal_front_1seg(void *handle, unsigned short devid, unsigned int clk) {
  switch (clk) {
  case 97650:
    bbm_word_write(handle, devid, 0x1032, 0x2fd1);
    bbm_long_write(handle, devid, 0x2008, 0x3fead);
    bbm_long_write(handle, devid, 0x103c, 0x200a999a);
    break;
  case 97875:
    bbm_word_write(handle, devid, 0x1032, 0x2fb5);
    bbm_long_write(handle, devid, 0x2008, 0x3fc53);
    bbm_long_write(handle, devid, 0x103c, 0x201d8000);
    break;
  case 98175:
    bbm_word_write(handle, devid, 0x1032, 0x2f90);
    bbm_long_write(handle, devid, 0x2008, 0x3f935);
    bbm_long_write(handle, devid, 0x103c, 0x2036b333);
    break;
  case 98304:
    bbm_word_write(handle, devid, 0x1032, 0x2f80);
    bbm_long_write(handle, devid, 0x2008, 0x3f7df);
    bbm_long_write(handle, devid, 0x103c, 0x20418937);
    break;
  case 98310:
    bbm_word_write(handle, devid, 0x1032, 0x2f7f);
    bbm_long_write(handle, devid, 0x2008, 0x3f7d0);
    bbm_long_write(handle, devid, 0x103c, 0x20420a3d);
    break;
  case 99000:
    bbm_word_write(handle, devid, 0x1032, 0x2f2b);
    bbm_long_write(handle, devid, 0x2008, 0x3f0bb);
    bbm_long_write(handle, devid, 0x103c, 0x207c0000);
    break;
  case 100000:
    bbm_word_write(handle, devid, 0x1032, 0x2eb2);
    bbm_long_write(handle, devid, 0x2008, 0x3e6a5);
    bbm_long_write(handle, devid, 0x103c, 0x20d00000);
    break;
  case 100750:
    bbm_word_write(handle, devid, 0x1032, 0x2e59);
    bbm_long_write(handle, devid, 0x2008, 0x3df36);
    bbm_long_write(handle, devid, 0x103c, 0x210f0000);
    break;
  case 100800:
    bbm_word_write(handle, devid, 0x1032, 0x2e53);
    bbm_long_write(handle, devid, 0x2008, 0x3deb8);
    bbm_long_write(handle, devid, 0x103c, 0x21133333);
    break;
  case 101250:
    bbm_word_write(handle, devid, 0x1032, 0x2e1e);
    bbm_long_write(handle, devid, 0x2008, 0x3da51);
    bbm_long_write(handle, devid, 0x103c, 0x21390000);
    break;
  case 101376:
    bbm_word_write(handle, devid, 0x1032, 0x2e10);
    bbm_long_write(handle, devid, 0x2008, 0x3d917);
    bbm_long_write(handle, devid, 0x103c, 0x21439581);
    break;
  case 101700:
    bbm_word_write(handle, devid, 0x1032, 0x2dea);
    bbm_long_write(handle, devid, 0x2008, 0x3d5f3);
    bbm_long_write(handle, devid, 0x103c, 0x215ecccd);
    break;
  case 102400:
    bbm_word_write(handle, devid, 0x1032, 0x2d9a);
    bbm_long_write(handle, devid, 0x2008, 0x3cf3d);
    bbm_long_write(handle, devid, 0x103c, 0x2199999a);
    break;
  case 102850:
    bbm_word_write(handle, devid, 0x1032, 0x2d67);
    bbm_long_write(handle, devid, 0x2008, 0x3caf9);
    bbm_long_write(handle, devid, 0x103c, 0x21bf6666);
    break;
  case 103125:
    bbm_word_write(handle, devid, 0x1032, 0x2d48);
    bbm_long_write(handle, devid, 0x2008, 0x3c862);
    bbm_long_write(handle, devid, 0x103c, 0x21d68000);
    break;
  case 104000:
    bbm_word_write(handle, devid, 0x1032, 0x2ce6);
    bbm_long_write(handle, devid, 0x2008, 0x3c03c);
    bbm_long_write(handle, devid, 0x103c, 0x22200000);
    break;
  case 105600:
    bbm_word_write(handle, devid, 0x1032, 0x2c38);
    bbm_long_write(handle, devid, 0x2008, 0x3b1af);
    bbm_long_write(handle, devid, 0x103c, 0x22a66666);
    break;
  case 107250:
    bbm_word_write(handle, devid, 0x1032, 0x2b8a);
    bbm_long_write(handle, devid, 0x2008, 0x3a323);
    bbm_long_write(handle, devid, 0x103c, 0x23310000);
    break;
  case 107525:
    bbm_word_write(handle, devid, 0x1032, 0x2b6d);
    bbm_long_write(handle, devid, 0x2008, 0x3a0c1);
    bbm_long_write(handle, devid, 0x103c, 0x2348199a);
    break;
  case 108000:
    bbm_word_write(handle, devid, 0x1032, 0x2b3c);
    bbm_long_write(handle, devid, 0x2008, 0x39cac);
    bbm_long_write(handle, devid, 0x103c, 0x23700000);
    break;
  case 110400:
    bbm_word_write(handle, devid, 0x1032, 0x2a4c);
    bbm_long_write(handle, devid, 0x2008, 0x38892);
    bbm_long_write(handle, devid, 0x103c, 0x2439999a);
    break;
  case 111600:
    bbm_word_write(handle, devid, 0x1032, 0x29d7);
    bbm_long_write(handle, devid, 0x2008, 0x37ed8);
    bbm_long_write(handle, devid, 0x103c, 0x249e6666);
    break;
  case 112000:
    bbm_word_write(handle, devid, 0x1032, 0x29b1);
    bbm_long_write(handle, devid, 0x2008, 0x37ba5);
    bbm_long_write(handle, devid, 0x103c, 0x24c00000);
    break;
  case 112200:
    bbm_word_write(handle, devid, 0x1032, 0x299e);
    bbm_long_write(handle, devid, 0x2008, 0x37a0f);
    bbm_long_write(handle, devid, 0x103c, 0x24d0cccd);
    break;
  default:
    return 1;
  }
  return 0;
}
```