or you could use a very simple PIC or AVR chip to implement this with very little software work.
I would use an AVR chip if I were doing this. Something like the the ATTINY11-6PC which costs about half a dollar. It has one 8 bit counter built-in which should be adequate for your application.