the pwm work good and the frequency counter confirm the exact frequency and its possible to stop it at a fixed point, now i need a second timer to count the y pulses other than 400) with a same time of x. The x train with 400 pulses do the work in: 400*300+300=240.000us. I need the same time for y, with pulses other than 400....