function from txt to bin
function from txt to bin