translating hex strings into reg strings