code: def _unrecognised(chr):
      
      if options['handleUnrecognised'] == UNRECOGNISED_ECHO:
          return chr
      elif options['handleUnrecognised'] == UNRECOGNISED_SUBSTITUTE:
          return options['substituteChar']
      else:
          raise (KeyError, chr)
docs: Handle unrecognised characters.