mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 18:59:33 +00:00
wakeup devices obey autonomous messages
git-svn-id: https://svn.fhem.de/fhem/trunk@4362 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
e7dc434b9e
commit
33dacc9c32
@ -1581,12 +1581,17 @@ sub CUL_HM_parseCommon(@){#####################################################
|
||||
# VD wakes up with 8202
|
||||
# 9610
|
||||
|
||||
if( ((hex($mFlg) & 0xA2) == 0x82) &&
|
||||
(CUL_HM_getRxType($shash) & 0x08)){ #wakeup and process stack
|
||||
CUL_HM_appFromQ($shash->{NAME},"wu");# stack cmds if waiting
|
||||
if ($shash->{cmdStack}){
|
||||
CUL_HM_SndCmd($shash, '++A112'.CUL_HM_IOid($shash).$src);
|
||||
CUL_HM_ProcessCmdStack($shash);
|
||||
if(CUL_HM_getRxType($shash) & 0x08){ #wakeup device
|
||||
if((hex($mFlg) & 0xA2) == 0x82){ #wakeup signal
|
||||
CUL_HM_appFromQ($shash->{NAME},"wu");# stack cmds if waiting
|
||||
if ($shash->{cmdStack}){
|
||||
CUL_HM_SndCmd($shash, '++A112'.CUL_HM_IOid($shash).$src);
|
||||
CUL_HM_ProcessCmdStack($shash);
|
||||
}
|
||||
}
|
||||
elsif($shash->{helper}{prt}{sProc} != 1){ # no wakeup signal,
|
||||
# this is an autonom message send ACK but dont process further
|
||||
$shash->{helper}{prt}{sleeping} = 1 if(hex($mFlg) & 0x20) ;
|
||||
}
|
||||
}
|
||||
my $repeat;
|
||||
@ -3684,8 +3689,13 @@ sub CUL_HM_responseSetup($$) {#store all we need to handle the response
|
||||
}
|
||||
else{# no answer expected
|
||||
if($hash->{cmdStack} && scalar @{$hash->{cmdStack}}){
|
||||
CUL_HM_protState($hash,"CMDs_processing...");
|
||||
InternalTimer(gettimeofday()+.5, "CUL_HM_ProcessCmdStack", $hash, 0);
|
||||
if (!$hash->{helper}{prt}{sleeping}){
|
||||
CUL_HM_protState($hash,"CMDs_processing...");
|
||||
InternalTimer(gettimeofday()+.5, "CUL_HM_ProcessCmdStack", $hash, 0);
|
||||
}
|
||||
else{
|
||||
delete $hash->{helper}{prt}{sleeping};
|
||||
}
|
||||
}
|
||||
elsif(!$hash->{helper}{prt}{rspWait}{cmd}){
|
||||
CUL_HM_protState($hash,"CMDs_done");
|
||||
|
Loading…
Reference in New Issue
Block a user