Changing double to character array in Android
I need to change a double into a character array. In other words I have a variable that is a double and I would like to represent it as a character array. I want to do this because I am using the USB port on my Nexus On开发者_运维技巧e as a serial port and the only way I can get it to work is to send characters and I have GPS data that I want to send out which are doubles.
char[] characters = String.valueOf(myDoubleVariable).toCharArray();
精彩评论