PTD Encode / Decode Tool