Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
unsigned char *fat_pad(unsigned char *str)
{
int pc = 0, sc = 0; // pc = paded count, sc = str count
while(str[sc] != '\0') // while more left in string
{
if(str[sc] == '.') // if dot
{
for(; pc < 8; pc++) // untill 8
paded[pc] = ' '; // space pad
sc++; // jump over dot
}
paded[pc] = str[sc]; // reg letter just transfer
pc++; sc++; // move 1 letter ahead
}
return paded; // return new string
}