I\'ve got a thread that\'s polling a piece of hardware.
while not hardware_is_ready(): pass process_data_from_hardware()
But there are
If you're doing this on *nix, you might find the select library useful. Kamaela also has a few components you may find useful, but it may require a bit of a paradigm change.