switch to port-based sample time with no direct feed-through from the inputs to the outputs.
rename the timeout parameter to sample time.
explicitly set the output sample times.
multirate compatible main function.