I am currently trying to write a Python application on our RevPi compact. Yes, I now know that the compact is no longer supported, but I wasn't aware of this when I bought it.
To the point. Most of the application is not time-critical, but within one execution, a pulse measurement is made via the digital IOs. Now, on the data sheet(https://revolutionpi.com/documentation/ ... g%C3%A4nge) it says that the analogue inputs are sampled with a maximum of 125ms and the digital ones can manage a fast 250us. Perfect, I thought. But now I'm trying to access the digital IOs relatively quickly, and I'm having a difficult time with it.
What I have tried:
1. Via the revpimodio2 (revpi.io.DI_0.value). The problem here is that the minimum cycle time is 5ms. When I read out the IOs via this, they are only updated every max. 5ms. And if I run the whole application with the 5ms, I keep encountering the exceeding error. At the moment, I only lower the cycle time for the measurement and then raise it again.
2. A quasi direct readout via “/dev/piControl0” the process image. Here, the limit seems to be 1ms (from test runs). Unfortunately, I don't understand where this comes from, or whether it can be changed to be faster? Does anyone here have any input? What controls how often the process image is written to piControl0?
What I also don't understand:
3. What is the use of a maximum possible hardware rate of 250us if I have no direct and fast access to the IO's in the SW to read it out? Or does I simply not see how to access it?
How do you access your IO's in a fast way?
Thank you for your help

Greetings Raphael