for(int x=0; x<100; x++) {
if(gps_buffer[x]=='*'){
checksum_received = strtol(&gps_buffer[x + 1], NULL, 16);//Parsing received checksum...
break;
}
}
That means:
Look at each of the first 100 characters in the buffer.
If that character is an asterisk (the NMEA marker for the checksum):
Convert the hexadecimal (base 16) digits starting after the '*' into a long integer and store it in "checksum_received".
Stop looking at any further characters since you already found the checksum (break out of the FOR loop)