rtel wrote on Friday, November 12, 2004:
60K is still very fast. I’m not sure if it is possible. You presumable have to process each polled input and react somehow to changes.
portTICK_RATE_MS would be less than 1 - and as this is a integral variable this cannot be. However, this would not really matter as the constant is not used by the kernel - only the demo program as a convenient way of generating time values.
If setting 30KHz was possible you would then have to modify the kernel slightly to ensure that the poll task was woken every tick, and ensure that the poll task had completed and blocked again before the next tick. This could be done with a semaphore and a tick hook.
Alternatively, would it be possible to:
+ Have the input you are monitoring on an external interrupt so you need only process it when it’s state changes.
+ If these are the only function then maybe if you don’t use a kernel, have your calculation running in a continuous loop, and have the pin being polled in a simple timer ISR (if this can be done at 30KHz which is also a bit doubtfull).
+ Use an FPGA instead of a microcontroller.
+ Have a lower priority task poll the input - and have it preempted by the calculation?
+ Have the poll take place as a tick switch hook?