Does anyone have an example of a C# app that uses I2C devices in multiple threads? I'm having a bit of a problem with mine, it's one of those where if I single step it everything works and if I run it full sped everything messes up. The i2C traffic is actually getting corrupted (as viewed on my logic analyzer) which surprised me a bit. I kind of assumed that I2C operations would be atomic, but it looks like that's not necessarily the case. This clearly seems like a race condition.
So, if anyone has done multi-threaded I2C access, what do you need to do to ensure thread-safety?
I have some ideas on how to approach this but the documentation is a bit silent on threading requirements, so I thought I'd ask if anyone has already done it successfully before I go off down some dead ends