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

```asm
<get_scancode>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %edi,-0x4(%rbp)
  cmpl   $0x60,-0x4(%rbp)
  jle    L317
  cmpl   $0x7a,-0x4(%rbp)
  jg     L317
  subl   $0x20,-0x4(%rbp)
L317:
  mov    -0x4(%rbp),%eax
  sub    $0x8,%eax
  cmp    $0x77,%eax
  ja     L490
  mov    %eax,%eax
  lea    0x0(,%rax,4),%rdx
  lea    D13(%rip),%rax
  mov    (%rdx,%rax,1),%eax
  cltq
  lea    D13(%rip),%rdx
  add    %rdx,%rax
  notrack jmp *%rax
  mov    $0x100,%eax
  jmp    L445
  mov    $0x200,%eax
  jmp    L445
  mov    $0x300,%eax
  jmp    L445
  mov    $0x400,%eax
  jmp    L445
  mov    $0x500,%eax
  jmp    L445
  mov    $0x600,%eax
  jmp    L445
  mov    $0x700,%eax
  jmp    L445
  mov    $0x800,%eax
  jmp    L445
  mov    $0x900,%eax
  jmp    L445
  mov    $0xa00,%eax
  jmp    L445
  mov    $0xb00,%eax
  jmp    L445
  mov    $0xc00,%eax
  jmp    L445
  mov    $0xd00,%eax
  jmp    L445
  mov    $0xe00,%eax
  jmp    L445
  mov    $0xf00,%eax
  jmp    L445
  mov    $0x1000,%eax
  jmp    L445
  mov    $0x1100,%eax
  jmp    L445
  mov    $0x1200,%eax
  jmp    L445
  mov    $0x1300,%eax
  jmp    L445
  mov    $0x1400,%eax
  jmp    L445
  mov    $0x1500,%eax
  jmp    L445
  mov    $0x1600,%eax
  jmp    L445
  mov    $0x1700,%eax
  jmp    L445
  mov    $0x1800,%eax
  jmp    L445
  mov    $0x1900,%eax
  jmp    L445
  mov    $0x1a00,%eax
  jmp    L445
  mov    $0x1b00,%eax
  jmp    L445
  mov    $0x1c00,%eax
  jmp    L445
  mov    $0x1e00,%eax
  jmp    L445
  mov    $0x1f00,%eax
  jmp    L445
  mov    $0x2000,%eax
  jmp    L445
  mov    $0x2100,%eax
  jmp    L445
  mov    $0x2200,%eax
  jmp    L445
  mov    $0x2300,%eax
  jmp    L445
  mov    $0x2400,%eax
  jmp    L445
  mov    $0x2500,%eax
  jmp    L445
  mov    $0x2600,%eax
  jmp    L445
  mov    $0x2700,%eax
  jmp    L445
  mov    $0x2800,%eax
  jmp    L445
  mov    $0x2900,%eax
  jmp    L445
  mov    $0x2b00,%eax
  jmp    L445
  mov    $0x2c00,%eax
  jmp    L445
  mov    $0x2d00,%eax
  jmp    L445
  mov    $0x2e00,%eax
  jmp    L445
  mov    $0x2f00,%eax
  jmp    L445
  mov    $0x3000,%eax
  jmp    L445
  mov    $0x3100,%eax
  jmp    L445
  mov    $0x3200,%eax
  jmp    L445
  mov    $0x3300,%eax
  jmp    L445
  mov    $0x3400,%eax
  jmp    L445
  mov    $0x3500,%eax
  jmp    L445
  mov    $0x3900,%eax
  jmp    L445
L490:
  mov    -0x4(%rbp),%eax
  and    $0xff00,%eax
L445:
  pop    %rbp
  ret
```

assistant: ```c
int get_scancode(int i) {
  if (i >= 'a' && i <= 'z')
    i = i - 'a' + 'A';
  switch (i) {
  case 0x1b:
    return 0x0100;
  case '!':
  case '1':
    return 0x0200;
  case '@':
  case '2':
    return 0x0300;
  case '#':
  case '3':
    return 0x0400;
  case '$':
  case '4':
    return 0x0500;
  case '%':
  case '5':
    return 0x0600;
  case '^':
  case '6':
    return 0x0700;
  case '&':
  case '7':
    return 0x0800;
  case '*':
  case '8':
    return 0x0900;
  case '(':
  case '9':
    return 0x0A00;
  case ')':
  case '0':
    return 0x0B00;
  case '_':
  case '-':
    return 0x0C00;
  case '+':
  case '=':
    return 0x0D00;
  case 0x7F:
  case 0x08:
    return 0x0E00;
  case 0x09:
    return 0x0F00;
  case 'Q':
    return 0x1000;
  case 'W':
    return 0x1100;
  case 'E':
    return 0x1200;
  case 'R':
    return 0x1300;
  case 'T':
    return 0x1400;
  case 'Y':
    return 0x1500;
  case 'U':
    return 0x1600;
  case 'I':
    return 0x1700;
  case 'O':
    return 0x1800;
  case 'P':
    return 0x1900;
  case '{':
  case '[':
    return 0x1A00;
  case '}':
  case ']':
    return 0x1B00;
  case 0x0D:
    return 0x1C00;
  case 'A':
    return 0x1E00;
  case 'S':
    return 0x1F00;
  case 'D':
    return 0x2000;
  case 'F':
    return 0x2100;
  case 'G':
    return 0x2200;
  case 'H':
    return 0x2300;
  case 'J':
    return 0x2400;
  case 'K':
    return 0x2500;
  case 'L':
    return 0x2600;
  case ':':
  case ';':
    return 0x2700;
  case '\'':
  case '"':
    return 0x2800;
  case '`':
  case '~':
    return 0x2900;
  case '\\':
  case '|':
    return 0x2B00;
  case 'Z':
    return 0x2C00;
  case 'X':
    return 0x2D00;
  case 'C':
    return 0x2E00;
  case 'V':
    return 0x2F00;
  case 'B':
    return 0x3000;
  case 'N':
    return 0x3100;
  case 'M':
    return 0x3200;
  case ',':
  case '<':
    return 0x3300;
  case '.':
  case '>':
    return 0x3400;
  case '/':
  case '?':
    return 0x3500;
  case ' ':
    return 0x3900;
  default:
    return i & 0xFF00;
  }
}
```