Binary reading working sometimes