cancel
Showing results for 
Search instead for 
Did you mean: 

conversion of decimal/hexadecimal in ascii characters

aatif
Associate II
Posted on April 18, 2015 at 23:58

Hi,

I am writing data on my sd card through spi in stm32f429zi controller using library of fatFs by chan. But after writing the data when i check the file it shows strange characters instead of the data entered. Later i came to know that the result shown is correct but in ascii characters for instance i entered 0x12345678 and result that came was xV4&&sharp18;|.

Please help me in getting the desired result.

Regards

#clive1
1 REPLY 1
Posted on April 19, 2015 at 00:04

Well there's sprintf() and itoa()? Or you can divide the number down an generate the digits in ASCII.

https://my.st.com/public/STe2ecommunities/mcu/Lists/STM32Discovery/flat.aspx?RootFolder=/public/STe2ecommunities/mcu/Lists/STM32Discovery/usart%20stm32f0&FolderCTID=0x01200200770978C69A1141439FE559EB459D75800084C20D8867EAD444A5987D47BE638E0F&currentviews=376

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..