writing values received from serial to eeprom

I want to write the values received from the serial to different locations in the eeprom. the issue i face is mismatch of data type. The value i get from serial is a Char value and i need to covert it to a int to store in the eeprom location. I tried using the iota method but in vain. can someone help me to solve this issue.

Have you tried the union method?

I tried using the iota method but in vain. can someone help me to solve this issue.

Using the itoa() function - integer to ASCII - makes no sense. Using the atoi() function - ASCII to integer - does.