So you mean you expect 40 changes per second, or a scan class/tag group of 25ms? I didn’t notice the “40 Hz” in the original post. It’s a quite odd unit to use in this context.
That’s likely just too fast for OPC. According to the OPC specification, the OPC client can ask for a refresh rate, but the OPC server (which is probably your PLC, unless you have an intermediate serer) can ignore that rate and return results at a slower pace. Most PLC’s only send OPC values when there’s time left during their cycle. Even with a slow refresh rate, it’s possible the results will arrive with a delay when the PLC is busy.
100ms (or 10 Hz as you call it) is already quite fast for OPC.
But I don’t get why you are seeing duplicated values. Did you force the historian to write every 25ms? It shouldn’t get an OPC update, so it shouldn’t write to the database normally. I also don’t get how it seems to log in two groups both at 100ms but 26ms apart from each other.
Can you show the tag configurations (tag group settings, historian settings)?
But anyway, it looks like you will have to use a different method for logging this data. Like keeping a buffer in the PLC and storing it to a local file or using some other protocol.