## ABSTRACT

Data conversion instructions convert the contents of a variable from one format to another. The following conversion macros are described in this chapter: Conv_UsInt_2_BCD_U (Unsigned Short Integer to Unpacked BCD Conversion), Conv_UsInt_2_BCD_P (Unsigned Short Integer to Packed BCD Conversion), Conv_UInt_2_BCD_U (Unsigned Integer to Unpacked BCD Conversion), Conv_UInt_2_BCD_P (Unsigned Integer to Packed BCD Conversion), Conv_BCD_U_2_UInt (5 Digit Unpacked BCD to Unsigned Integer Conversion), Conv_BCD_P_2_UInt (5 Digit Packed BCD to Unsigned Integer Conversion), Segment_CCD (Segment_CCD Instruction), Segment_CAD (Segment_CAD Instruction), Conv_Bin_2_Gray (Binary to Gray Code Conversion), Conv_Bin_2_Gray_16 (Binary to Gray Code Conversion), Conv_Gray_2_Bin (Gray Code to Binary Conversion), Conv_Gray_2_Bin_16 (Gray Code to Binary Conversion). Twelve examples are considered to show the application of conversion macros presented in this chapter.