QUOTE: I had an additional thought: if the logic resets the counter on the scan when the counter reaches 4, then if the counter trigger is still 1, it may count to 1 on the next scan.
That's what you said & as I pointed out if the trigger is still at 1 after a reset on the next scan it will not count, however, I believe the problem is that as the reset is directly after the count when it reaches 4 it will instantly reset so any logic before or after (assuming using the .DN bit or checking for C = 4).
So the simplest way is to reset the counter after the use of the DN bit or a compare.
Interesting though, I did a quick bit of logic in ladder where the counter was reset before using the equivelent of the .DN bit to set a Bit, when the counter value equalled 4 the counter reset so the bit was never set, when the reset was moved after using the .DN bit to set a bit it worked as expected (no surprises there), however,
I did the same logic using IEC Counters (these have a reset in the block call so it seems to indicate that it would reset the equivelent of the .DN bit before it was used to set the bit), however, it did not so no matter whether you evaluate the DN bit before or after a reset (you can reset the counter external to the counter function).
It appears (well in Mitsubishi) the IEC counter function works differently than the standard timer in ladder, cannot try it on ML1400 as it does not have IEC counters.
See attached picture (reset after evaluating the .DN bit equivelent).