Changed to explicity deal with binary vs text output.