From: Marc M. <ma...@me...> - 2009-07-20 02:44:12
|
Speaking of which, I've been reading the code to see how I can query my stat's current mode (i.e. not whether it's in cool mode, but whether it's currently sending the cool command to my thermostat). While reading, I noticed why I was getting those pauses in mh: Omnistat.pm: # send it to thermostat $main::Serial_Ports{Omnistat}{object}->write($cmd); # need to wait a bit for the reply sleep 2; # read response &main::check_for_generic_serial_data('Omnistat'); my $temp = $main::Serial_Ports{Omnistat}{data}; Err, what can we done to remove that sleep? The sleep can cause problems with insteon and other protocols. This is sepcfically a problem in my case because I query both my thermostats every minute, which causes 4 seconds lost every minute, which is quite bad. Can this be changed for a timer callback or somesuch? Thanks, Marc -- "A mouse is a device used to point at the xterm you want to type in" - A.S.R. Microsoft is to operating systems & security .... .... what McDonalds is to gourmet cooking Home page: http://marc.merlins.org/ |