mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-17 05:16:02 +00:00
00_HMUARTLGW.pm: deactivate firmware on close/dummy
git-svn-id: https://svn.fhem.de/fhem/trunk@13148 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
f2305d0885
commit
7c33fcb76c
@ -1716,6 +1716,9 @@ sub HMUARTLGW_Set($@)
|
||||
} elsif ($cmd eq "reopen") {
|
||||
HMUARTLGW_Reopen($hash);
|
||||
} elsif ($cmd eq "close") {
|
||||
#switch to bootloader to stop the module from interfering
|
||||
HMUARTLGW_send($hash, HMUARTLGW_OS_CHANGE_APP, HMUARTLGW_DST_OS)
|
||||
if ($hash->{DevState} > HMUARTLGW_STATE_ENTER_APP);
|
||||
HMUARTLGW_Undefine($hash, $name);
|
||||
readingsSingleUpdate($hash, "state", "closed", 1);
|
||||
$hash->{XmitOpen} = 0;
|
||||
@ -1845,6 +1848,9 @@ sub HMUARTLGW_Attr(@)
|
||||
} elsif ($aName eq "dummy") {
|
||||
if ($cmd eq "set") {
|
||||
if (!defined($attr{$name}{$aName})) {
|
||||
#switch to bootloader to stop the module from interfering
|
||||
HMUARTLGW_send($hash, HMUARTLGW_OS_CHANGE_APP, HMUARTLGW_DST_OS)
|
||||
if ($hash->{DevState} > HMUARTLGW_STATE_ENTER_APP);
|
||||
HMUARTLGW_Undefine($hash, $name);
|
||||
readingsSingleUpdate($hash, "state", "dummy", 1);
|
||||
HMUARTLGW_updateCondition($hash);
|
||||
|
Loading…
x
Reference in New Issue
Block a user