Nios/bcd8
From ASMBits
nios/bcd2Previous
Nextnios/normalize
Binary-coded decimal is a method to represent decimal numbers encoded into binary. It uses each group of 4 bits (which can normally represent numbers from 0 to 15) to represent one decimal digit (of values 0 to 9).
Write a function that converts a number into its BCD representation. You are guaranteed that the input number will be between 0 and 99999999.
Sample Input
10
Sample Output
0x10
nios/bcd2Previous
Nextnios/normalize