Forum Discussion
Altera_Forum
Honored Contributor
11 years agoHow to read a 16-bit data into string in C code
I have a 16-bit data that is fed from FPGA in vhdl, The NIos II processor reads the 16-bit data from FPGA and do some processing tasks, where Nios II system is programmed in C code How could...
Altera_Forum
Honored Contributor
11 years agoC doesn't support that directly. So, I suggest you write yourself a function to do so. Have a look at the following link - I'm sure it'll point you in the right direction.
http://www.programmingsimplified.com/c/source-code/c-program-convert-decimal-to-binary (http://www.programmingsimplified.com/c/source-code/c-program-convert-decimal-to-binary) Cheers, Alex