poll() versus spin on any()
Posted: Mon Oct 19, 2015 11:57 pm
What is to be gained by calling poll() versus spinning on any() for the current PyBoard peripherals? Does it reduce latency?
Related, I note that the CAN peripheral is not enabled as a stream. It would be a little strange, in that it has two receive fifo's, but I guess there would be one CAN stream interface and then after poll() the user would call both can_instance.any(0) and can_instance.any(1) to see where data might be found.
Also, I presume the can.rxcallback function runs at interrupt level, correct?
Related, I note that the CAN peripheral is not enabled as a stream. It would be a little strange, in that it has two receive fifo's, but I guess there would be one CAN stream interface and then after poll() the user would call both can_instance.any(0) and can_instance.any(1) to see where data might be found.
Also, I presume the can.rxcallback function runs at interrupt level, correct?