I have the following program in which I need to convert my_string to an integer because it has some alphabets and numbers. I get the integer value in value_i variable. I have checked that with if statement but now I need to be sure that I have extracted the integer value correctly. The function "itoa" does not work if I enable the statement.
int value_i;
char value_s[4];
value_i = atoi(my_string); // This statement is working
// itoa(value_i, value_s, 4); // I get error when I enable the statement.
EUSART_Write("\n\rThe value is: \n\r");
EUSART_Write(value_s);