mercredi 5 août 2015

How to convert double value to uint8_t string[] to print on terminal window in atmel studio


I am trying to convert some double values to uint8_t String[] (in C) when programming in Atmel Studio 6.2 in order to use it further in function: usart_write_buffer_job.

And this is the whole command I am going to use further, but instead of characters, I would like to print the given double values on the screen:

   uint8_t string[] = "Hello World!\n";
   usart_write_buffer_job(&usart_instance, string, sizeof(string));

I have tried casting, but it does not work properly in Atmel, as it does not recognize the (uint8_t*)(&MyDoubleValue)



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire