Thanks all!
So - this is part of my code:
void loop(){
if (Serial.available()==0)
{
timeout++;
}
if (timeout>1500)
{
flag=50; //This is for sending over i2c
for (byte i=0; i<10; i++){ //This is RESET sequence emulation
digitalWrite(9, HIGH);
delay(100);
digitalWrite(9, LOW);
delay(100);
}
}
/*Serial.print("timeout="); // for control only
Serial.println(timeout);
Serial.print("flag=");
Serial.println(flag);
*/
while (Serial.available() > 0){
timeout =0;
gps.encode(Serial.read());
}
---------CUT----------
i use a little delay(300) in end of main loop - this is acceptable for my task and timeout variable not increased to fast.