Cant figure out what Im doing wrong here

Hello I,m trying to build a chronograph just Using AVR 16 bit timer and interrupts .im using an ATmega8A running at 8Mhz with External crystal. I was using an Overflow interrupt to count seconds that should be 122 overflows per second at /1 prescaler . well look and see if you can see my problems it,s not working as expected …

//------------------------ATmega8-16-bit-timer
#define F_CPU 8000000
#include <avr/io.h>
#include <avr/interrupt.h>
#include <util/delay.h>
#include <Wire.h>//MUST include for LCD to work
#include <LiquidCrystal_I2C.h>//MUST include for LCD to work

LiquidCrystal_I2C lcd(0x27,16,2); //MUST have for LCD to work with I2C on ATmega 

 volatile uint16_t overflows = 0;
 volatile uint8_t Seconds = 0;
 volatile uint16_t Time0 = 0;
 volatile uint16_t Time1 = 0;
 volatile uint16_t result = 0;

void setup(void)
{   
    lcd.init();                      // initialize the lcd 
    // Print a message to the LCD.
    lcd.backlight();
    
    GICR = 0b11000000;//-General Interrupt Control Register turn on external INT0 and INT1
    MCUCR = 0b00000110;//--INTERRUPT-SENSE-CONTROL-SET-TO-FALLING-EDGE on both inerrupts
    DDRB = 0b00000001; //enable PORTB0 as OUTPUT  
   // TIMSK = 0b00000100 ;//--OVERFLOW INTERRUPT  
    sei();  // enable global interrupts
    lcd.setCursor(0,0);
    lcd.print("  it,s alive  ");
    delay(2000);
}//end setup

void loop(void)
    {

    result = Time1 - Time0 ; 
    lcd.setCursor(0,0);
    lcd.print("Result ");
    lcd.print(result);
    lcd.print("        ");
    lcd.setCursor(0,1);
    lcd.print("Seconds ");
    lcd.print(Seconds);
    lcd.print("          ");
    delay(500);
    
}//end loop

//-------------------------------------
ISR (INT0_vect)
{
  TCCR1B = 0b00000001;//--START-timer-no prescaling 
  Time0 = TCNT1;  
}
//-------------------------------------
ISR (INT1_vect)
{ 
  Time1 = TCNT1; 
//  TCCR1B = 0b00000000;//--CLEAR-Timer 
  //TIMSK = 0x00 ;//--OVERFLOW INTERRUPT RESET
}
//---------------------------------------

ISR(TIMER1_OVF_vect)
{
 
    overflows++; 
    
    if (overflows >= 122) // NOTE: '>=' used instead of '=='
    {
       Seconds++;
        overflows = 0;   // reset overflow counter
    }
    if(Seconds >= 6){Seconds = 0;PORTB ^= 0b00000001; }
}

it,s not working as expected

What is it doing?
Rewriting Shakespeare's sonnets as rap?

// TIMSK = 0b00000100 ;

well the Seconds variable seems to be incremented way faster than once per second which is throwing off my calculations for slow moving objects ..

I,m trying to build a chronograph

It’s very easy to use the input capture of timer 1

Have a look at Nick Gammon’s own forum for useful examples.

hmmmm ? I will look into that I,m not a pro I was going for an accurate time but.. Ill have to work on using input capture

OK input capture is only on one PIN that is why i was using interrpts . I wanted to use two pins

I,m not a pro I was going for an accurate time

Input capture can get down to processor clock rate - at 8MHz, that's 125ns.

What's the big deal about two pins?

bandmwhitt2013:
OK input capture is only on one PIN that is why i was using interrpts . I wanted to use two pins

You can route both sensors signals to the same pin. The signals shouldn't be nearly simultaneous unless you are measuring light-speed velocities.

well how should I route both to the same pin ..I have dual op amps and some dual comparators would one of those work ?

A picture is worth . . .

I built a very simple input capture chronograph as a flash trigger, using not much more than a couple of photodiodes and a resistor (plus illuminator LEDs and optotriac).

bandmwhitt2013:
well how should I route both to the same pin ..I have dual op amps and some dual comparators would one of those work ?

If there's a will there's a way. Or you could use a Mega2560, it has two input captures.

well I have photodiodes and LDRs just for testing i used LDRs but i'm sure photodiodes are maybe faster ..maybe not don't know ..and I'm guessing the lm393 is faster than the lm358 dual op amp ..should I connect both negative inputs together and just use one POT to adjust sensitivity ? the lm393 will only sink so it will
have to trigger on negative edge if i use the comparator

well I have several options i guess i'm going for the simple yet most accurate approach I want to build a chronograph for my uncle who would be using a 22 cal or BOW but maybe slower or faster

bandmwhitt2013:
well I have photodiodes and LDRs just for testing i used LDRs but i'm sure photodiodes are maybe faster ..maybe not don't know ..and I'm guessing the lm393 is faster than the lm358 dual op amp ..should I connect both negative inputs together and just use one POT to adjust sensitivity ? the lm393 will only sink so it will
have to trigger on negative edge if i use the comparator

Why don't you stop guessing and do some research? Please post your schematic so we aren't discussing vague generalities.

but i'm sure photodiodes are maybe faster

Very, very much faster.

I know what a BAR is, but what is a BOW?

so your saying the LM393 is a lot faster than an op amp ? AWOL

you know shooting arrows LOL

I don't recall mentioning the LM393.

Oh, you mean a bow.

well .... I just need general info so there is no need to draw up a schematic

yea a 22 shoots around 1800 FPS and bows vary a lot