code: def parse_args():
      
      global default_device
  
      parser = argparse.ArgumentParser(description = "Validate YubiKey OTP's using YubiHSM",
                                       add_help=True
                                       )
      parser.add_argument('-D', '--device',
                          dest='device',
                          default=default_device,
                          required=False,
                          help='YubiHSM device (default : %s).' % default_device
                          )
      parser.add_argument('-v', '--verbose',
                          dest='verbose',
                          action='store_true', default=False,
                          help='Enable verbose operation.'
                          )
      parser.add_argument('--debug',
                          dest='debug',
                          action='store_true', default=False,
                          help='Enable debug operation.'
                          )
      group = parser.add_argument_group('Modes', 'What you want to validate')
      mode_group = group.add_mutually_exclusive_group(required = True)
      mode_group.add_argument('--otp',
                              dest='otp',
                              help='The output from your YubiKey.'
                              )
      mode_group.add_argument('--oath',
                              dest='oath',
                              help='The output from your OATH-HOTP token.'
                              )
  
      args = parser.parse_args()
      return args
docs: Parse the command line arguments