Reading status on pellet-burner

Hello. I've a little problem. I want to read the status of my pellet-burner. The problem is this (it's all on same input pin):

When it's not lit, it's off. When it's blinking with 2sec pulses ( ||||_|| ) it's waiting (the temp is ok) When it's blinking fast with 1 sec pulses ( _| || |_ ) it's try to fire. And when it's on whole time it's burning in full effect.

How is the best way to code? I want to check this and other inputs in mainloop and send status to a display.

Ihave a Idea to use 2 interrupt wich is using Falling and Raising on pulses and measure the time between them and set a variable and then in the mainloop check this variable.

There are other inputs to check but it's normal on/off.

Sorry for my 'english' :)

With pulses that long it would probably be easiest to just have a variable set to equal millis when high, then reset and read the difference when it goes low. It can just be part of the main program loop because there can be 999ms error and still get the correct state.