139
If it's just a single character 0-9 in ASCII, then subtracting the the value of the ASCII zero character from ASCII value should work fine.
If you want to convert larger numbers then the following will do:
char *string = "24";
int value;
int assigned = sscanf(string, "%d", &value);
** don't forget to check the status (which should be 1 if it worked in the above case).
Paul.