High frequency pulse counter working mechanism

Could you please describe working mechanism of high frequency pulse counter. After one pulse it get large random numbers.
Does it work based on rising edge or counts cycles in closed state?

Each transition through open circuit to closed circuit will cause a pulse. Be sure you are workign with dry contacts. If you are working with PNP or NPN type transistor type, or hall effect sensors you can try with reversing the polarity. Let me know what device you are using. and I can offer better suggestions.

Be aware of contact bounce as the dry contact closes, if you’re using a wire to open/close the inputs this could add noise to your results.

Dear Maurice,

I use T3-BB-ARM with the latest firmware, input number 29 (high speed) and range Counter 100Hz.
After a shorting of input (it is dry contact) I receive as a value something like -22121 (with a minus). After a second shorting value changes to positive one and so on.

Fixed high speed counter in rev49.5. High word and low word are inversed in recent version.

Thanks a lot! Works!

How to reset the counter from ModBus?

You should be able to just write to the value with a zero. Give it a try and report back. I am traveling just now or I would try it for you.

Maurice Duteau

Unfortunately it is read only. There is no reaction after writing to register 7547 (UI32 on T3-BB Arm).
And I think it could be much better not to multiply counter value by 1000 in ModBus registers. In DWORD type we have 4294967295 values, I think you use DINT divided by two WORD so it will be 2147483647. After multiply by 1000 it allow us to have just 2 147 483 results in counter.