user: Demonstrate the C code that generates the assembly output below:

```asm
<SelectGySleep>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %edi,%eax
  mov    %al,-0x14(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  cmpb   $0x1,-0x14(%rbp)
  jne    L21
  mov    $0x0,%esi
  mov    $0x101,%edi
  call   <RegWriteA@plt>
  mov    $0x1,%esi
  mov    $0x280,%edi
  call   <RegWriteA@plt>
  lea    -0x9(%rbp),%rax
  mov    %rax,%rsi
  mov    $0x281,%edi
  call   <RegReadA@plt>
  movzbl -0x9(%rbp),%eax
  or     $0x4,%eax
  movzbl %al,%eax
  mov    %eax,%esi
  mov    $0x281,%edi
  call   <RegWriteA@plt>
  mov    $0x6b,%esi
  mov    $0x283,%edi
  call   <RegWriteA@plt>
  mov    $0x1,%esi
  mov    $0x282,%edi
  call   <RegWriteA@plt>
  mov    $0x1,%edi
  call   <AccWit@plt>
  lea    -0xa(%rbp),%rax
  mov    %rax,%rsi
  mov    $0x290,%edi
  call   <RegReadA@plt>
  movzbl -0xa(%rbp),%eax
  or     $0x40,%eax
  mov    %al,-0xa(%rbp)
  mov    $0x6b,%esi
  mov    $0x283,%edi
  call   <RegWriteA@plt>
  movzbl -0xa(%rbp),%eax
  movzbl %al,%eax
  mov    %eax,%esi
  mov    $0x28a,%edi
  call   <RegWriteA@plt>
  mov    $0x10,%esi
  mov    $0x282,%edi
  call   <RegWriteA@plt>
  mov    $0x10,%edi
  call   <AccWit@plt>
  jmp    L9
L21:
  mov    $0x6b,%esi
  mov    $0x283,%edi
  call   <RegWriteA@plt>
  mov    $0x1,%esi
  mov    $0x282,%edi
  call   <RegWriteA@plt>
  mov    $0x1,%edi
  call   <AccWit@plt>
  lea    -0xa(%rbp),%rax
  mov    %rax,%rsi
  mov    $0x290,%edi
  call   <RegReadA@plt>
  movzbl -0xa(%rbp),%eax
  and    $0xffffffbf,%eax
  mov    %al,-0xa(%rbp)
  movzbl -0xa(%rbp),%eax
  movzbl %al,%eax
  mov    %eax,%esi
  mov    $0x28a,%edi
  call   <RegWriteA@plt>
  mov    $0x10,%esi
  mov    $0x282,%edi
  call   <RegWriteA@plt>
  mov    $0x10,%edi
  call   <AccWit@plt>
  lea    -0x9(%rbp),%rax
  mov    %rax,%rsi
  mov    $0x281,%edi
  call   <RegReadA@plt>
  movzbl -0x9(%rbp),%eax
  movzbl %al,%eax
  and    $0xfffffffb,%eax
  mov    %eax,%esi
  mov    $0x281,%edi
  call   <RegWriteA@plt>
  mov    $0x0,%eax
  call   <GyOutSignal@plt>
  mov    $0x32,%edi
  call   <WitTim@plt>
  mov    $0x1,%esi
  mov    $0x101,%edi
  call   <RegWriteA@plt>
  mov    $0x2,%esi
  mov    $0x7f,%edi
  call   <ClrGyr@plt>
L9:
  nop
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L23
  call   <__stack_chk_fail@plt>
L23:
  leave
  ret
```

assistant: ```c
void SelectGySleep(unsigned char UcSelMode) {
  unsigned char UcRamIni;
  unsigned char UcGrini;
  if (UcSelMode == 0x01) {
    RegWriteA(0x0101, 0x00);
    RegWriteA(0x0280, 0x01);
    RegReadA(0x0281, &UcGrini);
    RegWriteA(0x0281, (UcGrini | 0x04));
    RegWriteA(0x0283, 0x6B);
    RegWriteA(0x0282, 0x01);
    AccWit(0x01);
    RegReadA(0x0290, &UcRamIni);
    UcRamIni |= 0x40;
    RegWriteA(0x0283, 0x6B);
    RegWriteA(0x028A, UcRamIni);
    RegWriteA(0x0282, 0x10);
    AccWit(0x10);
  } else {
    RegWriteA(0x0283, 0x6B);
    RegWriteA(0x0282, 0x01);
    AccWit(0x01);
    RegReadA(0x0290, &UcRamIni);
    UcRamIni &= ~0x40;
    RegWriteA(0x028A, UcRamIni);
    RegWriteA(0x0282, 0x10);
    AccWit(0x10);
    RegReadA(0x0281, &UcGrini);
    RegWriteA(0x0281, (UcGrini & ~0x04));
    GyOutSignal();
    WitTim(50);
    RegWriteA(0x0101, 0x01);
    ClrGyr(0x007F, 0x02);
  }
}
```