Binary encoder and decoder from/to text or multiple number formats